Turn any idea, plan, or codebase into a beautiful interactive diagram. An agent skill for Claude Code, Codex, and more.
HTML agent-skillsai-agentsarchitecture-diagramclaude-codeclaude-skillscodexcoding-agentsdeepseek-harnessdeveloper-toolsdiagramsdiagrams-as-codedsh-pluginflowchartllmmermaidopencodesequence-diagramsoftware-architecturesystem-designvisualization
feat: add truthful configurable legends (#54)
tt-a1icc5576451a19
diff --git a/CHANGELOG.md b/CHANGELOG.mdindex 44c6e2b7..3381adab 100644--- a/CHANGELOG.md+++ b/CHANGELOG.md@@ -7,6 +7,7 @@ All notable changes are documented here. Format loosely follows [Keep a Changelo> Development identity: `v2.13.0-dev.0`. This checkout contains unreleased work and is not the published `v2.12.0` release.### Added+- **Truthful configurable legends.** All five typed renderers now resolve a strict additive `meta.legend` contract with `auto`, `all`, and `hidden` modes plus renderer-owned label and visibility overrides. The default legend names only semantic kinds present in typed IR; Lifecycle covers every valid state type, while Sequence/Dataflow message and flow keys remain visual-only unless exact node facts exist. Shared Unicode-aware measured rows keep labels aligned and bounded, custom wording reaches accessible Semantic Legend names without changing stable kinds or topology, and Architecture Delta classifies legend edits as presentation-only changes.- **Exact-ID Architecture Delta Review Navigator.** Every validated Architecture Delta proof now keeps a compact Overview / Previous / Review / Next strip above the unchanged three-state canvas and turns its deterministic authored-change list into native exact-ID controls. Selecting a component, relationship, or boundary highlights only matching `data-node-id`, `data-edge-id`, or derived boundary identity; one deliberate Review activation advances through the same stable order once at 1400ms per change, never loops, and yields to manual navigation, view changes, page hiding, print, or dynamic reduced motion. Generation and runtime validators require one unambiguous primary identity with the receipt's exact state and classification, otherwise the navigator fails closed while the static Before / Delta / After proof remains usable. Roving keyboard navigation, Overview/Escape cleanup, dark/light and all three presets add no URL, history, storage, schema, comparator inference, dependency, GitHub integration, risk claim, or mobile product surface.- **Architecture Delta / PR Proof.** The zero-dependency CLI now exposes `archify compare architecture <base.json> <head.json> [output.html] --json`: it validates both snapshots independently, pairs components and relationships only by authored stable IDs, classifies semantic, evidence, scope, topology, geometry, provenance, and presentation changes separately, and emits deterministic Before / Delta / After HTML plus a complete machine receipt. Removed nodes and relationships retain baseline geometry, moved nodes keep a `MOVE FROM` phantom, endpoint changes show old and new routes, and `+ / ~ / − / ↔` plus line patterns keep meaning independent of color or motion. Formatting, object-key, entity-order, `wraps`, and `sources` set changes preserve the semantic hash and artifact bytes; failures preserve the previous artifact. Repository mismatches, zero shared component IDs, missing relationship IDs, and ambiguous boundary keys fail closed. The proof says `AUTHORED SNAPSHOTS` or, after both repository-evidence gates pass, `REVISION-PINNED INPUTS`; it never claims risk, blast radius, safety, mergeability, or verified PR impact. No sixth diagram type, GitHub API, Git ref parser, LLM, Graphviz, hosted service, dependency, telemetry, or mobile product surface was added.- **Deployment Ownership Engineering Profile.** Architecture diagrams may opt into `meta.engineering_profile: "deployment-ownership"` when the user explicitly wants a fail-closed deployment review. The zero-dependency loader then requires named owners for every non-external component, exactly one region per workload, region and security-group boundaries, private placement for every database, one shared region per security group, and a real label for every connection that changes region/security-group membership. Human and JSON validate/deliver receipts name the passing profile; failures use stable diagnostic codes, exact subjects, evidence, and supported repairs. The Production Deployment proof now exercises the contract and publishes one compact Gallery receipt. The committed ZIP smoke is shared by Ubuntu, macOS, and Windows and runs doctor, all five validators, the deployment render/check path, atomic delivery, open fallback, and an invalid-schema rejection without installing dependencies. Profile-less v1 inputs remain unchanged, and the profile does not infer facts or claim repository/live-environment verification. No new renderer, diagram type, visual preset, dependency, hosted service, telemetry, or mobile product surface was added.diff --git a/CONTRIBUTING.md b/CONTRIBUTING.mdindex df8d0e99..11e8c6c4 100644--- a/CONTRIBUTING.md+++ b/CONTRIBUTING.md@@ -21,7 +21,7 @@ npm cinpm test```-During development, run the narrowest relevant test first, then the full suite before opening a pull request. Behavioral fixes should include a failing regression test that demonstrates the problem before the implementation changes.+During development, run the narrowest relevant test first, then the full suite before opening a pull request. Behavioral fixes should include a failing regression test that demonstrates the problem before the implementation changes. Cross-renderer contracts belong in one public CLI seam (`archify render`/`validate` against final SVG/HTML), not tests of private resolver helpers.## Bug fixesdiff --git a/archify.zip b/archify.zipindex 6796d76e..ae80a0e3 100644Binary files a/archify.zip and b/archify.zip differdiff --git a/archify/SKILL.md b/archify/SKILL.mdindex e356c649..2a5f24ef 100644--- a/archify/SKILL.md+++ b/archify/SKILL.md@@ -61,6 +61,7 @@ Read Mermaid for topology and meaning, then author fresh Archify JSON; do not me## Authoring invariants- One obvious main path; side branches leave the nearest main-path node. Remove low-value edges before adding routing controls.+- Omit `meta.legend` for the truthful `auto` default. When needed, use only `mode: auto|all|hidden` and renderer-supported `entries.<kind>.label|visible`; labels never change semantics.- Component types are `frontend`, `backend`, `database`, `cloud`, `security`, `messagebus`, and `external`; variants are `default`, `emphasis`, `security`, and `dashed`.- Spacing means clear gap, not center distance. For a relationship label, clear gap must exceed its measured mask width; otherwise omit the label or move it deliberately.- Automatic routes own their endpoint sides. A side is a direction contract: the first and final segment must leave/enter perpendicular to that side.diff --git a/archify/assets/template.html b/archify/assets/template.htmlindex 97ef1a08..aca07db6 100644--- a/archify/assets/template.html+++ b/archify/assets/template.html@@ -5399,6 +5399,7 @@});Array.prototype.forEach.call(clone.querySelectorAll('[data-legend-kind]'), function (el) {el.removeAttribute('data-legend-kind');+ el.removeAttribute('data-legend-label');el.removeAttribute('data-legend-count');el.removeAttribute('data-legend-zero');el.removeAttribute('data-legend-selected');@@ -12357,7 +12358,8 @@}entry.setAttribute('role', 'button');entry.setAttribute('tabindex', legendEntries.length ? '-1' : '0');- entry.setAttribute('aria-label', 'Inspect ' + fact.label + ', ' + count + ' node' + (count === 1 ? '' : 's'));+ var visibleLabel = entry.getAttribute('data-legend-label') || fact.label;+ entry.setAttribute('aria-label', 'Inspect ' + visibleLabel + ', ' + count + ' node' + (count === 1 ? '' : 's'));entry.setAttribute('aria-pressed', 'false');entry.setAttribute('aria-haspopup', 'dialog');entry.setAttribute('aria-controls', 'semantic-lens');diff --git a/archify/delta/architecture-delta.mjs b/archify/delta/architecture-delta.mjsindex fa3b8dd9..094bcd53 100644--- a/archify/delta/architecture-delta.mjs+++ b/archify/delta/architecture-delta.mjs@@ -201,6 +201,7 @@ function presentationChanged(base, head) {visual_preset: base.meta?.visual_preset,quality_profile: base.meta?.quality_profile,engineering_profile: base.meta?.engineering_profile,+ legend: base.meta?.legend,views: base.meta?.views,viewBox: base.meta?.viewBox,layout: base.layout,@@ -213,6 +214,7 @@ function presentationChanged(base, head) {visual_preset: head.meta?.visual_preset,quality_profile: head.meta?.quality_profile,engineering_profile: head.meta?.engineering_profile,+ legend: head.meta?.legend,views: head.meta?.views,viewBox: head.meta?.viewBox,layout: head.layout,diff --git a/archify/examples/dataflow-product-analytics.html b/archify/examples/dataflow-product-analytics.htmlindex b585c2fd..d86ebf25 100644--- a/archify/examples/dataflow-product-analytics.html+++ b/archify/examples/dataflow-product-analytics.html@@ -4784,15 +4784,29 @@</g><!-- Legend -->- <text x="214" y="704" class="t-primary" font-size="10" font-weight="600">Legend</text>- <path d="M 214 724 L 248 724" class="a-emphasis" stroke-width="1.8" marker-end="url(#arrowhead-emphasis)"/>- <text x="257" y="727" class="t-muted" font-size="8">primary data</text>- <path d="M 340 724 L 374 724" class="a-security" stroke-width="1.4" marker-end="url(#arrowhead-security)"/>- <text x="383" y="727" class="t-muted" font-size="8">policy / PII</text>- <path d="M 480 724 L 514 724" class="a-dashed" stroke-width="1.4" marker-end="url(#arrowhead-dashed)"/>- <text x="523" y="727" class="t-muted" font-size="8">async batch</text>- <rect x="625" y="716" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>- <text x="646" y="724" class="t-muted" font-size="8">data store</text>+ <g data-legend data-legend-bridge>+ <text x="40" y="704" class="t-primary" font-size="10" font-weight="600">Legend</text>+ <g data-legend-semantic-kind="emphasis" data-legend-x="40" data-legend-baseline="724" data-legend-width="103">+ <path d="M 40 721 L 74 721" class="a-emphasis" stroke-width="1.8" marker-end="url(#arrowhead-emphasis)"/>+ <text x="83" y="724" class="t-muted" font-size="8">primary data</text>+ </g>+ <g data-legend-semantic-kind="security" data-legend-x="165" data-legend-baseline="724" data-legend-width="103">+ <path d="M 165 721 L 199 721" class="a-security" stroke-width="1.4" marker-end="url(#arrowhead-security)"/>+ <text x="208" y="724" class="t-muted" font-size="8">policy / PII</text>+ </g>+ <g data-legend-semantic-kind="dashed" data-legend-x="290" data-legend-baseline="724" data-legend-width="98">+ <path d="M 290 721 L 324 721" class="a-dashed" stroke-width="1.4" marker-end="url(#arrowhead-dashed)"/>+ <text x="333" y="724" class="t-muted" font-size="8">async batch</text>+ </g>+ <g data-legend-semantic-kind="database" data-legend-kind="database" data-legend-label="data store" data-legend-x="410" data-legend-baseline="724" data-legend-width="92">+ <rect x="410" y="716" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>+ <text x="431" y="724" class="t-muted" font-size="8">data store</text>+ </g>+ <g data-legend-semantic-kind="default" data-legend-x="524" data-legend-baseline="724" data-legend-width="88">+ <path d="M 524 721 L 558 721" class="a-default" stroke-width="1.4" marker-end="url(#arrowhead)"/>+ <text x="567" y="724" class="t-muted" font-size="8">data flow</text>+ </g>+ </g></svg><p class="intent-trace-status no-print" id="intent-trace-status" role="status" aria-live="polite" aria-atomic="true"></p><div class="share-chapter-cue no-print" id="share-chapter-cue" hidden role="status" aria-live="polite">@@ -5497,6 +5511,7 @@});Array.prototype.forEach.call(clone.querySelectorAll('[data-legend-kind]'), function (el) {el.removeAttribute('data-legend-kind');+ el.removeAttribute('data-legend-label');el.removeAttribute('data-legend-count');el.removeAttribute('data-legend-zero');el.removeAttribute('data-legend-selected');@@ -12455,7 +12470,8 @@}entry.setAttribute('role', 'button');entry.setAttribute('tabindex', legendEntries.length ? '-1' : '0');- entry.setAttribute('aria-label', 'Inspect ' + fact.label + ', ' + count + ' node' + (count === 1 ? '' : 's'));+ var visibleLabel = entry.getAttribute('data-legend-label') || fact.label;+ entry.setAttribute('aria-label', 'Inspect ' + visibleLabel + ', ' + count + ' node' + (count === 1 ? '' : 's'));entry.setAttribute('aria-pressed', 'false');entry.setAttribute('aria-haspopup', 'dialog');entry.setAttribute('aria-controls', 'semantic-lens');diff --git a/archify/examples/lifecycle-agent-run.html b/archify/examples/lifecycle-agent-run.htmlindex 7a7580bc..5bb5d2ec 100644--- a/archify/examples/lifecycle-agent-run.html+++ b/archify/examples/lifecycle-agent-run.html@@ -4729,24 +4729,32 @@<!-- Legend -->- <g data-legend-bridge>- <text x="220" y="542" class="t-primary" font-size="10" font-weight="600">Legend</text>- <g data-legend-kind="active">- <rect x="220" y="554" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>- <text x="240" y="562" class="t-muted" font-size="7">active state</text>- </g>- <g data-legend-kind="waiting">- <rect x="325" y="554" width="14" height="9" rx="2" class="c-cloud" stroke-width="1"/>- <text x="345" y="562" class="t-muted" font-size="7">waiting</text>- </g>- <g data-legend-kind="success">- <rect x="415" y="554" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>- <text x="435" y="562" class="t-muted" font-size="7">terminal success</text>- </g>- <g data-legend-kind="failure">- <rect x="560" y="554" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>- <text x="580" y="562" class="t-muted" font-size="7">failure / exit</text>- </g>+ <g data-legend data-legend-bridge>+ <text x="40" y="604" class="t-primary" font-size="10" font-weight="600">Legend</text>+ <g data-legend-semantic-kind="start" data-legend-kind="start" data-legend-label="start" data-legend-x="40" data-legend-baseline="624" data-legend-width="67">+ <rect x="40" y="616" width="14" height="9" rx="2" class="c-frontend" stroke-width="1"/>+ <text x="61" y="624" class="t-muted" font-size="8">start</text>+ </g>+ <g data-legend-semantic-kind="active" data-legend-kind="active" data-legend-label="active state" data-legend-x="129" data-legend-baseline="624" data-legend-width="102">+ <rect x="129" y="616" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>+ <text x="150" y="624" class="t-muted" font-size="8">active state</text>+ </g>+ <g data-legend-semantic-kind="waiting" data-legend-kind="waiting" data-legend-label="waiting" data-legend-x="253" data-legend-baseline="624" data-legend-width="77">+ <rect x="253" y="616" width="14" height="9" rx="2" class="c-cloud" stroke-width="1"/>+ <text x="274" y="624" class="t-muted" font-size="8">waiting</text>+ </g>+ <g data-legend-semantic-kind="decision" data-legend-kind="decision" data-legend-label="decision" data-legend-x="352" data-legend-baseline="624" data-legend-width="82">+ <rect x="352" y="616" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>+ <text x="373" y="624" class="t-muted" font-size="8">decision</text>+ </g>+ <g data-legend-semantic-kind="success" data-legend-kind="success" data-legend-label="terminal success" data-legend-x="456" data-legend-baseline="624" data-legend-width="122">+ <rect x="456" y="616" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>+ <text x="477" y="624" class="t-muted" font-size="8">terminal success</text>+ </g>+ <g data-legend-semantic-kind="failure" data-legend-kind="failure" data-legend-label="failure / exit" data-legend-x="600" data-legend-baseline="624" data-legend-width="112">+ <rect x="600" y="616" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>+ <text x="621" y="624" class="t-muted" font-size="8">failure / exit</text>+ </g></g></svg><p class="intent-trace-status no-print" id="intent-trace-status" role="status" aria-live="polite" aria-atomic="true"></p>@@ -5452,6 +5460,7 @@});Array.prototype.forEach.call(clone.querySelectorAll('[data-legend-kind]'), function (el) {el.removeAttribute('data-legend-kind');+ el.removeAttribute('data-legend-label');el.removeAttribute('data-legend-count');el.removeAttribute('data-legend-zero');el.removeAttribute('data-legend-selected');@@ -12410,7 +12419,8 @@}entry.setAttribute('role', 'button');entry.setAttribute('tabindex', legendEntries.length ? '-1' : '0');- entry.setAttribute('aria-label', 'Inspect ' + fact.label + ', ' + count + ' node' + (count === 1 ? '' : 's'));+ var visibleLabel = entry.getAttribute('data-legend-label') || fact.label;+ entry.setAttribute('aria-label', 'Inspect ' + visibleLabel + ', ' + count + ' node' + (count === 1 ? '' : 's'));entry.setAttribute('aria-pressed', 'false');entry.setAttribute('aria-haspopup', 'dialog');entry.setAttribute('aria-controls', 'semantic-lens');diff --git a/archify/examples/sequence-cache-miss-request.html b/archify/examples/sequence-cache-miss-request.htmlindex d68ad688..4ba124e4 100644--- a/archify/examples/sequence-cache-miss-request.html+++ b/archify/examples/sequence-cache-miss-request.html@@ -4799,15 +4799,29 @@</g><!-- Legend -->- <text x="150" y="686" class="t-primary" font-size="10" font-weight="600">Legend</text>- <path d="M 150 706 L 184 706" class="a-emphasis" stroke-width="1.8" marker-end="url(#arrowhead-emphasis)"/>- <text x="193" y="709" class="t-muted" font-size="8">request</text>- <path d="M 270 706 L 304 706" class="a-default" stroke-width="1.4" stroke-dasharray="3,5" marker-end="url(#arrowhead)"/>- <text x="313" y="709" class="t-muted" font-size="8">return</text>- <path d="M 385 706 L 419 706" class="a-security" stroke-width="1.4" marker-end="url(#arrowhead-security)"/>- <text x="428" y="709" class="t-muted" font-size="8">security</text>- <path d="M 530 706 L 564 706" class="a-dashed" stroke-width="1.4" marker-end="url(#arrowhead-dashed)"/>- <text x="573" y="709" class="t-muted" font-size="8">async trace</text>+ <g data-legend>+ <text x="40" y="686" class="t-primary" font-size="10" font-weight="600">Legend</text>+ <g data-legend-semantic-kind="emphasis" data-legend-x="40" data-legend-baseline="706" data-legend-width="78">+ <path d="M 40 703 L 74 703" class="a-emphasis" stroke-width="1.8" marker-end="url(#arrowhead-emphasis)"/>+ <text x="83" y="706" class="t-muted" font-size="8">request</text>+ </g>+ <g data-legend-semantic-kind="return" data-legend-x="140" data-legend-baseline="706" data-legend-width="73">+ <path d="M 140 703 L 174 703" class="a-default" stroke-width="1.4" stroke-dasharray="3,5" marker-end="url(#arrowhead)"/>+ <text x="183" y="706" class="t-muted" font-size="8">return</text>+ </g>+ <g data-legend-semantic-kind="security" data-legend-x="235" data-legend-baseline="706" data-legend-width="83">+ <path d="M 235 703 L 269 703" class="a-security" stroke-width="1.4" marker-end="url(#arrowhead-security)"/>+ <text x="278" y="706" class="t-muted" font-size="8">security</text>+ </g>+ <g data-legend-semantic-kind="dashed" data-legend-x="340" data-legend-baseline="706" data-legend-width="98">+ <path d="M 340 703 L 374 703" class="a-dashed" stroke-width="1.4" marker-end="url(#arrowhead-dashed)"/>+ <text x="383" y="706" class="t-muted" font-size="8">async trace</text>+ </g>+ <g data-legend-semantic-kind="default" data-legend-x="460" data-legend-baseline="706" data-legend-width="118">+ <path d="M 460 703 L 494 703" class="a-default" stroke-width="1.4" marker-end="url(#arrowhead)"/>+ <text x="503" y="706" class="t-muted" font-size="8">default message</text>+ </g>+ </g></svg><p class="intent-trace-status no-print" id="intent-trace-status" role="status" aria-live="polite" aria-atomic="true"></p><div class="share-chapter-cue no-print" id="share-chapter-cue" hidden role="status" aria-live="polite">@@ -5512,6 +5526,7 @@});Array.prototype.forEach.call(clone.querySelectorAll('[data-legend-kind]'), function (el) {el.removeAttribute('data-legend-kind');+ el.removeAttribute('data-legend-label');el.removeAttribute('data-legend-count');el.removeAttribute('data-legend-zero');el.removeAttribute('data-legend-selected');@@ -12470,7 +12485,8 @@}entry.setAttribute('role', 'button');entry.setAttribute('tabindex', legendEntries.length ? '-1' : '0');- entry.setAttribute('aria-label', 'Inspect ' + fact.label + ', ' + count + ' node' + (count === 1 ? '' : 's'));+ var visibleLabel = entry.getAttribute('data-legend-label') || fact.label;+ entry.setAttribute('aria-label', 'Inspect ' + visibleLabel + ', ' + count + ' node' + (count === 1 ? '' : 's'));entry.setAttribute('aria-pressed', 'false');entry.setAttribute('aria-haspopup', 'dialog');entry.setAttribute('aria-controls', 'semantic-lens');diff --git a/archify/examples/web-app-rendered.html b/archify/examples/web-app-rendered.htmlindex 6118f90a..b655a35e 100644--- a/archify/examples/web-app-rendered.html+++ b/archify/examples/web-app-rendered.html@@ -4737,31 +4737,31 @@<!-- Legend -->- <g data-legend-bridge>- <text x="40" y="559" class="t-primary" font-size="9" font-weight="600">Legend</text>- <g data-legend-kind="external">- <rect x="40" y="564" width="14" height="9" rx="2" class="c-external" stroke-width="1"/>- <text x="60" y="572" class="t-muted" font-size="8">External</text>+ <g data-legend data-legend-bridge>+ <text x="40" y="552" class="t-primary" font-size="10" font-weight="600">Legend</text>+ <g data-legend-semantic-kind="backend" data-legend-kind="backend" data-legend-label="Backend" data-legend-x="40" data-legend-baseline="572" data-legend-width="77">+ <rect x="40" y="564" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>+ <text x="61" y="572" class="t-muted" font-size="8">Backend</text></g>- <g data-legend-kind="security">- <rect x="144" y="564" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>- <text x="164" y="572" class="t-muted" font-size="8">Security</text>+ <g data-legend-semantic-kind="database" data-legend-kind="database" data-legend-label="Database" data-legend-x="139" data-legend-baseline="572" data-legend-width="82">+ <rect x="139" y="564" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>+ <text x="160" y="572" class="t-muted" font-size="8">Database</text></g>- <g data-legend-kind="cloud">- <rect x="248" y="564" width="14" height="9" rx="2" class="c-cloud" stroke-width="1"/>- <text x="268" y="572" class="t-muted" font-size="8">Cloud</text>+ <g data-legend-semantic-kind="cloud" data-legend-kind="cloud" data-legend-label="Cloud" data-legend-x="243" data-legend-baseline="572" data-legend-width="67">+ <rect x="243" y="564" width="14" height="9" rx="2" class="c-cloud" stroke-width="1"/>+ <text x="264" y="572" class="t-muted" font-size="8">Cloud</text></g>- <g data-legend-kind="backend">- <rect x="337" y="564" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>- <text x="357" y="572" class="t-muted" font-size="8">Backend</text>+ <g data-legend-semantic-kind="security" data-legend-kind="security" data-legend-label="Security" data-legend-x="332" data-legend-baseline="572" data-legend-width="82">+ <rect x="332" y="564" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>+ <text x="353" y="572" class="t-muted" font-size="8">Security</text></g>- <g data-legend-kind="database">- <rect x="436" y="564" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>- <text x="456" y="572" class="t-muted" font-size="8">Database</text>+ <g data-legend-semantic-kind="messagebus" data-legend-kind="messagebus" data-legend-label="Message bus" data-legend-x="436" data-legend-baseline="572" data-legend-width="97">+ <rect x="436" y="564" width="14" height="9" rx="2" class="c-messagebus" stroke-width="1"/>+ <text x="457" y="572" class="t-muted" font-size="8">Message bus</text></g>- <g data-legend-kind="messagebus">- <rect x="540" y="564" width="14" height="9" rx="2" class="c-messagebus" stroke-width="1"/>- <text x="560" y="572" class="t-muted" font-size="8">Message bus</text>+ <g data-legend-semantic-kind="external" data-legend-kind="external" data-legend-label="External" data-legend-x="555" data-legend-baseline="572" data-legend-width="82">+ <rect x="555" y="564" width="14" height="9" rx="2" class="c-external" stroke-width="1"/>+ <text x="576" y="572" class="t-muted" font-size="8">External</text></g></g></svg>@@ -5466,6 +5466,7 @@});Array.prototype.forEach.call(clone.querySelectorAll('[data-legend-kind]'), function (el) {el.removeAttribute('data-legend-kind');+ el.removeAttribute('data-legend-label');el.removeAttribute('data-legend-count');el.removeAttribute('data-legend-zero');el.removeAttribute('data-legend-selected');@@ -12424,7 +12425,8 @@}entry.setAttribute('role', 'button');entry.setAttribute('tabindex', legendEntries.length ? '-1' : '0');- entry.setAttribute('aria-label', 'Inspect ' + fact.label + ', ' + count + ' node' + (count === 1 ? '' : 's'));+ var visibleLabel = entry.getAttribute('data-legend-label') || fact.label;+ entry.setAttribute('aria-label', 'Inspect ' + visibleLabel + ', ' + count + ' node' + (count === 1 ? '' : 's'));entry.setAttribute('aria-pressed', 'false');entry.setAttribute('aria-haspopup', 'dialog');entry.setAttribute('aria-controls', 'semantic-lens');diff --git a/archify/examples/workflow-agent-tool-call-rendered.html b/archify/examples/workflow-agent-tool-call-rendered.htmlindex 35c7c1a1..1d8e87b2 100644--- a/archify/examples/workflow-agent-tool-call-rendered.html+++ b/archify/examples/workflow-agent-tool-call-rendered.html@@ -4800,28 +4800,36 @@</g><!-- Legend -->- <g data-legend-bridge>- <text x="175" y="800" class="t-primary" font-size="10" font-weight="600">Legend</text>- <g data-legend-kind="frontend">- <rect x="175" y="812" width="14" height="9" rx="2" class="c-frontend" stroke-width="1"/>- <text x="195" y="820" class="t-muted" font-size="7">User UI</text>- </g>- <g data-legend-kind="backend">- <rect x="260" y="812" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>- <text x="280" y="820" class="t-muted" font-size="7">Agent logic</text>- </g>- <g data-legend-kind="security">- <rect x="370" y="812" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>- <text x="390" y="820" class="t-muted" font-size="7">Policy</text>- </g>- <g data-legend-kind="messagebus">- <rect x="455" y="812" width="14" height="9" rx="2" class="c-messagebus" stroke-width="1"/>- <text x="475" y="820" class="t-muted" font-size="7">Tool action</text>- </g>- <g data-legend-kind="database">- <rect x="565" y="812" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>- <text x="585" y="820" class="t-muted" font-size="7">Context / trace</text>- </g>+ <g data-legend data-legend-bridge>+ <text x="20" y="800" class="t-primary" font-size="10" font-weight="600">Legend</text>+ <g data-legend-semantic-kind="frontend" data-legend-kind="frontend" data-legend-label="User UI" data-legend-x="20" data-legend-baseline="820" data-legend-width="73">+ <rect x="20" y="812" width="14" height="9" rx="2" class="c-frontend" stroke-width="1"/>+ <text x="41" y="820" class="t-muted" font-size="7">User UI</text>+ </g>+ <g data-legend-semantic-kind="backend" data-legend-kind="backend" data-legend-label="Agent logic" data-legend-x="100" data-legend-baseline="820" data-legend-width="90">+ <rect x="100" y="812" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>+ <text x="121" y="820" class="t-muted" font-size="7">Agent logic</text>+ </g>+ <g data-legend-semantic-kind="security" data-legend-kind="security" data-legend-label="Policy" data-legend-x="197" data-legend-baseline="820" data-legend-width="69">+ <rect x="197" y="812" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>+ <text x="218" y="820" class="t-muted" font-size="7">Policy</text>+ </g>+ <g data-legend-semantic-kind="messagebus" data-legend-kind="messagebus" data-legend-label="Tool action" data-legend-x="273" data-legend-baseline="820" data-legend-width="90">+ <rect x="273" y="812" width="14" height="9" rx="2" class="c-messagebus" stroke-width="1"/>+ <text x="294" y="820" class="t-muted" font-size="7">Tool action</text>+ </g>+ <g data-legend-semantic-kind="database" data-legend-kind="database" data-legend-label="Context / trace" data-legend-x="370" data-legend-baseline="820" data-legend-width="108">+ <rect x="370" y="812" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>+ <text x="391" y="820" class="t-muted" font-size="7">Context / trace</text>+ </g>+ <g data-legend-semantic-kind="cloud" data-legend-kind="cloud" data-legend-label="Cloud service" data-legend-x="485" data-legend-baseline="820" data-legend-width="99">+ <rect x="485" y="812" width="14" height="9" rx="2" class="c-cloud" stroke-width="1"/>+ <text x="506" y="820" class="t-muted" font-size="7">Cloud service</text>+ </g>+ <g data-legend-semantic-kind="external" data-legend-kind="external" data-legend-label="External system" data-legend-x="591" data-legend-baseline="820" data-legend-width="108">+ <rect x="591" y="812" width="14" height="9" rx="2" class="c-external" stroke-width="1"/>+ <text x="612" y="820" class="t-muted" font-size="7">External system</text>+ </g></g></svg><p class="intent-trace-status no-print" id="intent-trace-status" role="status" aria-live="polite" aria-atomic="true"></p>@@ -5530,6 +5538,7 @@});Array.prototype.forEach.call(clone.querySelectorAll('[data-legend-kind]'), function (el) {el.removeAttribute('data-legend-kind');+ el.removeAttribute('data-legend-label');el.removeAttribute('data-legend-count');el.removeAttribute('data-legend-zero');el.removeAttribute('data-legend-selected');@@ -12488,7 +12497,8 @@}entry.setAttribute('role', 'button');entry.setAttribute('tabindex', legendEntries.length ? '-1' : '0');- entry.setAttribute('aria-label', 'Inspect ' + fact.label + ', ' + count + ' node' + (count === 1 ? '' : 's'));+ var visibleLabel = entry.getAttribute('data-legend-label') || fact.label;+ entry.setAttribute('aria-label', 'Inspect ' + visibleLabel + ', ' + count + ' node' + (count === 1 ? '' : 's'));entry.setAttribute('aria-pressed', 'false');entry.setAttribute('aria-haspopup', 'dialog');entry.setAttribute('aria-controls', 'semantic-lens');diff --git a/archify/references/authoring-contract.md b/archify/references/authoring-contract.mdindex ccb53f19..9d80294d 100644--- a/archify/references/authoring-contract.md+++ b/archify/references/authoring-contract.md@@ -12,6 +12,25 @@ Read both the mode schema and `schemas/common.schema.json`. The mode schemas useDo not invent fields. Use the nearest matching example for structure, then author fresh IDs, wording, facts, and layout.+## Legend contract++Omit `meta.legend` for the truthful default: `auto` lists only semantic kinds+present in typed IR. Use `mode: "all"` for a renderer reference or+`mode: "hidden"` to remove the full legend. Under `entries`, only keys listed+by the selected mode schema are valid; each key accepts `label`, `visible`, or+both. `visible: true` may show an unused supported convention, while+`visible: false` hides it. `hidden` cannot be overridden.++A label override changes reader wording only. Never infer a kind from prose or+use the legend to compensate for missing nodes, states, messages, or flows.+Long labels are measured and wrap into deterministic rows. Architecture's+implicit automatic viewBox grows from that same measured footprint. For+backwards compatibility, a legacy document with no `meta.legend` may omit an+implicit auto legend that cannot fit its explicit viewBox; this never changes+its typed topology. Adding `meta.legend` makes the presentation intentional and+strict: if its resolved labels cannot fit the authored viewBox, shorten or hide+them, or widen the viewBox using the emitted diagnostic.+## Executable geometry rules- Node anchors are side midpoints. `left`/`right` change the horizontal endpoint; `top`/`bottom` change the vertical endpoint.diff --git a/archify/renderers/architecture/render-architecture.mjs b/archify/renderers/architecture/render-architecture.mjsindex ba27666a..2e484b97 100644--- a/archify/renderers/architecture/render-architecture.mjs+++ b/archify/renderers/architecture/render-architecture.mjs@@ -4,6 +4,7 @@ import { esc, renderDefinitions, renderSemanticSigil, textUnits } from '../shareimport { animateAttr, focusEdgeAttrs, focusNodeAttrs, focusNodeTitle, loadDiagram, writeDiagram, svgAccessibleText, svgRootAttrs } from '../shared/cli.mjs';import { componentBox, boundaryBox, connectionPath } from '../shared/layout-report.mjs';import { throwDiagnosticProblems } from '../shared/diagnostics.mjs';+import { legendFootprint, relationshipLegendObstacles, resolveLegend, renderLegend as renderResolvedLegend } from '../shared/legend.mjs';import { gridLayout, resolveComponentPos, validateGridPlacement } from './grid.mjs';import {asArray,@@ -60,6 +61,16 @@ const layout = {legendH: 28,};+const LEGEND_CATALOG = [+ ['frontend', 'Frontend'],+ ['backend', 'Backend'],+ ['database', 'Database'],+ ['cloud', 'Cloud'],+ ['security', 'Security'],+ ['messagebus', 'Message bus'],+ ['external', 'External'],+].map(([kind, label]) => ({ kind, label }));+// ---- Measure components from free coordinates --------------------------------function measureComponent(c) {const [x, y] = resolveComponentPos(c, grid);@@ -111,7 +122,13 @@ function componentContext(component) {return scopes.length ? scopes.join(' › ') : 'Architecture component';}-// ---- Auto viewBox: fit all geometry + a legend row --------------------------+const architectureLegendEntries = resolveLegend(+ arch.meta?.legend,+ LEGEND_CATALOG,+ new Set([...components.values()].map((component) => component.type)),+);++// ---- Auto viewBox: fit all geometry + the measured resolved legend ----------function autoViewBox() {let maxX = 0;let maxY = 0;@@ -123,9 +140,20 @@ function autoViewBox() {maxX = Math.max(maxX, b.x + b.width);maxY = Math.max(maxY, b.y + b.height);}++ let width = Math.ceil(maxX + layout.margin);+ let footprint = legendFootprint(architectureLegendEntries, {+ width: Math.max(1, width - layout.margin * 2),+ });+ if (footprint.minWidth > width - layout.margin * 2) {+ width = Math.ceil(footprint.minWidth + layout.margin * 2);+ footprint = legendFootprint(architectureLegendEntries, {+ width: width - layout.margin * 2,+ });+ }return [- Math.ceil(maxX + layout.margin),- Math.ceil(maxY + layout.margin + layout.legendH),+ width,+ Math.ceil(maxY + layout.margin + layout.legendH + footprint.extraHeight),];}@@ -603,30 +631,35 @@ function renderComponent(c) {</g>`;}-// Auto legend: one swatch per component type actually used, left to right.-const TYPE_LABELS = {- frontend: 'Frontend', backend: 'Backend', database: 'Database', cloud: 'Cloud',- security: 'Security', messagebus: 'Message bus', external: 'External',-};function renderLegend() {- const used = [];- const seen = new Set();- for (const c of components.values()) {- if (!seen.has(c.type)) { seen.add(c.type); used.push(c.type); }- }- const y = legendY();- let x = layout.margin;- const parts = [' <g data-legend-bridge>',- ` <text x="${x}" y="${y - 13}" class="t-primary" font-size="9" font-weight="600">Legend</text>`];- for (const type of used) {- parts.push(` <g data-legend-kind="${esc(type)}">`);- parts.push(` <rect x="${x}" y="${y - 8}" width="14" height="9" rx="2" class="${componentFill[type] || 'c-external'}" stroke-width="1"/>`);- parts.push(` <text x="${x + 20}" y="${y}" class="t-muted" font-size="8">${TYPE_LABELS[type] || type}</text>`);- parts.push(' </g>');- x += 30 + (textUnits(TYPE_LABELS[type] || type) * 5 + 34);- }- parts.push(' </g>');- return parts.join('\n');+ const entries = architectureLegendEntries;+ const relationshipObstacles = relationshipLegendObstacles(arch.connections, {+ pointsFor: (connection) => pathFor(connection).points,+ labelRectFor: (connection) => {+ if (!connection.label) return null;+ const [x, y] = labelPoint(connection, pathFor(connection).points);+ const width = Math.max(30, textUnits(connection.label) * 4.8 + 10);+ return { x: x - width / 2, y: y - 10, width, height: 14 };+ },+ });+ const contentBottom = Math.max(+ 0,+ ...[...components.values()].map((component) => component.y + component.height),+ ...boundaries.map((boundary) => boundary.y + boundary.height),+ );+ return renderResolvedLegend({+ entries,+ layout: {+ x: layout.margin,+ baselineY: legendY(),+ width: viewBox[0] - layout.margin * 2,+ minTitleY: contentBottom + 8,+ obstacles: relationshipObstacles,+ unfit: arch.meta?.legend === undefined ? 'hide' : 'error',+ diagramType: 'architecture',+ },+ renderSwatch: (entry) => `<rect x="${entry.x}" y="${entry.baseline - 8}" width="14" height="9" rx="2" class="${componentFill[entry.kind] || 'c-external'}" stroke-width="1"/>`,+ });}function renderSvg() {diff --git a/archify/renderers/dataflow/README.md b/archify/renderers/dataflow/README.mdindex d50d9d47..41186472 100644--- a/archify/renderers/dataflow/README.md+++ b/archify/renderers/dataflow/README.md@@ -42,6 +42,18 @@ The schema lives at:archify/schemas/dataflow.schema.json```+## Legend++The default visual legend derives kinds from `flows[].variant` (omitting+`variant` means `default`) and adds `database` only when a database node exists.+Supported `meta.legend.entries` keys, in stable order, are `emphasis`,+`security`, `dashed`, `database`, and `default`. Flow variants remain+visual-only because Archify has no compiled edge-kind facts in this slice. A+present `database` entry is different: it comes from exact+`nodes[].type: "database"` facts, so it publishes the normal Semantic Legend+count, accessible name, and keyboard interaction. Forcing `database` visible+without a database node keeps it visual-only.+## Layout budget| Constant | Value |diff --git a/archify/renderers/dataflow/render-dataflow.mjs b/archify/renderers/dataflow/render-dataflow.mjsindex 8d4defb8..743d308f 100644--- a/archify/renderers/dataflow/render-dataflow.mjs+++ b/archify/renderers/dataflow/render-dataflow.mjs@@ -3,6 +3,7 @@ import { fileURLToPath } from 'node:url';import { esc, renderDefinitions, renderSemanticSigil, textUnits } from '../shared/utils.mjs';import { animateAttr, focusEdgeAttrs, focusNodeAttrs, focusNodeTitle, loadDiagram, writeDiagram, svgAccessibleText, svgRootAttrs } from '../shared/cli.mjs';import { throwDiagnosticProblems } from '../shared/diagnostics.mjs';+import { resolveLegend, renderLegend as renderResolvedLegend } from '../shared/legend.mjs';import {asArray,isFinitePoint,@@ -360,17 +361,32 @@ function renderFlowLabel(flow, index) {</g>`;}+const LEGEND_CATALOG = [+ { kind: 'emphasis', label: 'primary data', className: 'a-emphasis', marker: 'arrowhead-emphasis', strokeWidth: 1.8, swatchWidth: 34, swatchGap: 9, interactive: false },+ { kind: 'security', label: 'policy / PII', className: 'a-security', marker: 'arrowhead-security', swatchWidth: 34, swatchGap: 9, interactive: false },+ { kind: 'dashed', label: 'async batch', className: 'a-dashed', marker: 'arrowhead-dashed', swatchWidth: 34, swatchGap: 9, interactive: false },+ { kind: 'database', label: 'data store' },+ { kind: 'default', label: 'data flow', className: 'a-default', marker: 'arrowhead', swatchWidth: 34, swatchGap: 9, interactive: false },+];+function renderLegend() {- const y = viewBox[1] - 36;- return ` <text x="214" y="${y - 20}" class="t-primary" font-size="10" font-weight="600">Legend</text>- <path d="M 214 ${y} L 248 ${y}" class="a-emphasis" stroke-width="1.8" marker-end="url(#arrowhead-emphasis)"/>- <text x="257" y="${y + 3}" class="t-muted" font-size="8">primary data</text>- <path d="M 340 ${y} L 374 ${y}" class="a-security" stroke-width="1.4" marker-end="url(#arrowhead-security)"/>- <text x="383" y="${y + 3}" class="t-muted" font-size="8">policy / PII</text>- <path d="M 480 ${y} L 514 ${y}" class="a-dashed" stroke-width="1.4" marker-end="url(#arrowhead-dashed)"/>- <text x="523" y="${y + 3}" class="t-muted" font-size="8">async batch</text>- <rect x="625" y="${y - 8}" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>- <text x="646" y="${y}" class="t-muted" font-size="8">data store</text>`;+ const presentKinds = new Set(asArray(dataflow.flows).map((flow) => flow.variant || 'default'));+ if ([...nodes.values()].some((node) => node.type === 'database')) presentKinds.add('database');+ const entries = resolveLegend(dataflow.meta?.legend, LEGEND_CATALOG, presentKinds);+ return renderResolvedLegend({+ entries,+ layout: {+ x: 40,+ baselineY: viewBox[1] - 36,+ width: viewBox[0] - 80,+ minTitleY: viewBox[1] - 66,+ unfit: dataflow.meta?.legend === undefined ? 'hide' : 'error',+ diagramType: 'dataflow',+ },+ renderSwatch: (entry) => entry.kind === 'database'+ ? `<rect x="${entry.x}" y="${entry.baseline - 8}" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>`+ : `<path d="M ${entry.x} ${entry.baseline - 3} L ${entry.x + 34} ${entry.baseline - 3}" class="${entry.className}" stroke-width="${entry.strokeWidth || 1.4}" marker-end="url(#${entry.marker})"/>`,+ });}function renderSvg() {diff --git a/archify/renderers/lifecycle/README.md b/archify/renderers/lifecycle/README.mdindex c170c4d4..bbbe07fc 100644--- a/archify/renderers/lifecycle/README.md+++ b/archify/renderers/lifecycle/README.md@@ -46,6 +46,14 @@ The schema lives at:archify/schemas/lifecycle.schema.json```+## Legend++The default legend derives kinds from `states[].type`. Supported+`meta.legend.entries` keys, in stable order, are `start`, `active`, `waiting`,+`decision`, `success`, `failure`, `neutral`, and `external`. Labels and+visibility may be overridden through the shared legend contract; only kinds+backed by rendered states receive Semantic Legend controls.+## Layout budget| Band | Lane id | Top y | Column centers | Default state |@@ -56,11 +64,11 @@ archify/schemas/lifecycle.schema.json| Constant | Value ||----------|-------|-| viewBox | default `[980, 660]`; schema minimum `[420, 360]` |-| State area | x within `[32, width − 32]`; y within `[64, legend y − 24]` |+| viewBox | default `[980, 660]`; schema minimum `[420, 566]` |+| State area | x within `[32, width − 32]`; state bottom at or above `height − 122` || State spacing | ≥10px between any two states — checked across lanes, because all event lanes share one band; separate same-band states with `col` or `yOffset` || Transition length | ≥32px between endpoints |-| Legend row | y = height − 98 |+| Legend row | final baseline y = height − 36; extra measured rows wrap upward |The primary lifecycle rail runs along the phase band and extends to thefurthest occupied phase column. Route presets for transitions: `straight`,diff --git a/archify/renderers/lifecycle/render-lifecycle.mjs b/archify/renderers/lifecycle/render-lifecycle.mjsindex bf0b3fb7..1c73934e 100644--- a/archify/renderers/lifecycle/render-lifecycle.mjs+++ b/archify/renderers/lifecycle/render-lifecycle.mjs@@ -3,6 +3,7 @@ import { fileURLToPath } from 'node:url';import { esc, renderDefinitions, renderSemanticSigil, textUnits } from '../shared/utils.mjs';import { animateAttr, focusEdgeAttrs, focusNodeAttrs, focusNodeTitle, loadDiagram, writeDiagram, svgAccessibleText, svgRootAttrs } from '../shared/cli.mjs';import { throwDiagnosticProblems } from '../shared/diagnostics.mjs';+import { resolveLegend, renderLegend as renderResolvedLegend } from '../shared/legend.mjs';import {asArray,isFinitePoint,@@ -73,7 +74,14 @@ const textClass = {};function legendY() {- return viewBox[1] - 98;+ return viewBox[1] - 36;+}++// Keep the authored state-placement contract independent from the measured+// legend's lower baseline. Moving legend chrome must not admit new state+// geometry into the reserved outcome/legend band.+function lifecycleAreaBottom() {+ return viewBox[1] - 122;}// Lane semantics are fixed: lane id "main" maps to the top phase band, lane id@@ -130,9 +138,9 @@ function validateLifecycle() {if (lifecycle.cards !== undefined && !Array.isArray(lifecycle.cards)) problems.push('Lifecycle "cards" must be an array.');if (states.size !== asArray(lifecycle.states).length) problems.push('State ids must be unique.');- // The three bands are fixed at y=112/264/436; the legend (viewBox[1] - 98)- // must clear the outcome band's header zone.- if (legendY() - 20 < 448) {+ // The three bands are fixed at y=112/264/436. Preserve the original+ // outcome/legend reserve even though measured legend rows now sit lower.+ if (lifecycleAreaBottom() + 4 < 448) {problems.push(`viewBox height ${viewBox[1]} is too short for the fixed band layout — set meta.viewBox[1] to at least 566.`);}@@ -164,8 +172,8 @@ function validateLifecycle() {if (state.x < 32 || state.x + state.width > viewBox[0] - 32) {problems.push(`State "${state.id}" exceeds the horizontal bounds of the diagram — reduce state.width or increase meta.viewBox[0].`);}- if (state.y < 64 || state.y + state.height > legendY() - 24) {- problems.push(`State "${state.id}" exceeds the vertical lifecycle area — keep y between 64 and ${legendY() - 24} (adjust yOffset or increase meta.viewBox[1]).`);+ if (state.y < 64 || state.y + state.height > lifecycleAreaBottom()) {+ problems.push(`State "${state.id}" exceeds the vertical lifecycle area — keep y between 64 and ${lifecycleAreaBottom()} (adjust yOffset or increase meta.viewBox[1]).`);}const estLabelW = textUnits(state.label) * 6.2;if (estLabelW > state.width + 6) {@@ -413,27 +421,32 @@ function renderTransitionLabel(transition, index) {</g>`;}+const LEGEND_CATALOG = [+ ['start', 'start'],+ ['active', 'active state'],+ ['waiting', 'waiting'],+ ['decision', 'decision'],+ ['success', 'terminal success'],+ ['failure', 'failure / exit'],+ ['neutral', 'neutral'],+ ['external', 'external'],+].map(([kind, label]) => ({ kind, label }));+function renderLegend() {- const y = legendY();- return ` <g data-legend-bridge>- <text x="220" y="${y - 20}" class="t-primary" font-size="10" font-weight="600">Legend</text>- <g data-legend-kind="active">- <rect x="220" y="${y - 8}" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>- <text x="240" y="${y}" class="t-muted" font-size="7">active state</text>- </g>- <g data-legend-kind="waiting">- <rect x="325" y="${y - 8}" width="14" height="9" rx="2" class="c-cloud" stroke-width="1"/>- <text x="345" y="${y}" class="t-muted" font-size="7">waiting</text>- </g>- <g data-legend-kind="success">- <rect x="415" y="${y - 8}" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>- <text x="435" y="${y}" class="t-muted" font-size="7">terminal success</text>- </g>- <g data-legend-kind="failure">- <rect x="560" y="${y - 8}" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>- <text x="580" y="${y}" class="t-muted" font-size="7">failure / exit</text>- </g>- </g>`;+ const presentKinds = new Set([...states.values()].map((state) => state.type));+ const entries = resolveLegend(lifecycle.meta?.legend, LEGEND_CATALOG, presentKinds);+ return renderResolvedLegend({+ entries,+ layout: {+ x: 40,+ baselineY: legendY(),+ width: viewBox[0] - 80,+ minTitleY: lifecycleAreaBottom() + 8,+ unfit: lifecycle.meta?.legend === undefined ? 'hide' : 'error',+ diagramType: 'lifecycle',+ },+ renderSwatch: (entry) => `<rect x="${entry.x}" y="${entry.baseline - 8}" width="14" height="9" rx="2" class="${typeClass[entry.kind] || 'c-external'}" stroke-width="1"/>`,+ });}function renderLifecycleRail() {diff --git a/archify/renderers/sequence/README.md b/archify/renderers/sequence/README.mdindex bd03162b..09746832 100644--- a/archify/renderers/sequence/README.md+++ b/archify/renderers/sequence/README.md@@ -45,6 +45,14 @@ The schema lives at:archify/schemas/sequence.schema.json```+## Legend++The default visual legend derives kinds from `messages[].variant` (omitting+`variant` means `default`). Supported `meta.legend.entries` keys, in stable+order, are `emphasis`, `return`, `security`, `dashed`, and `default`. These are+visual message keys, not Semantic Lens controls; label/visibility overrides do+not create edge facts.+## Layout budget| Constant | Value |diff --git a/archify/renderers/sequence/render-sequence.mjs b/archify/renderers/sequence/render-sequence.mjsindex 8e13cc4d..3f68b542 100644--- a/archify/renderers/sequence/render-sequence.mjs+++ b/archify/renderers/sequence/render-sequence.mjs@@ -3,6 +3,7 @@ import { fileURLToPath } from 'node:url';import { esc, renderDefinitions, renderSemanticSigil, textUnits } from '../shared/utils.mjs';import { animateAttr, focusEdgeAttrs, focusNodeAttrs, focusNodeTitle, loadDiagram, writeDiagram, svgAccessibleText, svgRootAttrs } from '../shared/cli.mjs';import { throwDiagnosticProblems } from '../shared/diagnostics.mjs';+import { resolveLegend, renderLegend as renderResolvedLegend } from '../shared/legend.mjs';import { componentFill, arrowClassMap, rectsOverlap, cleanFlowProblems, cleanCrossingProblems, cleanAmbiguousCorridorProblems, cleanBorderRunProblems, cleanRouteRhythmProblems, cleanLabelRouteClearanceProblems, routePointsValue, asArray, isFinitePoint } from '../shared/geometry.mjs';const __dirname = path.dirname(fileURLToPath(import.meta.url));@@ -348,17 +349,29 @@ ${messageLabel(message, start, end)}${note}</g>`;}+const LEGEND_CATALOG = [+ { kind: 'emphasis', label: 'request', className: 'a-emphasis', marker: 'arrowhead-emphasis', strokeWidth: 1.8 },+ { kind: 'return', label: 'return', className: 'a-default', marker: 'arrowhead', dash: '3,5' },+ { kind: 'security', label: 'security', className: 'a-security', marker: 'arrowhead-security' },+ { kind: 'dashed', label: 'async trace', className: 'a-dashed', marker: 'arrowhead-dashed' },+ { kind: 'default', label: 'default message', className: 'a-default', marker: 'arrowhead' },+].map((entry) => ({ ...entry, interactive: false, swatchWidth: 34, swatchGap: 9 }));+function renderLegend() {- const y = layout.legendY;- return ` <text x="150" y="${y - 20}" class="t-primary" font-size="10" font-weight="600">Legend</text>- <path d="M 150 ${y} L 184 ${y}" class="a-emphasis" stroke-width="1.8" marker-end="url(#arrowhead-emphasis)"/>- <text x="193" y="${y + 3}" class="t-muted" font-size="8">request</text>- <path d="M 270 ${y} L 304 ${y}" class="a-default" stroke-width="1.4" stroke-dasharray="3,5" marker-end="url(#arrowhead)"/>- <text x="313" y="${y + 3}" class="t-muted" font-size="8">return</text>- <path d="M 385 ${y} L 419 ${y}" class="a-security" stroke-width="1.4" marker-end="url(#arrowhead-security)"/>- <text x="428" y="${y + 3}" class="t-muted" font-size="8">security</text>- <path d="M 530 ${y} L 564 ${y}" class="a-dashed" stroke-width="1.4" marker-end="url(#arrowhead-dashed)"/>- <text x="573" y="${y + 3}" class="t-muted" font-size="8">async trace</text>`;+ const presentKinds = new Set(asArray(sequence.messages).map((message) => message.variant || 'default'));+ const entries = resolveLegend(sequence.meta?.legend, LEGEND_CATALOG, presentKinds);+ return renderResolvedLegend({+ entries,+ layout: {+ x: 40,+ baselineY: layout.legendY,+ width: viewBox[0] - 80,+ minTitleY: layout.legendY - 30,+ unfit: sequence.meta?.legend === undefined ? 'hide' : 'error',+ diagramType: 'sequence',+ },+ renderSwatch: (entry) => `<path d="M ${entry.x} ${entry.baseline - 3} L ${entry.x + 34} ${entry.baseline - 3}" class="${entry.className}" stroke-width="${entry.strokeWidth || 1.4}"${entry.dash ? ` stroke-dasharray="${entry.dash}"` : ''} marker-end="url(#${entry.marker})"/>`,+ });}function renderSvg() {diff --git a/archify/renderers/shared/generated-validators.mjs b/archify/renderers/shared/generated-validators.mjsindex 2a6021a2..95b850b1 100644--- a/archify/renderers/shared/generated-validators.mjs+++ b/archify/renderers/shared/generated-validators.mjs@@ -1,5 +1,5 @@// Generated by scripts/generate-validators.mjs. Do not edit by hand.-"use strict";export const workflow = validate20;const schema31 = {"$schema":"https://json-schema.org/draft/2020-12/schema","$id":"https://github.com/tt-a1i/archify/schemas/workflow.schema.json","title":"Archify Workflow Diagram","type":"object","additionalProperties":false,"required":["schema_version","diagram_type","meta","lanes","nodes","edges"],"properties":{"schema_version":{"const":1},"diagram_type":{"const":"workflow"},"meta":{"type":"object","additionalProperties":false,"required":["title"],"properties":{"title":{"type":"string","minLength":1},"subtitle":{"type":"string"},"output":{"type":"string"},"animation":{"enum":["trace","none"]},"visual_preset":{"enum":["classic","signal-flow","blueprint","editorial"]},"quality_profile":{"enum":["standard","showcase"]},"views":{"$ref":"common.schema.json#/$defs/guidedViews"},"viewBox":{"type":"array","prefixItems":[{"type":"number","minimum":700},{"type":"number","minimum":240}],"items":false,"minItems":2,"maxItems":2}}},"lanes":{"type":"array","minItems":1,"items":{"type":"object","additionalProperties":false,"required":["id","label"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"label":{"type":"string","minLength":1},"variant":{"enum":["normal","exception"]}}}},"phases":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["id","label","fromCol","toCol"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"label":{"type":"string","minLength":1},"fromCol":{"type":"integer","minimum":0,"maximum":5},"toCol":{"type":"integer","minimum":0,"maximum":5},"variant":{"enum":["default","emphasis","security","dashed"]}}}},"groups":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["id","label","lane","fromCol","toCol"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"label":{"type":"string","minLength":1},"lane":{"$ref":"common.schema.json#/$defs/id"},"fromCol":{"type":"integer","minimum":0,"maximum":5},"toCol":{"type":"integer","minimum":0,"maximum":5},"variant":{"enum":["default","emphasis","security","dashed"]}}}},"mainPath":{"type":"array","minItems":2,"items":{"$ref":"common.schema.json#/$defs/id"}},"nodes":{"type":"array","minItems":1,"items":{"type":"object","additionalProperties":false,"required":["id","lane","col","type","label"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"lane":{"$ref":"common.schema.json#/$defs/id"},"col":{"type":"integer","minimum":0,"maximum":5},"type":{"$ref":"common.schema.json#/$defs/componentType"},"label":{"type":"string","minLength":1},"sublabel":{"type":"string"},"tag":{"type":"string"},"width":{"type":"number","minimum":32},"height":{"type":"number","minimum":32},"yOffset":{"type":"number"}}}},"edges":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"from":{"$ref":"common.schema.json#/$defs/id"},"to":{"$ref":"common.schema.json#/$defs/id"},"label":{"type":"string"},"variant":{"$ref":"common.schema.json#/$defs/variant"},"role":{"enum":["main","branch","async","return","error"]},"fromSide":{"$ref":"#/$defs/side"},"toSide":{"$ref":"#/$defs/side"},"route":{"enum":["auto","straight","drop","outside-right","return-left","bottom-channel","up-channel"]},"via":{"type":"array","items":{"$ref":"common.schema.json#/$defs/point"}},"labelAt":{"$ref":"common.schema.json#/$defs/point"},"labelDx":{"type":"number"},"labelDy":{"type":"number"},"labelSegment":{"type":"integer","minimum":0},"channelX":{"type":"number"},"channelY":{"type":"number"},"bias":{"type":"number","minimum":0,"maximum":1},"width":{"type":"number","minimum":0.5}}}},"cards":{"$ref":"common.schema.json#/$defs/cards"}},"$defs":{"side":{"enum":["left","right","top","bottom"]}}};const schema34 = {"type":"string","pattern":"^[a-zA-Z][a-zA-Z0-9_-]*$"};const schema43 = {"enum":["frontend","backend","database","cloud","security","messagebus","external"]};const schema47 = {"enum":["default","emphasis","security","dashed"]};const schema48 = {"enum":["left","right","top","bottom"]};const schema50 = {"type":"array","prefixItems":[{"type":"number"},{"type":"number"}],"items":false,"minItems":2,"maxItems":2};const schema52 = {"type":"array","items":{"type":"object","additionalProperties":false,"required":["dot","title","items"],"properties":{"dot":{"enum":["cyan","emerald","violet","amber","rose","orange","slate"]},"title":{"type":"string","minLength":1},"items":{"type":"array","items":{"type":"string"}}}}};const func1 = Object.prototype.hasOwnProperty;const func2 = function ucs2length(str) {+"use strict";export const workflow = validate20;const schema31 = {"$schema":"https://json-schema.org/draft/2020-12/schema","$id":"https://github.com/tt-a1i/archify/schemas/workflow.schema.json","title":"Archify Workflow Diagram","type":"object","additionalProperties":false,"required":["schema_version","diagram_type","meta","lanes","nodes","edges"],"properties":{"schema_version":{"const":1},"diagram_type":{"const":"workflow"},"meta":{"type":"object","additionalProperties":false,"required":["title"],"properties":{"title":{"type":"string","minLength":1},"subtitle":{"type":"string"},"output":{"type":"string"},"animation":{"enum":["trace","none"]},"visual_preset":{"enum":["classic","signal-flow","blueprint","editorial"]},"quality_profile":{"enum":["standard","showcase"]},"views":{"$ref":"common.schema.json#/$defs/guidedViews"},"legend":{"type":"object","additionalProperties":false,"properties":{"mode":{"$ref":"common.schema.json#/$defs/legendMode"},"entries":{"type":"object","additionalProperties":false,"properties":{"frontend":{"$ref":"common.schema.json#/$defs/legendEntry"},"backend":{"$ref":"common.schema.json#/$defs/legendEntry"},"database":{"$ref":"common.schema.json#/$defs/legendEntry"},"cloud":{"$ref":"common.schema.json#/$defs/legendEntry"},"security":{"$ref":"common.schema.json#/$defs/legendEntry"},"messagebus":{"$ref":"common.schema.json#/$defs/legendEntry"},"external":{"$ref":"common.schema.json#/$defs/legendEntry"}}}}},"viewBox":{"type":"array","prefixItems":[{"type":"number","minimum":700},{"type":"number","minimum":240}],"items":false,"minItems":2,"maxItems":2}}},"lanes":{"type":"array","minItems":1,"items":{"type":"object","additionalProperties":false,"required":["id","label"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"label":{"type":"string","minLength":1},"variant":{"enum":["normal","exception"]}}}},"phases":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["id","label","fromCol","toCol"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"label":{"type":"string","minLength":1},"fromCol":{"type":"integer","minimum":0,"maximum":5},"toCol":{"type":"integer","minimum":0,"maximum":5},"variant":{"enum":["default","emphasis","security","dashed"]}}}},"groups":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["id","label","lane","fromCol","toCol"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"label":{"type":"string","minLength":1},"lane":{"$ref":"common.schema.json#/$defs/id"},"fromCol":{"type":"integer","minimum":0,"maximum":5},"toCol":{"type":"integer","minimum":0,"maximum":5},"variant":{"enum":["default","emphasis","security","dashed"]}}}},"mainPath":{"type":"array","minItems":2,"items":{"$ref":"common.schema.json#/$defs/id"}},"nodes":{"type":"array","minItems":1,"items":{"type":"object","additionalProperties":false,"required":["id","lane","col","type","label"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"lane":{"$ref":"common.schema.json#/$defs/id"},"col":{"type":"integer","minimum":0,"maximum":5},"type":{"$ref":"common.schema.json#/$defs/componentType"},"label":{"type":"string","minLength":1},"sublabel":{"type":"string"},"tag":{"type":"string"},"width":{"type":"number","minimum":32},"height":{"type":"number","minimum":32},"yOffset":{"type":"number"}}}},"edges":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"from":{"$ref":"common.schema.json#/$defs/id"},"to":{"$ref":"common.schema.json#/$defs/id"},"label":{"type":"string"},"variant":{"$ref":"common.schema.json#/$defs/variant"},"role":{"enum":["main","branch","async","return","error"]},"fromSide":{"$ref":"#/$defs/side"},"toSide":{"$ref":"#/$defs/side"},"route":{"enum":["auto","straight","drop","outside-right","return-left","bottom-channel","up-channel"]},"via":{"type":"array","items":{"$ref":"common.schema.json#/$defs/point"}},"labelAt":{"$ref":"common.schema.json#/$defs/point"},"labelDx":{"type":"number"},"labelDy":{"type":"number"},"labelSegment":{"type":"integer","minimum":0},"channelX":{"type":"number"},"channelY":{"type":"number"},"bias":{"type":"number","minimum":0,"maximum":1},"width":{"type":"number","minimum":0.5}}}},"cards":{"$ref":"common.schema.json#/$defs/cards"}},"$defs":{"side":{"enum":["left","right","top","bottom"]}}};const schema36 = {"enum":["auto","all","hidden"]};const schema37 = {"type":"object","additionalProperties":false,"minProperties":1,"properties":{"label":{"type":"string","minLength":1,"maxLength":80},"visible":{"type":"boolean"}}};const schema34 = {"type":"string","pattern":"^[a-zA-Z][a-zA-Z0-9_-]*$"};const schema51 = {"enum":["frontend","backend","database","cloud","security","messagebus","external"]};const schema55 = {"enum":["default","emphasis","security","dashed"]};const schema56 = {"enum":["left","right","top","bottom"]};const schema58 = {"type":"array","prefixItems":[{"type":"number"},{"type":"number"}],"items":false,"minItems":2,"maxItems":2};const schema60 = {"type":"array","items":{"type":"object","additionalProperties":false,"required":["dot","title","items"],"properties":{"dot":{"enum":["cyan","emerald","violet","amber","rose","orange","slate"]},"title":{"type":"string","minLength":1},"items":{"type":"array","items":{"type":"string"}}}}};const func1 = Object.prototype.hasOwnProperty;const func3 = function ucs2length(str) {const len = str.length;let length = 0;let pos = 0;@@ -10,4 +10,4 @@&& (str.charCodeAt(pos) & 0xfc00) === 0xdc00) pos += 1;}return length;-};const schema33 = {"type":"array","maxItems":5,"items":{"type":"object","additionalProperties":false,"required":["id","label","focus"],"properties":{"id":{"$ref":"#/$defs/id"},"label":{"type":"string","minLength":1,"maxLength":48},"focus":{"type":"array","minItems":1,"items":{"$ref":"#/$defs/id"}},"note":{"type":"string","maxLength":140}}}};const pattern4 = new RegExp("^[a-zA-Z][a-zA-Z0-9_-]*$", "u");function validate22(data, {instancePath="", parentData, parentDataProperty, rootData=data, dynamicAnchors={}}={}){let vErrors = null;let errors = 0;const evaluated0 = validate22.evaluated;if(evaluated0.dynamicProps){evaluated0.props = undefined;}if(evaluated0.dynamicItems){evaluated0.items = undefined;}if(Array.isArray(data)){if(data.length > 5){const err0 = {instancePath,schemaPath:"#/maxItems",keyword:"maxItems",params:{limit: 5},message:"must NOT have more than 5 items"};if(vErrors === null){vErrors = [err0];}else {vErrors.push(err0);}errors++;}const len0 = data.length;for(let i0=0; i0<len0; i0++){let data0 = data[i0];if(data0 && typeof data0 == "object" && !Array.isArray(data0)){if(data0.id === undefined){const err1 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err1];}else {vErrors.push(err1);}errors++;}if(data0.label === undefined){const err2 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err2];}else {vErrors.push(err2);}errors++;}if(data0.focus === undefined){const err3 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "focus"},message:"must have required property '"+"focus"+"'"};if(vErrors === null){vErrors = [err3];}else {vErrors.push(err3);}errors++;}for(const key0 in data0){if(!((((key0 === "id") || (key0 === "label")) || (key0 === "focus")) || (key0 === "note"))){const err4 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key0},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err4];}else {vErrors.push(err4);}errors++;}}if(data0.id !== undefined){let data1 = data0.id;if(typeof data1 === "string"){if(!pattern4.test(data1)){const err5 = {instancePath:instancePath+"/" + i0+"/id",schemaPath:"#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err5];}else {vErrors.push(err5);}errors++;}}else {const err6 = {instancePath:instancePath+"/" + i0+"/id",schemaPath:"#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err6];}else {vErrors.push(err6);}errors++;}}if(data0.label !== undefined){let data2 = data0.label;if(typeof data2 === "string"){if(func2(data2) > 48){const err7 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/maxLength",keyword:"maxLength",params:{limit: 48},message:"must NOT have more than 48 characters"};if(vErrors === null){vErrors = [err7];}else {vErrors.push(err7);}errors++;}if(func2(data2) < 1){const err8 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err8];}else {vErrors.push(err8);}errors++;}}else {const err9 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err9];}else {vErrors.push(err9);}errors++;}}if(data0.focus !== undefined){let data3 = data0.focus;if(Array.isArray(data3)){if(data3.length < 1){const err10 = {instancePath:instancePath+"/" + i0+"/focus",schemaPath:"#/items/properties/focus/minItems",keyword:"minItems",params:{limit: 1},message:"must NOT have fewer than 1 items"};if(vErrors === null){vErrors = [err10];}else {vErrors.push(err10);}errors++;}const len1 = data3.length;for(let i1=0; i1<len1; i1++){let data4 = data3[i1];if(typeof data4 === "string"){if(!pattern4.test(data4)){const err11 = {instancePath:instancePath+"/" + i0+"/focus/" + i1,schemaPath:"#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err11];}else {vErrors.push(err11);}errors++;}}else {const err12 = {instancePath:instancePath+"/" + i0+"/focus/" + i1,schemaPath:"#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err12];}else {vErrors.push(err12);}errors++;}}}else {const err13 = {instancePath:instancePath+"/" + i0+"/focus",schemaPath:"#/items/properties/focus/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err13];}else {vErrors.push(err13);}errors++;}}if(data0.note !== undefined){let data5 = data0.note;if(typeof data5 === "string"){if(func2(data5) > 140){const err14 = {instancePath:instancePath+"/" + i0+"/note",schemaPath:"#/items/properties/note/maxLength",keyword:"maxLength",params:{limit: 140},message:"must NOT have more than 140 characters"};if(vErrors === null){vErrors = [err14];}else {vErrors.push(err14);}errors++;}}else {const err15 = {instancePath:instancePath+"/" + i0+"/note",schemaPath:"#/items/properties/note/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err15];}else {vErrors.push(err15);}errors++;}}}else {const err16 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err16];}else {vErrors.push(err16);}errors++;}}}else {const err17 = {instancePath,schemaPath:"#/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err17];}else {vErrors.push(err17);}errors++;}validate22.errors = vErrors;return errors === 0;}validate22.evaluated = {"items":true,"dynamicProps":false,"dynamicItems":false};function validate20(data, {instancePath="", parentData, parentDataProperty, rootData=data, dynamicAnchors={}}={}){/*# sourceURL="https://github.com/tt-a1i/archify/schemas/workflow.schema.json" */;let vErrors = null;let errors = 0;const evaluated0 = validate20.evaluated;if(evaluated0.dynamicProps){evaluated0.props = undefined;}if(evaluated0.dynamicItems){evaluated0.items = undefined;}if(data && typeof data == "object" && !Array.isArray(data)){if(data.schema_version === undefined){const err0 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "schema_version"},message:"must have required property '"+"schema_version"+"'"};if(vErrors === null){vErrors = [err0];}else {vErrors.push(err0);}errors++;}if(data.diagram_type === undefined){const err1 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "diagram_type"},message:"must have required property '"+"diagram_type"+"'"};if(vErrors === null){vErrors = [err1];}else {vErrors.push(err1);}errors++;}if(data.meta === undefined){const err2 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "meta"},message:"must have required property '"+"meta"+"'"};if(vErrors === null){vErrors = [err2];}else {vErrors.push(err2);}errors++;}if(data.lanes === undefined){const err3 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "lanes"},message:"must have required property '"+"lanes"+"'"};if(vErrors === null){vErrors = [err3];}else {vErrors.push(err3);}errors++;}if(data.nodes === undefined){const err4 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "nodes"},message:"must have required property '"+"nodes"+"'"};if(vErrors === null){vErrors = [err4];}else {vErrors.push(err4);}errors++;}if(data.edges === undefined){const err5 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "edges"},message:"must have required property '"+"edges"+"'"};if(vErrors === null){vErrors = [err5];}else {vErrors.push(err5);}errors++;}for(const key0 in data){if(!(func1.call(schema31.properties, key0))){const err6 = {instancePath,schemaPath:"#/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key0},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err6];}else {vErrors.push(err6);}errors++;}}if(data.schema_version !== undefined){if(1 !== data.schema_version){const err7 = {instancePath:instancePath+"/schema_version",schemaPath:"#/properties/schema_version/const",keyword:"const",params:{allowedValue: 1},message:"must be equal to constant"};if(vErrors === null){vErrors = [err7];}else {vErrors.push(err7);}errors++;}}if(data.diagram_type !== undefined){if("workflow" !== data.diagram_type){const err8 = {instancePath:instancePath+"/diagram_type",schemaPath:"#/properties/diagram_type/const",keyword:"const",params:{allowedValue: "workflow"},message:"must be equal to constant"};if(vErrors === null){vErrors = [err8];}else {vErrors.push(err8);}errors++;}}if(data.meta !== undefined){let data2 = data.meta;if(data2 && typeof data2 == "object" && !Array.isArray(data2)){if(data2.title === undefined){const err9 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/required",keyword:"required",params:{missingProperty: "title"},message:"must have required property '"+"title"+"'"};if(vErrors === null){vErrors = [err9];}else {vErrors.push(err9);}errors++;}for(const key1 in data2){if(!((((((((key1 === "title") || (key1 === "subtitle")) || (key1 === "output")) || (key1 === "animation")) || (key1 === "visual_preset")) || (key1 === "quality_profile")) || (key1 === "views")) || (key1 === "viewBox"))){const err10 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key1},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err10];}else {vErrors.push(err10);}errors++;}}if(data2.title !== undefined){let data3 = data2.title;if(typeof data3 === "string"){if(func2(data3) < 1){const err11 = {instancePath:instancePath+"/meta/title",schemaPath:"#/properties/meta/properties/title/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err11];}else {vErrors.push(err11);}errors++;}}else {const err12 = {instancePath:instancePath+"/meta/title",schemaPath:"#/properties/meta/properties/title/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err12];}else {vErrors.push(err12);}errors++;}}if(data2.subtitle !== undefined){if(typeof data2.subtitle !== "string"){const err13 = {instancePath:instancePath+"/meta/subtitle",schemaPath:"#/properties/meta/properties/subtitle/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err13];}else {vErrors.push(err13);}errors++;}}if(data2.output !== undefined){if(typeof data2.output !== "string"){const err14 = {instancePath:instancePath+"/meta/output",schemaPath:"#/properties/meta/properties/output/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err14];}else {vErrors.push(err14);}errors++;}}if(data2.animation !== undefined){let data6 = data2.animation;if(!((data6 === "trace") || (data6 === "none"))){const err15 = {instancePath:instancePath+"/meta/animation",schemaPath:"#/properties/meta/properties/animation/enum",keyword:"enum",params:{allowedValues: schema31.properties.meta.properties.animation.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err15];}else {vErrors.push(err15);}errors++;}}if(data2.visual_preset !== undefined){let data7 = data2.visual_preset;if(!((((data7 === "classic") || (data7 === "signal-flow")) || (data7 === "blueprint")) || (data7 === "editorial"))){const err16 = {instancePath:instancePath+"/meta/visual_preset",schemaPath:"#/properties/meta/properties/visual_preset/enum",keyword:"enum",params:{allowedValues: schema31.properties.meta.properties.visual_preset.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err16];}else {vErrors.push(err16);}errors++;}}if(data2.quality_profile !== undefined){let data8 = data2.quality_profile;if(!((data8 === "standard") || (data8 === "showcase"))){const err17 = {instancePath:instancePath+"/meta/quality_profile",schemaPath:"#/properties/meta/properties/quality_profile/enum",keyword:"enum",params:{allowedValues: schema31.properties.meta.properties.quality_profile.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err17];}else {vErrors.push(err17);}errors++;}}if(data2.views !== undefined){if(!(validate22(data2.views, {instancePath:instancePath+"/meta/views",parentData:data2,parentDataProperty:"views",rootData,dynamicAnchors}))){vErrors = vErrors === null ? validate22.errors : vErrors.concat(validate22.errors);errors = vErrors.length;}}if(data2.viewBox !== undefined){let data10 = data2.viewBox;if(Array.isArray(data10)){if(data10.length > 2){const err18 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err18];}else {vErrors.push(err18);}errors++;}if(data10.length < 2){const err19 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err19];}else {vErrors.push(err19);}errors++;}const len0 = data10.length;if(len0 > 0){let data11 = data10[0];if((typeof data11 == "number") && (isFinite(data11))){if(data11 < 700 || isNaN(data11)){const err20 = {instancePath:instancePath+"/meta/viewBox/0",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/0/minimum",keyword:"minimum",params:{comparison: ">=", limit: 700},message:"must be >= 700"};if(vErrors === null){vErrors = [err20];}else {vErrors.push(err20);}errors++;}}else {const err21 = {instancePath:instancePath+"/meta/viewBox/0",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err21];}else {vErrors.push(err21);}errors++;}}if(len0 > 1){let data12 = data10[1];if((typeof data12 == "number") && (isFinite(data12))){if(data12 < 240 || isNaN(data12)){const err22 = {instancePath:instancePath+"/meta/viewBox/1",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/1/minimum",keyword:"minimum",params:{comparison: ">=", limit: 240},message:"must be >= 240"};if(vErrors === null){vErrors = [err22];}else {vErrors.push(err22);}errors++;}}else {const err23 = {instancePath:instancePath+"/meta/viewBox/1",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err23];}else {vErrors.push(err23);}errors++;}}const len1 = data10.length;if(!(len1 <= 2)){const err24 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err24];}else {vErrors.push(err24);}errors++;}}else {const err25 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err25];}else {vErrors.push(err25);}errors++;}}}else {const err26 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err26];}else {vErrors.push(err26);}errors++;}}if(data.lanes !== undefined){let data13 = data.lanes;if(Array.isArray(data13)){if(data13.length < 1){const err27 = {instancePath:instancePath+"/lanes",schemaPath:"#/properties/lanes/minItems",keyword:"minItems",params:{limit: 1},message:"must NOT have fewer than 1 items"};if(vErrors === null){vErrors = [err27];}else {vErrors.push(err27);}errors++;}const len2 = data13.length;for(let i0=0; i0<len2; i0++){let data14 = data13[i0];if(data14 && typeof data14 == "object" && !Array.isArray(data14)){if(data14.id === undefined){const err28 = {instancePath:instancePath+"/lanes/" + i0,schemaPath:"#/properties/lanes/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err28];}else {vErrors.push(err28);}errors++;}if(data14.label === undefined){const err29 = {instancePath:instancePath+"/lanes/" + i0,schemaPath:"#/properties/lanes/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err29];}else {vErrors.push(err29);}errors++;}for(const key2 in data14){if(!(((key2 === "id") || (key2 === "label")) || (key2 === "variant"))){const err30 = {instancePath:instancePath+"/lanes/" + i0,schemaPath:"#/properties/lanes/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key2},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err30];}else {vErrors.push(err30);}errors++;}}if(data14.id !== undefined){let data15 = data14.id;if(typeof data15 === "string"){if(!pattern4.test(data15)){const err31 = {instancePath:instancePath+"/lanes/" + i0+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err31];}else {vErrors.push(err31);}errors++;}}else {const err32 = {instancePath:instancePath+"/lanes/" + i0+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err32];}else {vErrors.push(err32);}errors++;}}if(data14.label !== undefined){let data16 = data14.label;if(typeof data16 === "string"){if(func2(data16) < 1){const err33 = {instancePath:instancePath+"/lanes/" + i0+"/label",schemaPath:"#/properties/lanes/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err33];}else {vErrors.push(err33);}errors++;}}else {const err34 = {instancePath:instancePath+"/lanes/" + i0+"/label",schemaPath:"#/properties/lanes/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err34];}else {vErrors.push(err34);}errors++;}}if(data14.variant !== undefined){let data17 = data14.variant;if(!((data17 === "normal") || (data17 === "exception"))){const err35 = {instancePath:instancePath+"/lanes/" + i0+"/variant",schemaPath:"#/properties/lanes/items/properties/variant/enum",keyword:"enum",params:{allowedValues: schema31.properties.lanes.items.properties.variant.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err35];}else {vErrors.push(err35);}errors++;}}}else {const err36 = {instancePath:instancePath+"/lanes/" + i0,schemaPath:"#/properties/lanes/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err36];}else {vErrors.push(err36);}errors++;}}}else {const err37 = {instancePath:instancePath+"/lanes",schemaPath:"#/properties/lanes/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err37];}else {vErrors.push(err37);}errors++;}}if(data.phases !== undefined){let data18 = data.phases;if(Array.isArray(data18)){const len3 = data18.length;for(let i1=0; i1<len3; i1++){let data19 = data18[i1];if(data19 && typeof data19 == "object" && !Array.isArray(data19)){if(data19.id === undefined){const err38 = {instancePath:instancePath+"/phases/" + i1,schemaPath:"#/properties/phases/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err38];}else {vErrors.push(err38);}errors++;}if(data19.label === undefined){const err39 = {instancePath:instancePath+"/phases/" + i1,schemaPath:"#/properties/phases/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err39];}else {vErrors.push(err39);}errors++;}if(data19.fromCol === undefined){const err40 = {instancePath:instancePath+"/phases/" + i1,schemaPath:"#/properties/phases/items/required",keyword:"required",params:{missingProperty: "fromCol"},message:"must have required property '"+"fromCol"+"'"};if(vErrors === null){vErrors = [err40];}else {vErrors.push(err40);}errors++;}if(data19.toCol === undefined){const err41 = {instancePath:instancePath+"/phases/" + i1,schemaPath:"#/properties/phases/items/required",keyword:"required",params:{missingProperty: "toCol"},message:"must have required property '"+"toCol"+"'"};if(vErrors === null){vErrors = [err41];}else {vErrors.push(err41);}errors++;}for(const key3 in data19){if(!(((((key3 === "id") || (key3 === "label")) || (key3 === "fromCol")) || (key3 === "toCol")) || (key3 === "variant"))){const err42 = {instancePath:instancePath+"/phases/" + i1,schemaPath:"#/properties/phases/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key3},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err42];}else {vErrors.push(err42);}errors++;}}if(data19.id !== undefined){let data20 = data19.id;if(typeof data20 === "string"){if(!pattern4.test(data20)){const err43 = {instancePath:instancePath+"/phases/" + i1+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err43];}else {vErrors.push(err43);}errors++;}}else {const err44 = {instancePath:instancePath+"/phases/" + i1+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err44];}else {vErrors.push(err44);}errors++;}}if(data19.label !== undefined){let data21 = data19.label;if(typeof data21 === "string"){if(func2(data21) < 1){const err45 = {instancePath:instancePath+"/phases/" + i1+"/label",schemaPath:"#/properties/phases/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err45];}else {vErrors.push(err45);}errors++;}}else {const err46 = {instancePath:instancePath+"/phases/" + i1+"/label",schemaPath:"#/properties/phases/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err46];}else {vErrors.push(err46);}errors++;}}if(data19.fromCol !== undefined){let data22 = data19.fromCol;if(!(((typeof data22 == "number") && (!(data22 % 1) && !isNaN(data22))) && (isFinite(data22)))){const err47 = {instancePath:instancePath+"/phases/" + i1+"/fromCol",schemaPath:"#/properties/phases/items/properties/fromCol/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err47];}else {vErrors.push(err47);}errors++;}if((typeof data22 == "number") && (isFinite(data22))){if(data22 > 5 || isNaN(data22)){const err48 = {instancePath:instancePath+"/phases/" + i1+"/fromCol",schemaPath:"#/properties/phases/items/properties/fromCol/maximum",keyword:"maximum",params:{comparison: "<=", limit: 5},message:"must be <= 5"};if(vErrors === null){vErrors = [err48];}else {vErrors.push(err48);}errors++;}if(data22 < 0 || isNaN(data22)){const err49 = {instancePath:instancePath+"/phases/" + i1+"/fromCol",schemaPath:"#/properties/phases/items/properties/fromCol/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err49];}else {vErrors.push(err49);}errors++;}}}if(data19.toCol !== undefined){let data23 = data19.toCol;if(!(((typeof data23 == "number") && (!(data23 % 1) && !isNaN(data23))) && (isFinite(data23)))){const err50 = {instancePath:instancePath+"/phases/" + i1+"/toCol",schemaPath:"#/properties/phases/items/properties/toCol/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err50];}else {vErrors.push(err50);}errors++;}if((typeof data23 == "number") && (isFinite(data23))){if(data23 > 5 || isNaN(data23)){const err51 = {instancePath:instancePath+"/phases/" + i1+"/toCol",schemaPath:"#/properties/phases/items/properties/toCol/maximum",keyword:"maximum",params:{comparison: "<=", limit: 5},message:"must be <= 5"};if(vErrors === null){vErrors = [err51];}else {vErrors.push(err51);}errors++;}if(data23 < 0 || isNaN(data23)){const err52 = {instancePath:instancePath+"/phases/" + i1+"/toCol",schemaPath:"#/properties/phases/items/properties/toCol/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err52];}else {vErrors.push(err52);}errors++;}}}if(data19.variant !== undefined){let data24 = data19.variant;if(!((((data24 === "default") || (data24 === "emphasis")) || (data24 === "security")) || (data24 === "dashed"))){const err53 = {instancePath:instancePath+"/phases/" + i1+"/variant",schemaPath:"#/properties/phases/items/properties/variant/enum",keyword:"enum",params:{allowedValues: schema31.properties.phases.items.properties.variant.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err53];}else {vErrors.push(err53);}errors++;}}}else {const err54 = {instancePath:instancePath+"/phases/" + i1,schemaPath:"#/properties/phases/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err54];}else {vErrors.push(err54);}errors++;}}}else {const err55 = {instancePath:instancePath+"/phases",schemaPath:"#/properties/phases/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err55];}else {vErrors.push(err55);}errors++;}}if(data.groups !== undefined){let data25 = data.groups;if(Array.isArray(data25)){const len4 = data25.length;for(let i2=0; i2<len4; i2++){let data26 = data25[i2];if(data26 && typeof data26 == "object" && !Array.isArray(data26)){if(data26.id === undefined){const err56 = {instancePath:instancePath+"/groups/" + i2,schemaPath:"#/properties/groups/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err56];}else {vErrors.push(err56);}errors++;}if(data26.label === undefined){const err57 = {instancePath:instancePath+"/groups/" + i2,schemaPath:"#/properties/groups/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err57];}else {vErrors.push(err57);}errors++;}if(data26.lane === undefined){const err58 = {instancePath:instancePath+"/groups/" + i2,schemaPath:"#/properties/groups/items/required",keyword:"required",params:{missingProperty: "lane"},message:"must have required property '"+"lane"+"'"};if(vErrors === null){vErrors = [err58];}else {vErrors.push(err58);}errors++;}if(data26.fromCol === undefined){const err59 = {instancePath:instancePath+"/groups/" + i2,schemaPath:"#/properties/groups/items/required",keyword:"required",params:{missingProperty: "fromCol"},message:"must have required property '"+"fromCol"+"'"};if(vErrors === null){vErrors = [err59];}else {vErrors.push(err59);}errors++;}if(data26.toCol === undefined){const err60 = {instancePath:instancePath+"/groups/" + i2,schemaPath:"#/properties/groups/items/required",keyword:"required",params:{missingProperty: "toCol"},message:"must have required property '"+"toCol"+"'"};if(vErrors === null){vErrors = [err60];}else {vErrors.push(err60);}errors++;}for(const key4 in data26){if(!((((((key4 === "id") || (key4 === "label")) || (key4 === "lane")) || (key4 === "fromCol")) || (key4 === "toCol")) || (key4 === "variant"))){const err61 = {instancePath:instancePath+"/groups/" + i2,schemaPath:"#/properties/groups/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key4},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err61];}else {vErrors.push(err61);}errors++;}}if(data26.id !== undefined){let data27 = data26.id;if(typeof data27 === "string"){if(!pattern4.test(data27)){const err62 = {instancePath:instancePath+"/groups/" + i2+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err62];}else {vErrors.push(err62);}errors++;}}else {const err63 = {instancePath:instancePath+"/groups/" + i2+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err63];}else {vErrors.push(err63);}errors++;}}if(data26.label !== undefined){let data28 = data26.label;if(typeof data28 === "string"){if(func2(data28) < 1){const err64 = {instancePath:instancePath+"/groups/" + i2+"/label",schemaPath:"#/properties/groups/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err64];}else {vErrors.push(err64);}errors++;}}else {const err65 = {instancePath:instancePath+"/groups/" + i2+"/label",schemaPath:"#/properties/groups/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err65];}else {vErrors.push(err65);}errors++;}}if(data26.lane !== undefined){let data29 = data26.lane;if(typeof data29 === "string"){if(!pattern4.test(data29)){const err66 = {instancePath:instancePath+"/groups/" + i2+"/lane",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err66];}else {vErrors.push(err66);}errors++;}}else {const err67 = {instancePath:instancePath+"/groups/" + i2+"/lane",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err67];}else {vErrors.push(err67);}errors++;}}if(data26.fromCol !== undefined){let data30 = data26.fromCol;if(!(((typeof data30 == "number") && (!(data30 % 1) && !isNaN(data30))) && (isFinite(data30)))){const err68 = {instancePath:instancePath+"/groups/" + i2+"/fromCol",schemaPath:"#/properties/groups/items/properties/fromCol/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err68];}else {vErrors.push(err68);}errors++;}if((typeof data30 == "number") && (isFinite(data30))){if(data30 > 5 || isNaN(data30)){const err69 = {instancePath:instancePath+"/groups/" + i2+"/fromCol",schemaPath:"#/properties/groups/items/properties/fromCol/maximum",keyword:"maximum",params:{comparison: "<=", limit: 5},message:"must be <= 5"};if(vErrors === null){vErrors = [err69];}else {vErrors.push(err69);}errors++;}if(data30 < 0 || isNaN(data30)){const err70 = {instancePath:instancePath+"/groups/" + i2+"/fromCol",schemaPath:"#/properties/groups/items/properties/fromCol/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err70];}else {vErrors.push(err70);}errors++;}}}if(data26.toCol !== undefined){let data31 = data26.toCol;if(!(((typeof data31 == "number") && (!(data31 % 1) && !isNaN(data31))) && (isFinite(data31)))){const err71 = {instancePath:instancePath+"/groups/" + i2+"/toCol",schemaPath:"#/properties/groups/items/properties/toCol/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err71];}else {vErrors.push(err71);}errors++;}if((typeof data31 == "number") && (isFinite(data31))){if(data31 > 5 || isNaN(data31)){const err72 = {instancePath:instancePath+"/groups/" + i2+"/toCol",schemaPath:"#/properties/groups/items/properties/toCol/maximum",keyword:"maximum",params:{comparison: "<=", limit: 5},message:"must be <= 5"};if(vErrors === null){vErrors = [err72];}else {vErrors.push(err72);}errors++;}if(data31 < 0 || isNaN(data31)){const err73 = {instancePath:instancePath+"/groups/" + i2+"/toCol",schemaPath:"#/properties/groups/items/properties/toCol/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err73];}else {vErrors.push(err73);}errors++;}}}if(data26.variant !== undefined){let data32 = data26.variant;if(!((((data32 === "default") || (data32 === "emphasis")) || (data32 === "security")) || (data32 === "dashed"))){const err74 = {instancePath:instancePath+"/groups/" + i2+"/variant",schemaPath:"#/properties/groups/items/properties/variant/enum",keyword:"enum",params:{allowedValues: schema31.properties.groups.items.properties.variant.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err74];}else {vErrors.push(err74);}errors++;}}}else {const err75 = {instancePath:instancePath+"/groups/" + i2,schemaPath:"#/properties/groups/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err75];}else {vErrors.push(err75);}errors++;}}}else {const err76 = {instancePath:instancePath+"/groups",schemaPath:"#/properties/groups/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err76];}else {vErrors.push(err76);}errors++;}}if(data.mainPath !== undefined){let data33 = data.mainPath;if(Array.isArray(data33)){if(data33.length < 2){const err77 = {instancePath:instancePath+"/mainPath",schemaPath:"#/properties/mainPath/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err77];}else {vErrors.push(err77);}errors++;}const len5 = data33.length;for(let i3=0; i3<len5; i3++){let data34 = data33[i3];if(typeof data34 === "string"){if(!pattern4.test(data34)){const err78 = {instancePath:instancePath+"/mainPath/" + i3,schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err78];}else {vErrors.push(err78);}errors++;}}else {const err79 = {instancePath:instancePath+"/mainPath/" + i3,schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err79];}else {vErrors.push(err79);}errors++;}}}else {const err80 = {instancePath:instancePath+"/mainPath",schemaPath:"#/properties/mainPath/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err80];}else {vErrors.push(err80);}errors++;}}if(data.nodes !== undefined){let data35 = data.nodes;if(Array.isArray(data35)){if(data35.length < 1){const err81 = {instancePath:instancePath+"/nodes",schemaPath:"#/properties/nodes/minItems",keyword:"minItems",params:{limit: 1},message:"must NOT have fewer than 1 items"};if(vErrors === null){vErrors = [err81];}else {vErrors.push(err81);}errors++;}const len6 = data35.length;for(let i4=0; i4<len6; i4++){let data36 = data35[i4];if(data36 && typeof data36 == "object" && !Array.isArray(data36)){if(data36.id === undefined){const err82 = {instancePath:instancePath+"/nodes/" + i4,schemaPath:"#/properties/nodes/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err82];}else {vErrors.push(err82);}errors++;}if(data36.lane === undefined){const err83 = {instancePath:instancePath+"/nodes/" + i4,schemaPath:"#/properties/nodes/items/required",keyword:"required",params:{missingProperty: "lane"},message:"must have required property '"+"lane"+"'"};if(vErrors === null){vErrors = [err83];}else {vErrors.push(err83);}errors++;}if(data36.col === undefined){const err84 = {instancePath:instancePath+"/nodes/" + i4,schemaPath:"#/properties/nodes/items/required",keyword:"required",params:{missingProperty: "col"},message:"must have required property '"+"col"+"'"};if(vErrors === null){vErrors = [err84];}else {vErrors.push(err84);}errors++;}if(data36.type === undefined){const err85 = {instancePath:instancePath+"/nodes/" + i4,schemaPath:"#/properties/nodes/items/required",keyword:"required",params:{missingProperty: "type"},message:"must have required property '"+"type"+"'"};if(vErrors === null){vErrors = [err85];}else {vErrors.push(err85);}errors++;}if(data36.label === undefined){const err86 = {instancePath:instancePath+"/nodes/" + i4,schemaPath:"#/properties/nodes/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err86];}else {vErrors.push(err86);}errors++;}for(const key5 in data36){if(!(func1.call(schema31.properties.nodes.items.properties, key5))){const err87 = {instancePath:instancePath+"/nodes/" + i4,schemaPath:"#/properties/nodes/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key5},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err87];}else {vErrors.push(err87);}errors++;}}if(data36.id !== undefined){let data37 = data36.id;if(typeof data37 === "string"){if(!pattern4.test(data37)){const err88 = {instancePath:instancePath+"/nodes/" + i4+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err88];}else {vErrors.push(err88);}errors++;}}else {const err89 = {instancePath:instancePath+"/nodes/" + i4+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err89];}else {vErrors.push(err89);}errors++;}}if(data36.lane !== undefined){let data38 = data36.lane;if(typeof data38 === "string"){if(!pattern4.test(data38)){const err90 = {instancePath:instancePath+"/nodes/" + i4+"/lane",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err90];}else {vErrors.push(err90);}errors++;}}else {const err91 = {instancePath:instancePath+"/nodes/" + i4+"/lane",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err91];}else {vErrors.push(err91);}errors++;}}if(data36.col !== undefined){let data39 = data36.col;if(!(((typeof data39 == "number") && (!(data39 % 1) && !isNaN(data39))) && (isFinite(data39)))){const err92 = {instancePath:instancePath+"/nodes/" + i4+"/col",schemaPath:"#/properties/nodes/items/properties/col/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err92];}else {vErrors.push(err92);}errors++;}if((typeof data39 == "number") && (isFinite(data39))){if(data39 > 5 || isNaN(data39)){const err93 = {instancePath:instancePath+"/nodes/" + i4+"/col",schemaPath:"#/properties/nodes/items/properties/col/maximum",keyword:"maximum",params:{comparison: "<=", limit: 5},message:"must be <= 5"};if(vErrors === null){vErrors = [err93];}else {vErrors.push(err93);}errors++;}if(data39 < 0 || isNaN(data39)){const err94 = {instancePath:instancePath+"/nodes/" + i4+"/col",schemaPath:"#/properties/nodes/items/properties/col/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err94];}else {vErrors.push(err94);}errors++;}}}if(data36.type !== undefined){let data40 = data36.type;if(!(((((((data40 === "frontend") || (data40 === "backend")) || (data40 === "database")) || (data40 === "cloud")) || (data40 === "security")) || (data40 === "messagebus")) || (data40 === "external"))){const err95 = {instancePath:instancePath+"/nodes/" + i4+"/type",schemaPath:"common.schema.json#/$defs/componentType/enum",keyword:"enum",params:{allowedValues: schema43.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err95];}else {vErrors.push(err95);}errors++;}}if(data36.label !== undefined){let data41 = data36.label;if(typeof data41 === "string"){if(func2(data41) < 1){const err96 = {instancePath:instancePath+"/nodes/" + i4+"/label",schemaPath:"#/properties/nodes/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err96];}else {vErrors.push(err96);}errors++;}}else {const err97 = {instancePath:instancePath+"/nodes/" + i4+"/label",schemaPath:"#/properties/nodes/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err97];}else {vErrors.push(err97);}errors++;}}if(data36.sublabel !== undefined){if(typeof data36.sublabel !== "string"){const err98 = {instancePath:instancePath+"/nodes/" + i4+"/sublabel",schemaPath:"#/properties/nodes/items/properties/sublabel/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err98];}else {vErrors.push(err98);}errors++;}}if(data36.tag !== undefined){if(typeof data36.tag !== "string"){const err99 = {instancePath:instancePath+"/nodes/" + i4+"/tag",schemaPath:"#/properties/nodes/items/properties/tag/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err99];}else {vErrors.push(err99);}errors++;}}if(data36.width !== undefined){let data44 = data36.width;if((typeof data44 == "number") && (isFinite(data44))){if(data44 < 32 || isNaN(data44)){const err100 = {instancePath:instancePath+"/nodes/" + i4+"/width",schemaPath:"#/properties/nodes/items/properties/width/minimum",keyword:"minimum",params:{comparison: ">=", limit: 32},message:"must be >= 32"};if(vErrors === null){vErrors = [err100];}else {vErrors.push(err100);}errors++;}}else {const err101 = {instancePath:instancePath+"/nodes/" + i4+"/width",schemaPath:"#/properties/nodes/items/properties/width/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err101];}else {vErrors.push(err101);}errors++;}}if(data36.height !== undefined){let data45 = data36.height;if((typeof data45 == "number") && (isFinite(data45))){if(data45 < 32 || isNaN(data45)){const err102 = {instancePath:instancePath+"/nodes/" + i4+"/height",schemaPath:"#/properties/nodes/items/properties/height/minimum",keyword:"minimum",params:{comparison: ">=", limit: 32},message:"must be >= 32"};if(vErrors === null){vErrors = [err102];}else {vErrors.push(err102);}errors++;}}else {const err103 = {instancePath:instancePath+"/nodes/" + i4+"/height",schemaPath:"#/properties/nodes/items/properties/height/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err103];}else {vErrors.push(err103);}errors++;}}if(data36.yOffset !== undefined){let data46 = data36.yOffset;if(!((typeof data46 == "number") && (isFinite(data46)))){const err104 = {instancePath:instancePath+"/nodes/" + i4+"/yOffset",schemaPath:"#/properties/nodes/items/properties/yOffset/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err104];}else {vErrors.push(err104);}errors++;}}}else {const err105 = {instancePath:instancePath+"/nodes/" + i4,schemaPath:"#/properties/nodes/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err105];}else {vErrors.push(err105);}errors++;}}}else {const err106 = {instancePath:instancePath+"/nodes",schemaPath:"#/properties/nodes/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err106];}else {vErrors.push(err106);}errors++;}}if(data.edges !== undefined){let data47 = data.edges;if(Array.isArray(data47)){const len7 = data47.length;for(let i5=0; i5<len7; i5++){let data48 = data47[i5];if(data48 && typeof data48 == "object" && !Array.isArray(data48)){if(data48.from === undefined){const err107 = {instancePath:instancePath+"/edges/" + i5,schemaPath:"#/properties/edges/items/required",keyword:"required",params:{missingProperty: "from"},message:"must have required property '"+"from"+"'"};if(vErrors === null){vErrors = [err107];}else {vErrors.push(err107);}errors++;}if(data48.to === undefined){const err108 = {instancePath:instancePath+"/edges/" + i5,schemaPath:"#/properties/edges/items/required",keyword:"required",params:{missingProperty: "to"},message:"must have required property '"+"to"+"'"};if(vErrors === null){vErrors = [err108];}else {vErrors.push(err108);}errors++;}for(const key6 in data48){if(!(func1.call(schema31.properties.edges.items.properties, key6))){const err109 = {instancePath:instancePath+"/edges/" + i5,schemaPath:"#/properties/edges/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key6},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err109];}else {vErrors.push(err109);}errors++;}}if(data48.id !== undefined){let data49 = data48.id;if(typeof data49 === "string"){if(!pattern4.test(data49)){const err110 = {instancePath:instancePath+"/edges/" + i5+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err110];}else {vErrors.push(err110);}errors++;}}else {const err111 = {instancePath:instancePath+"/edges/" + i5+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err111];}else {vErrors.push(err111);}errors++;}}if(data48.from !== undefined){let data50 = data48.from;if(typeof data50 === "string"){if(!pattern4.test(data50)){const err112 = {instancePath:instancePath+"/edges/" + i5+"/from",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err112];}else {vErrors.push(err112);}errors++;}}else {const err113 = {instancePath:instancePath+"/edges/" + i5+"/from",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err113];}else {vErrors.push(err113);}errors++;}}if(data48.to !== undefined){let data51 = data48.to;if(typeof data51 === "string"){if(!pattern4.test(data51)){const err114 = {instancePath:instancePath+"/edges/" + i5+"/to",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err114];}else {vErrors.push(err114);}errors++;}}else {const err115 = {instancePath:instancePath+"/edges/" + i5+"/to",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err115];}else {vErrors.push(err115);}errors++;}}if(data48.label !== undefined){if(typeof data48.label !== "string"){const err116 = {instancePath:instancePath+"/edges/" + i5+"/label",schemaPath:"#/properties/edges/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err116];}else {vErrors.push(err116);}errors++;}}if(data48.variant !== undefined){let data53 = data48.variant;if(!((((data53 === "default") || (data53 === "emphasis")) || (data53 === "security")) || (data53 === "dashed"))){const err117 = {instancePath:instancePath+"/edges/" + i5+"/variant",schemaPath:"common.schema.json#/$defs/variant/enum",keyword:"enum",params:{allowedValues: schema47.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err117];}else {vErrors.push(err117);}errors++;}}if(data48.role !== undefined){let data54 = data48.role;if(!(((((data54 === "main") || (data54 === "branch")) || (data54 === "async")) || (data54 === "return")) || (data54 === "error"))){const err118 = {instancePath:instancePath+"/edges/" + i5+"/role",schemaPath:"#/properties/edges/items/properties/role/enum",keyword:"enum",params:{allowedValues: schema31.properties.edges.items.properties.role.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err118];}else {vErrors.push(err118);}errors++;}}if(data48.fromSide !== undefined){let data55 = data48.fromSide;if(!((((data55 === "left") || (data55 === "right")) || (data55 === "top")) || (data55 === "bottom"))){const err119 = {instancePath:instancePath+"/edges/" + i5+"/fromSide",schemaPath:"#/$defs/side/enum",keyword:"enum",params:{allowedValues: schema48.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err119];}else {vErrors.push(err119);}errors++;}}if(data48.toSide !== undefined){let data56 = data48.toSide;if(!((((data56 === "left") || (data56 === "right")) || (data56 === "top")) || (data56 === "bottom"))){const err120 = {instancePath:instancePath+"/edges/" + i5+"/toSide",schemaPath:"#/$defs/side/enum",keyword:"enum",params:{allowedValues: schema48.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err120];}else {vErrors.push(err120);}errors++;}}if(data48.route !== undefined){let data57 = data48.route;if(!(((((((data57 === "auto") || (data57 === "straight")) || (data57 === "drop")) || (data57 === "outside-right")) || (data57 === "return-left")) || (data57 === "bottom-channel")) || (data57 === "up-channel"))){const err121 = {instancePath:instancePath+"/edges/" + i5+"/route",schemaPath:"#/properties/edges/items/properties/route/enum",keyword:"enum",params:{allowedValues: schema31.properties.edges.items.properties.route.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err121];}else {vErrors.push(err121);}errors++;}}if(data48.via !== undefined){let data58 = data48.via;if(Array.isArray(data58)){const len8 = data58.length;for(let i6=0; i6<len8; i6++){let data59 = data58[i6];if(Array.isArray(data59)){if(data59.length > 2){const err122 = {instancePath:instancePath+"/edges/" + i5+"/via/" + i6,schemaPath:"common.schema.json#/$defs/point/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err122];}else {vErrors.push(err122);}errors++;}if(data59.length < 2){const err123 = {instancePath:instancePath+"/edges/" + i5+"/via/" + i6,schemaPath:"common.schema.json#/$defs/point/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err123];}else {vErrors.push(err123);}errors++;}const len9 = data59.length;if(len9 > 0){let data60 = data59[0];if(!((typeof data60 == "number") && (isFinite(data60)))){const err124 = {instancePath:instancePath+"/edges/" + i5+"/via/" + i6+"/0",schemaPath:"common.schema.json#/$defs/point/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err124];}else {vErrors.push(err124);}errors++;}}if(len9 > 1){let data61 = data59[1];if(!((typeof data61 == "number") && (isFinite(data61)))){const err125 = {instancePath:instancePath+"/edges/" + i5+"/via/" + i6+"/1",schemaPath:"common.schema.json#/$defs/point/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err125];}else {vErrors.push(err125);}errors++;}}const len10 = data59.length;if(!(len10 <= 2)){const err126 = {instancePath:instancePath+"/edges/" + i5+"/via/" + i6,schemaPath:"common.schema.json#/$defs/point/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err126];}else {vErrors.push(err126);}errors++;}}else {const err127 = {instancePath:instancePath+"/edges/" + i5+"/via/" + i6,schemaPath:"common.schema.json#/$defs/point/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err127];}else {vErrors.push(err127);}errors++;}}}else {const err128 = {instancePath:instancePath+"/edges/" + i5+"/via",schemaPath:"#/properties/edges/items/properties/via/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err128];}else {vErrors.push(err128);}errors++;}}if(data48.labelAt !== undefined){let data62 = data48.labelAt;if(Array.isArray(data62)){if(data62.length > 2){const err129 = {instancePath:instancePath+"/edges/" + i5+"/labelAt",schemaPath:"common.schema.json#/$defs/point/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err129];}else {vErrors.push(err129);}errors++;}if(data62.length < 2){const err130 = {instancePath:instancePath+"/edges/" + i5+"/labelAt",schemaPath:"common.schema.json#/$defs/point/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err130];}else {vErrors.push(err130);}errors++;}const len11 = data62.length;if(len11 > 0){let data63 = data62[0];if(!((typeof data63 == "number") && (isFinite(data63)))){const err131 = {instancePath:instancePath+"/edges/" + i5+"/labelAt/0",schemaPath:"common.schema.json#/$defs/point/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err131];}else {vErrors.push(err131);}errors++;}}if(len11 > 1){let data64 = data62[1];if(!((typeof data64 == "number") && (isFinite(data64)))){const err132 = {instancePath:instancePath+"/edges/" + i5+"/labelAt/1",schemaPath:"common.schema.json#/$defs/point/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err132];}else {vErrors.push(err132);}errors++;}}const len12 = data62.length;if(!(len12 <= 2)){const err133 = {instancePath:instancePath+"/edges/" + i5+"/labelAt",schemaPath:"common.schema.json#/$defs/point/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err133];}else {vErrors.push(err133);}errors++;}}else {const err134 = {instancePath:instancePath+"/edges/" + i5+"/labelAt",schemaPath:"common.schema.json#/$defs/point/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err134];}else {vErrors.push(err134);}errors++;}}if(data48.labelDx !== undefined){let data65 = data48.labelDx;if(!((typeof data65 == "number") && (isFinite(data65)))){const err135 = {instancePath:instancePath+"/edges/" + i5+"/labelDx",schemaPath:"#/properties/edges/items/properties/labelDx/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err135];}else {vErrors.push(err135);}errors++;}}if(data48.labelDy !== undefined){let data66 = data48.labelDy;if(!((typeof data66 == "number") && (isFinite(data66)))){const err136 = {instancePath:instancePath+"/edges/" + i5+"/labelDy",schemaPath:"#/properties/edges/items/properties/labelDy/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err136];}else {vErrors.push(err136);}errors++;}}if(data48.labelSegment !== undefined){let data67 = data48.labelSegment;if(!(((typeof data67 == "number") && (!(data67 % 1) && !isNaN(data67))) && (isFinite(data67)))){const err137 = {instancePath:instancePath+"/edges/" + i5+"/labelSegment",schemaPath:"#/properties/edges/items/properties/labelSegment/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err137];}else {vErrors.push(err137);}errors++;}if((typeof data67 == "number") && (isFinite(data67))){if(data67 < 0 || isNaN(data67)){const err138 = {instancePath:instancePath+"/edges/" + i5+"/labelSegment",schemaPath:"#/properties/edges/items/properties/labelSegment/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err138];}else {vErrors.push(err138);}errors++;}}}if(data48.channelX !== undefined){let data68 = data48.channelX;if(!((typeof data68 == "number") && (isFinite(data68)))){const err139 = {instancePath:instancePath+"/edges/" + i5+"/channelX",schemaPath:"#/properties/edges/items/properties/channelX/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err139];}else {vErrors.push(err139);}errors++;}}if(data48.channelY !== undefined){let data69 = data48.channelY;if(!((typeof data69 == "number") && (isFinite(data69)))){const err140 = {instancePath:instancePath+"/edges/" + i5+"/channelY",schemaPath:"#/properties/edges/items/properties/channelY/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err140];}else {vErrors.push(err140);}errors++;}}if(data48.bias !== undefined){let data70 = data48.bias;if((typeof data70 == "number") && (isFinite(data70))){if(data70 > 1 || isNaN(data70)){const err141 = {instancePath:instancePath+"/edges/" + i5+"/bias",schemaPath:"#/properties/edges/items/properties/bias/maximum",keyword:"maximum",params:{comparison: "<=", limit: 1},message:"must be <= 1"};if(vErrors === null){vErrors = [err141];}else {vErrors.push(err141);}errors++;}if(data70 < 0 || isNaN(data70)){const err142 = {instancePath:instancePath+"/edges/" + i5+"/bias",schemaPath:"#/properties/edges/items/properties/bias/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err142];}else {vErrors.push(err142);}errors++;}}else {const err143 = {instancePath:instancePath+"/edges/" + i5+"/bias",schemaPath:"#/properties/edges/items/properties/bias/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err143];}else {vErrors.push(err143);}errors++;}}if(data48.width !== undefined){let data71 = data48.width;if((typeof data71 == "number") && (isFinite(data71))){if(data71 < 0.5 || isNaN(data71)){const err144 = {instancePath:instancePath+"/edges/" + i5+"/width",schemaPath:"#/properties/edges/items/properties/width/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0.5},message:"must be >= 0.5"};if(vErrors === null){vErrors = [err144];}else {vErrors.push(err144);}errors++;}}else {const err145 = {instancePath:instancePath+"/edges/" + i5+"/width",schemaPath:"#/properties/edges/items/properties/width/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err145];}else {vErrors.push(err145);}errors++;}}}else {const err146 = {instancePath:instancePath+"/edges/" + i5,schemaPath:"#/properties/edges/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err146];}else {vErrors.push(err146);}errors++;}}}else {const err147 = {instancePath:instancePath+"/edges",schemaPath:"#/properties/edges/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err147];}else {vErrors.push(err147);}errors++;}}if(data.cards !== undefined){let data72 = data.cards;if(Array.isArray(data72)){const len13 = data72.length;for(let i7=0; i7<len13; i7++){let data73 = data72[i7];if(data73 && typeof data73 == "object" && !Array.isArray(data73)){if(data73.dot === undefined){const err148 = {instancePath:instancePath+"/cards/" + i7,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "dot"},message:"must have required property '"+"dot"+"'"};if(vErrors === null){vErrors = [err148];}else {vErrors.push(err148);}errors++;}if(data73.title === undefined){const err149 = {instancePath:instancePath+"/cards/" + i7,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "title"},message:"must have required property '"+"title"+"'"};if(vErrors === null){vErrors = [err149];}else {vErrors.push(err149);}errors++;}if(data73.items === undefined){const err150 = {instancePath:instancePath+"/cards/" + i7,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "items"},message:"must have required property '"+"items"+"'"};if(vErrors === null){vErrors = [err150];}else {vErrors.push(err150);}errors++;}for(const key7 in data73){if(!(((key7 === "dot") || (key7 === "title")) || (key7 === "items"))){const err151 = {instancePath:instancePath+"/cards/" + i7,schemaPath:"common.schema.json#/$defs/cards/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key7},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err151];}else {vErrors.push(err151);}errors++;}}if(data73.dot !== undefined){let data74 = data73.dot;if(!(((((((data74 === "cyan") || (data74 === "emerald")) || (data74 === "violet")) || (data74 === "amber")) || (data74 === "rose")) || (data74 === "orange")) || (data74 === "slate"))){const err152 = {instancePath:instancePath+"/cards/" + i7+"/dot",schemaPath:"common.schema.json#/$defs/cards/items/properties/dot/enum",keyword:"enum",params:{allowedValues: schema52.items.properties.dot.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err152];}else {vErrors.push(err152);}errors++;}}if(data73.title !== undefined){let data75 = data73.title;if(typeof data75 === "string"){if(func2(data75) < 1){const err153 = {instancePath:instancePath+"/cards/" + i7+"/title",schemaPath:"common.schema.json#/$defs/cards/items/properties/title/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err153];}else {vErrors.push(err153);}errors++;}}else {const err154 = {instancePath:instancePath+"/cards/" + i7+"/title",schemaPath:"common.schema.json#/$defs/cards/items/properties/title/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err154];}else {vErrors.push(err154);}errors++;}}if(data73.items !== undefined){let data76 = data73.items;if(Array.isArray(data76)){const len14 = data76.length;for(let i8=0; i8<len14; i8++){if(typeof data76[i8] !== "string"){const err155 = {instancePath:instancePath+"/cards/" + i7+"/items/" + i8,schemaPath:"common.schema.json#/$defs/cards/items/properties/items/items/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err155];}else {vErrors.push(err155);}errors++;}}}else {const err156 = {instancePath:instancePath+"/cards/" + i7+"/items",schemaPath:"common.schema.json#/$defs/cards/items/properties/items/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err156];}else {vErrors.push(err156);}errors++;}}}else {const err157 = {instancePath:instancePath+"/cards/" + i7,schemaPath:"common.schema.json#/$defs/cards/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err157];}else {vErrors.push(err157);}errors++;}}}else {const err158 = {instancePath:instancePath+"/cards",schemaPath:"common.schema.json#/$defs/cards/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err158];}else {vErrors.push(err158);}errors++;}}}else {const err159 = {instancePath,schemaPath:"#/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err159];}else {vErrors.push(err159);}errors++;}validate20.errors = vErrors;return errors === 0;}validate20.evaluated = {"props":true,"dynamicProps":false,"dynamicItems":false};export const sequence = validate24;const schema53 = {"$schema":"https://json-schema.org/draft/2020-12/schema","$id":"https://github.com/tt-a1i/archify/schemas/sequence.schema.json","title":"Archify Sequence Diagram","type":"object","additionalProperties":false,"required":["schema_version","diagram_type","meta","participants","messages"],"properties":{"schema_version":{"const":1},"diagram_type":{"const":"sequence"},"meta":{"type":"object","additionalProperties":false,"required":["title"],"properties":{"title":{"type":"string","minLength":1},"subtitle":{"type":"string"},"output":{"type":"string"},"animation":{"enum":["trace","none"]},"visual_preset":{"enum":["classic","signal-flow","blueprint","editorial"]},"quality_profile":{"enum":["standard","showcase"]},"views":{"$ref":"common.schema.json#/$defs/guidedViews"},"viewBox":{"type":"array","prefixItems":[{"type":"number","minimum":480},{"type":"number","minimum":480}],"items":false,"minItems":2,"maxItems":2}}},"participants":{"type":"array","minItems":2,"items":{"type":"object","additionalProperties":false,"required":["id","type","label"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"type":{"$ref":"common.schema.json#/$defs/componentType"},"label":{"type":"string","minLength":1},"sublabel":{"type":"string"}}}},"segments":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to","label"],"properties":{"from":{"type":"number"},"to":{"type":"number"},"label":{"type":"string","minLength":1}}}},"messages":{"type":"array","minItems":1,"items":{"type":"object","additionalProperties":false,"required":["from","to","y","label"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"from":{"$ref":"common.schema.json#/$defs/id"},"to":{"$ref":"common.schema.json#/$defs/id"},"y":{"type":"number","minimum":160},"label":{"type":"string","minLength":1},"variant":{"enum":["default","emphasis","security","dashed","return"]},"note":{"type":"string"}}}},"activations":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["participant","from","to"],"properties":{"participant":{"$ref":"common.schema.json#/$defs/id"},"from":{"type":"number"},"to":{"type":"number"},"type":{"$ref":"common.schema.json#/$defs/componentType"}}}},"cards":{"$ref":"common.schema.json#/$defs/cards"}}};function validate25(data, {instancePath="", parentData, parentDataProperty, rootData=data, dynamicAnchors={}}={}){let vErrors = null;let errors = 0;const evaluated0 = validate25.evaluated;if(evaluated0.dynamicProps){evaluated0.props = undefined;}if(evaluated0.dynamicItems){evaluated0.items = undefined;}if(Array.isArray(data)){if(data.length > 5){const err0 = {instancePath,schemaPath:"#/maxItems",keyword:"maxItems",params:{limit: 5},message:"must NOT have more than 5 items"};if(vErrors === null){vErrors = [err0];}else {vErrors.push(err0);}errors++;}const len0 = data.length;for(let i0=0; i0<len0; i0++){let data0 = data[i0];if(data0 && typeof data0 == "object" && !Array.isArray(data0)){if(data0.id === undefined){const err1 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err1];}else {vErrors.push(err1);}errors++;}if(data0.label === undefined){const err2 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err2];}else {vErrors.push(err2);}errors++;}if(data0.focus === undefined){const err3 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "focus"},message:"must have required property '"+"focus"+"'"};if(vErrors === null){vErrors = [err3];}else {vErrors.push(err3);}errors++;}for(const key0 in data0){if(!((((key0 === "id") || (key0 === "label")) || (key0 === "focus")) || (key0 === "note"))){const err4 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key0},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err4];}else {vErrors.push(err4);}errors++;}}if(data0.id !== undefined){let data1 = data0.id;if(typeof data1 === "string"){if(!pattern4.test(data1)){const err5 = {instancePath:instancePath+"/" + i0+"/id",schemaPath:"#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err5];}else {vErrors.push(err5);}errors++;}}else {const err6 = {instancePath:instancePath+"/" + i0+"/id",schemaPath:"#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err6];}else {vErrors.push(err6);}errors++;}}if(data0.label !== undefined){let data2 = data0.label;if(typeof data2 === "string"){if(func2(data2) > 48){const err7 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/maxLength",keyword:"maxLength",params:{limit: 48},message:"must NOT have more than 48 characters"};if(vErrors === null){vErrors = [err7];}else {vErrors.push(err7);}errors++;}if(func2(data2) < 1){const err8 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err8];}else {vErrors.push(err8);}errors++;}}else {const err9 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err9];}else {vErrors.push(err9);}errors++;}}if(data0.focus !== undefined){let data3 = data0.focus;if(Array.isArray(data3)){if(data3.length < 1){const err10 = {instancePath:instancePath+"/" + i0+"/focus",schemaPath:"#/items/properties/focus/minItems",keyword:"minItems",params:{limit: 1},message:"must NOT have fewer than 1 items"};if(vErrors === null){vErrors = [err10];}else {vErrors.push(err10);}errors++;}const len1 = data3.length;for(let i1=0; i1<len1; i1++){let data4 = data3[i1];if(typeof data4 === "string"){if(!pattern4.test(data4)){const err11 = {instancePath:instancePath+"/" + i0+"/focus/" + i1,schemaPath:"#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err11];}else {vErrors.push(err11);}errors++;}}else {const err12 = {instancePath:instancePath+"/" + i0+"/focus/" + i1,schemaPath:"#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err12];}else {vErrors.push(err12);}errors++;}}}else {const err13 = {instancePath:instancePath+"/" + i0+"/focus",schemaPath:"#/items/properties/focus/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err13];}else {vErrors.push(err13);}errors++;}}if(data0.note !== undefined){let data5 = data0.note;if(typeof data5 === "string"){if(func2(data5) > 140){const err14 = {instancePath:instancePath+"/" + i0+"/note",schemaPath:"#/items/properties/note/maxLength",keyword:"maxLength",params:{limit: 140},message:"must NOT have more than 140 characters"};if(vErrors === null){vErrors = [err14];}else {vErrors.push(err14);}errors++;}}else {const err15 = {instancePath:instancePath+"/" + i0+"/note",schemaPath:"#/items/properties/note/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err15];}else {vErrors.push(err15);}errors++;}}}else {const err16 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err16];}else {vErrors.push(err16);}errors++;}}}else {const err17 = {instancePath,schemaPath:"#/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err17];}else {vErrors.push(err17);}errors++;}validate25.errors = vErrors;return errors === 0;}validate25.evaluated = {"items":true,"dynamicProps":false,"dynamicItems":false};function validate24(data, {instancePath="", parentData, parentDataProperty, rootData=data, dynamicAnchors={}}={}){/*# sourceURL="https://github.com/tt-a1i/archify/schemas/sequence.schema.json" */;let vErrors = null;let errors = 0;const evaluated0 = validate24.evaluated;if(evaluated0.dynamicProps){evaluated0.props = undefined;}if(evaluated0.dynamicItems){evaluated0.items = undefined;}if(data && typeof data == "object" && !Array.isArray(data)){if(data.schema_version === undefined){const err0 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "schema_version"},message:"must have required property '"+"schema_version"+"'"};if(vErrors === null){vErrors = [err0];}else {vErrors.push(err0);}errors++;}if(data.diagram_type === undefined){const err1 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "diagram_type"},message:"must have required property '"+"diagram_type"+"'"};if(vErrors === null){vErrors = [err1];}else {vErrors.push(err1);}errors++;}if(data.meta === undefined){const err2 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "meta"},message:"must have required property '"+"meta"+"'"};if(vErrors === null){vErrors = [err2];}else {vErrors.push(err2);}errors++;}if(data.participants === undefined){const err3 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "participants"},message:"must have required property '"+"participants"+"'"};if(vErrors === null){vErrors = [err3];}else {vErrors.push(err3);}errors++;}if(data.messages === undefined){const err4 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "messages"},message:"must have required property '"+"messages"+"'"};if(vErrors === null){vErrors = [err4];}else {vErrors.push(err4);}errors++;}for(const key0 in data){if(!((((((((key0 === "schema_version") || (key0 === "diagram_type")) || (key0 === "meta")) || (key0 === "participants")) || (key0 === "segments")) || (key0 === "messages")) || (key0 === "activations")) || (key0 === "cards"))){const err5 = {instancePath,schemaPath:"#/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key0},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err5];}else {vErrors.push(err5);}errors++;}}if(data.schema_version !== undefined){if(1 !== data.schema_version){const err6 = {instancePath:instancePath+"/schema_version",schemaPath:"#/properties/schema_version/const",keyword:"const",params:{allowedValue: 1},message:"must be equal to constant"};if(vErrors === null){vErrors = [err6];}else {vErrors.push(err6);}errors++;}}if(data.diagram_type !== undefined){if("sequence" !== data.diagram_type){const err7 = {instancePath:instancePath+"/diagram_type",schemaPath:"#/properties/diagram_type/const",keyword:"const",params:{allowedValue: "sequence"},message:"must be equal to constant"};if(vErrors === null){vErrors = [err7];}else {vErrors.push(err7);}errors++;}}if(data.meta !== undefined){let data2 = data.meta;if(data2 && typeof data2 == "object" && !Array.isArray(data2)){if(data2.title === undefined){const err8 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/required",keyword:"required",params:{missingProperty: "title"},message:"must have required property '"+"title"+"'"};if(vErrors === null){vErrors = [err8];}else {vErrors.push(err8);}errors++;}for(const key1 in data2){if(!((((((((key1 === "title") || (key1 === "subtitle")) || (key1 === "output")) || (key1 === "animation")) || (key1 === "visual_preset")) || (key1 === "quality_profile")) || (key1 === "views")) || (key1 === "viewBox"))){const err9 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key1},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err9];}else {vErrors.push(err9);}errors++;}}if(data2.title !== undefined){let data3 = data2.title;if(typeof data3 === "string"){if(func2(data3) < 1){const err10 = {instancePath:instancePath+"/meta/title",schemaPath:"#/properties/meta/properties/title/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err10];}else {vErrors.push(err10);}errors++;}}else {const err11 = {instancePath:instancePath+"/meta/title",schemaPath:"#/properties/meta/properties/title/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err11];}else {vErrors.push(err11);}errors++;}}if(data2.subtitle !== undefined){if(typeof data2.subtitle !== "string"){const err12 = {instancePath:instancePath+"/meta/subtitle",schemaPath:"#/properties/meta/properties/subtitle/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err12];}else {vErrors.push(err12);}errors++;}}if(data2.output !== undefined){if(typeof data2.output !== "string"){const err13 = {instancePath:instancePath+"/meta/output",schemaPath:"#/properties/meta/properties/output/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err13];}else {vErrors.push(err13);}errors++;}}if(data2.animation !== undefined){let data6 = data2.animation;if(!((data6 === "trace") || (data6 === "none"))){const err14 = {instancePath:instancePath+"/meta/animation",schemaPath:"#/properties/meta/properties/animation/enum",keyword:"enum",params:{allowedValues: schema53.properties.meta.properties.animation.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err14];}else {vErrors.push(err14);}errors++;}}if(data2.visual_preset !== undefined){let data7 = data2.visual_preset;if(!((((data7 === "classic") || (data7 === "signal-flow")) || (data7 === "blueprint")) || (data7 === "editorial"))){const err15 = {instancePath:instancePath+"/meta/visual_preset",schemaPath:"#/properties/meta/properties/visual_preset/enum",keyword:"enum",params:{allowedValues: schema53.properties.meta.properties.visual_preset.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err15];}else {vErrors.push(err15);}errors++;}}if(data2.quality_profile !== undefined){let data8 = data2.quality_profile;if(!((data8 === "standard") || (data8 === "showcase"))){const err16 = {instancePath:instancePath+"/meta/quality_profile",schemaPath:"#/properties/meta/properties/quality_profile/enum",keyword:"enum",params:{allowedValues: schema53.properties.meta.properties.quality_profile.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err16];}else {vErrors.push(err16);}errors++;}}if(data2.views !== undefined){if(!(validate25(data2.views, {instancePath:instancePath+"/meta/views",parentData:data2,parentDataProperty:"views",rootData,dynamicAnchors}))){vErrors = vErrors === null ? validate25.errors : vErrors.concat(validate25.errors);errors = vErrors.length;}}if(data2.viewBox !== undefined){let data10 = data2.viewBox;if(Array.isArray(data10)){if(data10.length > 2){const err17 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err17];}else {vErrors.push(err17);}errors++;}if(data10.length < 2){const err18 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err18];}else {vErrors.push(err18);}errors++;}const len0 = data10.length;if(len0 > 0){let data11 = data10[0];if((typeof data11 == "number") && (isFinite(data11))){if(data11 < 480 || isNaN(data11)){const err19 = {instancePath:instancePath+"/meta/viewBox/0",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/0/minimum",keyword:"minimum",params:{comparison: ">=", limit: 480},message:"must be >= 480"};if(vErrors === null){vErrors = [err19];}else {vErrors.push(err19);}errors++;}}else {const err20 = {instancePath:instancePath+"/meta/viewBox/0",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err20];}else {vErrors.push(err20);}errors++;}}if(len0 > 1){let data12 = data10[1];if((typeof data12 == "number") && (isFinite(data12))){if(data12 < 480 || isNaN(data12)){const err21 = {instancePath:instancePath+"/meta/viewBox/1",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/1/minimum",keyword:"minimum",params:{comparison: ">=", limit: 480},message:"must be >= 480"};if(vErrors === null){vErrors = [err21];}else {vErrors.push(err21);}errors++;}}else {const err22 = {instancePath:instancePath+"/meta/viewBox/1",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err22];}else {vErrors.push(err22);}errors++;}}const len1 = data10.length;if(!(len1 <= 2)){const err23 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err23];}else {vErrors.push(err23);}errors++;}}else {const err24 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err24];}else {vErrors.push(err24);}errors++;}}}else {const err25 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err25];}else {vErrors.push(err25);}errors++;}}if(data.participants !== undefined){let data13 = data.participants;if(Array.isArray(data13)){if(data13.length < 2){const err26 = {instancePath:instancePath+"/participants",schemaPath:"#/properties/participants/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err26];}else {vErrors.push(err26);}errors++;}const len2 = data13.length;for(let i0=0; i0<len2; i0++){let data14 = data13[i0];if(data14 && typeof data14 == "object" && !Array.isArray(data14)){if(data14.id === undefined){const err27 = {instancePath:instancePath+"/participants/" + i0,schemaPath:"#/properties/participants/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err27];}else {vErrors.push(err27);}errors++;}if(data14.type === undefined){const err28 = {instancePath:instancePath+"/participants/" + i0,schemaPath:"#/properties/participants/items/required",keyword:"required",params:{missingProperty: "type"},message:"must have required property '"+"type"+"'"};if(vErrors === null){vErrors = [err28];}else {vErrors.push(err28);}errors++;}if(data14.label === undefined){const err29 = {instancePath:instancePath+"/participants/" + i0,schemaPath:"#/properties/participants/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err29];}else {vErrors.push(err29);}errors++;}for(const key2 in data14){if(!((((key2 === "id") || (key2 === "type")) || (key2 === "label")) || (key2 === "sublabel"))){const err30 = {instancePath:instancePath+"/participants/" + i0,schemaPath:"#/properties/participants/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key2},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err30];}else {vErrors.push(err30);}errors++;}}if(data14.id !== undefined){let data15 = data14.id;if(typeof data15 === "string"){if(!pattern4.test(data15)){const err31 = {instancePath:instancePath+"/participants/" + i0+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err31];}else {vErrors.push(err31);}errors++;}}else {const err32 = {instancePath:instancePath+"/participants/" + i0+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err32];}else {vErrors.push(err32);}errors++;}}if(data14.type !== undefined){let data16 = data14.type;if(!(((((((data16 === "frontend") || (data16 === "backend")) || (data16 === "database")) || (data16 === "cloud")) || (data16 === "security")) || (data16 === "messagebus")) || (data16 === "external"))){const err33 = {instancePath:instancePath+"/participants/" + i0+"/type",schemaPath:"common.schema.json#/$defs/componentType/enum",keyword:"enum",params:{allowedValues: schema43.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err33];}else {vErrors.push(err33);}errors++;}}if(data14.label !== undefined){let data17 = data14.label;if(typeof data17 === "string"){if(func2(data17) < 1){const err34 = {instancePath:instancePath+"/participants/" + i0+"/label",schemaPath:"#/properties/participants/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err34];}else {vErrors.push(err34);}errors++;}}else {const err35 = {instancePath:instancePath+"/participants/" + i0+"/label",schemaPath:"#/properties/participants/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err35];}else {vErrors.push(err35);}errors++;}}if(data14.sublabel !== undefined){if(typeof data14.sublabel !== "string"){const err36 = {instancePath:instancePath+"/participants/" + i0+"/sublabel",schemaPath:"#/properties/participants/items/properties/sublabel/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err36];}else {vErrors.push(err36);}errors++;}}}else {const err37 = {instancePath:instancePath+"/participants/" + i0,schemaPath:"#/properties/participants/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err37];}else {vErrors.push(err37);}errors++;}}}else {const err38 = {instancePath:instancePath+"/participants",schemaPath:"#/properties/participants/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err38];}else {vErrors.push(err38);}errors++;}}if(data.segments !== undefined){let data19 = data.segments;if(Array.isArray(data19)){const len3 = data19.length;for(let i1=0; i1<len3; i1++){let data20 = data19[i1];if(data20 && typeof data20 == "object" && !Array.isArray(data20)){if(data20.from === undefined){const err39 = {instancePath:instancePath+"/segments/" + i1,schemaPath:"#/properties/segments/items/required",keyword:"required",params:{missingProperty: "from"},message:"must have required property '"+"from"+"'"};if(vErrors === null){vErrors = [err39];}else {vErrors.push(err39);}errors++;}if(data20.to === undefined){const err40 = {instancePath:instancePath+"/segments/" + i1,schemaPath:"#/properties/segments/items/required",keyword:"required",params:{missingProperty: "to"},message:"must have required property '"+"to"+"'"};if(vErrors === null){vErrors = [err40];}else {vErrors.push(err40);}errors++;}if(data20.label === undefined){const err41 = {instancePath:instancePath+"/segments/" + i1,schemaPath:"#/properties/segments/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err41];}else {vErrors.push(err41);}errors++;}for(const key3 in data20){if(!(((key3 === "from") || (key3 === "to")) || (key3 === "label"))){const err42 = {instancePath:instancePath+"/segments/" + i1,schemaPath:"#/properties/segments/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key3},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err42];}else {vErrors.push(err42);}errors++;}}if(data20.from !== undefined){let data21 = data20.from;if(!((typeof data21 == "number") && (isFinite(data21)))){const err43 = {instancePath:instancePath+"/segments/" + i1+"/from",schemaPath:"#/properties/segments/items/properties/from/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err43];}else {vErrors.push(err43);}errors++;}}if(data20.to !== undefined){let data22 = data20.to;if(!((typeof data22 == "number") && (isFinite(data22)))){const err44 = {instancePath:instancePath+"/segments/" + i1+"/to",schemaPath:"#/properties/segments/items/properties/to/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err44];}else {vErrors.push(err44);}errors++;}}if(data20.label !== undefined){let data23 = data20.label;if(typeof data23 === "string"){if(func2(data23) < 1){const err45 = {instancePath:instancePath+"/segments/" + i1+"/label",schemaPath:"#/properties/segments/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err45];}else {vErrors.push(err45);}errors++;}}else {const err46 = {instancePath:instancePath+"/segments/" + i1+"/label",schemaPath:"#/properties/segments/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err46];}else {vErrors.push(err46);}errors++;}}}else {const err47 = {instancePath:instancePath+"/segments/" + i1,schemaPath:"#/properties/segments/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err47];}else {vErrors.push(err47);}errors++;}}}else {const err48 = {instancePath:instancePath+"/segments",schemaPath:"#/properties/segments/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err48];}else {vErrors.push(err48);}errors++;}}if(data.messages !== undefined){let data24 = data.messages;if(Array.isArray(data24)){if(data24.length < 1){const err49 = {instancePath:instancePath+"/messages",schemaPath:"#/properties/messages/minItems",keyword:"minItems",params:{limit: 1},message:"must NOT have fewer than 1 items"};if(vErrors === null){vErrors = [err49];}else {vErrors.push(err49);}errors++;}const len4 = data24.length;for(let i2=0; i2<len4; i2++){let data25 = data24[i2];if(data25 && typeof data25 == "object" && !Array.isArray(data25)){if(data25.from === undefined){const err50 = {instancePath:instancePath+"/messages/" + i2,schemaPath:"#/properties/messages/items/required",keyword:"required",params:{missingProperty: "from"},message:"must have required property '"+"from"+"'"};if(vErrors === null){vErrors = [err50];}else {vErrors.push(err50);}errors++;}if(data25.to === undefined){const err51 = {instancePath:instancePath+"/messages/" + i2,schemaPath:"#/properties/messages/items/required",keyword:"required",params:{missingProperty: "to"},message:"must have required property '"+"to"+"'"};if(vErrors === null){vErrors = [err51];}else {vErrors.push(err51);}errors++;}if(data25.y === undefined){const err52 = {instancePath:instancePath+"/messages/" + i2,schemaPath:"#/properties/messages/items/required",keyword:"required",params:{missingProperty: "y"},message:"must have required property '"+"y"+"'"};if(vErrors === null){vErrors = [err52];}else {vErrors.push(err52);}errors++;}if(data25.label === undefined){const err53 = {instancePath:instancePath+"/messages/" + i2,schemaPath:"#/properties/messages/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err53];}else {vErrors.push(err53);}errors++;}for(const key4 in data25){if(!(((((((key4 === "id") || (key4 === "from")) || (key4 === "to")) || (key4 === "y")) || (key4 === "label")) || (key4 === "variant")) || (key4 === "note"))){const err54 = {instancePath:instancePath+"/messages/" + i2,schemaPath:"#/properties/messages/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key4},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err54];}else {vErrors.push(err54);}errors++;}}if(data25.id !== undefined){let data26 = data25.id;if(typeof data26 === "string"){if(!pattern4.test(data26)){const err55 = {instancePath:instancePath+"/messages/" + i2+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err55];}else {vErrors.push(err55);}errors++;}}else {const err56 = {instancePath:instancePath+"/messages/" + i2+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err56];}else {vErrors.push(err56);}errors++;}}if(data25.from !== undefined){let data27 = data25.from;if(typeof data27 === "string"){if(!pattern4.test(data27)){const err57 = {instancePath:instancePath+"/messages/" + i2+"/from",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err57];}else {vErrors.push(err57);}errors++;}}else {const err58 = {instancePath:instancePath+"/messages/" + i2+"/from",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err58];}else {vErrors.push(err58);}errors++;}}if(data25.to !== undefined){let data28 = data25.to;if(typeof data28 === "string"){if(!pattern4.test(data28)){const err59 = {instancePath:instancePath+"/messages/" + i2+"/to",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err59];}else {vErrors.push(err59);}errors++;}}else {const err60 = {instancePath:instancePath+"/messages/" + i2+"/to",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err60];}else {vErrors.push(err60);}errors++;}}if(data25.y !== undefined){let data29 = data25.y;if((typeof data29 == "number") && (isFinite(data29))){if(data29 < 160 || isNaN(data29)){const err61 = {instancePath:instancePath+"/messages/" + i2+"/y",schemaPath:"#/properties/messages/items/properties/y/minimum",keyword:"minimum",params:{comparison: ">=", limit: 160},message:"must be >= 160"};if(vErrors === null){vErrors = [err61];}else {vErrors.push(err61);}errors++;}}else {const err62 = {instancePath:instancePath+"/messages/" + i2+"/y",schemaPath:"#/properties/messages/items/properties/y/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err62];}else {vErrors.push(err62);}errors++;}}if(data25.label !== undefined){let data30 = data25.label;if(typeof data30 === "string"){if(func2(data30) < 1){const err63 = {instancePath:instancePath+"/messages/" + i2+"/label",schemaPath:"#/properties/messages/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err63];}else {vErrors.push(err63);}errors++;}}else {const err64 = {instancePath:instancePath+"/messages/" + i2+"/label",schemaPath:"#/properties/messages/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err64];}else {vErrors.push(err64);}errors++;}}if(data25.variant !== undefined){let data31 = data25.variant;if(!(((((data31 === "default") || (data31 === "emphasis")) || (data31 === "security")) || (data31 === "dashed")) || (data31 === "return"))){const err65 = {instancePath:instancePath+"/messages/" + i2+"/variant",schemaPath:"#/properties/messages/items/properties/variant/enum",keyword:"enum",params:{allowedValues: schema53.properties.messages.items.properties.variant.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err65];}else {vErrors.push(err65);}errors++;}}if(data25.note !== undefined){if(typeof data25.note !== "string"){const err66 = {instancePath:instancePath+"/messages/" + i2+"/note",schemaPath:"#/properties/messages/items/properties/note/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err66];}else {vErrors.push(err66);}errors++;}}}else {const err67 = {instancePath:instancePath+"/messages/" + i2,schemaPath:"#/properties/messages/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err67];}else {vErrors.push(err67);}errors++;}}}else {const err68 = {instancePath:instancePath+"/messages",schemaPath:"#/properties/messages/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err68];}else {vErrors.push(err68);}errors++;}}if(data.activations !== undefined){let data33 = data.activations;if(Array.isArray(data33)){const len5 = data33.length;for(let i3=0; i3<len5; i3++){let data34 = data33[i3];if(data34 && typeof data34 == "object" && !Array.isArray(data34)){if(data34.participant === undefined){const err69 = {instancePath:instancePath+"/activations/" + i3,schemaPath:"#/properties/activations/items/required",keyword:"required",params:{missingProperty: "participant"},message:"must have required property '"+"participant"+"'"};if(vErrors === null){vErrors = [err69];}else {vErrors.push(err69);}errors++;}if(data34.from === undefined){const err70 = {instancePath:instancePath+"/activations/" + i3,schemaPath:"#/properties/activations/items/required",keyword:"required",params:{missingProperty: "from"},message:"must have required property '"+"from"+"'"};if(vErrors === null){vErrors = [err70];}else {vErrors.push(err70);}errors++;}if(data34.to === undefined){const err71 = {instancePath:instancePath+"/activations/" + i3,schemaPath:"#/properties/activations/items/required",keyword:"required",params:{missingProperty: "to"},message:"must have required property '"+"to"+"'"};if(vErrors === null){vErrors = [err71];}else {vErrors.push(err71);}errors++;}for(const key5 in data34){if(!((((key5 === "participant") || (key5 === "from")) || (key5 === "to")) || (key5 === "type"))){const err72 = {instancePath:instancePath+"/activations/" + i3,schemaPath:"#/properties/activations/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key5},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err72];}else {vErrors.push(err72);}errors++;}}if(data34.participant !== undefined){let data35 = data34.participant;if(typeof data35 === "string"){if(!pattern4.test(data35)){const err73 = {instancePath:instancePath+"/activations/" + i3+"/participant",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err73];}else {vErrors.push(err73);}errors++;}}else {const err74 = {instancePath:instancePath+"/activations/" + i3+"/participant",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err74];}else {vErrors.push(err74);}errors++;}}if(data34.from !== undefined){let data36 = data34.from;if(!((typeof data36 == "number") && (isFinite(data36)))){const err75 = {instancePath:instancePath+"/activations/" + i3+"/from",schemaPath:"#/properties/activations/items/properties/from/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err75];}else {vErrors.push(err75);}errors++;}}if(data34.to !== undefined){let data37 = data34.to;if(!((typeof data37 == "number") && (isFinite(data37)))){const err76 = {instancePath:instancePath+"/activations/" + i3+"/to",schemaPath:"#/properties/activations/items/properties/to/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err76];}else {vErrors.push(err76);}errors++;}}if(data34.type !== undefined){let data38 = data34.type;if(!(((((((data38 === "frontend") || (data38 === "backend")) || (data38 === "database")) || (data38 === "cloud")) || (data38 === "security")) || (data38 === "messagebus")) || (data38 === "external"))){const err77 = {instancePath:instancePath+"/activations/" + i3+"/type",schemaPath:"common.schema.json#/$defs/componentType/enum",keyword:"enum",params:{allowedValues: schema43.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err77];}else {vErrors.push(err77);}errors++;}}}else {const err78 = {instancePath:instancePath+"/activations/" + i3,schemaPath:"#/properties/activations/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err78];}else {vErrors.push(err78);}errors++;}}}else {const err79 = {instancePath:instancePath+"/activations",schemaPath:"#/properties/activations/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err79];}else {vErrors.push(err79);}errors++;}}if(data.cards !== undefined){let data39 = data.cards;if(Array.isArray(data39)){const len6 = data39.length;for(let i4=0; i4<len6; i4++){let data40 = data39[i4];if(data40 && typeof data40 == "object" && !Array.isArray(data40)){if(data40.dot === undefined){const err80 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "dot"},message:"must have required property '"+"dot"+"'"};if(vErrors === null){vErrors = [err80];}else {vErrors.push(err80);}errors++;}if(data40.title === undefined){const err81 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "title"},message:"must have required property '"+"title"+"'"};if(vErrors === null){vErrors = [err81];}else {vErrors.push(err81);}errors++;}if(data40.items === undefined){const err82 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "items"},message:"must have required property '"+"items"+"'"};if(vErrors === null){vErrors = [err82];}else {vErrors.push(err82);}errors++;}for(const key6 in data40){if(!(((key6 === "dot") || (key6 === "title")) || (key6 === "items"))){const err83 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key6},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err83];}else {vErrors.push(err83);}errors++;}}if(data40.dot !== undefined){let data41 = data40.dot;if(!(((((((data41 === "cyan") || (data41 === "emerald")) || (data41 === "violet")) || (data41 === "amber")) || (data41 === "rose")) || (data41 === "orange")) || (data41 === "slate"))){const err84 = {instancePath:instancePath+"/cards/" + i4+"/dot",schemaPath:"common.schema.json#/$defs/cards/items/properties/dot/enum",keyword:"enum",params:{allowedValues: schema52.items.properties.dot.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err84];}else {vErrors.push(err84);}errors++;}}if(data40.title !== undefined){let data42 = data40.title;if(typeof data42 === "string"){if(func2(data42) < 1){const err85 = {instancePath:instancePath+"/cards/" + i4+"/title",schemaPath:"common.schema.json#/$defs/cards/items/properties/title/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err85];}else {vErrors.push(err85);}errors++;}}else {const err86 = {instancePath:instancePath+"/cards/" + i4+"/title",schemaPath:"common.schema.json#/$defs/cards/items/properties/title/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err86];}else {vErrors.push(err86);}errors++;}}if(data40.items !== undefined){let data43 = data40.items;if(Array.isArray(data43)){const len7 = data43.length;for(let i5=0; i5<len7; i5++){if(typeof data43[i5] !== "string"){const err87 = {instancePath:instancePath+"/cards/" + i4+"/items/" + i5,schemaPath:"common.schema.json#/$defs/cards/items/properties/items/items/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err87];}else {vErrors.push(err87);}errors++;}}}else {const err88 = {instancePath:instancePath+"/cards/" + i4+"/items",schemaPath:"common.schema.json#/$defs/cards/items/properties/items/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err88];}else {vErrors.push(err88);}errors++;}}}else {const err89 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err89];}else {vErrors.push(err89);}errors++;}}}else {const err90 = {instancePath:instancePath+"/cards",schemaPath:"common.schema.json#/$defs/cards/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err90];}else {vErrors.push(err90);}errors++;}}}else {const err91 = {instancePath,schemaPath:"#/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err91];}else {vErrors.push(err91);}errors++;}validate24.errors = vErrors;return errors === 0;}validate24.evaluated = {"props":true,"dynamicProps":false,"dynamicItems":false};export const dataflow = validate27;const schema65 = {"$schema":"https://json-schema.org/draft/2020-12/schema","$id":"https://github.com/tt-a1i/archify/schemas/dataflow.schema.json","title":"Archify Data Flow Diagram","type":"object","additionalProperties":false,"required":["schema_version","diagram_type","meta","stages","nodes","flows"],"properties":{"schema_version":{"const":1},"diagram_type":{"const":"dataflow"},"meta":{"type":"object","additionalProperties":false,"required":["title"],"properties":{"title":{"type":"string","minLength":1},"subtitle":{"type":"string"},"output":{"type":"string"},"animation":{"enum":["trace","none"]},"visual_preset":{"enum":["classic","signal-flow","blueprint","editorial"]},"quality_profile":{"enum":["standard","showcase"]},"views":{"$ref":"common.schema.json#/$defs/guidedViews"},"viewBox":{"type":"array","prefixItems":[{"type":"number","minimum":360},{"type":"number","minimum":360}],"items":false,"minItems":2,"maxItems":2}}},"stages":{"type":"array","minItems":2,"maxItems":5,"items":{"type":"object","additionalProperties":false,"required":["label"],"properties":{"label":{"type":"string","minLength":1}}}},"nodes":{"type":"array","minItems":2,"items":{"type":"object","additionalProperties":false,"required":["id","type","label","stage","row"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"type":{"$ref":"common.schema.json#/$defs/componentType"},"label":{"type":"string","minLength":1},"sublabel":{"type":"string"},"tag":{"type":"string"},"stage":{"type":"integer","minimum":0},"row":{"type":"integer","minimum":0},"width":{"type":"number","minimum":48},"height":{"type":"number","minimum":36},"yOffset":{"type":"number"}}}},"flows":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to","label"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"from":{"$ref":"common.schema.json#/$defs/id"},"to":{"$ref":"common.schema.json#/$defs/id"},"label":{"type":"string","minLength":1},"classification":{"type":"string"},"variant":{"$ref":"common.schema.json#/$defs/variant"},"route":{"enum":["auto","straight","vertical-channel","bottom-channel","top-channel"]},"fromSide":{"enum":["left","right","top","bottom"]},"toSide":{"enum":["left","right","top","bottom"]},"channelX":{"type":"number"},"channelY":{"type":"number"},"labelAt":{"$ref":"common.schema.json#/$defs/point"},"labelDx":{"type":"number"},"labelDy":{"type":"number"},"labelSegment":{"type":"integer","minimum":0},"via":{"type":"array","items":{"$ref":"common.schema.json#/$defs/point"}},"width":{"type":"number","minimum":0.5}}}},"cards":{"$ref":"common.schema.json#/$defs/cards"}}};function validate28(data, {instancePath="", parentData, parentDataProperty, rootData=data, dynamicAnchors={}}={}){let vErrors = null;let errors = 0;const evaluated0 = validate28.evaluated;if(evaluated0.dynamicProps){evaluated0.props = undefined;}if(evaluated0.dynamicItems){evaluated0.items = undefined;}if(Array.isArray(data)){if(data.length > 5){const err0 = {instancePath,schemaPath:"#/maxItems",keyword:"maxItems",params:{limit: 5},message:"must NOT have more than 5 items"};if(vErrors === null){vErrors = [err0];}else {vErrors.push(err0);}errors++;}const len0 = data.length;for(let i0=0; i0<len0; i0++){let data0 = data[i0];if(data0 && typeof data0 == "object" && !Array.isArray(data0)){if(data0.id === undefined){const err1 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err1];}else {vErrors.push(err1);}errors++;}if(data0.label === undefined){const err2 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err2];}else {vErrors.push(err2);}errors++;}if(data0.focus === undefined){const err3 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "focus"},message:"must have required property '"+"focus"+"'"};if(vErrors === null){vErrors = [err3];}else {vErrors.push(err3);}errors++;}for(const key0 in data0){if(!((((key0 === "id") || (key0 === "label")) || (key0 === "focus")) || (key0 === "note"))){const err4 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key0},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err4];}else {vErrors.push(err4);}errors++;}}if(data0.id !== undefined){let data1 = data0.id;if(typeof data1 === "string"){if(!pattern4.test(data1)){const err5 = {instancePath:instancePath+"/" + i0+"/id",schemaPath:"#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err5];}else {vErrors.push(err5);}errors++;}}else {const err6 = {instancePath:instancePath+"/" + i0+"/id",schemaPath:"#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err6];}else {vErrors.push(err6);}errors++;}}if(data0.label !== undefined){let data2 = data0.label;if(typeof data2 === "string"){if(func2(data2) > 48){const err7 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/maxLength",keyword:"maxLength",params:{limit: 48},message:"must NOT have more than 48 characters"};if(vErrors === null){vErrors = [err7];}else {vErrors.push(err7);}errors++;}if(func2(data2) < 1){const err8 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err8];}else {vErrors.push(err8);}errors++;}}else {const err9 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err9];}else {vErrors.push(err9);}errors++;}}if(data0.focus !== undefined){let data3 = data0.focus;if(Array.isArray(data3)){if(data3.length < 1){const err10 = {instancePath:instancePath+"/" + i0+"/focus",schemaPath:"#/items/properties/focus/minItems",keyword:"minItems",params:{limit: 1},message:"must NOT have fewer than 1 items"};if(vErrors === null){vErrors = [err10];}else {vErrors.push(err10);}errors++;}const len1 = data3.length;for(let i1=0; i1<len1; i1++){let data4 = data3[i1];if(typeof data4 === "string"){if(!pattern4.test(data4)){const err11 = {instancePath:instancePath+"/" + i0+"/focus/" + i1,schemaPath:"#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err11];}else {vErrors.push(err11);}errors++;}}else {const err12 = {instancePath:instancePath+"/" + i0+"/focus/" + i1,schemaPath:"#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err12];}else {vErrors.push(err12);}errors++;}}}else {const err13 = {instancePath:instancePath+"/" + i0+"/focus",schemaPath:"#/items/properties/focus/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err13];}else {vErrors.push(err13);}errors++;}}if(data0.note !== undefined){let data5 = data0.note;if(typeof data5 === "string"){if(func2(data5) > 140){const err14 = {instancePath:instancePath+"/" + i0+"/note",schemaPath:"#/items/properties/note/maxLength",keyword:"maxLength",params:{limit: 140},message:"must NOT have more than 140 characters"};if(vErrors === null){vErrors = [err14];}else {vErrors.push(err14);}errors++;}}else {const err15 = {instancePath:instancePath+"/" + i0+"/note",schemaPath:"#/items/properties/note/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err15];}else {vErrors.push(err15);}errors++;}}}else {const err16 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err16];}else {vErrors.push(err16);}errors++;}}}else {const err17 = {instancePath,schemaPath:"#/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err17];}else {vErrors.push(err17);}errors++;}validate28.errors = vErrors;return errors === 0;}validate28.evaluated = {"items":true,"dynamicProps":false,"dynamicItems":false};function validate27(data, {instancePath="", parentData, parentDataProperty, rootData=data, dynamicAnchors={}}={}){/*# sourceURL="https://github.com/tt-a1i/archify/schemas/dataflow.schema.json" */;let vErrors = null;let errors = 0;const evaluated0 = validate27.evaluated;if(evaluated0.dynamicProps){evaluated0.props = undefined;}if(evaluated0.dynamicItems){evaluated0.items = undefined;}if(data && typeof data == "object" && !Array.isArray(data)){if(data.schema_version === undefined){const err0 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "schema_version"},message:"must have required property '"+"schema_version"+"'"};if(vErrors === null){vErrors = [err0];}else {vErrors.push(err0);}errors++;}if(data.diagram_type === undefined){const err1 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "diagram_type"},message:"must have required property '"+"diagram_type"+"'"};if(vErrors === null){vErrors = [err1];}else {vErrors.push(err1);}errors++;}if(data.meta === undefined){const err2 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "meta"},message:"must have required property '"+"meta"+"'"};if(vErrors === null){vErrors = [err2];}else {vErrors.push(err2);}errors++;}if(data.stages === undefined){const err3 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "stages"},message:"must have required property '"+"stages"+"'"};if(vErrors === null){vErrors = [err3];}else {vErrors.push(err3);}errors++;}if(data.nodes === undefined){const err4 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "nodes"},message:"must have required property '"+"nodes"+"'"};if(vErrors === null){vErrors = [err4];}else {vErrors.push(err4);}errors++;}if(data.flows === undefined){const err5 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "flows"},message:"must have required property '"+"flows"+"'"};if(vErrors === null){vErrors = [err5];}else {vErrors.push(err5);}errors++;}for(const key0 in data){if(!(((((((key0 === "schema_version") || (key0 === "diagram_type")) || (key0 === "meta")) || (key0 === "stages")) || (key0 === "nodes")) || (key0 === "flows")) || (key0 === "cards"))){const err6 = {instancePath,schemaPath:"#/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key0},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err6];}else {vErrors.push(err6);}errors++;}}if(data.schema_version !== undefined){if(1 !== data.schema_version){const err7 = {instancePath:instancePath+"/schema_version",schemaPath:"#/properties/schema_version/const",keyword:"const",params:{allowedValue: 1},message:"must be equal to constant"};if(vErrors === null){vErrors = [err7];}else {vErrors.push(err7);}errors++;}}if(data.diagram_type !== undefined){if("dataflow" !== data.diagram_type){const err8 = {instancePath:instancePath+"/diagram_type",schemaPath:"#/properties/diagram_type/const",keyword:"const",params:{allowedValue: "dataflow"},message:"must be equal to constant"};if(vErrors === null){vErrors = [err8];}else {vErrors.push(err8);}errors++;}}if(data.meta !== undefined){let data2 = data.meta;if(data2 && typeof data2 == "object" && !Array.isArray(data2)){if(data2.title === undefined){const err9 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/required",keyword:"required",params:{missingProperty: "title"},message:"must have required property '"+"title"+"'"};if(vErrors === null){vErrors = [err9];}else {vErrors.push(err9);}errors++;}for(const key1 in data2){if(!((((((((key1 === "title") || (key1 === "subtitle")) || (key1 === "output")) || (key1 === "animation")) || (key1 === "visual_preset")) || (key1 === "quality_profile")) || (key1 === "views")) || (key1 === "viewBox"))){const err10 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key1},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err10];}else {vErrors.push(err10);}errors++;}}if(data2.title !== undefined){let data3 = data2.title;if(typeof data3 === "string"){if(func2(data3) < 1){const err11 = {instancePath:instancePath+"/meta/title",schemaPath:"#/properties/meta/properties/title/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err11];}else {vErrors.push(err11);}errors++;}}else {const err12 = {instancePath:instancePath+"/meta/title",schemaPath:"#/properties/meta/properties/title/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err12];}else {vErrors.push(err12);}errors++;}}if(data2.subtitle !== undefined){if(typeof data2.subtitle !== "string"){const err13 = {instancePath:instancePath+"/meta/subtitle",schemaPath:"#/properties/meta/properties/subtitle/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err13];}else {vErrors.push(err13);}errors++;}}if(data2.output !== undefined){if(typeof data2.output !== "string"){const err14 = {instancePath:instancePath+"/meta/output",schemaPath:"#/properties/meta/properties/output/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err14];}else {vErrors.push(err14);}errors++;}}if(data2.animation !== undefined){let data6 = data2.animation;if(!((data6 === "trace") || (data6 === "none"))){const err15 = {instancePath:instancePath+"/meta/animation",schemaPath:"#/properties/meta/properties/animation/enum",keyword:"enum",params:{allowedValues: schema65.properties.meta.properties.animation.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err15];}else {vErrors.push(err15);}errors++;}}if(data2.visual_preset !== undefined){let data7 = data2.visual_preset;if(!((((data7 === "classic") || (data7 === "signal-flow")) || (data7 === "blueprint")) || (data7 === "editorial"))){const err16 = {instancePath:instancePath+"/meta/visual_preset",schemaPath:"#/properties/meta/properties/visual_preset/enum",keyword:"enum",params:{allowedValues: schema65.properties.meta.properties.visual_preset.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err16];}else {vErrors.push(err16);}errors++;}}if(data2.quality_profile !== undefined){let data8 = data2.quality_profile;if(!((data8 === "standard") || (data8 === "showcase"))){const err17 = {instancePath:instancePath+"/meta/quality_profile",schemaPath:"#/properties/meta/properties/quality_profile/enum",keyword:"enum",params:{allowedValues: schema65.properties.meta.properties.quality_profile.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err17];}else {vErrors.push(err17);}errors++;}}if(data2.views !== undefined){if(!(validate28(data2.views, {instancePath:instancePath+"/meta/views",parentData:data2,parentDataProperty:"views",rootData,dynamicAnchors}))){vErrors = vErrors === null ? validate28.errors : vErrors.concat(validate28.errors);errors = vErrors.length;}}if(data2.viewBox !== undefined){let data10 = data2.viewBox;if(Array.isArray(data10)){if(data10.length > 2){const err18 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err18];}else {vErrors.push(err18);}errors++;}if(data10.length < 2){const err19 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err19];}else {vErrors.push(err19);}errors++;}const len0 = data10.length;if(len0 > 0){let data11 = data10[0];if((typeof data11 == "number") && (isFinite(data11))){if(data11 < 360 || isNaN(data11)){const err20 = {instancePath:instancePath+"/meta/viewBox/0",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/0/minimum",keyword:"minimum",params:{comparison: ">=", limit: 360},message:"must be >= 360"};if(vErrors === null){vErrors = [err20];}else {vErrors.push(err20);}errors++;}}else {const err21 = {instancePath:instancePath+"/meta/viewBox/0",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err21];}else {vErrors.push(err21);}errors++;}}if(len0 > 1){let data12 = data10[1];if((typeof data12 == "number") && (isFinite(data12))){if(data12 < 360 || isNaN(data12)){const err22 = {instancePath:instancePath+"/meta/viewBox/1",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/1/minimum",keyword:"minimum",params:{comparison: ">=", limit: 360},message:"must be >= 360"};if(vErrors === null){vErrors = [err22];}else {vErrors.push(err22);}errors++;}}else {const err23 = {instancePath:instancePath+"/meta/viewBox/1",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err23];}else {vErrors.push(err23);}errors++;}}const len1 = data10.length;if(!(len1 <= 2)){const err24 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err24];}else {vErrors.push(err24);}errors++;}}else {const err25 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err25];}else {vErrors.push(err25);}errors++;}}}else {const err26 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err26];}else {vErrors.push(err26);}errors++;}}if(data.stages !== undefined){let data13 = data.stages;if(Array.isArray(data13)){if(data13.length > 5){const err27 = {instancePath:instancePath+"/stages",schemaPath:"#/properties/stages/maxItems",keyword:"maxItems",params:{limit: 5},message:"must NOT have more than 5 items"};if(vErrors === null){vErrors = [err27];}else {vErrors.push(err27);}errors++;}if(data13.length < 2){const err28 = {instancePath:instancePath+"/stages",schemaPath:"#/properties/stages/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err28];}else {vErrors.push(err28);}errors++;}const len2 = data13.length;for(let i0=0; i0<len2; i0++){let data14 = data13[i0];if(data14 && typeof data14 == "object" && !Array.isArray(data14)){if(data14.label === undefined){const err29 = {instancePath:instancePath+"/stages/" + i0,schemaPath:"#/properties/stages/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err29];}else {vErrors.push(err29);}errors++;}for(const key2 in data14){if(!(key2 === "label")){const err30 = {instancePath:instancePath+"/stages/" + i0,schemaPath:"#/properties/stages/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key2},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err30];}else {vErrors.push(err30);}errors++;}}if(data14.label !== undefined){let data15 = data14.label;if(typeof data15 === "string"){if(func2(data15) < 1){const err31 = {instancePath:instancePath+"/stages/" + i0+"/label",schemaPath:"#/properties/stages/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err31];}else {vErrors.push(err31);}errors++;}}else {const err32 = {instancePath:instancePath+"/stages/" + i0+"/label",schemaPath:"#/properties/stages/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err32];}else {vErrors.push(err32);}errors++;}}}else {const err33 = {instancePath:instancePath+"/stages/" + i0,schemaPath:"#/properties/stages/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err33];}else {vErrors.push(err33);}errors++;}}}else {const err34 = {instancePath:instancePath+"/stages",schemaPath:"#/properties/stages/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err34];}else {vErrors.push(err34);}errors++;}}if(data.nodes !== undefined){let data16 = data.nodes;if(Array.isArray(data16)){if(data16.length < 2){const err35 = {instancePath:instancePath+"/nodes",schemaPath:"#/properties/nodes/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err35];}else {vErrors.push(err35);}errors++;}const len3 = data16.length;for(let i1=0; i1<len3; i1++){let data17 = data16[i1];if(data17 && typeof data17 == "object" && !Array.isArray(data17)){if(data17.id === undefined){const err36 = {instancePath:instancePath+"/nodes/" + i1,schemaPath:"#/properties/nodes/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err36];}else {vErrors.push(err36);}errors++;}if(data17.type === undefined){const err37 = {instancePath:instancePath+"/nodes/" + i1,schemaPath:"#/properties/nodes/items/required",keyword:"required",params:{missingProperty: "type"},message:"must have required property '"+"type"+"'"};if(vErrors === null){vErrors = [err37];}else {vErrors.push(err37);}errors++;}if(data17.label === undefined){const err38 = {instancePath:instancePath+"/nodes/" + i1,schemaPath:"#/properties/nodes/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err38];}else {vErrors.push(err38);}errors++;}if(data17.stage === undefined){const err39 = {instancePath:instancePath+"/nodes/" + i1,schemaPath:"#/properties/nodes/items/required",keyword:"required",params:{missingProperty: "stage"},message:"must have required property '"+"stage"+"'"};if(vErrors === null){vErrors = [err39];}else {vErrors.push(err39);}errors++;}if(data17.row === undefined){const err40 = {instancePath:instancePath+"/nodes/" + i1,schemaPath:"#/properties/nodes/items/required",keyword:"required",params:{missingProperty: "row"},message:"must have required property '"+"row"+"'"};if(vErrors === null){vErrors = [err40];}else {vErrors.push(err40);}errors++;}for(const key3 in data17){if(!(func1.call(schema65.properties.nodes.items.properties, key3))){const err41 = {instancePath:instancePath+"/nodes/" + i1,schemaPath:"#/properties/nodes/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key3},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err41];}else {vErrors.push(err41);}errors++;}}if(data17.id !== undefined){let data18 = data17.id;if(typeof data18 === "string"){if(!pattern4.test(data18)){const err42 = {instancePath:instancePath+"/nodes/" + i1+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err42];}else {vErrors.push(err42);}errors++;}}else {const err43 = {instancePath:instancePath+"/nodes/" + i1+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err43];}else {vErrors.push(err43);}errors++;}}if(data17.type !== undefined){let data19 = data17.type;if(!(((((((data19 === "frontend") || (data19 === "backend")) || (data19 === "database")) || (data19 === "cloud")) || (data19 === "security")) || (data19 === "messagebus")) || (data19 === "external"))){const err44 = {instancePath:instancePath+"/nodes/" + i1+"/type",schemaPath:"common.schema.json#/$defs/componentType/enum",keyword:"enum",params:{allowedValues: schema43.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err44];}else {vErrors.push(err44);}errors++;}}if(data17.label !== undefined){let data20 = data17.label;if(typeof data20 === "string"){if(func2(data20) < 1){const err45 = {instancePath:instancePath+"/nodes/" + i1+"/label",schemaPath:"#/properties/nodes/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err45];}else {vErrors.push(err45);}errors++;}}else {const err46 = {instancePath:instancePath+"/nodes/" + i1+"/label",schemaPath:"#/properties/nodes/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err46];}else {vErrors.push(err46);}errors++;}}if(data17.sublabel !== undefined){if(typeof data17.sublabel !== "string"){const err47 = {instancePath:instancePath+"/nodes/" + i1+"/sublabel",schemaPath:"#/properties/nodes/items/properties/sublabel/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err47];}else {vErrors.push(err47);}errors++;}}if(data17.tag !== undefined){if(typeof data17.tag !== "string"){const err48 = {instancePath:instancePath+"/nodes/" + i1+"/tag",schemaPath:"#/properties/nodes/items/properties/tag/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err48];}else {vErrors.push(err48);}errors++;}}if(data17.stage !== undefined){let data23 = data17.stage;if(!(((typeof data23 == "number") && (!(data23 % 1) && !isNaN(data23))) && (isFinite(data23)))){const err49 = {instancePath:instancePath+"/nodes/" + i1+"/stage",schemaPath:"#/properties/nodes/items/properties/stage/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err49];}else {vErrors.push(err49);}errors++;}if((typeof data23 == "number") && (isFinite(data23))){if(data23 < 0 || isNaN(data23)){const err50 = {instancePath:instancePath+"/nodes/" + i1+"/stage",schemaPath:"#/properties/nodes/items/properties/stage/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err50];}else {vErrors.push(err50);}errors++;}}}if(data17.row !== undefined){let data24 = data17.row;if(!(((typeof data24 == "number") && (!(data24 % 1) && !isNaN(data24))) && (isFinite(data24)))){const err51 = {instancePath:instancePath+"/nodes/" + i1+"/row",schemaPath:"#/properties/nodes/items/properties/row/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err51];}else {vErrors.push(err51);}errors++;}if((typeof data24 == "number") && (isFinite(data24))){if(data24 < 0 || isNaN(data24)){const err52 = {instancePath:instancePath+"/nodes/" + i1+"/row",schemaPath:"#/properties/nodes/items/properties/row/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err52];}else {vErrors.push(err52);}errors++;}}}if(data17.width !== undefined){let data25 = data17.width;if((typeof data25 == "number") && (isFinite(data25))){if(data25 < 48 || isNaN(data25)){const err53 = {instancePath:instancePath+"/nodes/" + i1+"/width",schemaPath:"#/properties/nodes/items/properties/width/minimum",keyword:"minimum",params:{comparison: ">=", limit: 48},message:"must be >= 48"};if(vErrors === null){vErrors = [err53];}else {vErrors.push(err53);}errors++;}}else {const err54 = {instancePath:instancePath+"/nodes/" + i1+"/width",schemaPath:"#/properties/nodes/items/properties/width/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err54];}else {vErrors.push(err54);}errors++;}}if(data17.height !== undefined){let data26 = data17.height;if((typeof data26 == "number") && (isFinite(data26))){if(data26 < 36 || isNaN(data26)){const err55 = {instancePath:instancePath+"/nodes/" + i1+"/height",schemaPath:"#/properties/nodes/items/properties/height/minimum",keyword:"minimum",params:{comparison: ">=", limit: 36},message:"must be >= 36"};if(vErrors === null){vErrors = [err55];}else {vErrors.push(err55);}errors++;}}else {const err56 = {instancePath:instancePath+"/nodes/" + i1+"/height",schemaPath:"#/properties/nodes/items/properties/height/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err56];}else {vErrors.push(err56);}errors++;}}if(data17.yOffset !== undefined){let data27 = data17.yOffset;if(!((typeof data27 == "number") && (isFinite(data27)))){const err57 = {instancePath:instancePath+"/nodes/" + i1+"/yOffset",schemaPath:"#/properties/nodes/items/properties/yOffset/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err57];}else {vErrors.push(err57);}errors++;}}}else {const err58 = {instancePath:instancePath+"/nodes/" + i1,schemaPath:"#/properties/nodes/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err58];}else {vErrors.push(err58);}errors++;}}}else {const err59 = {instancePath:instancePath+"/nodes",schemaPath:"#/properties/nodes/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err59];}else {vErrors.push(err59);}errors++;}}if(data.flows !== undefined){let data28 = data.flows;if(Array.isArray(data28)){const len4 = data28.length;for(let i2=0; i2<len4; i2++){let data29 = data28[i2];if(data29 && typeof data29 == "object" && !Array.isArray(data29)){if(data29.from === undefined){const err60 = {instancePath:instancePath+"/flows/" + i2,schemaPath:"#/properties/flows/items/required",keyword:"required",params:{missingProperty: "from"},message:"must have required property '"+"from"+"'"};if(vErrors === null){vErrors = [err60];}else {vErrors.push(err60);}errors++;}if(data29.to === undefined){const err61 = {instancePath:instancePath+"/flows/" + i2,schemaPath:"#/properties/flows/items/required",keyword:"required",params:{missingProperty: "to"},message:"must have required property '"+"to"+"'"};if(vErrors === null){vErrors = [err61];}else {vErrors.push(err61);}errors++;}if(data29.label === undefined){const err62 = {instancePath:instancePath+"/flows/" + i2,schemaPath:"#/properties/flows/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err62];}else {vErrors.push(err62);}errors++;}for(const key4 in data29){if(!(func1.call(schema65.properties.flows.items.properties, key4))){const err63 = {instancePath:instancePath+"/flows/" + i2,schemaPath:"#/properties/flows/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key4},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err63];}else {vErrors.push(err63);}errors++;}}if(data29.id !== undefined){let data30 = data29.id;if(typeof data30 === "string"){if(!pattern4.test(data30)){const err64 = {instancePath:instancePath+"/flows/" + i2+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err64];}else {vErrors.push(err64);}errors++;}}else {const err65 = {instancePath:instancePath+"/flows/" + i2+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err65];}else {vErrors.push(err65);}errors++;}}if(data29.from !== undefined){let data31 = data29.from;if(typeof data31 === "string"){if(!pattern4.test(data31)){const err66 = {instancePath:instancePath+"/flows/" + i2+"/from",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err66];}else {vErrors.push(err66);}errors++;}}else {const err67 = {instancePath:instancePath+"/flows/" + i2+"/from",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err67];}else {vErrors.push(err67);}errors++;}}if(data29.to !== undefined){let data32 = data29.to;if(typeof data32 === "string"){if(!pattern4.test(data32)){const err68 = {instancePath:instancePath+"/flows/" + i2+"/to",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err68];}else {vErrors.push(err68);}errors++;}}else {const err69 = {instancePath:instancePath+"/flows/" + i2+"/to",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err69];}else {vErrors.push(err69);}errors++;}}if(data29.label !== undefined){let data33 = data29.label;if(typeof data33 === "string"){if(func2(data33) < 1){const err70 = {instancePath:instancePath+"/flows/" + i2+"/label",schemaPath:"#/properties/flows/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err70];}else {vErrors.push(err70);}errors++;}}else {const err71 = {instancePath:instancePath+"/flows/" + i2+"/label",schemaPath:"#/properties/flows/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err71];}else {vErrors.push(err71);}errors++;}}if(data29.classification !== undefined){if(typeof data29.classification !== "string"){const err72 = {instancePath:instancePath+"/flows/" + i2+"/classification",schemaPath:"#/properties/flows/items/properties/classification/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err72];}else {vErrors.push(err72);}errors++;}}if(data29.variant !== undefined){let data35 = data29.variant;if(!((((data35 === "default") || (data35 === "emphasis")) || (data35 === "security")) || (data35 === "dashed"))){const err73 = {instancePath:instancePath+"/flows/" + i2+"/variant",schemaPath:"common.schema.json#/$defs/variant/enum",keyword:"enum",params:{allowedValues: schema47.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err73];}else {vErrors.push(err73);}errors++;}}if(data29.route !== undefined){let data36 = data29.route;if(!(((((data36 === "auto") || (data36 === "straight")) || (data36 === "vertical-channel")) || (data36 === "bottom-channel")) || (data36 === "top-channel"))){const err74 = {instancePath:instancePath+"/flows/" + i2+"/route",schemaPath:"#/properties/flows/items/properties/route/enum",keyword:"enum",params:{allowedValues: schema65.properties.flows.items.properties.route.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err74];}else {vErrors.push(err74);}errors++;}}if(data29.fromSide !== undefined){let data37 = data29.fromSide;if(!((((data37 === "left") || (data37 === "right")) || (data37 === "top")) || (data37 === "bottom"))){const err75 = {instancePath:instancePath+"/flows/" + i2+"/fromSide",schemaPath:"#/properties/flows/items/properties/fromSide/enum",keyword:"enum",params:{allowedValues: schema65.properties.flows.items.properties.fromSide.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err75];}else {vErrors.push(err75);}errors++;}}if(data29.toSide !== undefined){let data38 = data29.toSide;if(!((((data38 === "left") || (data38 === "right")) || (data38 === "top")) || (data38 === "bottom"))){const err76 = {instancePath:instancePath+"/flows/" + i2+"/toSide",schemaPath:"#/properties/flows/items/properties/toSide/enum",keyword:"enum",params:{allowedValues: schema65.properties.flows.items.properties.toSide.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err76];}else {vErrors.push(err76);}errors++;}}if(data29.channelX !== undefined){let data39 = data29.channelX;if(!((typeof data39 == "number") && (isFinite(data39)))){const err77 = {instancePath:instancePath+"/flows/" + i2+"/channelX",schemaPath:"#/properties/flows/items/properties/channelX/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err77];}else {vErrors.push(err77);}errors++;}}if(data29.channelY !== undefined){let data40 = data29.channelY;if(!((typeof data40 == "number") && (isFinite(data40)))){const err78 = {instancePath:instancePath+"/flows/" + i2+"/channelY",schemaPath:"#/properties/flows/items/properties/channelY/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err78];}else {vErrors.push(err78);}errors++;}}if(data29.labelAt !== undefined){let data41 = data29.labelAt;if(Array.isArray(data41)){if(data41.length > 2){const err79 = {instancePath:instancePath+"/flows/" + i2+"/labelAt",schemaPath:"common.schema.json#/$defs/point/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err79];}else {vErrors.push(err79);}errors++;}if(data41.length < 2){const err80 = {instancePath:instancePath+"/flows/" + i2+"/labelAt",schemaPath:"common.schema.json#/$defs/point/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err80];}else {vErrors.push(err80);}errors++;}const len5 = data41.length;if(len5 > 0){let data42 = data41[0];if(!((typeof data42 == "number") && (isFinite(data42)))){const err81 = {instancePath:instancePath+"/flows/" + i2+"/labelAt/0",schemaPath:"common.schema.json#/$defs/point/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err81];}else {vErrors.push(err81);}errors++;}}if(len5 > 1){let data43 = data41[1];if(!((typeof data43 == "number") && (isFinite(data43)))){const err82 = {instancePath:instancePath+"/flows/" + i2+"/labelAt/1",schemaPath:"common.schema.json#/$defs/point/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err82];}else {vErrors.push(err82);}errors++;}}const len6 = data41.length;if(!(len6 <= 2)){const err83 = {instancePath:instancePath+"/flows/" + i2+"/labelAt",schemaPath:"common.schema.json#/$defs/point/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err83];}else {vErrors.push(err83);}errors++;}}else {const err84 = {instancePath:instancePath+"/flows/" + i2+"/labelAt",schemaPath:"common.schema.json#/$defs/point/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err84];}else {vErrors.push(err84);}errors++;}}if(data29.labelDx !== undefined){let data44 = data29.labelDx;if(!((typeof data44 == "number") && (isFinite(data44)))){const err85 = {instancePath:instancePath+"/flows/" + i2+"/labelDx",schemaPath:"#/properties/flows/items/properties/labelDx/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err85];}else {vErrors.push(err85);}errors++;}}if(data29.labelDy !== undefined){let data45 = data29.labelDy;if(!((typeof data45 == "number") && (isFinite(data45)))){const err86 = {instancePath:instancePath+"/flows/" + i2+"/labelDy",schemaPath:"#/properties/flows/items/properties/labelDy/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err86];}else {vErrors.push(err86);}errors++;}}if(data29.labelSegment !== undefined){let data46 = data29.labelSegment;if(!(((typeof data46 == "number") && (!(data46 % 1) && !isNaN(data46))) && (isFinite(data46)))){const err87 = {instancePath:instancePath+"/flows/" + i2+"/labelSegment",schemaPath:"#/properties/flows/items/properties/labelSegment/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err87];}else {vErrors.push(err87);}errors++;}if((typeof data46 == "number") && (isFinite(data46))){if(data46 < 0 || isNaN(data46)){const err88 = {instancePath:instancePath+"/flows/" + i2+"/labelSegment",schemaPath:"#/properties/flows/items/properties/labelSegment/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err88];}else {vErrors.push(err88);}errors++;}}}if(data29.via !== undefined){let data47 = data29.via;if(Array.isArray(data47)){const len7 = data47.length;for(let i3=0; i3<len7; i3++){let data48 = data47[i3];if(Array.isArray(data48)){if(data48.length > 2){const err89 = {instancePath:instancePath+"/flows/" + i2+"/via/" + i3,schemaPath:"common.schema.json#/$defs/point/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err89];}else {vErrors.push(err89);}errors++;}if(data48.length < 2){const err90 = {instancePath:instancePath+"/flows/" + i2+"/via/" + i3,schemaPath:"common.schema.json#/$defs/point/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err90];}else {vErrors.push(err90);}errors++;}const len8 = data48.length;if(len8 > 0){let data49 = data48[0];if(!((typeof data49 == "number") && (isFinite(data49)))){const err91 = {instancePath:instancePath+"/flows/" + i2+"/via/" + i3+"/0",schemaPath:"common.schema.json#/$defs/point/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err91];}else {vErrors.push(err91);}errors++;}}if(len8 > 1){let data50 = data48[1];if(!((typeof data50 == "number") && (isFinite(data50)))){const err92 = {instancePath:instancePath+"/flows/" + i2+"/via/" + i3+"/1",schemaPath:"common.schema.json#/$defs/point/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err92];}else {vErrors.push(err92);}errors++;}}const len9 = data48.length;if(!(len9 <= 2)){const err93 = {instancePath:instancePath+"/flows/" + i2+"/via/" + i3,schemaPath:"common.schema.json#/$defs/point/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err93];}else {vErrors.push(err93);}errors++;}}else {const err94 = {instancePath:instancePath+"/flows/" + i2+"/via/" + i3,schemaPath:"common.schema.json#/$defs/point/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err94];}else {vErrors.push(err94);}errors++;}}}else {const err95 = {instancePath:instancePath+"/flows/" + i2+"/via",schemaPath:"#/properties/flows/items/properties/via/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err95];}else {vErrors.push(err95);}errors++;}}if(data29.width !== undefined){let data51 = data29.width;if((typeof data51 == "number") && (isFinite(data51))){if(data51 < 0.5 || isNaN(data51)){const err96 = {instancePath:instancePath+"/flows/" + i2+"/width",schemaPath:"#/properties/flows/items/properties/width/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0.5},message:"must be >= 0.5"};if(vErrors === null){vErrors = [err96];}else {vErrors.push(err96);}errors++;}}else {const err97 = {instancePath:instancePath+"/flows/" + i2+"/width",schemaPath:"#/properties/flows/items/properties/width/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err97];}else {vErrors.push(err97);}errors++;}}}else {const err98 = {instancePath:instancePath+"/flows/" + i2,schemaPath:"#/properties/flows/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err98];}else {vErrors.push(err98);}errors++;}}}else {const err99 = {instancePath:instancePath+"/flows",schemaPath:"#/properties/flows/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err99];}else {vErrors.push(err99);}errors++;}}if(data.cards !== undefined){let data52 = data.cards;if(Array.isArray(data52)){const len10 = data52.length;for(let i4=0; i4<len10; i4++){let data53 = data52[i4];if(data53 && typeof data53 == "object" && !Array.isArray(data53)){if(data53.dot === undefined){const err100 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "dot"},message:"must have required property '"+"dot"+"'"};if(vErrors === null){vErrors = [err100];}else {vErrors.push(err100);}errors++;}if(data53.title === undefined){const err101 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "title"},message:"must have required property '"+"title"+"'"};if(vErrors === null){vErrors = [err101];}else {vErrors.push(err101);}errors++;}if(data53.items === undefined){const err102 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "items"},message:"must have required property '"+"items"+"'"};if(vErrors === null){vErrors = [err102];}else {vErrors.push(err102);}errors++;}for(const key5 in data53){if(!(((key5 === "dot") || (key5 === "title")) || (key5 === "items"))){const err103 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key5},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err103];}else {vErrors.push(err103);}errors++;}}if(data53.dot !== undefined){let data54 = data53.dot;if(!(((((((data54 === "cyan") || (data54 === "emerald")) || (data54 === "violet")) || (data54 === "amber")) || (data54 === "rose")) || (data54 === "orange")) || (data54 === "slate"))){const err104 = {instancePath:instancePath+"/cards/" + i4+"/dot",schemaPath:"common.schema.json#/$defs/cards/items/properties/dot/enum",keyword:"enum",params:{allowedValues: schema52.items.properties.dot.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err104];}else {vErrors.push(err104);}errors++;}}if(data53.title !== undefined){let data55 = data53.title;if(typeof data55 === "string"){if(func2(data55) < 1){const err105 = {instancePath:instancePath+"/cards/" + i4+"/title",schemaPath:"common.schema.json#/$defs/cards/items/properties/title/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err105];}else {vErrors.push(err105);}errors++;}}else {const err106 = {instancePath:instancePath+"/cards/" + i4+"/title",schemaPath:"common.schema.json#/$defs/cards/items/properties/title/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err106];}else {vErrors.push(err106);}errors++;}}if(data53.items !== undefined){let data56 = data53.items;if(Array.isArray(data56)){const len11 = data56.length;for(let i5=0; i5<len11; i5++){if(typeof data56[i5] !== "string"){const err107 = {instancePath:instancePath+"/cards/" + i4+"/items/" + i5,schemaPath:"common.schema.json#/$defs/cards/items/properties/items/items/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err107];}else {vErrors.push(err107);}errors++;}}}else {const err108 = {instancePath:instancePath+"/cards/" + i4+"/items",schemaPath:"common.schema.json#/$defs/cards/items/properties/items/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err108];}else {vErrors.push(err108);}errors++;}}}else {const err109 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err109];}else {vErrors.push(err109);}errors++;}}}else {const err110 = {instancePath:instancePath+"/cards",schemaPath:"common.schema.json#/$defs/cards/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err110];}else {vErrors.push(err110);}errors++;}}}else {const err111 = {instancePath,schemaPath:"#/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err111];}else {vErrors.push(err111);}errors++;}validate27.errors = vErrors;return errors === 0;}validate27.evaluated = {"props":true,"dynamicProps":false,"dynamicItems":false};export const lifecycle = validate30;const schema78 = {"$schema":"https://json-schema.org/draft/2020-12/schema","$id":"https://github.com/tt-a1i/archify/schemas/lifecycle.schema.json","title":"Archify Lifecycle Diagram","type":"object","additionalProperties":false,"required":["schema_version","diagram_type","meta","lanes","states","transitions"],"properties":{"schema_version":{"const":1},"diagram_type":{"const":"lifecycle"},"meta":{"type":"object","additionalProperties":false,"required":["title"],"properties":{"title":{"type":"string","minLength":1},"subtitle":{"type":"string"},"output":{"type":"string"},"animation":{"enum":["trace","none"]},"visual_preset":{"enum":["classic","signal-flow","blueprint","editorial"]},"quality_profile":{"enum":["standard","showcase"]},"views":{"$ref":"common.schema.json#/$defs/guidedViews"},"viewBox":{"type":"array","prefixItems":[{"type":"number","minimum":420},{"type":"number","minimum":566}],"items":false,"minItems":2,"maxItems":2}}},"lanes":{"type":"array","minItems":1,"maxItems":4,"items":{"type":"object","additionalProperties":false,"required":["id","label"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"label":{"type":"string","minLength":1}}}},"states":{"type":"array","minItems":2,"items":{"type":"object","additionalProperties":false,"required":["id","type","label","lane","col"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"type":{"enum":["start","active","waiting","decision","success","failure","neutral","external"]},"label":{"type":"string","minLength":1},"sublabel":{"type":"string"},"tag":{"type":"string"},"step":{"type":"string"},"lane":{"$ref":"common.schema.json#/$defs/id"},"col":{"type":"integer","minimum":0,"maximum":4},"width":{"type":"number","minimum":48},"height":{"type":"number","minimum":36},"yOffset":{"type":"number"}}}},"transitions":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"from":{"$ref":"common.schema.json#/$defs/id"},"to":{"$ref":"common.schema.json#/$defs/id"},"label":{"type":"string"},"note":{"type":"string"},"variant":{"$ref":"common.schema.json#/$defs/variant"},"route":{"enum":["auto","straight","drop","bottom-channel","top-channel","right-channel","left-channel"]},"fromSide":{"enum":["left","right","top","bottom"]},"toSide":{"enum":["left","right","top","bottom"]},"channelX":{"type":"number"},"channelY":{"type":"number"},"cornerRadius":{"type":"number","minimum":0},"labelAt":{"$ref":"common.schema.json#/$defs/point"},"labelDx":{"type":"number"},"labelDy":{"type":"number"},"labelSegment":{"type":"integer","minimum":0},"via":{"type":"array","items":{"$ref":"common.schema.json#/$defs/point"}},"width":{"type":"number","minimum":0.5}}}},"cards":{"$ref":"common.schema.json#/$defs/cards"}}};function validate31(data, {instancePath="", parentData, parentDataProperty, rootData=data, dynamicAnchors={}}={}){let vErrors = null;let errors = 0;const evaluated0 = validate31.evaluated;if(evaluated0.dynamicProps){evaluated0.props = undefined;}if(evaluated0.dynamicItems){evaluated0.items = undefined;}if(Array.isArray(data)){if(data.length > 5){const err0 = {instancePath,schemaPath:"#/maxItems",keyword:"maxItems",params:{limit: 5},message:"must NOT have more than 5 items"};if(vErrors === null){vErrors = [err0];}else {vErrors.push(err0);}errors++;}const len0 = data.length;for(let i0=0; i0<len0; i0++){let data0 = data[i0];if(data0 && typeof data0 == "object" && !Array.isArray(data0)){if(data0.id === undefined){const err1 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err1];}else {vErrors.push(err1);}errors++;}if(data0.label === undefined){const err2 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err2];}else {vErrors.push(err2);}errors++;}if(data0.focus === undefined){const err3 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "focus"},message:"must have required property '"+"focus"+"'"};if(vErrors === null){vErrors = [err3];}else {vErrors.push(err3);}errors++;}for(const key0 in data0){if(!((((key0 === "id") || (key0 === "label")) || (key0 === "focus")) || (key0 === "note"))){const err4 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key0},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err4];}else {vErrors.push(err4);}errors++;}}if(data0.id !== undefined){let data1 = data0.id;if(typeof data1 === "string"){if(!pattern4.test(data1)){const err5 = {instancePath:instancePath+"/" + i0+"/id",schemaPath:"#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err5];}else {vErrors.push(err5);}errors++;}}else {const err6 = {instancePath:instancePath+"/" + i0+"/id",schemaPath:"#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err6];}else {vErrors.push(err6);}errors++;}}if(data0.label !== undefined){let data2 = data0.label;if(typeof data2 === "string"){if(func2(data2) > 48){const err7 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/maxLength",keyword:"maxLength",params:{limit: 48},message:"must NOT have more than 48 characters"};if(vErrors === null){vErrors = [err7];}else {vErrors.push(err7);}errors++;}if(func2(data2) < 1){const err8 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err8];}else {vErrors.push(err8);}errors++;}}else {const err9 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err9];}else {vErrors.push(err9);}errors++;}}if(data0.focus !== undefined){let data3 = data0.focus;if(Array.isArray(data3)){if(data3.length < 1){const err10 = {instancePath:instancePath+"/" + i0+"/focus",schemaPath:"#/items/properties/focus/minItems",keyword:"minItems",params:{limit: 1},message:"must NOT have fewer than 1 items"};if(vErrors === null){vErrors = [err10];}else {vErrors.push(err10);}errors++;}const len1 = data3.length;for(let i1=0; i1<len1; i1++){let data4 = data3[i1];if(typeof data4 === "string"){if(!pattern4.test(data4)){const err11 = {instancePath:instancePath+"/" + i0+"/focus/" + i1,schemaPath:"#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err11];}else {vErrors.push(err11);}errors++;}}else {const err12 = {instancePath:instancePath+"/" + i0+"/focus/" + i1,schemaPath:"#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err12];}else {vErrors.push(err12);}errors++;}}}else {const err13 = {instancePath:instancePath+"/" + i0+"/focus",schemaPath:"#/items/properties/focus/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err13];}else {vErrors.push(err13);}errors++;}}if(data0.note !== undefined){let data5 = data0.note;if(typeof data5 === "string"){if(func2(data5) > 140){const err14 = {instancePath:instancePath+"/" + i0+"/note",schemaPath:"#/items/properties/note/maxLength",keyword:"maxLength",params:{limit: 140},message:"must NOT have more than 140 characters"};if(vErrors === null){vErrors = [err14];}else {vErrors.push(err14);}errors++;}}else {const err15 = {instancePath:instancePath+"/" + i0+"/note",schemaPath:"#/items/properties/note/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err15];}else {vErrors.push(err15);}errors++;}}}else {const err16 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err16];}else {vErrors.push(err16);}errors++;}}}else {const err17 = {instancePath,schemaPath:"#/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err17];}else {vErrors.push(err17);}errors++;}validate31.errors = vErrors;return errors === 0;}validate31.evaluated = {"items":true,"dynamicProps":false,"dynamicItems":false};function validate30(data, {instancePath="", parentData, parentDataProperty, rootData=data, dynamicAnchors={}}={}){/*# sourceURL="https://github.com/tt-a1i/archify/schemas/lifecycle.schema.json" */;let vErrors = null;let errors = 0;const evaluated0 = validate30.evaluated;if(evaluated0.dynamicProps){evaluated0.props = undefined;}if(evaluated0.dynamicItems){evaluated0.items = undefined;}if(data && typeof data == "object" && !Array.isArray(data)){if(data.schema_version === undefined){const err0 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "schema_version"},message:"must have required property '"+"schema_version"+"'"};if(vErrors === null){vErrors = [err0];}else {vErrors.push(err0);}errors++;}if(data.diagram_type === undefined){const err1 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "diagram_type"},message:"must have required property '"+"diagram_type"+"'"};if(vErrors === null){vErrors = [err1];}else {vErrors.push(err1);}errors++;}if(data.meta === undefined){const err2 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "meta"},message:"must have required property '"+"meta"+"'"};if(vErrors === null){vErrors = [err2];}else {vErrors.push(err2);}errors++;}if(data.lanes === undefined){const err3 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "lanes"},message:"must have required property '"+"lanes"+"'"};if(vErrors === null){vErrors = [err3];}else {vErrors.push(err3);}errors++;}if(data.states === undefined){const err4 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "states"},message:"must have required property '"+"states"+"'"};if(vErrors === null){vErrors = [err4];}else {vErrors.push(err4);}errors++;}if(data.transitions === undefined){const err5 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "transitions"},message:"must have required property '"+"transitions"+"'"};if(vErrors === null){vErrors = [err5];}else {vErrors.push(err5);}errors++;}for(const key0 in data){if(!(((((((key0 === "schema_version") || (key0 === "diagram_type")) || (key0 === "meta")) || (key0 === "lanes")) || (key0 === "states")) || (key0 === "transitions")) || (key0 === "cards"))){const err6 = {instancePath,schemaPath:"#/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key0},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err6];}else {vErrors.push(err6);}errors++;}}if(data.schema_version !== undefined){if(1 !== data.schema_version){const err7 = {instancePath:instancePath+"/schema_version",schemaPath:"#/properties/schema_version/const",keyword:"const",params:{allowedValue: 1},message:"must be equal to constant"};if(vErrors === null){vErrors = [err7];}else {vErrors.push(err7);}errors++;}}if(data.diagram_type !== undefined){if("lifecycle" !== data.diagram_type){const err8 = {instancePath:instancePath+"/diagram_type",schemaPath:"#/properties/diagram_type/const",keyword:"const",params:{allowedValue: "lifecycle"},message:"must be equal to constant"};if(vErrors === null){vErrors = [err8];}else {vErrors.push(err8);}errors++;}}if(data.meta !== undefined){let data2 = data.meta;if(data2 && typeof data2 == "object" && !Array.isArray(data2)){if(data2.title === undefined){const err9 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/required",keyword:"required",params:{missingProperty: "title"},message:"must have required property '"+"title"+"'"};if(vErrors === null){vErrors = [err9];}else {vErrors.push(err9);}errors++;}for(const key1 in data2){if(!((((((((key1 === "title") || (key1 === "subtitle")) || (key1 === "output")) || (key1 === "animation")) || (key1 === "visual_preset")) || (key1 === "quality_profile")) || (key1 === "views")) || (key1 === "viewBox"))){const err10 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key1},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err10];}else {vErrors.push(err10);}errors++;}}if(data2.title !== undefined){let data3 = data2.title;if(typeof data3 === "string"){if(func2(data3) < 1){const err11 = {instancePath:instancePath+"/meta/title",schemaPath:"#/properties/meta/properties/title/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err11];}else {vErrors.push(err11);}errors++;}}else {const err12 = {instancePath:instancePath+"/meta/title",schemaPath:"#/properties/meta/properties/title/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err12];}else {vErrors.push(err12);}errors++;}}if(data2.subtitle !== undefined){if(typeof data2.subtitle !== "string"){const err13 = {instancePath:instancePath+"/meta/subtitle",schemaPath:"#/properties/meta/properties/subtitle/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err13];}else {vErrors.push(err13);}errors++;}}if(data2.output !== undefined){if(typeof data2.output !== "string"){const err14 = {instancePath:instancePath+"/meta/output",schemaPath:"#/properties/meta/properties/output/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err14];}else {vErrors.push(err14);}errors++;}}if(data2.animation !== undefined){let data6 = data2.animation;if(!((data6 === "trace") || (data6 === "none"))){const err15 = {instancePath:instancePath+"/meta/animation",schemaPath:"#/properties/meta/properties/animation/enum",keyword:"enum",params:{allowedValues: schema78.properties.meta.properties.animation.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err15];}else {vErrors.push(err15);}errors++;}}if(data2.visual_preset !== undefined){let data7 = data2.visual_preset;if(!((((data7 === "classic") || (data7 === "signal-flow")) || (data7 === "blueprint")) || (data7 === "editorial"))){const err16 = {instancePath:instancePath+"/meta/visual_preset",schemaPath:"#/properties/meta/properties/visual_preset/enum",keyword:"enum",params:{allowedValues: schema78.properties.meta.properties.visual_preset.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err16];}else {vErrors.push(err16);}errors++;}}if(data2.quality_profile !== undefined){let data8 = data2.quality_profile;if(!((data8 === "standard") || (data8 === "showcase"))){const err17 = {instancePath:instancePath+"/meta/quality_profile",schemaPath:"#/properties/meta/properties/quality_profile/enum",keyword:"enum",params:{allowedValues: schema78.properties.meta.properties.quality_profile.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err17];}else {vErrors.push(err17);}errors++;}}if(data2.views !== undefined){if(!(validate31(data2.views, {instancePath:instancePath+"/meta/views",parentData:data2,parentDataProperty:"views",rootData,dynamicAnchors}))){vErrors = vErrors === null ? validate31.errors : vErrors.concat(validate31.errors);errors = vErrors.length;}}if(data2.viewBox !== undefined){let data10 = data2.viewBox;if(Array.isArray(data10)){if(data10.length > 2){const err18 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err18];}else {vErrors.push(err18);}errors++;}if(data10.length < 2){const err19 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err19];}else {vErrors.push(err19);}errors++;}const len0 = data10.length;if(len0 > 0){let data11 = data10[0];if((typeof data11 == "number") && (isFinite(data11))){if(data11 < 420 || isNaN(data11)){const err20 = {instancePath:instancePath+"/meta/viewBox/0",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/0/minimum",keyword:"minimum",params:{comparison: ">=", limit: 420},message:"must be >= 420"};if(vErrors === null){vErrors = [err20];}else {vErrors.push(err20);}errors++;}}else {const err21 = {instancePath:instancePath+"/meta/viewBox/0",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err21];}else {vErrors.push(err21);}errors++;}}if(len0 > 1){let data12 = data10[1];if((typeof data12 == "number") && (isFinite(data12))){if(data12 < 566 || isNaN(data12)){const err22 = {instancePath:instancePath+"/meta/viewBox/1",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/1/minimum",keyword:"minimum",params:{comparison: ">=", limit: 566},message:"must be >= 566"};if(vErrors === null){vErrors = [err22];}else {vErrors.push(err22);}errors++;}}else {const err23 = {instancePath:instancePath+"/meta/viewBox/1",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err23];}else {vErrors.push(err23);}errors++;}}const len1 = data10.length;if(!(len1 <= 2)){const err24 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err24];}else {vErrors.push(err24);}errors++;}}else {const err25 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err25];}else {vErrors.push(err25);}errors++;}}}else {const err26 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err26];}else {vErrors.push(err26);}errors++;}}if(data.lanes !== undefined){let data13 = data.lanes;if(Array.isArray(data13)){if(data13.length > 4){const err27 = {instancePath:instancePath+"/lanes",schemaPath:"#/properties/lanes/maxItems",keyword:"maxItems",params:{limit: 4},message:"must NOT have more than 4 items"};if(vErrors === null){vErrors = [err27];}else {vErrors.push(err27);}errors++;}if(data13.length < 1){const err28 = {instancePath:instancePath+"/lanes",schemaPath:"#/properties/lanes/minItems",keyword:"minItems",params:{limit: 1},message:"must NOT have fewer than 1 items"};if(vErrors === null){vErrors = [err28];}else {vErrors.push(err28);}errors++;}const len2 = data13.length;for(let i0=0; i0<len2; i0++){let data14 = data13[i0];if(data14 && typeof data14 == "object" && !Array.isArray(data14)){if(data14.id === undefined){const err29 = {instancePath:instancePath+"/lanes/" + i0,schemaPath:"#/properties/lanes/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err29];}else {vErrors.push(err29);}errors++;}if(data14.label === undefined){const err30 = {instancePath:instancePath+"/lanes/" + i0,schemaPath:"#/properties/lanes/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err30];}else {vErrors.push(err30);}errors++;}for(const key2 in data14){if(!((key2 === "id") || (key2 === "label"))){const err31 = {instancePath:instancePath+"/lanes/" + i0,schemaPath:"#/properties/lanes/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key2},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err31];}else {vErrors.push(err31);}errors++;}}if(data14.id !== undefined){let data15 = data14.id;if(typeof data15 === "string"){if(!pattern4.test(data15)){const err32 = {instancePath:instancePath+"/lanes/" + i0+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err32];}else {vErrors.push(err32);}errors++;}}else {const err33 = {instancePath:instancePath+"/lanes/" + i0+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err33];}else {vErrors.push(err33);}errors++;}}if(data14.label !== undefined){let data16 = data14.label;if(typeof data16 === "string"){if(func2(data16) < 1){const err34 = {instancePath:instancePath+"/lanes/" + i0+"/label",schemaPath:"#/properties/lanes/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err34];}else {vErrors.push(err34);}errors++;}}else {const err35 = {instancePath:instancePath+"/lanes/" + i0+"/label",schemaPath:"#/properties/lanes/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err35];}else {vErrors.push(err35);}errors++;}}}else {const err36 = {instancePath:instancePath+"/lanes/" + i0,schemaPath:"#/properties/lanes/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err36];}else {vErrors.push(err36);}errors++;}}}else {const err37 = {instancePath:instancePath+"/lanes",schemaPath:"#/properties/lanes/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err37];}else {vErrors.push(err37);}errors++;}}if(data.states !== undefined){let data17 = data.states;if(Array.isArray(data17)){if(data17.length < 2){const err38 = {instancePath:instancePath+"/states",schemaPath:"#/properties/states/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err38];}else {vErrors.push(err38);}errors++;}const len3 = data17.length;for(let i1=0; i1<len3; i1++){let data18 = data17[i1];if(data18 && typeof data18 == "object" && !Array.isArray(data18)){if(data18.id === undefined){const err39 = {instancePath:instancePath+"/states/" + i1,schemaPath:"#/properties/states/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err39];}else {vErrors.push(err39);}errors++;}if(data18.type === undefined){const err40 = {instancePath:instancePath+"/states/" + i1,schemaPath:"#/properties/states/items/required",keyword:"required",params:{missingProperty: "type"},message:"must have required property '"+"type"+"'"};if(vErrors === null){vErrors = [err40];}else {vErrors.push(err40);}errors++;}if(data18.label === undefined){const err41 = {instancePath:instancePath+"/states/" + i1,schemaPath:"#/properties/states/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err41];}else {vErrors.push(err41);}errors++;}if(data18.lane === undefined){const err42 = {instancePath:instancePath+"/states/" + i1,schemaPath:"#/properties/states/items/required",keyword:"required",params:{missingProperty: "lane"},message:"must have required property '"+"lane"+"'"};if(vErrors === null){vErrors = [err42];}else {vErrors.push(err42);}errors++;}if(data18.col === undefined){const err43 = {instancePath:instancePath+"/states/" + i1,schemaPath:"#/properties/states/items/required",keyword:"required",params:{missingProperty: "col"},message:"must have required property '"+"col"+"'"};if(vErrors === null){vErrors = [err43];}else {vErrors.push(err43);}errors++;}for(const key3 in data18){if(!(func1.call(schema78.properties.states.items.properties, key3))){const err44 = {instancePath:instancePath+"/states/" + i1,schemaPath:"#/properties/states/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key3},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err44];}else {vErrors.push(err44);}errors++;}}if(data18.id !== undefined){let data19 = data18.id;if(typeof data19 === "string"){if(!pattern4.test(data19)){const err45 = {instancePath:instancePath+"/states/" + i1+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err45];}else {vErrors.push(err45);}errors++;}}else {const err46 = {instancePath:instancePath+"/states/" + i1+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err46];}else {vErrors.push(err46);}errors++;}}if(data18.type !== undefined){let data20 = data18.type;if(!((((((((data20 === "start") || (data20 === "active")) || (data20 === "waiting")) || (data20 === "decision")) || (data20 === "success")) || (data20 === "failure")) || (data20 === "neutral")) || (data20 === "external"))){const err47 = {instancePath:instancePath+"/states/" + i1+"/type",schemaPath:"#/properties/states/items/properties/type/enum",keyword:"enum",params:{allowedValues: schema78.properties.states.items.properties.type.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err47];}else {vErrors.push(err47);}errors++;}}if(data18.label !== undefined){let data21 = data18.label;if(typeof data21 === "string"){if(func2(data21) < 1){const err48 = {instancePath:instancePath+"/states/" + i1+"/label",schemaPath:"#/properties/states/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err48];}else {vErrors.push(err48);}errors++;}}else {const err49 = {instancePath:instancePath+"/states/" + i1+"/label",schemaPath:"#/properties/states/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err49];}else {vErrors.push(err49);}errors++;}}if(data18.sublabel !== undefined){if(typeof data18.sublabel !== "string"){const err50 = {instancePath:instancePath+"/states/" + i1+"/sublabel",schemaPath:"#/properties/states/items/properties/sublabel/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err50];}else {vErrors.push(err50);}errors++;}}if(data18.tag !== undefined){if(typeof data18.tag !== "string"){const err51 = {instancePath:instancePath+"/states/" + i1+"/tag",schemaPath:"#/properties/states/items/properties/tag/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err51];}else {vErrors.push(err51);}errors++;}}if(data18.step !== undefined){if(typeof data18.step !== "string"){const err52 = {instancePath:instancePath+"/states/" + i1+"/step",schemaPath:"#/properties/states/items/properties/step/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err52];}else {vErrors.push(err52);}errors++;}}if(data18.lane !== undefined){let data25 = data18.lane;if(typeof data25 === "string"){if(!pattern4.test(data25)){const err53 = {instancePath:instancePath+"/states/" + i1+"/lane",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err53];}else {vErrors.push(err53);}errors++;}}else {const err54 = {instancePath:instancePath+"/states/" + i1+"/lane",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err54];}else {vErrors.push(err54);}errors++;}}if(data18.col !== undefined){let data26 = data18.col;if(!(((typeof data26 == "number") && (!(data26 % 1) && !isNaN(data26))) && (isFinite(data26)))){const err55 = {instancePath:instancePath+"/states/" + i1+"/col",schemaPath:"#/properties/states/items/properties/col/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err55];}else {vErrors.push(err55);}errors++;}if((typeof data26 == "number") && (isFinite(data26))){if(data26 > 4 || isNaN(data26)){const err56 = {instancePath:instancePath+"/states/" + i1+"/col",schemaPath:"#/properties/states/items/properties/col/maximum",keyword:"maximum",params:{comparison: "<=", limit: 4},message:"must be <= 4"};if(vErrors === null){vErrors = [err56];}else {vErrors.push(err56);}errors++;}if(data26 < 0 || isNaN(data26)){const err57 = {instancePath:instancePath+"/states/" + i1+"/col",schemaPath:"#/properties/states/items/properties/col/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err57];}else {vErrors.push(err57);}errors++;}}}if(data18.width !== undefined){let data27 = data18.width;if((typeof data27 == "number") && (isFinite(data27))){if(data27 < 48 || isNaN(data27)){const err58 = {instancePath:instancePath+"/states/" + i1+"/width",schemaPath:"#/properties/states/items/properties/width/minimum",keyword:"minimum",params:{comparison: ">=", limit: 48},message:"must be >= 48"};if(vErrors === null){vErrors = [err58];}else {vErrors.push(err58);}errors++;}}else {const err59 = {instancePath:instancePath+"/states/" + i1+"/width",schemaPath:"#/properties/states/items/properties/width/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err59];}else {vErrors.push(err59);}errors++;}}if(data18.height !== undefined){let data28 = data18.height;if((typeof data28 == "number") && (isFinite(data28))){if(data28 < 36 || isNaN(data28)){const err60 = {instancePath:instancePath+"/states/" + i1+"/height",schemaPath:"#/properties/states/items/properties/height/minimum",keyword:"minimum",params:{comparison: ">=", limit: 36},message:"must be >= 36"};if(vErrors === null){vErrors = [err60];}else {vErrors.push(err60);}errors++;}}else {const err61 = {instancePath:instancePath+"/states/" + i1+"/height",schemaPath:"#/properties/states/items/properties/height/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err61];}else {vErrors.push(err61);}errors++;}}if(data18.yOffset !== undefined){let data29 = data18.yOffset;if(!((typeof data29 == "number") && (isFinite(data29)))){const err62 = {instancePath:instancePath+"/states/" + i1+"/yOffset",schemaPath:"#/properties/states/items/properties/yOffset/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err62];}else {vErrors.push(err62);}errors++;}}}else {const err63 = {instancePath:instancePath+"/states/" + i1,schemaPath:"#/properties/states/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err63];}else {vErrors.push(err63);}errors++;}}}else {const err64 = {instancePath:instancePath+"/states",schemaPath:"#/properties/states/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err64];}else {vErrors.push(err64);}errors++;}}if(data.transitions !== undefined){let data30 = data.transitions;if(Array.isArray(data30)){const len4 = data30.length;for(let i2=0; i2<len4; i2++){let data31 = data30[i2];if(data31 && typeof data31 == "object" && !Array.isArray(data31)){if(data31.from === undefined){const err65 = {instancePath:instancePath+"/transitions/" + i2,schemaPath:"#/properties/transitions/items/required",keyword:"required",params:{missingProperty: "from"},message:"must have required property '"+"from"+"'"};if(vErrors === null){vErrors = [err65];}else {vErrors.push(err65);}errors++;}if(data31.to === undefined){const err66 = {instancePath:instancePath+"/transitions/" + i2,schemaPath:"#/properties/transitions/items/required",keyword:"required",params:{missingProperty: "to"},message:"must have required property '"+"to"+"'"};if(vErrors === null){vErrors = [err66];}else {vErrors.push(err66);}errors++;}for(const key4 in data31){if(!(func1.call(schema78.properties.transitions.items.properties, key4))){const err67 = {instancePath:instancePath+"/transitions/" + i2,schemaPath:"#/properties/transitions/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key4},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err67];}else {vErrors.push(err67);}errors++;}}if(data31.id !== undefined){let data32 = data31.id;if(typeof data32 === "string"){if(!pattern4.test(data32)){const err68 = {instancePath:instancePath+"/transitions/" + i2+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err68];}else {vErrors.push(err68);}errors++;}}else {const err69 = {instancePath:instancePath+"/transitions/" + i2+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err69];}else {vErrors.push(err69);}errors++;}}if(data31.from !== undefined){let data33 = data31.from;if(typeof data33 === "string"){if(!pattern4.test(data33)){const err70 = {instancePath:instancePath+"/transitions/" + i2+"/from",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err70];}else {vErrors.push(err70);}errors++;}}else {const err71 = {instancePath:instancePath+"/transitions/" + i2+"/from",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err71];}else {vErrors.push(err71);}errors++;}}if(data31.to !== undefined){let data34 = data31.to;if(typeof data34 === "string"){if(!pattern4.test(data34)){const err72 = {instancePath:instancePath+"/transitions/" + i2+"/to",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err72];}else {vErrors.push(err72);}errors++;}}else {const err73 = {instancePath:instancePath+"/transitions/" + i2+"/to",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err73];}else {vErrors.push(err73);}errors++;}}if(data31.label !== undefined){if(typeof data31.label !== "string"){const err74 = {instancePath:instancePath+"/transitions/" + i2+"/label",schemaPath:"#/properties/transitions/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err74];}else {vErrors.push(err74);}errors++;}}if(data31.note !== undefined){if(typeof data31.note !== "string"){const err75 = {instancePath:instancePath+"/transitions/" + i2+"/note",schemaPath:"#/properties/transitions/items/properties/note/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err75];}else {vErrors.push(err75);}errors++;}}if(data31.variant !== undefined){let data37 = data31.variant;if(!((((data37 === "default") || (data37 === "emphasis")) || (data37 === "security")) || (data37 === "dashed"))){const err76 = {instancePath:instancePath+"/transitions/" + i2+"/variant",schemaPath:"common.schema.json#/$defs/variant/enum",keyword:"enum",params:{allowedValues: schema47.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err76];}else {vErrors.push(err76);}errors++;}}if(data31.route !== undefined){let data38 = data31.route;if(!(((((((data38 === "auto") || (data38 === "straight")) || (data38 === "drop")) || (data38 === "bottom-channel")) || (data38 === "top-channel")) || (data38 === "right-channel")) || (data38 === "left-channel"))){const err77 = {instancePath:instancePath+"/transitions/" + i2+"/route",schemaPath:"#/properties/transitions/items/properties/route/enum",keyword:"enum",params:{allowedValues: schema78.properties.transitions.items.properties.route.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err77];}else {vErrors.push(err77);}errors++;}}if(data31.fromSide !== undefined){let data39 = data31.fromSide;if(!((((data39 === "left") || (data39 === "right")) || (data39 === "top")) || (data39 === "bottom"))){const err78 = {instancePath:instancePath+"/transitions/" + i2+"/fromSide",schemaPath:"#/properties/transitions/items/properties/fromSide/enum",keyword:"enum",params:{allowedValues: schema78.properties.transitions.items.properties.fromSide.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err78];}else {vErrors.push(err78);}errors++;}}if(data31.toSide !== undefined){let data40 = data31.toSide;if(!((((data40 === "left") || (data40 === "right")) || (data40 === "top")) || (data40 === "bottom"))){const err79 = {instancePath:instancePath+"/transitions/" + i2+"/toSide",schemaPath:"#/properties/transitions/items/properties/toSide/enum",keyword:"enum",params:{allowedValues: schema78.properties.transitions.items.properties.toSide.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err79];}else {vErrors.push(err79);}errors++;}}if(data31.channelX !== undefined){let data41 = data31.channelX;if(!((typeof data41 == "number") && (isFinite(data41)))){const err80 = {instancePath:instancePath+"/transitions/" + i2+"/channelX",schemaPath:"#/properties/transitions/items/properties/channelX/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err80];}else {vErrors.push(err80);}errors++;}}if(data31.channelY !== undefined){let data42 = data31.channelY;if(!((typeof data42 == "number") && (isFinite(data42)))){const err81 = {instancePath:instancePath+"/transitions/" + i2+"/channelY",schemaPath:"#/properties/transitions/items/properties/channelY/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err81];}else {vErrors.push(err81);}errors++;}}if(data31.cornerRadius !== undefined){let data43 = data31.cornerRadius;if((typeof data43 == "number") && (isFinite(data43))){if(data43 < 0 || isNaN(data43)){const err82 = {instancePath:instancePath+"/transitions/" + i2+"/cornerRadius",schemaPath:"#/properties/transitions/items/properties/cornerRadius/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err82];}else {vErrors.push(err82);}errors++;}}else {const err83 = {instancePath:instancePath+"/transitions/" + i2+"/cornerRadius",schemaPath:"#/properties/transitions/items/properties/cornerRadius/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err83];}else {vErrors.push(err83);}errors++;}}if(data31.labelAt !== undefined){let data44 = data31.labelAt;if(Array.isArray(data44)){if(data44.length > 2){const err84 = {instancePath:instancePath+"/transitions/" + i2+"/labelAt",schemaPath:"common.schema.json#/$defs/point/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err84];}else {vErrors.push(err84);}errors++;}if(data44.length < 2){const err85 = {instancePath:instancePath+"/transitions/" + i2+"/labelAt",schemaPath:"common.schema.json#/$defs/point/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err85];}else {vErrors.push(err85);}errors++;}const len5 = data44.length;if(len5 > 0){let data45 = data44[0];if(!((typeof data45 == "number") && (isFinite(data45)))){const err86 = {instancePath:instancePath+"/transitions/" + i2+"/labelAt/0",schemaPath:"common.schema.json#/$defs/point/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err86];}else {vErrors.push(err86);}errors++;}}if(len5 > 1){let data46 = data44[1];if(!((typeof data46 == "number") && (isFinite(data46)))){const err87 = {instancePath:instancePath+"/transitions/" + i2+"/labelAt/1",schemaPath:"common.schema.json#/$defs/point/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err87];}else {vErrors.push(err87);}errors++;}}const len6 = data44.length;if(!(len6 <= 2)){const err88 = {instancePath:instancePath+"/transitions/" + i2+"/labelAt",schemaPath:"common.schema.json#/$defs/point/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err88];}else {vErrors.push(err88);}errors++;}}else {const err89 = {instancePath:instancePath+"/transitions/" + i2+"/labelAt",schemaPath:"common.schema.json#/$defs/point/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err89];}else {vErrors.push(err89);}errors++;}}if(data31.labelDx !== undefined){let data47 = data31.labelDx;if(!((typeof data47 == "number") && (isFinite(data47)))){const err90 = {instancePath:instancePath+"/transitions/" + i2+"/labelDx",schemaPath:"#/properties/transitions/items/properties/labelDx/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err90];}else {vErrors.push(err90);}errors++;}}if(data31.labelDy !== undefined){let data48 = data31.labelDy;if(!((typeof data48 == "number") && (isFinite(data48)))){const err91 = {instancePath:instancePath+"/transitions/" + i2+"/labelDy",schemaPath:"#/properties/transitions/items/properties/labelDy/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err91];}else {vErrors.push(err91);}errors++;}}if(data31.labelSegment !== undefined){let data49 = data31.labelSegment;if(!(((typeof data49 == "number") && (!(data49 % 1) && !isNaN(data49))) && (isFinite(data49)))){const err92 = {instancePath:instancePath+"/transitions/" + i2+"/labelSegment",schemaPath:"#/properties/transitions/items/properties/labelSegment/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err92];}else {vErrors.push(err92);}errors++;}if((typeof data49 == "number") && (isFinite(data49))){if(data49 < 0 || isNaN(data49)){const err93 = {instancePath:instancePath+"/transitions/" + i2+"/labelSegment",schemaPath:"#/properties/transitions/items/properties/labelSegment/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err93];}else {vErrors.push(err93);}errors++;}}}if(data31.via !== undefined){let data50 = data31.via;if(Array.isArray(data50)){const len7 = data50.length;for(let i3=0; i3<len7; i3++){let data51 = data50[i3];if(Array.isArray(data51)){if(data51.length > 2){const err94 = {instancePath:instancePath+"/transitions/" + i2+"/via/" + i3,schemaPath:"common.schema.json#/$defs/point/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err94];}else {vErrors.push(err94);}errors++;}if(data51.length < 2){const err95 = {instancePath:instancePath+"/transitions/" + i2+"/via/" + i3,schemaPath:"common.schema.json#/$defs/point/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err95];}else {vErrors.push(err95);}errors++;}const len8 = data51.length;if(len8 > 0){let data52 = data51[0];if(!((typeof data52 == "number") && (isFinite(data52)))){const err96 = {instancePath:instancePath+"/transitions/" + i2+"/via/" + i3+"/0",schemaPath:"common.schema.json#/$defs/point/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err96];}else {vErrors.push(err96);}errors++;}}if(len8 > 1){let data53 = data51[1];if(!((typeof data53 == "number") && (isFinite(data53)))){const err97 = {instancePath:instancePath+"/transitions/" + i2+"/via/" + i3+"/1",schemaPath:"common.schema.json#/$defs/point/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err97];}else {vErrors.push(err97);}errors++;}}const len9 = data51.length;if(!(len9 <= 2)){const err98 = {instancePath:instancePath+"/transitions/" + i2+"/via/" + i3,schemaPath:"common.schema.json#/$defs/point/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err98];}else {vErrors.push(err98);}errors++;}}else {const err99 = {instancePath:instancePath+"/transitions/" + i2+"/via/" + i3,schemaPath:"common.schema.json#/$defs/point/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err99];}else {vErrors.push(err99);}errors++;}}}else {const err100 = {instancePath:instancePath+"/transitions/" + i2+"/via",schemaPath:"#/properties/transitions/items/properties/via/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err100];}else {vErrors.push(err100);}errors++;}}if(data31.width !== undefined){let data54 = data31.width;if((typeof data54 == "number") && (isFinite(data54))){if(data54 < 0.5 || isNaN(data54)){const err101 = {instancePath:instancePath+"/transitions/" + i2+"/width",schemaPath:"#/properties/transitions/items/properties/width/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0.5},message:"must be >= 0.5"};if(vErrors === null){vErrors = [err101];}else {vErrors.push(err101);}errors++;}}else {const err102 = {instancePath:instancePath+"/transitions/" + i2+"/width",schemaPath:"#/properties/transitions/items/properties/width/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err102];}else {vErrors.push(err102);}errors++;}}}else {const err103 = {instancePath:instancePath+"/transitions/" + i2,schemaPath:"#/properties/transitions/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err103];}else {vErrors.push(err103);}errors++;}}}else {const err104 = {instancePath:instancePath+"/transitions",schemaPath:"#/properties/transitions/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err104];}else {vErrors.push(err104);}errors++;}}if(data.cards !== undefined){let data55 = data.cards;if(Array.isArray(data55)){const len10 = data55.length;for(let i4=0; i4<len10; i4++){let data56 = data55[i4];if(data56 && typeof data56 == "object" && !Array.isArray(data56)){if(data56.dot === undefined){const err105 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "dot"},message:"must have required property '"+"dot"+"'"};if(vErrors === null){vErrors = [err105];}else {vErrors.push(err105);}errors++;}if(data56.title === undefined){const err106 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "title"},message:"must have required property '"+"title"+"'"};if(vErrors === null){vErrors = [err106];}else {vErrors.push(err106);}errors++;}if(data56.items === undefined){const err107 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "items"},message:"must have required property '"+"items"+"'"};if(vErrors === null){vErrors = [err107];}else {vErrors.push(err107);}errors++;}for(const key5 in data56){if(!(((key5 === "dot") || (key5 === "title")) || (key5 === "items"))){const err108 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key5},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err108];}else {vErrors.push(err108);}errors++;}}if(data56.dot !== undefined){let data57 = data56.dot;if(!(((((((data57 === "cyan") || (data57 === "emerald")) || (data57 === "violet")) || (data57 === "amber")) || (data57 === "rose")) || (data57 === "orange")) || (data57 === "slate"))){const err109 = {instancePath:instancePath+"/cards/" + i4+"/dot",schemaPath:"common.schema.json#/$defs/cards/items/properties/dot/enum",keyword:"enum",params:{allowedValues: schema52.items.properties.dot.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err109];}else {vErrors.push(err109);}errors++;}}if(data56.title !== undefined){let data58 = data56.title;if(typeof data58 === "string"){if(func2(data58) < 1){const err110 = {instancePath:instancePath+"/cards/" + i4+"/title",schemaPath:"common.schema.json#/$defs/cards/items/properties/title/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err110];}else {vErrors.push(err110);}errors++;}}else {const err111 = {instancePath:instancePath+"/cards/" + i4+"/title",schemaPath:"common.schema.json#/$defs/cards/items/properties/title/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err111];}else {vErrors.push(err111);}errors++;}}if(data56.items !== undefined){let data59 = data56.items;if(Array.isArray(data59)){const len11 = data59.length;for(let i5=0; i5<len11; i5++){if(typeof data59[i5] !== "string"){const err112 = {instancePath:instancePath+"/cards/" + i4+"/items/" + i5,schemaPath:"common.schema.json#/$defs/cards/items/properties/items/items/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err112];}else {vErrors.push(err112);}errors++;}}}else {const err113 = {instancePath:instancePath+"/cards/" + i4+"/items",schemaPath:"common.schema.json#/$defs/cards/items/properties/items/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err113];}else {vErrors.push(err113);}errors++;}}}else {const err114 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err114];}else {vErrors.push(err114);}errors++;}}}else {const err115 = {instancePath:instancePath+"/cards",schemaPath:"common.schema.json#/$defs/cards/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err115];}else {vErrors.push(err115);}errors++;}}}else {const err116 = {instancePath,schemaPath:"#/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err116];}else {vErrors.push(err116);}errors++;}validate30.errors = vErrors;return errors === 0;}validate30.evaluated = {"props":true,"dynamicProps":false,"dynamicItems":false};export const architecture = validate33;const schema92 = {"$schema":"https://json-schema.org/draft/2020-12/schema","$id":"https://github.com/tt-a1i/archify/schemas/architecture.schema.json","title":"Archify Architecture Diagram","type":"object","additionalProperties":false,"required":["schema_version","diagram_type","meta","components"],"properties":{"schema_version":{"const":1},"diagram_type":{"const":"architecture"},"meta":{"type":"object","additionalProperties":false,"required":["title"],"properties":{"title":{"type":"string","minLength":1},"subtitle":{"type":"string"},"output":{"type":"string"},"animation":{"enum":["trace","none"]},"visual_preset":{"enum":["classic","signal-flow","blueprint","editorial"]},"quality_profile":{"enum":["standard","showcase"]},"engineering_profile":{"enum":["deployment-ownership"]},"repository":{"type":"object","additionalProperties":false,"required":["url","revision"],"properties":{"url":{"type":"string","pattern":"^https://github\\.com/[A-Za-z0-9_.-]+/[A-Za-z0-9_.-]+(?:\\.git)?/?$"},"revision":{"type":"string","pattern":"^[a-fA-F0-9]{40}$"}}},"views":{"$ref":"common.schema.json#/$defs/guidedViews"},"viewBox":{"type":"array","prefixItems":[{"type":"number","minimum":320},{"type":"number","minimum":240}],"items":false,"minItems":2,"maxItems":2}}},"layout":{"type":"object","additionalProperties":false,"required":["mode"],"properties":{"mode":{"enum":["grid"]},"origin":{"$ref":"common.schema.json#/$defs/point"},"cols":{"type":"integer","minimum":1,"maximum":12},"gapX":{"type":"number","minimum":0},"gapY":{"type":"number","minimum":0},"cellW":{"type":"number","minimum":40},"cellH":{"type":"number","minimum":24}}},"components":{"type":"array","minItems":1,"items":{"type":"object","additionalProperties":false,"required":["id","type","label"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"type":{"$ref":"common.schema.json#/$defs/componentType"},"label":{"type":"string","minLength":1},"sublabel":{"type":"string"},"tag":{"type":"string"},"sources":{"type":"array","minItems":1,"maxItems":3,"items":{"type":"object","additionalProperties":false,"required":["path"],"properties":{"path":{"type":"string","minLength":1,"maxLength":240},"line":{"type":"integer","minimum":1},"end_line":{"type":"integer","minimum":1},"label":{"type":"string","minLength":1,"maxLength":48}}}},"row":{"type":"integer","minimum":0},"col":{"type":"integer","minimum":0},"pos":{"$ref":"common.schema.json#/$defs/point"},"size":{"type":"array","prefixItems":[{"type":"number","exclusiveMinimum":0},{"type":"number","exclusiveMinimum":0}],"items":false,"minItems":2,"maxItems":2}}}},"boundaries":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["kind","label","wraps"],"properties":{"kind":{"enum":["region","security-group"]},"label":{"type":"string","minLength":1},"wraps":{"type":"array","minItems":1,"items":{"$ref":"common.schema.json#/$defs/id"}},"pad":{"type":"number","minimum":0}}}},"connections":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"from":{"$ref":"common.schema.json#/$defs/id"},"to":{"$ref":"common.schema.json#/$defs/id"},"label":{"type":"string"},"variant":{"$ref":"common.schema.json#/$defs/variant"},"fromSide":{"enum":["left","right","top","bottom"]},"toSide":{"enum":["left","right","top","bottom"]},"route":{"enum":["auto","straight","orthogonal-h","orthogonal-v"]},"via":{"type":"array","items":{"$ref":"common.schema.json#/$defs/point"}},"labelAt":{"$ref":"common.schema.json#/$defs/point"},"labelDx":{"type":"number"},"labelDy":{"type":"number"},"labelSegment":{"type":"integer","minimum":0},"width":{"type":"number","minimum":0.5}}}},"cards":{"$ref":"common.schema.json#/$defs/cards"}}};const pattern37 = new RegExp("^https://github\\.com/[A-Za-z0-9_.-]+/[A-Za-z0-9_.-]+(?:\\.git)?/?$", "u");const pattern38 = new RegExp("^[a-fA-F0-9]{40}$", "u");function validate34(data, {instancePath="", parentData, parentDataProperty, rootData=data, dynamicAnchors={}}={}){let vErrors = null;let errors = 0;const evaluated0 = validate34.evaluated;if(evaluated0.dynamicProps){evaluated0.props = undefined;}if(evaluated0.dynamicItems){evaluated0.items = undefined;}if(Array.isArray(data)){if(data.length > 5){const err0 = {instancePath,schemaPath:"#/maxItems",keyword:"maxItems",params:{limit: 5},message:"must NOT have more than 5 items"};if(vErrors === null){vErrors = [err0];}else {vErrors.push(err0);}errors++;}const len0 = data.length;for(let i0=0; i0<len0; i0++){let data0 = data[i0];if(data0 && typeof data0 == "object" && !Array.isArray(data0)){if(data0.id === undefined){const err1 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err1];}else {vErrors.push(err1);}errors++;}if(data0.label === undefined){const err2 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err2];}else {vErrors.push(err2);}errors++;}if(data0.focus === undefined){const err3 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "focus"},message:"must have required property '"+"focus"+"'"};if(vErrors === null){vErrors = [err3];}else {vErrors.push(err3);}errors++;}for(const key0 in data0){if(!((((key0 === "id") || (key0 === "label")) || (key0 === "focus")) || (key0 === "note"))){const err4 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key0},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err4];}else {vErrors.push(err4);}errors++;}}if(data0.id !== undefined){let data1 = data0.id;if(typeof data1 === "string"){if(!pattern4.test(data1)){const err5 = {instancePath:instancePath+"/" + i0+"/id",schemaPath:"#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err5];}else {vErrors.push(err5);}errors++;}}else {const err6 = {instancePath:instancePath+"/" + i0+"/id",schemaPath:"#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err6];}else {vErrors.push(err6);}errors++;}}if(data0.label !== undefined){let data2 = data0.label;if(typeof data2 === "string"){if(func2(data2) > 48){const err7 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/maxLength",keyword:"maxLength",params:{limit: 48},message:"must NOT have more than 48 characters"};if(vErrors === null){vErrors = [err7];}else {vErrors.push(err7);}errors++;}if(func2(data2) < 1){const err8 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err8];}else {vErrors.push(err8);}errors++;}}else {const err9 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err9];}else {vErrors.push(err9);}errors++;}}if(data0.focus !== undefined){let data3 = data0.focus;if(Array.isArray(data3)){if(data3.length < 1){const err10 = {instancePath:instancePath+"/" + i0+"/focus",schemaPath:"#/items/properties/focus/minItems",keyword:"minItems",params:{limit: 1},message:"must NOT have fewer than 1 items"};if(vErrors === null){vErrors = [err10];}else {vErrors.push(err10);}errors++;}const len1 = data3.length;for(let i1=0; i1<len1; i1++){let data4 = data3[i1];if(typeof data4 === "string"){if(!pattern4.test(data4)){const err11 = {instancePath:instancePath+"/" + i0+"/focus/" + i1,schemaPath:"#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err11];}else {vErrors.push(err11);}errors++;}}else {const err12 = {instancePath:instancePath+"/" + i0+"/focus/" + i1,schemaPath:"#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err12];}else {vErrors.push(err12);}errors++;}}}else {const err13 = {instancePath:instancePath+"/" + i0+"/focus",schemaPath:"#/items/properties/focus/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err13];}else {vErrors.push(err13);}errors++;}}if(data0.note !== undefined){let data5 = data0.note;if(typeof data5 === "string"){if(func2(data5) > 140){const err14 = {instancePath:instancePath+"/" + i0+"/note",schemaPath:"#/items/properties/note/maxLength",keyword:"maxLength",params:{limit: 140},message:"must NOT have more than 140 characters"};if(vErrors === null){vErrors = [err14];}else {vErrors.push(err14);}errors++;}}else {const err15 = {instancePath:instancePath+"/" + i0+"/note",schemaPath:"#/items/properties/note/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err15];}else {vErrors.push(err15);}errors++;}}}else {const err16 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err16];}else {vErrors.push(err16);}errors++;}}}else {const err17 = {instancePath,schemaPath:"#/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err17];}else {vErrors.push(err17);}errors++;}validate34.errors = vErrors;return errors === 0;}validate34.evaluated = {"items":true,"dynamicProps":false,"dynamicItems":false};function validate33(data, {instancePath="", parentData, parentDataProperty, rootData=data, dynamicAnchors={}}={}){/*# sourceURL="https://github.com/tt-a1i/archify/schemas/architecture.schema.json" */;let vErrors = null;let errors = 0;const evaluated0 = validate33.evaluated;if(evaluated0.dynamicProps){evaluated0.props = undefined;}if(evaluated0.dynamicItems){evaluated0.items = undefined;}if(data && typeof data == "object" && !Array.isArray(data)){if(data.schema_version === undefined){const err0 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "schema_version"},message:"must have required property '"+"schema_version"+"'"};if(vErrors === null){vErrors = [err0];}else {vErrors.push(err0);}errors++;}if(data.diagram_type === undefined){const err1 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "diagram_type"},message:"must have required property '"+"diagram_type"+"'"};if(vErrors === null){vErrors = [err1];}else {vErrors.push(err1);}errors++;}if(data.meta === undefined){const err2 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "meta"},message:"must have required property '"+"meta"+"'"};if(vErrors === null){vErrors = [err2];}else {vErrors.push(err2);}errors++;}if(data.components === undefined){const err3 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "components"},message:"must have required property '"+"components"+"'"};if(vErrors === null){vErrors = [err3];}else {vErrors.push(err3);}errors++;}for(const key0 in data){if(!((((((((key0 === "schema_version") || (key0 === "diagram_type")) || (key0 === "meta")) || (key0 === "layout")) || (key0 === "components")) || (key0 === "boundaries")) || (key0 === "connections")) || (key0 === "cards"))){const err4 = {instancePath,schemaPath:"#/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key0},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err4];}else {vErrors.push(err4);}errors++;}}if(data.schema_version !== undefined){if(1 !== data.schema_version){const err5 = {instancePath:instancePath+"/schema_version",schemaPath:"#/properties/schema_version/const",keyword:"const",params:{allowedValue: 1},message:"must be equal to constant"};if(vErrors === null){vErrors = [err5];}else {vErrors.push(err5);}errors++;}}if(data.diagram_type !== undefined){if("architecture" !== data.diagram_type){const err6 = {instancePath:instancePath+"/diagram_type",schemaPath:"#/properties/diagram_type/const",keyword:"const",params:{allowedValue: "architecture"},message:"must be equal to constant"};if(vErrors === null){vErrors = [err6];}else {vErrors.push(err6);}errors++;}}if(data.meta !== undefined){let data2 = data.meta;if(data2 && typeof data2 == "object" && !Array.isArray(data2)){if(data2.title === undefined){const err7 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/required",keyword:"required",params:{missingProperty: "title"},message:"must have required property '"+"title"+"'"};if(vErrors === null){vErrors = [err7];}else {vErrors.push(err7);}errors++;}for(const key1 in data2){if(!(func1.call(schema92.properties.meta.properties, key1))){const err8 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key1},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err8];}else {vErrors.push(err8);}errors++;}}if(data2.title !== undefined){let data3 = data2.title;if(typeof data3 === "string"){if(func2(data3) < 1){const err9 = {instancePath:instancePath+"/meta/title",schemaPath:"#/properties/meta/properties/title/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err9];}else {vErrors.push(err9);}errors++;}}else {const err10 = {instancePath:instancePath+"/meta/title",schemaPath:"#/properties/meta/properties/title/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err10];}else {vErrors.push(err10);}errors++;}}if(data2.subtitle !== undefined){if(typeof data2.subtitle !== "string"){const err11 = {instancePath:instancePath+"/meta/subtitle",schemaPath:"#/properties/meta/properties/subtitle/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err11];}else {vErrors.push(err11);}errors++;}}if(data2.output !== undefined){if(typeof data2.output !== "string"){const err12 = {instancePath:instancePath+"/meta/output",schemaPath:"#/properties/meta/properties/output/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err12];}else {vErrors.push(err12);}errors++;}}if(data2.animation !== undefined){let data6 = data2.animation;if(!((data6 === "trace") || (data6 === "none"))){const err13 = {instancePath:instancePath+"/meta/animation",schemaPath:"#/properties/meta/properties/animation/enum",keyword:"enum",params:{allowedValues: schema92.properties.meta.properties.animation.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err13];}else {vErrors.push(err13);}errors++;}}if(data2.visual_preset !== undefined){let data7 = data2.visual_preset;if(!((((data7 === "classic") || (data7 === "signal-flow")) || (data7 === "blueprint")) || (data7 === "editorial"))){const err14 = {instancePath:instancePath+"/meta/visual_preset",schemaPath:"#/properties/meta/properties/visual_preset/enum",keyword:"enum",params:{allowedValues: schema92.properties.meta.properties.visual_preset.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err14];}else {vErrors.push(err14);}errors++;}}if(data2.quality_profile !== undefined){let data8 = data2.quality_profile;if(!((data8 === "standard") || (data8 === "showcase"))){const err15 = {instancePath:instancePath+"/meta/quality_profile",schemaPath:"#/properties/meta/properties/quality_profile/enum",keyword:"enum",params:{allowedValues: schema92.properties.meta.properties.quality_profile.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err15];}else {vErrors.push(err15);}errors++;}}if(data2.engineering_profile !== undefined){if(!(data2.engineering_profile === "deployment-ownership")){const err16 = {instancePath:instancePath+"/meta/engineering_profile",schemaPath:"#/properties/meta/properties/engineering_profile/enum",keyword:"enum",params:{allowedValues: schema92.properties.meta.properties.engineering_profile.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err16];}else {vErrors.push(err16);}errors++;}}if(data2.repository !== undefined){let data10 = data2.repository;if(data10 && typeof data10 == "object" && !Array.isArray(data10)){if(data10.url === undefined){const err17 = {instancePath:instancePath+"/meta/repository",schemaPath:"#/properties/meta/properties/repository/required",keyword:"required",params:{missingProperty: "url"},message:"must have required property '"+"url"+"'"};if(vErrors === null){vErrors = [err17];}else {vErrors.push(err17);}errors++;}if(data10.revision === undefined){const err18 = {instancePath:instancePath+"/meta/repository",schemaPath:"#/properties/meta/properties/repository/required",keyword:"required",params:{missingProperty: "revision"},message:"must have required property '"+"revision"+"'"};if(vErrors === null){vErrors = [err18];}else {vErrors.push(err18);}errors++;}for(const key2 in data10){if(!((key2 === "url") || (key2 === "revision"))){const err19 = {instancePath:instancePath+"/meta/repository",schemaPath:"#/properties/meta/properties/repository/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key2},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err19];}else {vErrors.push(err19);}errors++;}}if(data10.url !== undefined){let data11 = data10.url;if(typeof data11 === "string"){if(!pattern37.test(data11)){const err20 = {instancePath:instancePath+"/meta/repository/url",schemaPath:"#/properties/meta/properties/repository/properties/url/pattern",keyword:"pattern",params:{pattern: "^https://github\\.com/[A-Za-z0-9_.-]+/[A-Za-z0-9_.-]+(?:\\.git)?/?$"},message:"must match pattern \""+"^https://github\\.com/[A-Za-z0-9_.-]+/[A-Za-z0-9_.-]+(?:\\.git)?/?$"+"\""};if(vErrors === null){vErrors = [err20];}else {vErrors.push(err20);}errors++;}}else {const err21 = {instancePath:instancePath+"/meta/repository/url",schemaPath:"#/properties/meta/properties/repository/properties/url/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err21];}else {vErrors.push(err21);}errors++;}}if(data10.revision !== undefined){let data12 = data10.revision;if(typeof data12 === "string"){if(!pattern38.test(data12)){const err22 = {instancePath:instancePath+"/meta/repository/revision",schemaPath:"#/properties/meta/properties/repository/properties/revision/pattern",keyword:"pattern",params:{pattern: "^[a-fA-F0-9]{40}$"},message:"must match pattern \""+"^[a-fA-F0-9]{40}$"+"\""};if(vErrors === null){vErrors = [err22];}else {vErrors.push(err22);}errors++;}}else {const err23 = {instancePath:instancePath+"/meta/repository/revision",schemaPath:"#/properties/meta/properties/repository/properties/revision/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err23];}else {vErrors.push(err23);}errors++;}}}else {const err24 = {instancePath:instancePath+"/meta/repository",schemaPath:"#/properties/meta/properties/repository/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err24];}else {vErrors.push(err24);}errors++;}}if(data2.views !== undefined){if(!(validate34(data2.views, {instancePath:instancePath+"/meta/views",parentData:data2,parentDataProperty:"views",rootData,dynamicAnchors}))){vErrors = vErrors === null ? validate34.errors : vErrors.concat(validate34.errors);errors = vErrors.length;}}if(data2.viewBox !== undefined){let data14 = data2.viewBox;if(Array.isArray(data14)){if(data14.length > 2){const err25 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err25];}else {vErrors.push(err25);}errors++;}if(data14.length < 2){const err26 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err26];}else {vErrors.push(err26);}errors++;}const len0 = data14.length;if(len0 > 0){let data15 = data14[0];if((typeof data15 == "number") && (isFinite(data15))){if(data15 < 320 || isNaN(data15)){const err27 = {instancePath:instancePath+"/meta/viewBox/0",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/0/minimum",keyword:"minimum",params:{comparison: ">=", limit: 320},message:"must be >= 320"};if(vErrors === null){vErrors = [err27];}else {vErrors.push(err27);}errors++;}}else {const err28 = {instancePath:instancePath+"/meta/viewBox/0",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err28];}else {vErrors.push(err28);}errors++;}}if(len0 > 1){let data16 = data14[1];if((typeof data16 == "number") && (isFinite(data16))){if(data16 < 240 || isNaN(data16)){const err29 = {instancePath:instancePath+"/meta/viewBox/1",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/1/minimum",keyword:"minimum",params:{comparison: ">=", limit: 240},message:"must be >= 240"};if(vErrors === null){vErrors = [err29];}else {vErrors.push(err29);}errors++;}}else {const err30 = {instancePath:instancePath+"/meta/viewBox/1",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err30];}else {vErrors.push(err30);}errors++;}}const len1 = data14.length;if(!(len1 <= 2)){const err31 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err31];}else {vErrors.push(err31);}errors++;}}else {const err32 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err32];}else {vErrors.push(err32);}errors++;}}}else {const err33 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err33];}else {vErrors.push(err33);}errors++;}}if(data.layout !== undefined){let data17 = data.layout;if(data17 && typeof data17 == "object" && !Array.isArray(data17)){if(data17.mode === undefined){const err34 = {instancePath:instancePath+"/layout",schemaPath:"#/properties/layout/required",keyword:"required",params:{missingProperty: "mode"},message:"must have required property '"+"mode"+"'"};if(vErrors === null){vErrors = [err34];}else {vErrors.push(err34);}errors++;}for(const key3 in data17){if(!(((((((key3 === "mode") || (key3 === "origin")) || (key3 === "cols")) || (key3 === "gapX")) || (key3 === "gapY")) || (key3 === "cellW")) || (key3 === "cellH"))){const err35 = {instancePath:instancePath+"/layout",schemaPath:"#/properties/layout/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key3},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err35];}else {vErrors.push(err35);}errors++;}}if(data17.mode !== undefined){if(!(data17.mode === "grid")){const err36 = {instancePath:instancePath+"/layout/mode",schemaPath:"#/properties/layout/properties/mode/enum",keyword:"enum",params:{allowedValues: schema92.properties.layout.properties.mode.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err36];}else {vErrors.push(err36);}errors++;}}if(data17.origin !== undefined){let data19 = data17.origin;if(Array.isArray(data19)){if(data19.length > 2){const err37 = {instancePath:instancePath+"/layout/origin",schemaPath:"common.schema.json#/$defs/point/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err37];}else {vErrors.push(err37);}errors++;}if(data19.length < 2){const err38 = {instancePath:instancePath+"/layout/origin",schemaPath:"common.schema.json#/$defs/point/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err38];}else {vErrors.push(err38);}errors++;}const len2 = data19.length;if(len2 > 0){let data20 = data19[0];if(!((typeof data20 == "number") && (isFinite(data20)))){const err39 = {instancePath:instancePath+"/layout/origin/0",schemaPath:"common.schema.json#/$defs/point/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err39];}else {vErrors.push(err39);}errors++;}}if(len2 > 1){let data21 = data19[1];if(!((typeof data21 == "number") && (isFinite(data21)))){const err40 = {instancePath:instancePath+"/layout/origin/1",schemaPath:"common.schema.json#/$defs/point/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err40];}else {vErrors.push(err40);}errors++;}}const len3 = data19.length;if(!(len3 <= 2)){const err41 = {instancePath:instancePath+"/layout/origin",schemaPath:"common.schema.json#/$defs/point/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err41];}else {vErrors.push(err41);}errors++;}}else {const err42 = {instancePath:instancePath+"/layout/origin",schemaPath:"common.schema.json#/$defs/point/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err42];}else {vErrors.push(err42);}errors++;}}if(data17.cols !== undefined){let data22 = data17.cols;if(!(((typeof data22 == "number") && (!(data22 % 1) && !isNaN(data22))) && (isFinite(data22)))){const err43 = {instancePath:instancePath+"/layout/cols",schemaPath:"#/properties/layout/properties/cols/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err43];}else {vErrors.push(err43);}errors++;}if((typeof data22 == "number") && (isFinite(data22))){if(data22 > 12 || isNaN(data22)){const err44 = {instancePath:instancePath+"/layout/cols",schemaPath:"#/properties/layout/properties/cols/maximum",keyword:"maximum",params:{comparison: "<=", limit: 12},message:"must be <= 12"};if(vErrors === null){vErrors = [err44];}else {vErrors.push(err44);}errors++;}if(data22 < 1 || isNaN(data22)){const err45 = {instancePath:instancePath+"/layout/cols",schemaPath:"#/properties/layout/properties/cols/minimum",keyword:"minimum",params:{comparison: ">=", limit: 1},message:"must be >= 1"};if(vErrors === null){vErrors = [err45];}else {vErrors.push(err45);}errors++;}}}if(data17.gapX !== undefined){let data23 = data17.gapX;if((typeof data23 == "number") && (isFinite(data23))){if(data23 < 0 || isNaN(data23)){const err46 = {instancePath:instancePath+"/layout/gapX",schemaPath:"#/properties/layout/properties/gapX/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err46];}else {vErrors.push(err46);}errors++;}}else {const err47 = {instancePath:instancePath+"/layout/gapX",schemaPath:"#/properties/layout/properties/gapX/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err47];}else {vErrors.push(err47);}errors++;}}if(data17.gapY !== undefined){let data24 = data17.gapY;if((typeof data24 == "number") && (isFinite(data24))){if(data24 < 0 || isNaN(data24)){const err48 = {instancePath:instancePath+"/layout/gapY",schemaPath:"#/properties/layout/properties/gapY/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err48];}else {vErrors.push(err48);}errors++;}}else {const err49 = {instancePath:instancePath+"/layout/gapY",schemaPath:"#/properties/layout/properties/gapY/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err49];}else {vErrors.push(err49);}errors++;}}if(data17.cellW !== undefined){let data25 = data17.cellW;if((typeof data25 == "number") && (isFinite(data25))){if(data25 < 40 || isNaN(data25)){const err50 = {instancePath:instancePath+"/layout/cellW",schemaPath:"#/properties/layout/properties/cellW/minimum",keyword:"minimum",params:{comparison: ">=", limit: 40},message:"must be >= 40"};if(vErrors === null){vErrors = [err50];}else {vErrors.push(err50);}errors++;}}else {const err51 = {instancePath:instancePath+"/layout/cellW",schemaPath:"#/properties/layout/properties/cellW/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err51];}else {vErrors.push(err51);}errors++;}}if(data17.cellH !== undefined){let data26 = data17.cellH;if((typeof data26 == "number") && (isFinite(data26))){if(data26 < 24 || isNaN(data26)){const err52 = {instancePath:instancePath+"/layout/cellH",schemaPath:"#/properties/layout/properties/cellH/minimum",keyword:"minimum",params:{comparison: ">=", limit: 24},message:"must be >= 24"};if(vErrors === null){vErrors = [err52];}else {vErrors.push(err52);}errors++;}}else {const err53 = {instancePath:instancePath+"/layout/cellH",schemaPath:"#/properties/layout/properties/cellH/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err53];}else {vErrors.push(err53);}errors++;}}}else {const err54 = {instancePath:instancePath+"/layout",schemaPath:"#/properties/layout/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err54];}else {vErrors.push(err54);}errors++;}}if(data.components !== undefined){let data27 = data.components;if(Array.isArray(data27)){if(data27.length < 1){const err55 = {instancePath:instancePath+"/components",schemaPath:"#/properties/components/minItems",keyword:"minItems",params:{limit: 1},message:"must NOT have fewer than 1 items"};if(vErrors === null){vErrors = [err55];}else {vErrors.push(err55);}errors++;}const len4 = data27.length;for(let i0=0; i0<len4; i0++){let data28 = data27[i0];if(data28 && typeof data28 == "object" && !Array.isArray(data28)){if(data28.id === undefined){const err56 = {instancePath:instancePath+"/components/" + i0,schemaPath:"#/properties/components/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err56];}else {vErrors.push(err56);}errors++;}if(data28.type === undefined){const err57 = {instancePath:instancePath+"/components/" + i0,schemaPath:"#/properties/components/items/required",keyword:"required",params:{missingProperty: "type"},message:"must have required property '"+"type"+"'"};if(vErrors === null){vErrors = [err57];}else {vErrors.push(err57);}errors++;}if(data28.label === undefined){const err58 = {instancePath:instancePath+"/components/" + i0,schemaPath:"#/properties/components/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err58];}else {vErrors.push(err58);}errors++;}for(const key4 in data28){if(!(func1.call(schema92.properties.components.items.properties, key4))){const err59 = {instancePath:instancePath+"/components/" + i0,schemaPath:"#/properties/components/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key4},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err59];}else {vErrors.push(err59);}errors++;}}if(data28.id !== undefined){let data29 = data28.id;if(typeof data29 === "string"){if(!pattern4.test(data29)){const err60 = {instancePath:instancePath+"/components/" + i0+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err60];}else {vErrors.push(err60);}errors++;}}else {const err61 = {instancePath:instancePath+"/components/" + i0+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err61];}else {vErrors.push(err61);}errors++;}}if(data28.type !== undefined){let data30 = data28.type;if(!(((((((data30 === "frontend") || (data30 === "backend")) || (data30 === "database")) || (data30 === "cloud")) || (data30 === "security")) || (data30 === "messagebus")) || (data30 === "external"))){const err62 = {instancePath:instancePath+"/components/" + i0+"/type",schemaPath:"common.schema.json#/$defs/componentType/enum",keyword:"enum",params:{allowedValues: schema43.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err62];}else {vErrors.push(err62);}errors++;}}if(data28.label !== undefined){let data31 = data28.label;if(typeof data31 === "string"){if(func2(data31) < 1){const err63 = {instancePath:instancePath+"/components/" + i0+"/label",schemaPath:"#/properties/components/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err63];}else {vErrors.push(err63);}errors++;}}else {const err64 = {instancePath:instancePath+"/components/" + i0+"/label",schemaPath:"#/properties/components/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err64];}else {vErrors.push(err64);}errors++;}}if(data28.sublabel !== undefined){if(typeof data28.sublabel !== "string"){const err65 = {instancePath:instancePath+"/components/" + i0+"/sublabel",schemaPath:"#/properties/components/items/properties/sublabel/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err65];}else {vErrors.push(err65);}errors++;}}if(data28.tag !== undefined){if(typeof data28.tag !== "string"){const err66 = {instancePath:instancePath+"/components/" + i0+"/tag",schemaPath:"#/properties/components/items/properties/tag/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err66];}else {vErrors.push(err66);}errors++;}}if(data28.sources !== undefined){let data34 = data28.sources;if(Array.isArray(data34)){if(data34.length > 3){const err67 = {instancePath:instancePath+"/components/" + i0+"/sources",schemaPath:"#/properties/components/items/properties/sources/maxItems",keyword:"maxItems",params:{limit: 3},message:"must NOT have more than 3 items"};if(vErrors === null){vErrors = [err67];}else {vErrors.push(err67);}errors++;}if(data34.length < 1){const err68 = {instancePath:instancePath+"/components/" + i0+"/sources",schemaPath:"#/properties/components/items/properties/sources/minItems",keyword:"minItems",params:{limit: 1},message:"must NOT have fewer than 1 items"};if(vErrors === null){vErrors = [err68];}else {vErrors.push(err68);}errors++;}const len5 = data34.length;for(let i1=0; i1<len5; i1++){let data35 = data34[i1];if(data35 && typeof data35 == "object" && !Array.isArray(data35)){if(data35.path === undefined){const err69 = {instancePath:instancePath+"/components/" + i0+"/sources/" + i1,schemaPath:"#/properties/components/items/properties/sources/items/required",keyword:"required",params:{missingProperty: "path"},message:"must have required property '"+"path"+"'"};if(vErrors === null){vErrors = [err69];}else {vErrors.push(err69);}errors++;}for(const key5 in data35){if(!((((key5 === "path") || (key5 === "line")) || (key5 === "end_line")) || (key5 === "label"))){const err70 = {instancePath:instancePath+"/components/" + i0+"/sources/" + i1,schemaPath:"#/properties/components/items/properties/sources/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key5},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err70];}else {vErrors.push(err70);}errors++;}}if(data35.path !== undefined){let data36 = data35.path;if(typeof data36 === "string"){if(func2(data36) > 240){const err71 = {instancePath:instancePath+"/components/" + i0+"/sources/" + i1+"/path",schemaPath:"#/properties/components/items/properties/sources/items/properties/path/maxLength",keyword:"maxLength",params:{limit: 240},message:"must NOT have more than 240 characters"};if(vErrors === null){vErrors = [err71];}else {vErrors.push(err71);}errors++;}if(func2(data36) < 1){const err72 = {instancePath:instancePath+"/components/" + i0+"/sources/" + i1+"/path",schemaPath:"#/properties/components/items/properties/sources/items/properties/path/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err72];}else {vErrors.push(err72);}errors++;}}else {const err73 = {instancePath:instancePath+"/components/" + i0+"/sources/" + i1+"/path",schemaPath:"#/properties/components/items/properties/sources/items/properties/path/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err73];}else {vErrors.push(err73);}errors++;}}if(data35.line !== undefined){let data37 = data35.line;if(!(((typeof data37 == "number") && (!(data37 % 1) && !isNaN(data37))) && (isFinite(data37)))){const err74 = {instancePath:instancePath+"/components/" + i0+"/sources/" + i1+"/line",schemaPath:"#/properties/components/items/properties/sources/items/properties/line/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err74];}else {vErrors.push(err74);}errors++;}if((typeof data37 == "number") && (isFinite(data37))){if(data37 < 1 || isNaN(data37)){const err75 = {instancePath:instancePath+"/components/" + i0+"/sources/" + i1+"/line",schemaPath:"#/properties/components/items/properties/sources/items/properties/line/minimum",keyword:"minimum",params:{comparison: ">=", limit: 1},message:"must be >= 1"};if(vErrors === null){vErrors = [err75];}else {vErrors.push(err75);}errors++;}}}if(data35.end_line !== undefined){let data38 = data35.end_line;if(!(((typeof data38 == "number") && (!(data38 % 1) && !isNaN(data38))) && (isFinite(data38)))){const err76 = {instancePath:instancePath+"/components/" + i0+"/sources/" + i1+"/end_line",schemaPath:"#/properties/components/items/properties/sources/items/properties/end_line/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err76];}else {vErrors.push(err76);}errors++;}if((typeof data38 == "number") && (isFinite(data38))){if(data38 < 1 || isNaN(data38)){const err77 = {instancePath:instancePath+"/components/" + i0+"/sources/" + i1+"/end_line",schemaPath:"#/properties/components/items/properties/sources/items/properties/end_line/minimum",keyword:"minimum",params:{comparison: ">=", limit: 1},message:"must be >= 1"};if(vErrors === null){vErrors = [err77];}else {vErrors.push(err77);}errors++;}}}if(data35.label !== undefined){let data39 = data35.label;if(typeof data39 === "string"){if(func2(data39) > 48){const err78 = {instancePath:instancePath+"/components/" + i0+"/sources/" + i1+"/label",schemaPath:"#/properties/components/items/properties/sources/items/properties/label/maxLength",keyword:"maxLength",params:{limit: 48},message:"must NOT have more than 48 characters"};if(vErrors === null){vErrors = [err78];}else {vErrors.push(err78);}errors++;}if(func2(data39) < 1){const err79 = {instancePath:instancePath+"/components/" + i0+"/sources/" + i1+"/label",schemaPath:"#/properties/components/items/properties/sources/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err79];}else {vErrors.push(err79);}errors++;}}else {const err80 = {instancePath:instancePath+"/components/" + i0+"/sources/" + i1+"/label",schemaPath:"#/properties/components/items/properties/sources/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err80];}else {vErrors.push(err80);}errors++;}}}else {const err81 = {instancePath:instancePath+"/components/" + i0+"/sources/" + i1,schemaPath:"#/properties/components/items/properties/sources/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err81];}else {vErrors.push(err81);}errors++;}}}else {const err82 = {instancePath:instancePath+"/components/" + i0+"/sources",schemaPath:"#/properties/components/items/properties/sources/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err82];}else {vErrors.push(err82);}errors++;}}if(data28.row !== undefined){let data40 = data28.row;if(!(((typeof data40 == "number") && (!(data40 % 1) && !isNaN(data40))) && (isFinite(data40)))){const err83 = {instancePath:instancePath+"/components/" + i0+"/row",schemaPath:"#/properties/components/items/properties/row/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err83];}else {vErrors.push(err83);}errors++;}if((typeof data40 == "number") && (isFinite(data40))){if(data40 < 0 || isNaN(data40)){const err84 = {instancePath:instancePath+"/components/" + i0+"/row",schemaPath:"#/properties/components/items/properties/row/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err84];}else {vErrors.push(err84);}errors++;}}}if(data28.col !== undefined){let data41 = data28.col;if(!(((typeof data41 == "number") && (!(data41 % 1) && !isNaN(data41))) && (isFinite(data41)))){const err85 = {instancePath:instancePath+"/components/" + i0+"/col",schemaPath:"#/properties/components/items/properties/col/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err85];}else {vErrors.push(err85);}errors++;}if((typeof data41 == "number") && (isFinite(data41))){if(data41 < 0 || isNaN(data41)){const err86 = {instancePath:instancePath+"/components/" + i0+"/col",schemaPath:"#/properties/components/items/properties/col/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err86];}else {vErrors.push(err86);}errors++;}}}if(data28.pos !== undefined){let data42 = data28.pos;if(Array.isArray(data42)){if(data42.length > 2){const err87 = {instancePath:instancePath+"/components/" + i0+"/pos",schemaPath:"common.schema.json#/$defs/point/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err87];}else {vErrors.push(err87);}errors++;}if(data42.length < 2){const err88 = {instancePath:instancePath+"/components/" + i0+"/pos",schemaPath:"common.schema.json#/$defs/point/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err88];}else {vErrors.push(err88);}errors++;}const len6 = data42.length;if(len6 > 0){let data43 = data42[0];if(!((typeof data43 == "number") && (isFinite(data43)))){const err89 = {instancePath:instancePath+"/components/" + i0+"/pos/0",schemaPath:"common.schema.json#/$defs/point/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err89];}else {vErrors.push(err89);}errors++;}}if(len6 > 1){let data44 = data42[1];if(!((typeof data44 == "number") && (isFinite(data44)))){const err90 = {instancePath:instancePath+"/components/" + i0+"/pos/1",schemaPath:"common.schema.json#/$defs/point/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err90];}else {vErrors.push(err90);}errors++;}}const len7 = data42.length;if(!(len7 <= 2)){const err91 = {instancePath:instancePath+"/components/" + i0+"/pos",schemaPath:"common.schema.json#/$defs/point/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err91];}else {vErrors.push(err91);}errors++;}}else {const err92 = {instancePath:instancePath+"/components/" + i0+"/pos",schemaPath:"common.schema.json#/$defs/point/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err92];}else {vErrors.push(err92);}errors++;}}if(data28.size !== undefined){let data45 = data28.size;if(Array.isArray(data45)){if(data45.length > 2){const err93 = {instancePath:instancePath+"/components/" + i0+"/size",schemaPath:"#/properties/components/items/properties/size/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err93];}else {vErrors.push(err93);}errors++;}if(data45.length < 2){const err94 = {instancePath:instancePath+"/components/" + i0+"/size",schemaPath:"#/properties/components/items/properties/size/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err94];}else {vErrors.push(err94);}errors++;}const len8 = data45.length;if(len8 > 0){let data46 = data45[0];if((typeof data46 == "number") && (isFinite(data46))){if(data46 <= 0 || isNaN(data46)){const err95 = {instancePath:instancePath+"/components/" + i0+"/size/0",schemaPath:"#/properties/components/items/properties/size/prefixItems/0/exclusiveMinimum",keyword:"exclusiveMinimum",params:{comparison: ">", limit: 0},message:"must be > 0"};if(vErrors === null){vErrors = [err95];}else {vErrors.push(err95);}errors++;}}else {const err96 = {instancePath:instancePath+"/components/" + i0+"/size/0",schemaPath:"#/properties/components/items/properties/size/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err96];}else {vErrors.push(err96);}errors++;}}if(len8 > 1){let data47 = data45[1];if((typeof data47 == "number") && (isFinite(data47))){if(data47 <= 0 || isNaN(data47)){const err97 = {instancePath:instancePath+"/components/" + i0+"/size/1",schemaPath:"#/properties/components/items/properties/size/prefixItems/1/exclusiveMinimum",keyword:"exclusiveMinimum",params:{comparison: ">", limit: 0},message:"must be > 0"};if(vErrors === null){vErrors = [err97];}else {vErrors.push(err97);}errors++;}}else {const err98 = {instancePath:instancePath+"/components/" + i0+"/size/1",schemaPath:"#/properties/components/items/properties/size/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err98];}else {vErrors.push(err98);}errors++;}}const len9 = data45.length;if(!(len9 <= 2)){const err99 = {instancePath:instancePath+"/components/" + i0+"/size",schemaPath:"#/properties/components/items/properties/size/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err99];}else {vErrors.push(err99);}errors++;}}else {const err100 = {instancePath:instancePath+"/components/" + i0+"/size",schemaPath:"#/properties/components/items/properties/size/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err100];}else {vErrors.push(err100);}errors++;}}}else {const err101 = {instancePath:instancePath+"/components/" + i0,schemaPath:"#/properties/components/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err101];}else {vErrors.push(err101);}errors++;}}}else {const err102 = {instancePath:instancePath+"/components",schemaPath:"#/properties/components/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err102];}else {vErrors.push(err102);}errors++;}}if(data.boundaries !== undefined){let data48 = data.boundaries;if(Array.isArray(data48)){const len10 = data48.length;for(let i2=0; i2<len10; i2++){let data49 = data48[i2];if(data49 && typeof data49 == "object" && !Array.isArray(data49)){if(data49.kind === undefined){const err103 = {instancePath:instancePath+"/boundaries/" + i2,schemaPath:"#/properties/boundaries/items/required",keyword:"required",params:{missingProperty: "kind"},message:"must have required property '"+"kind"+"'"};if(vErrors === null){vErrors = [err103];}else {vErrors.push(err103);}errors++;}if(data49.label === undefined){const err104 = {instancePath:instancePath+"/boundaries/" + i2,schemaPath:"#/properties/boundaries/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err104];}else {vErrors.push(err104);}errors++;}if(data49.wraps === undefined){const err105 = {instancePath:instancePath+"/boundaries/" + i2,schemaPath:"#/properties/boundaries/items/required",keyword:"required",params:{missingProperty: "wraps"},message:"must have required property '"+"wraps"+"'"};if(vErrors === null){vErrors = [err105];}else {vErrors.push(err105);}errors++;}for(const key6 in data49){if(!((((key6 === "kind") || (key6 === "label")) || (key6 === "wraps")) || (key6 === "pad"))){const err106 = {instancePath:instancePath+"/boundaries/" + i2,schemaPath:"#/properties/boundaries/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key6},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err106];}else {vErrors.push(err106);}errors++;}}if(data49.kind !== undefined){let data50 = data49.kind;if(!((data50 === "region") || (data50 === "security-group"))){const err107 = {instancePath:instancePath+"/boundaries/" + i2+"/kind",schemaPath:"#/properties/boundaries/items/properties/kind/enum",keyword:"enum",params:{allowedValues: schema92.properties.boundaries.items.properties.kind.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err107];}else {vErrors.push(err107);}errors++;}}if(data49.label !== undefined){let data51 = data49.label;if(typeof data51 === "string"){if(func2(data51) < 1){const err108 = {instancePath:instancePath+"/boundaries/" + i2+"/label",schemaPath:"#/properties/boundaries/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err108];}else {vErrors.push(err108);}errors++;}}else {const err109 = {instancePath:instancePath+"/boundaries/" + i2+"/label",schemaPath:"#/properties/boundaries/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err109];}else {vErrors.push(err109);}errors++;}}if(data49.wraps !== undefined){let data52 = data49.wraps;if(Array.isArray(data52)){if(data52.length < 1){const err110 = {instancePath:instancePath+"/boundaries/" + i2+"/wraps",schemaPath:"#/properties/boundaries/items/properties/wraps/minItems",keyword:"minItems",params:{limit: 1},message:"must NOT have fewer than 1 items"};if(vErrors === null){vErrors = [err110];}else {vErrors.push(err110);}errors++;}const len11 = data52.length;for(let i3=0; i3<len11; i3++){let data53 = data52[i3];if(typeof data53 === "string"){if(!pattern4.test(data53)){const err111 = {instancePath:instancePath+"/boundaries/" + i2+"/wraps/" + i3,schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err111];}else {vErrors.push(err111);}errors++;}}else {const err112 = {instancePath:instancePath+"/boundaries/" + i2+"/wraps/" + i3,schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err112];}else {vErrors.push(err112);}errors++;}}}else {const err113 = {instancePath:instancePath+"/boundaries/" + i2+"/wraps",schemaPath:"#/properties/boundaries/items/properties/wraps/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err113];}else {vErrors.push(err113);}errors++;}}if(data49.pad !== undefined){let data54 = data49.pad;if((typeof data54 == "number") && (isFinite(data54))){if(data54 < 0 || isNaN(data54)){const err114 = {instancePath:instancePath+"/boundaries/" + i2+"/pad",schemaPath:"#/properties/boundaries/items/properties/pad/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err114];}else {vErrors.push(err114);}errors++;}}else {const err115 = {instancePath:instancePath+"/boundaries/" + i2+"/pad",schemaPath:"#/properties/boundaries/items/properties/pad/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err115];}else {vErrors.push(err115);}errors++;}}}else {const err116 = {instancePath:instancePath+"/boundaries/" + i2,schemaPath:"#/properties/boundaries/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err116];}else {vErrors.push(err116);}errors++;}}}else {const err117 = {instancePath:instancePath+"/boundaries",schemaPath:"#/properties/boundaries/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err117];}else {vErrors.push(err117);}errors++;}}if(data.connections !== undefined){let data55 = data.connections;if(Array.isArray(data55)){const len12 = data55.length;for(let i4=0; i4<len12; i4++){let data56 = data55[i4];if(data56 && typeof data56 == "object" && !Array.isArray(data56)){if(data56.from === undefined){const err118 = {instancePath:instancePath+"/connections/" + i4,schemaPath:"#/properties/connections/items/required",keyword:"required",params:{missingProperty: "from"},message:"must have required property '"+"from"+"'"};if(vErrors === null){vErrors = [err118];}else {vErrors.push(err118);}errors++;}if(data56.to === undefined){const err119 = {instancePath:instancePath+"/connections/" + i4,schemaPath:"#/properties/connections/items/required",keyword:"required",params:{missingProperty: "to"},message:"must have required property '"+"to"+"'"};if(vErrors === null){vErrors = [err119];}else {vErrors.push(err119);}errors++;}for(const key7 in data56){if(!(func1.call(schema92.properties.connections.items.properties, key7))){const err120 = {instancePath:instancePath+"/connections/" + i4,schemaPath:"#/properties/connections/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key7},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err120];}else {vErrors.push(err120);}errors++;}}if(data56.id !== undefined){let data57 = data56.id;if(typeof data57 === "string"){if(!pattern4.test(data57)){const err121 = {instancePath:instancePath+"/connections/" + i4+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err121];}else {vErrors.push(err121);}errors++;}}else {const err122 = {instancePath:instancePath+"/connections/" + i4+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err122];}else {vErrors.push(err122);}errors++;}}if(data56.from !== undefined){let data58 = data56.from;if(typeof data58 === "string"){if(!pattern4.test(data58)){const err123 = {instancePath:instancePath+"/connections/" + i4+"/from",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err123];}else {vErrors.push(err123);}errors++;}}else {const err124 = {instancePath:instancePath+"/connections/" + i4+"/from",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err124];}else {vErrors.push(err124);}errors++;}}if(data56.to !== undefined){let data59 = data56.to;if(typeof data59 === "string"){if(!pattern4.test(data59)){const err125 = {instancePath:instancePath+"/connections/" + i4+"/to",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err125];}else {vErrors.push(err125);}errors++;}}else {const err126 = {instancePath:instancePath+"/connections/" + i4+"/to",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err126];}else {vErrors.push(err126);}errors++;}}if(data56.label !== undefined){if(typeof data56.label !== "string"){const err127 = {instancePath:instancePath+"/connections/" + i4+"/label",schemaPath:"#/properties/connections/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err127];}else {vErrors.push(err127);}errors++;}}if(data56.variant !== undefined){let data61 = data56.variant;if(!((((data61 === "default") || (data61 === "emphasis")) || (data61 === "security")) || (data61 === "dashed"))){const err128 = {instancePath:instancePath+"/connections/" + i4+"/variant",schemaPath:"common.schema.json#/$defs/variant/enum",keyword:"enum",params:{allowedValues: schema47.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err128];}else {vErrors.push(err128);}errors++;}}if(data56.fromSide !== undefined){let data62 = data56.fromSide;if(!((((data62 === "left") || (data62 === "right")) || (data62 === "top")) || (data62 === "bottom"))){const err129 = {instancePath:instancePath+"/connections/" + i4+"/fromSide",schemaPath:"#/properties/connections/items/properties/fromSide/enum",keyword:"enum",params:{allowedValues: schema92.properties.connections.items.properties.fromSide.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err129];}else {vErrors.push(err129);}errors++;}}if(data56.toSide !== undefined){let data63 = data56.toSide;if(!((((data63 === "left") || (data63 === "right")) || (data63 === "top")) || (data63 === "bottom"))){const err130 = {instancePath:instancePath+"/connections/" + i4+"/toSide",schemaPath:"#/properties/connections/items/properties/toSide/enum",keyword:"enum",params:{allowedValues: schema92.properties.connections.items.properties.toSide.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err130];}else {vErrors.push(err130);}errors++;}}if(data56.route !== undefined){let data64 = data56.route;if(!((((data64 === "auto") || (data64 === "straight")) || (data64 === "orthogonal-h")) || (data64 === "orthogonal-v"))){const err131 = {instancePath:instancePath+"/connections/" + i4+"/route",schemaPath:"#/properties/connections/items/properties/route/enum",keyword:"enum",params:{allowedValues: schema92.properties.connections.items.properties.route.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err131];}else {vErrors.push(err131);}errors++;}}if(data56.via !== undefined){let data65 = data56.via;if(Array.isArray(data65)){const len13 = data65.length;for(let i5=0; i5<len13; i5++){let data66 = data65[i5];if(Array.isArray(data66)){if(data66.length > 2){const err132 = {instancePath:instancePath+"/connections/" + i4+"/via/" + i5,schemaPath:"common.schema.json#/$defs/point/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err132];}else {vErrors.push(err132);}errors++;}if(data66.length < 2){const err133 = {instancePath:instancePath+"/connections/" + i4+"/via/" + i5,schemaPath:"common.schema.json#/$defs/point/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err133];}else {vErrors.push(err133);}errors++;}const len14 = data66.length;if(len14 > 0){let data67 = data66[0];if(!((typeof data67 == "number") && (isFinite(data67)))){const err134 = {instancePath:instancePath+"/connections/" + i4+"/via/" + i5+"/0",schemaPath:"common.schema.json#/$defs/point/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err134];}else {vErrors.push(err134);}errors++;}}if(len14 > 1){let data68 = data66[1];if(!((typeof data68 == "number") && (isFinite(data68)))){const err135 = {instancePath:instancePath+"/connections/" + i4+"/via/" + i5+"/1",schemaPath:"common.schema.json#/$defs/point/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err135];}else {vErrors.push(err135);}errors++;}}const len15 = data66.length;if(!(len15 <= 2)){const err136 = {instancePath:instancePath+"/connections/" + i4+"/via/" + i5,schemaPath:"common.schema.json#/$defs/point/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err136];}else {vErrors.push(err136);}errors++;}}else {const err137 = {instancePath:instancePath+"/connections/" + i4+"/via/" + i5,schemaPath:"common.schema.json#/$defs/point/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err137];}else {vErrors.push(err137);}errors++;}}}else {const err138 = {instancePath:instancePath+"/connections/" + i4+"/via",schemaPath:"#/properties/connections/items/properties/via/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err138];}else {vErrors.push(err138);}errors++;}}if(data56.labelAt !== undefined){let data69 = data56.labelAt;if(Array.isArray(data69)){if(data69.length > 2){const err139 = {instancePath:instancePath+"/connections/" + i4+"/labelAt",schemaPath:"common.schema.json#/$defs/point/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err139];}else {vErrors.push(err139);}errors++;}if(data69.length < 2){const err140 = {instancePath:instancePath+"/connections/" + i4+"/labelAt",schemaPath:"common.schema.json#/$defs/point/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err140];}else {vErrors.push(err140);}errors++;}const len16 = data69.length;if(len16 > 0){let data70 = data69[0];if(!((typeof data70 == "number") && (isFinite(data70)))){const err141 = {instancePath:instancePath+"/connections/" + i4+"/labelAt/0",schemaPath:"common.schema.json#/$defs/point/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err141];}else {vErrors.push(err141);}errors++;}}if(len16 > 1){let data71 = data69[1];if(!((typeof data71 == "number") && (isFinite(data71)))){const err142 = {instancePath:instancePath+"/connections/" + i4+"/labelAt/1",schemaPath:"common.schema.json#/$defs/point/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err142];}else {vErrors.push(err142);}errors++;}}const len17 = data69.length;if(!(len17 <= 2)){const err143 = {instancePath:instancePath+"/connections/" + i4+"/labelAt",schemaPath:"common.schema.json#/$defs/point/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err143];}else {vErrors.push(err143);}errors++;}}else {const err144 = {instancePath:instancePath+"/connections/" + i4+"/labelAt",schemaPath:"common.schema.json#/$defs/point/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err144];}else {vErrors.push(err144);}errors++;}}if(data56.labelDx !== undefined){let data72 = data56.labelDx;if(!((typeof data72 == "number") && (isFinite(data72)))){const err145 = {instancePath:instancePath+"/connections/" + i4+"/labelDx",schemaPath:"#/properties/connections/items/properties/labelDx/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err145];}else {vErrors.push(err145);}errors++;}}if(data56.labelDy !== undefined){let data73 = data56.labelDy;if(!((typeof data73 == "number") && (isFinite(data73)))){const err146 = {instancePath:instancePath+"/connections/" + i4+"/labelDy",schemaPath:"#/properties/connections/items/properties/labelDy/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err146];}else {vErrors.push(err146);}errors++;}}if(data56.labelSegment !== undefined){let data74 = data56.labelSegment;if(!(((typeof data74 == "number") && (!(data74 % 1) && !isNaN(data74))) && (isFinite(data74)))){const err147 = {instancePath:instancePath+"/connections/" + i4+"/labelSegment",schemaPath:"#/properties/connections/items/properties/labelSegment/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err147];}else {vErrors.push(err147);}errors++;}if((typeof data74 == "number") && (isFinite(data74))){if(data74 < 0 || isNaN(data74)){const err148 = {instancePath:instancePath+"/connections/" + i4+"/labelSegment",schemaPath:"#/properties/connections/items/properties/labelSegment/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err148];}else {vErrors.push(err148);}errors++;}}}if(data56.width !== undefined){let data75 = data56.width;if((typeof data75 == "number") && (isFinite(data75))){if(data75 < 0.5 || isNaN(data75)){const err149 = {instancePath:instancePath+"/connections/" + i4+"/width",schemaPath:"#/properties/connections/items/properties/width/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0.5},message:"must be >= 0.5"};if(vErrors === null){vErrors = [err149];}else {vErrors.push(err149);}errors++;}}else {const err150 = {instancePath:instancePath+"/connections/" + i4+"/width",schemaPath:"#/properties/connections/items/properties/width/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err150];}else {vErrors.push(err150);}errors++;}}}else {const err151 = {instancePath:instancePath+"/connections/" + i4,schemaPath:"#/properties/connections/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err151];}else {vErrors.push(err151);}errors++;}}}else {const err152 = {instancePath:instancePath+"/connections",schemaPath:"#/properties/connections/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err152];}else {vErrors.push(err152);}errors++;}}if(data.cards !== undefined){let data76 = data.cards;if(Array.isArray(data76)){const len18 = data76.length;for(let i6=0; i6<len18; i6++){let data77 = data76[i6];if(data77 && typeof data77 == "object" && !Array.isArray(data77)){if(data77.dot === undefined){const err153 = {instancePath:instancePath+"/cards/" + i6,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "dot"},message:"must have required property '"+"dot"+"'"};if(vErrors === null){vErrors = [err153];}else {vErrors.push(err153);}errors++;}if(data77.title === undefined){const err154 = {instancePath:instancePath+"/cards/" + i6,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "title"},message:"must have required property '"+"title"+"'"};if(vErrors === null){vErrors = [err154];}else {vErrors.push(err154);}errors++;}if(data77.items === undefined){const err155 = {instancePath:instancePath+"/cards/" + i6,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "items"},message:"must have required property '"+"items"+"'"};if(vErrors === null){vErrors = [err155];}else {vErrors.push(err155);}errors++;}for(const key8 in data77){if(!(((key8 === "dot") || (key8 === "title")) || (key8 === "items"))){const err156 = {instancePath:instancePath+"/cards/" + i6,schemaPath:"common.schema.json#/$defs/cards/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key8},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err156];}else {vErrors.push(err156);}errors++;}}if(data77.dot !== undefined){let data78 = data77.dot;if(!(((((((data78 === "cyan") || (data78 === "emerald")) || (data78 === "violet")) || (data78 === "amber")) || (data78 === "rose")) || (data78 === "orange")) || (data78 === "slate"))){const err157 = {instancePath:instancePath+"/cards/" + i6+"/dot",schemaPath:"common.schema.json#/$defs/cards/items/properties/dot/enum",keyword:"enum",params:{allowedValues: schema52.items.properties.dot.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err157];}else {vErrors.push(err157);}errors++;}}if(data77.title !== undefined){let data79 = data77.title;if(typeof data79 === "string"){if(func2(data79) < 1){const err158 = {instancePath:instancePath+"/cards/" + i6+"/title",schemaPath:"common.schema.json#/$defs/cards/items/properties/title/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err158];}else {vErrors.push(err158);}errors++;}}else {const err159 = {instancePath:instancePath+"/cards/" + i6+"/title",schemaPath:"common.schema.json#/$defs/cards/items/properties/title/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err159];}else {vErrors.push(err159);}errors++;}}if(data77.items !== undefined){let data80 = data77.items;if(Array.isArray(data80)){const len19 = data80.length;for(let i7=0; i7<len19; i7++){if(typeof data80[i7] !== "string"){const err160 = {instancePath:instancePath+"/cards/" + i6+"/items/" + i7,schemaPath:"common.schema.json#/$defs/cards/items/properties/items/items/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err160];}else {vErrors.push(err160);}errors++;}}}else {const err161 = {instancePath:instancePath+"/cards/" + i6+"/items",schemaPath:"common.schema.json#/$defs/cards/items/properties/items/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err161];}else {vErrors.push(err161);}errors++;}}}else {const err162 = {instancePath:instancePath+"/cards/" + i6,schemaPath:"common.schema.json#/$defs/cards/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err162];}else {vErrors.push(err162);}errors++;}}}else {const err163 = {instancePath:instancePath+"/cards",schemaPath:"common.schema.json#/$defs/cards/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err163];}else {vErrors.push(err163);}errors++;}}}else {const err164 = {instancePath,schemaPath:"#/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err164];}else {vErrors.push(err164);}errors++;}validate33.errors = vErrors;return errors === 0;}validate33.evaluated = {"props":true,"dynamicProps":false,"dynamicItems":false};+};const schema33 = {"type":"array","maxItems":5,"items":{"type":"object","additionalProperties":false,"required":["id","label","focus"],"properties":{"id":{"$ref":"#/$defs/id"},"label":{"type":"string","minLength":1,"maxLength":48},"focus":{"type":"array","minItems":1,"items":{"$ref":"#/$defs/id"}},"note":{"type":"string","maxLength":140}}}};const pattern4 = new RegExp("^[a-zA-Z][a-zA-Z0-9_-]*$", "u");function validate22(data, {instancePath="", parentData, parentDataProperty, rootData=data, dynamicAnchors={}}={}){let vErrors = null;let errors = 0;const evaluated0 = validate22.evaluated;if(evaluated0.dynamicProps){evaluated0.props = undefined;}if(evaluated0.dynamicItems){evaluated0.items = undefined;}if(Array.isArray(data)){if(data.length > 5){const err0 = {instancePath,schemaPath:"#/maxItems",keyword:"maxItems",params:{limit: 5},message:"must NOT have more than 5 items"};if(vErrors === null){vErrors = [err0];}else {vErrors.push(err0);}errors++;}const len0 = data.length;for(let i0=0; i0<len0; i0++){let data0 = data[i0];if(data0 && typeof data0 == "object" && !Array.isArray(data0)){if(data0.id === undefined){const err1 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err1];}else {vErrors.push(err1);}errors++;}if(data0.label === undefined){const err2 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err2];}else {vErrors.push(err2);}errors++;}if(data0.focus === undefined){const err3 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "focus"},message:"must have required property '"+"focus"+"'"};if(vErrors === null){vErrors = [err3];}else {vErrors.push(err3);}errors++;}for(const key0 in data0){if(!((((key0 === "id") || (key0 === "label")) || (key0 === "focus")) || (key0 === "note"))){const err4 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key0},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err4];}else {vErrors.push(err4);}errors++;}}if(data0.id !== undefined){let data1 = data0.id;if(typeof data1 === "string"){if(!pattern4.test(data1)){const err5 = {instancePath:instancePath+"/" + i0+"/id",schemaPath:"#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err5];}else {vErrors.push(err5);}errors++;}}else {const err6 = {instancePath:instancePath+"/" + i0+"/id",schemaPath:"#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err6];}else {vErrors.push(err6);}errors++;}}if(data0.label !== undefined){let data2 = data0.label;if(typeof data2 === "string"){if(func3(data2) > 48){const err7 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/maxLength",keyword:"maxLength",params:{limit: 48},message:"must NOT have more than 48 characters"};if(vErrors === null){vErrors = [err7];}else {vErrors.push(err7);}errors++;}if(func3(data2) < 1){const err8 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err8];}else {vErrors.push(err8);}errors++;}}else {const err9 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err9];}else {vErrors.push(err9);}errors++;}}if(data0.focus !== undefined){let data3 = data0.focus;if(Array.isArray(data3)){if(data3.length < 1){const err10 = {instancePath:instancePath+"/" + i0+"/focus",schemaPath:"#/items/properties/focus/minItems",keyword:"minItems",params:{limit: 1},message:"must NOT have fewer than 1 items"};if(vErrors === null){vErrors = [err10];}else {vErrors.push(err10);}errors++;}const len1 = data3.length;for(let i1=0; i1<len1; i1++){let data4 = data3[i1];if(typeof data4 === "string"){if(!pattern4.test(data4)){const err11 = {instancePath:instancePath+"/" + i0+"/focus/" + i1,schemaPath:"#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err11];}else {vErrors.push(err11);}errors++;}}else {const err12 = {instancePath:instancePath+"/" + i0+"/focus/" + i1,schemaPath:"#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err12];}else {vErrors.push(err12);}errors++;}}}else {const err13 = {instancePath:instancePath+"/" + i0+"/focus",schemaPath:"#/items/properties/focus/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err13];}else {vErrors.push(err13);}errors++;}}if(data0.note !== undefined){let data5 = data0.note;if(typeof data5 === "string"){if(func3(data5) > 140){const err14 = {instancePath:instancePath+"/" + i0+"/note",schemaPath:"#/items/properties/note/maxLength",keyword:"maxLength",params:{limit: 140},message:"must NOT have more than 140 characters"};if(vErrors === null){vErrors = [err14];}else {vErrors.push(err14);}errors++;}}else {const err15 = {instancePath:instancePath+"/" + i0+"/note",schemaPath:"#/items/properties/note/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err15];}else {vErrors.push(err15);}errors++;}}}else {const err16 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err16];}else {vErrors.push(err16);}errors++;}}}else {const err17 = {instancePath,schemaPath:"#/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err17];}else {vErrors.push(err17);}errors++;}validate22.errors = vErrors;return errors === 0;}validate22.evaluated = {"items":true,"dynamicProps":false,"dynamicItems":false};function validate20(data, {instancePath="", parentData, parentDataProperty, rootData=data, dynamicAnchors={}}={}){/*# sourceURL="https://github.com/tt-a1i/archify/schemas/workflow.schema.json" */;let vErrors = null;let errors = 0;const evaluated0 = validate20.evaluated;if(evaluated0.dynamicProps){evaluated0.props = undefined;}if(evaluated0.dynamicItems){evaluated0.items = undefined;}if(data && typeof data == "object" && !Array.isArray(data)){if(data.schema_version === undefined){const err0 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "schema_version"},message:"must have required property '"+"schema_version"+"'"};if(vErrors === null){vErrors = [err0];}else {vErrors.push(err0);}errors++;}if(data.diagram_type === undefined){const err1 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "diagram_type"},message:"must have required property '"+"diagram_type"+"'"};if(vErrors === null){vErrors = [err1];}else {vErrors.push(err1);}errors++;}if(data.meta === undefined){const err2 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "meta"},message:"must have required property '"+"meta"+"'"};if(vErrors === null){vErrors = [err2];}else {vErrors.push(err2);}errors++;}if(data.lanes === undefined){const err3 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "lanes"},message:"must have required property '"+"lanes"+"'"};if(vErrors === null){vErrors = [err3];}else {vErrors.push(err3);}errors++;}if(data.nodes === undefined){const err4 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "nodes"},message:"must have required property '"+"nodes"+"'"};if(vErrors === null){vErrors = [err4];}else {vErrors.push(err4);}errors++;}if(data.edges === undefined){const err5 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "edges"},message:"must have required property '"+"edges"+"'"};if(vErrors === null){vErrors = [err5];}else {vErrors.push(err5);}errors++;}for(const key0 in data){if(!(func1.call(schema31.properties, key0))){const err6 = {instancePath,schemaPath:"#/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key0},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err6];}else {vErrors.push(err6);}errors++;}}if(data.schema_version !== undefined){if(1 !== data.schema_version){const err7 = {instancePath:instancePath+"/schema_version",schemaPath:"#/properties/schema_version/const",keyword:"const",params:{allowedValue: 1},message:"must be equal to constant"};if(vErrors === null){vErrors = [err7];}else {vErrors.push(err7);}errors++;}}if(data.diagram_type !== undefined){if("workflow" !== data.diagram_type){const err8 = {instancePath:instancePath+"/diagram_type",schemaPath:"#/properties/diagram_type/const",keyword:"const",params:{allowedValue: "workflow"},message:"must be equal to constant"};if(vErrors === null){vErrors = [err8];}else {vErrors.push(err8);}errors++;}}if(data.meta !== undefined){let data2 = data.meta;if(data2 && typeof data2 == "object" && !Array.isArray(data2)){if(data2.title === undefined){const err9 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/required",keyword:"required",params:{missingProperty: "title"},message:"must have required property '"+"title"+"'"};if(vErrors === null){vErrors = [err9];}else {vErrors.push(err9);}errors++;}for(const key1 in data2){if(!(func1.call(schema31.properties.meta.properties, key1))){const err10 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key1},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err10];}else {vErrors.push(err10);}errors++;}}if(data2.title !== undefined){let data3 = data2.title;if(typeof data3 === "string"){if(func3(data3) < 1){const err11 = {instancePath:instancePath+"/meta/title",schemaPath:"#/properties/meta/properties/title/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err11];}else {vErrors.push(err11);}errors++;}}else {const err12 = {instancePath:instancePath+"/meta/title",schemaPath:"#/properties/meta/properties/title/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err12];}else {vErrors.push(err12);}errors++;}}if(data2.subtitle !== undefined){if(typeof data2.subtitle !== "string"){const err13 = {instancePath:instancePath+"/meta/subtitle",schemaPath:"#/properties/meta/properties/subtitle/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err13];}else {vErrors.push(err13);}errors++;}}if(data2.output !== undefined){if(typeof data2.output !== "string"){const err14 = {instancePath:instancePath+"/meta/output",schemaPath:"#/properties/meta/properties/output/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err14];}else {vErrors.push(err14);}errors++;}}if(data2.animation !== undefined){let data6 = data2.animation;if(!((data6 === "trace") || (data6 === "none"))){const err15 = {instancePath:instancePath+"/meta/animation",schemaPath:"#/properties/meta/properties/animation/enum",keyword:"enum",params:{allowedValues: schema31.properties.meta.properties.animation.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err15];}else {vErrors.push(err15);}errors++;}}if(data2.visual_preset !== undefined){let data7 = data2.visual_preset;if(!((((data7 === "classic") || (data7 === "signal-flow")) || (data7 === "blueprint")) || (data7 === "editorial"))){const err16 = {instancePath:instancePath+"/meta/visual_preset",schemaPath:"#/properties/meta/properties/visual_preset/enum",keyword:"enum",params:{allowedValues: schema31.properties.meta.properties.visual_preset.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err16];}else {vErrors.push(err16);}errors++;}}if(data2.quality_profile !== undefined){let data8 = data2.quality_profile;if(!((data8 === "standard") || (data8 === "showcase"))){const err17 = {instancePath:instancePath+"/meta/quality_profile",schemaPath:"#/properties/meta/properties/quality_profile/enum",keyword:"enum",params:{allowedValues: schema31.properties.meta.properties.quality_profile.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err17];}else {vErrors.push(err17);}errors++;}}if(data2.views !== undefined){if(!(validate22(data2.views, {instancePath:instancePath+"/meta/views",parentData:data2,parentDataProperty:"views",rootData,dynamicAnchors}))){vErrors = vErrors === null ? validate22.errors : vErrors.concat(validate22.errors);errors = vErrors.length;}}if(data2.legend !== undefined){let data10 = data2.legend;if(data10 && typeof data10 == "object" && !Array.isArray(data10)){for(const key2 in data10){if(!((key2 === "mode") || (key2 === "entries"))){const err18 = {instancePath:instancePath+"/meta/legend",schemaPath:"#/properties/meta/properties/legend/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key2},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err18];}else {vErrors.push(err18);}errors++;}}if(data10.mode !== undefined){let data11 = data10.mode;if(!(((data11 === "auto") || (data11 === "all")) || (data11 === "hidden"))){const err19 = {instancePath:instancePath+"/meta/legend/mode",schemaPath:"common.schema.json#/$defs/legendMode/enum",keyword:"enum",params:{allowedValues: schema36.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err19];}else {vErrors.push(err19);}errors++;}}if(data10.entries !== undefined){let data12 = data10.entries;if(data12 && typeof data12 == "object" && !Array.isArray(data12)){for(const key3 in data12){if(!(((((((key3 === "frontend") || (key3 === "backend")) || (key3 === "database")) || (key3 === "cloud")) || (key3 === "security")) || (key3 === "messagebus")) || (key3 === "external"))){const err20 = {instancePath:instancePath+"/meta/legend/entries",schemaPath:"#/properties/meta/properties/legend/properties/entries/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key3},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err20];}else {vErrors.push(err20);}errors++;}}if(data12.frontend !== undefined){let data13 = data12.frontend;if(data13 && typeof data13 == "object" && !Array.isArray(data13)){if(Object.keys(data13).length < 1){const err21 = {instancePath:instancePath+"/meta/legend/entries/frontend",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err21];}else {vErrors.push(err21);}errors++;}for(const key4 in data13){if(!((key4 === "label") || (key4 === "visible"))){const err22 = {instancePath:instancePath+"/meta/legend/entries/frontend",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key4},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err22];}else {vErrors.push(err22);}errors++;}}if(data13.label !== undefined){let data14 = data13.label;if(typeof data14 === "string"){if(func3(data14) > 80){const err23 = {instancePath:instancePath+"/meta/legend/entries/frontend/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err23];}else {vErrors.push(err23);}errors++;}if(func3(data14) < 1){const err24 = {instancePath:instancePath+"/meta/legend/entries/frontend/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err24];}else {vErrors.push(err24);}errors++;}}else {const err25 = {instancePath:instancePath+"/meta/legend/entries/frontend/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err25];}else {vErrors.push(err25);}errors++;}}if(data13.visible !== undefined){if(typeof data13.visible !== "boolean"){const err26 = {instancePath:instancePath+"/meta/legend/entries/frontend/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err26];}else {vErrors.push(err26);}errors++;}}}else {const err27 = {instancePath:instancePath+"/meta/legend/entries/frontend",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err27];}else {vErrors.push(err27);}errors++;}}if(data12.backend !== undefined){let data16 = data12.backend;if(data16 && typeof data16 == "object" && !Array.isArray(data16)){if(Object.keys(data16).length < 1){const err28 = {instancePath:instancePath+"/meta/legend/entries/backend",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err28];}else {vErrors.push(err28);}errors++;}for(const key5 in data16){if(!((key5 === "label") || (key5 === "visible"))){const err29 = {instancePath:instancePath+"/meta/legend/entries/backend",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key5},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err29];}else {vErrors.push(err29);}errors++;}}if(data16.label !== undefined){let data17 = data16.label;if(typeof data17 === "string"){if(func3(data17) > 80){const err30 = {instancePath:instancePath+"/meta/legend/entries/backend/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err30];}else {vErrors.push(err30);}errors++;}if(func3(data17) < 1){const err31 = {instancePath:instancePath+"/meta/legend/entries/backend/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err31];}else {vErrors.push(err31);}errors++;}}else {const err32 = {instancePath:instancePath+"/meta/legend/entries/backend/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err32];}else {vErrors.push(err32);}errors++;}}if(data16.visible !== undefined){if(typeof data16.visible !== "boolean"){const err33 = {instancePath:instancePath+"/meta/legend/entries/backend/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err33];}else {vErrors.push(err33);}errors++;}}}else {const err34 = {instancePath:instancePath+"/meta/legend/entries/backend",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err34];}else {vErrors.push(err34);}errors++;}}if(data12.database !== undefined){let data19 = data12.database;if(data19 && typeof data19 == "object" && !Array.isArray(data19)){if(Object.keys(data19).length < 1){const err35 = {instancePath:instancePath+"/meta/legend/entries/database",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err35];}else {vErrors.push(err35);}errors++;}for(const key6 in data19){if(!((key6 === "label") || (key6 === "visible"))){const err36 = {instancePath:instancePath+"/meta/legend/entries/database",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key6},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err36];}else {vErrors.push(err36);}errors++;}}if(data19.label !== undefined){let data20 = data19.label;if(typeof data20 === "string"){if(func3(data20) > 80){const err37 = {instancePath:instancePath+"/meta/legend/entries/database/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err37];}else {vErrors.push(err37);}errors++;}if(func3(data20) < 1){const err38 = {instancePath:instancePath+"/meta/legend/entries/database/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err38];}else {vErrors.push(err38);}errors++;}}else {const err39 = {instancePath:instancePath+"/meta/legend/entries/database/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err39];}else {vErrors.push(err39);}errors++;}}if(data19.visible !== undefined){if(typeof data19.visible !== "boolean"){const err40 = {instancePath:instancePath+"/meta/legend/entries/database/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err40];}else {vErrors.push(err40);}errors++;}}}else {const err41 = {instancePath:instancePath+"/meta/legend/entries/database",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err41];}else {vErrors.push(err41);}errors++;}}if(data12.cloud !== undefined){let data22 = data12.cloud;if(data22 && typeof data22 == "object" && !Array.isArray(data22)){if(Object.keys(data22).length < 1){const err42 = {instancePath:instancePath+"/meta/legend/entries/cloud",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err42];}else {vErrors.push(err42);}errors++;}for(const key7 in data22){if(!((key7 === "label") || (key7 === "visible"))){const err43 = {instancePath:instancePath+"/meta/legend/entries/cloud",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key7},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err43];}else {vErrors.push(err43);}errors++;}}if(data22.label !== undefined){let data23 = data22.label;if(typeof data23 === "string"){if(func3(data23) > 80){const err44 = {instancePath:instancePath+"/meta/legend/entries/cloud/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err44];}else {vErrors.push(err44);}errors++;}if(func3(data23) < 1){const err45 = {instancePath:instancePath+"/meta/legend/entries/cloud/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err45];}else {vErrors.push(err45);}errors++;}}else {const err46 = {instancePath:instancePath+"/meta/legend/entries/cloud/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err46];}else {vErrors.push(err46);}errors++;}}if(data22.visible !== undefined){if(typeof data22.visible !== "boolean"){const err47 = {instancePath:instancePath+"/meta/legend/entries/cloud/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err47];}else {vErrors.push(err47);}errors++;}}}else {const err48 = {instancePath:instancePath+"/meta/legend/entries/cloud",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err48];}else {vErrors.push(err48);}errors++;}}if(data12.security !== undefined){let data25 = data12.security;if(data25 && typeof data25 == "object" && !Array.isArray(data25)){if(Object.keys(data25).length < 1){const err49 = {instancePath:instancePath+"/meta/legend/entries/security",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err49];}else {vErrors.push(err49);}errors++;}for(const key8 in data25){if(!((key8 === "label") || (key8 === "visible"))){const err50 = {instancePath:instancePath+"/meta/legend/entries/security",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key8},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err50];}else {vErrors.push(err50);}errors++;}}if(data25.label !== undefined){let data26 = data25.label;if(typeof data26 === "string"){if(func3(data26) > 80){const err51 = {instancePath:instancePath+"/meta/legend/entries/security/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err51];}else {vErrors.push(err51);}errors++;}if(func3(data26) < 1){const err52 = {instancePath:instancePath+"/meta/legend/entries/security/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err52];}else {vErrors.push(err52);}errors++;}}else {const err53 = {instancePath:instancePath+"/meta/legend/entries/security/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err53];}else {vErrors.push(err53);}errors++;}}if(data25.visible !== undefined){if(typeof data25.visible !== "boolean"){const err54 = {instancePath:instancePath+"/meta/legend/entries/security/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err54];}else {vErrors.push(err54);}errors++;}}}else {const err55 = {instancePath:instancePath+"/meta/legend/entries/security",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err55];}else {vErrors.push(err55);}errors++;}}if(data12.messagebus !== undefined){let data28 = data12.messagebus;if(data28 && typeof data28 == "object" && !Array.isArray(data28)){if(Object.keys(data28).length < 1){const err56 = {instancePath:instancePath+"/meta/legend/entries/messagebus",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err56];}else {vErrors.push(err56);}errors++;}for(const key9 in data28){if(!((key9 === "label") || (key9 === "visible"))){const err57 = {instancePath:instancePath+"/meta/legend/entries/messagebus",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key9},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err57];}else {vErrors.push(err57);}errors++;}}if(data28.label !== undefined){let data29 = data28.label;if(typeof data29 === "string"){if(func3(data29) > 80){const err58 = {instancePath:instancePath+"/meta/legend/entries/messagebus/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err58];}else {vErrors.push(err58);}errors++;}if(func3(data29) < 1){const err59 = {instancePath:instancePath+"/meta/legend/entries/messagebus/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err59];}else {vErrors.push(err59);}errors++;}}else {const err60 = {instancePath:instancePath+"/meta/legend/entries/messagebus/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err60];}else {vErrors.push(err60);}errors++;}}if(data28.visible !== undefined){if(typeof data28.visible !== "boolean"){const err61 = {instancePath:instancePath+"/meta/legend/entries/messagebus/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err61];}else {vErrors.push(err61);}errors++;}}}else {const err62 = {instancePath:instancePath+"/meta/legend/entries/messagebus",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err62];}else {vErrors.push(err62);}errors++;}}if(data12.external !== undefined){let data31 = data12.external;if(data31 && typeof data31 == "object" && !Array.isArray(data31)){if(Object.keys(data31).length < 1){const err63 = {instancePath:instancePath+"/meta/legend/entries/external",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err63];}else {vErrors.push(err63);}errors++;}for(const key10 in data31){if(!((key10 === "label") || (key10 === "visible"))){const err64 = {instancePath:instancePath+"/meta/legend/entries/external",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key10},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err64];}else {vErrors.push(err64);}errors++;}}if(data31.label !== undefined){let data32 = data31.label;if(typeof data32 === "string"){if(func3(data32) > 80){const err65 = {instancePath:instancePath+"/meta/legend/entries/external/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err65];}else {vErrors.push(err65);}errors++;}if(func3(data32) < 1){const err66 = {instancePath:instancePath+"/meta/legend/entries/external/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err66];}else {vErrors.push(err66);}errors++;}}else {const err67 = {instancePath:instancePath+"/meta/legend/entries/external/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err67];}else {vErrors.push(err67);}errors++;}}if(data31.visible !== undefined){if(typeof data31.visible !== "boolean"){const err68 = {instancePath:instancePath+"/meta/legend/entries/external/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err68];}else {vErrors.push(err68);}errors++;}}}else {const err69 = {instancePath:instancePath+"/meta/legend/entries/external",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err69];}else {vErrors.push(err69);}errors++;}}}else {const err70 = {instancePath:instancePath+"/meta/legend/entries",schemaPath:"#/properties/meta/properties/legend/properties/entries/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err70];}else {vErrors.push(err70);}errors++;}}}else {const err71 = {instancePath:instancePath+"/meta/legend",schemaPath:"#/properties/meta/properties/legend/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err71];}else {vErrors.push(err71);}errors++;}}if(data2.viewBox !== undefined){let data34 = data2.viewBox;if(Array.isArray(data34)){if(data34.length > 2){const err72 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err72];}else {vErrors.push(err72);}errors++;}if(data34.length < 2){const err73 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err73];}else {vErrors.push(err73);}errors++;}const len0 = data34.length;if(len0 > 0){let data35 = data34[0];if((typeof data35 == "number") && (isFinite(data35))){if(data35 < 700 || isNaN(data35)){const err74 = {instancePath:instancePath+"/meta/viewBox/0",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/0/minimum",keyword:"minimum",params:{comparison: ">=", limit: 700},message:"must be >= 700"};if(vErrors === null){vErrors = [err74];}else {vErrors.push(err74);}errors++;}}else {const err75 = {instancePath:instancePath+"/meta/viewBox/0",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err75];}else {vErrors.push(err75);}errors++;}}if(len0 > 1){let data36 = data34[1];if((typeof data36 == "number") && (isFinite(data36))){if(data36 < 240 || isNaN(data36)){const err76 = {instancePath:instancePath+"/meta/viewBox/1",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/1/minimum",keyword:"minimum",params:{comparison: ">=", limit: 240},message:"must be >= 240"};if(vErrors === null){vErrors = [err76];}else {vErrors.push(err76);}errors++;}}else {const err77 = {instancePath:instancePath+"/meta/viewBox/1",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err77];}else {vErrors.push(err77);}errors++;}}const len1 = data34.length;if(!(len1 <= 2)){const err78 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err78];}else {vErrors.push(err78);}errors++;}}else {const err79 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err79];}else {vErrors.push(err79);}errors++;}}}else {const err80 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err80];}else {vErrors.push(err80);}errors++;}}if(data.lanes !== undefined){let data37 = data.lanes;if(Array.isArray(data37)){if(data37.length < 1){const err81 = {instancePath:instancePath+"/lanes",schemaPath:"#/properties/lanes/minItems",keyword:"minItems",params:{limit: 1},message:"must NOT have fewer than 1 items"};if(vErrors === null){vErrors = [err81];}else {vErrors.push(err81);}errors++;}const len2 = data37.length;for(let i0=0; i0<len2; i0++){let data38 = data37[i0];if(data38 && typeof data38 == "object" && !Array.isArray(data38)){if(data38.id === undefined){const err82 = {instancePath:instancePath+"/lanes/" + i0,schemaPath:"#/properties/lanes/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err82];}else {vErrors.push(err82);}errors++;}if(data38.label === undefined){const err83 = {instancePath:instancePath+"/lanes/" + i0,schemaPath:"#/properties/lanes/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err83];}else {vErrors.push(err83);}errors++;}for(const key11 in data38){if(!(((key11 === "id") || (key11 === "label")) || (key11 === "variant"))){const err84 = {instancePath:instancePath+"/lanes/" + i0,schemaPath:"#/properties/lanes/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key11},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err84];}else {vErrors.push(err84);}errors++;}}if(data38.id !== undefined){let data39 = data38.id;if(typeof data39 === "string"){if(!pattern4.test(data39)){const err85 = {instancePath:instancePath+"/lanes/" + i0+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err85];}else {vErrors.push(err85);}errors++;}}else {const err86 = {instancePath:instancePath+"/lanes/" + i0+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err86];}else {vErrors.push(err86);}errors++;}}if(data38.label !== undefined){let data40 = data38.label;if(typeof data40 === "string"){if(func3(data40) < 1){const err87 = {instancePath:instancePath+"/lanes/" + i0+"/label",schemaPath:"#/properties/lanes/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err87];}else {vErrors.push(err87);}errors++;}}else {const err88 = {instancePath:instancePath+"/lanes/" + i0+"/label",schemaPath:"#/properties/lanes/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err88];}else {vErrors.push(err88);}errors++;}}if(data38.variant !== undefined){let data41 = data38.variant;if(!((data41 === "normal") || (data41 === "exception"))){const err89 = {instancePath:instancePath+"/lanes/" + i0+"/variant",schemaPath:"#/properties/lanes/items/properties/variant/enum",keyword:"enum",params:{allowedValues: schema31.properties.lanes.items.properties.variant.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err89];}else {vErrors.push(err89);}errors++;}}}else {const err90 = {instancePath:instancePath+"/lanes/" + i0,schemaPath:"#/properties/lanes/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err90];}else {vErrors.push(err90);}errors++;}}}else {const err91 = {instancePath:instancePath+"/lanes",schemaPath:"#/properties/lanes/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err91];}else {vErrors.push(err91);}errors++;}}if(data.phases !== undefined){let data42 = data.phases;if(Array.isArray(data42)){const len3 = data42.length;for(let i1=0; i1<len3; i1++){let data43 = data42[i1];if(data43 && typeof data43 == "object" && !Array.isArray(data43)){if(data43.id === undefined){const err92 = {instancePath:instancePath+"/phases/" + i1,schemaPath:"#/properties/phases/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err92];}else {vErrors.push(err92);}errors++;}if(data43.label === undefined){const err93 = {instancePath:instancePath+"/phases/" + i1,schemaPath:"#/properties/phases/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err93];}else {vErrors.push(err93);}errors++;}if(data43.fromCol === undefined){const err94 = {instancePath:instancePath+"/phases/" + i1,schemaPath:"#/properties/phases/items/required",keyword:"required",params:{missingProperty: "fromCol"},message:"must have required property '"+"fromCol"+"'"};if(vErrors === null){vErrors = [err94];}else {vErrors.push(err94);}errors++;}if(data43.toCol === undefined){const err95 = {instancePath:instancePath+"/phases/" + i1,schemaPath:"#/properties/phases/items/required",keyword:"required",params:{missingProperty: "toCol"},message:"must have required property '"+"toCol"+"'"};if(vErrors === null){vErrors = [err95];}else {vErrors.push(err95);}errors++;}for(const key12 in data43){if(!(((((key12 === "id") || (key12 === "label")) || (key12 === "fromCol")) || (key12 === "toCol")) || (key12 === "variant"))){const err96 = {instancePath:instancePath+"/phases/" + i1,schemaPath:"#/properties/phases/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key12},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err96];}else {vErrors.push(err96);}errors++;}}if(data43.id !== undefined){let data44 = data43.id;if(typeof data44 === "string"){if(!pattern4.test(data44)){const err97 = {instancePath:instancePath+"/phases/" + i1+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err97];}else {vErrors.push(err97);}errors++;}}else {const err98 = {instancePath:instancePath+"/phases/" + i1+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err98];}else {vErrors.push(err98);}errors++;}}if(data43.label !== undefined){let data45 = data43.label;if(typeof data45 === "string"){if(func3(data45) < 1){const err99 = {instancePath:instancePath+"/phases/" + i1+"/label",schemaPath:"#/properties/phases/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err99];}else {vErrors.push(err99);}errors++;}}else {const err100 = {instancePath:instancePath+"/phases/" + i1+"/label",schemaPath:"#/properties/phases/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err100];}else {vErrors.push(err100);}errors++;}}if(data43.fromCol !== undefined){let data46 = data43.fromCol;if(!(((typeof data46 == "number") && (!(data46 % 1) && !isNaN(data46))) && (isFinite(data46)))){const err101 = {instancePath:instancePath+"/phases/" + i1+"/fromCol",schemaPath:"#/properties/phases/items/properties/fromCol/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err101];}else {vErrors.push(err101);}errors++;}if((typeof data46 == "number") && (isFinite(data46))){if(data46 > 5 || isNaN(data46)){const err102 = {instancePath:instancePath+"/phases/" + i1+"/fromCol",schemaPath:"#/properties/phases/items/properties/fromCol/maximum",keyword:"maximum",params:{comparison: "<=", limit: 5},message:"must be <= 5"};if(vErrors === null){vErrors = [err102];}else {vErrors.push(err102);}errors++;}if(data46 < 0 || isNaN(data46)){const err103 = {instancePath:instancePath+"/phases/" + i1+"/fromCol",schemaPath:"#/properties/phases/items/properties/fromCol/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err103];}else {vErrors.push(err103);}errors++;}}}if(data43.toCol !== undefined){let data47 = data43.toCol;if(!(((typeof data47 == "number") && (!(data47 % 1) && !isNaN(data47))) && (isFinite(data47)))){const err104 = {instancePath:instancePath+"/phases/" + i1+"/toCol",schemaPath:"#/properties/phases/items/properties/toCol/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err104];}else {vErrors.push(err104);}errors++;}if((typeof data47 == "number") && (isFinite(data47))){if(data47 > 5 || isNaN(data47)){const err105 = {instancePath:instancePath+"/phases/" + i1+"/toCol",schemaPath:"#/properties/phases/items/properties/toCol/maximum",keyword:"maximum",params:{comparison: "<=", limit: 5},message:"must be <= 5"};if(vErrors === null){vErrors = [err105];}else {vErrors.push(err105);}errors++;}if(data47 < 0 || isNaN(data47)){const err106 = {instancePath:instancePath+"/phases/" + i1+"/toCol",schemaPath:"#/properties/phases/items/properties/toCol/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err106];}else {vErrors.push(err106);}errors++;}}}if(data43.variant !== undefined){let data48 = data43.variant;if(!((((data48 === "default") || (data48 === "emphasis")) || (data48 === "security")) || (data48 === "dashed"))){const err107 = {instancePath:instancePath+"/phases/" + i1+"/variant",schemaPath:"#/properties/phases/items/properties/variant/enum",keyword:"enum",params:{allowedValues: schema31.properties.phases.items.properties.variant.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err107];}else {vErrors.push(err107);}errors++;}}}else {const err108 = {instancePath:instancePath+"/phases/" + i1,schemaPath:"#/properties/phases/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err108];}else {vErrors.push(err108);}errors++;}}}else {const err109 = {instancePath:instancePath+"/phases",schemaPath:"#/properties/phases/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err109];}else {vErrors.push(err109);}errors++;}}if(data.groups !== undefined){let data49 = data.groups;if(Array.isArray(data49)){const len4 = data49.length;for(let i2=0; i2<len4; i2++){let data50 = data49[i2];if(data50 && typeof data50 == "object" && !Array.isArray(data50)){if(data50.id === undefined){const err110 = {instancePath:instancePath+"/groups/" + i2,schemaPath:"#/properties/groups/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err110];}else {vErrors.push(err110);}errors++;}if(data50.label === undefined){const err111 = {instancePath:instancePath+"/groups/" + i2,schemaPath:"#/properties/groups/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err111];}else {vErrors.push(err111);}errors++;}if(data50.lane === undefined){const err112 = {instancePath:instancePath+"/groups/" + i2,schemaPath:"#/properties/groups/items/required",keyword:"required",params:{missingProperty: "lane"},message:"must have required property '"+"lane"+"'"};if(vErrors === null){vErrors = [err112];}else {vErrors.push(err112);}errors++;}if(data50.fromCol === undefined){const err113 = {instancePath:instancePath+"/groups/" + i2,schemaPath:"#/properties/groups/items/required",keyword:"required",params:{missingProperty: "fromCol"},message:"must have required property '"+"fromCol"+"'"};if(vErrors === null){vErrors = [err113];}else {vErrors.push(err113);}errors++;}if(data50.toCol === undefined){const err114 = {instancePath:instancePath+"/groups/" + i2,schemaPath:"#/properties/groups/items/required",keyword:"required",params:{missingProperty: "toCol"},message:"must have required property '"+"toCol"+"'"};if(vErrors === null){vErrors = [err114];}else {vErrors.push(err114);}errors++;}for(const key13 in data50){if(!((((((key13 === "id") || (key13 === "label")) || (key13 === "lane")) || (key13 === "fromCol")) || (key13 === "toCol")) || (key13 === "variant"))){const err115 = {instancePath:instancePath+"/groups/" + i2,schemaPath:"#/properties/groups/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key13},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err115];}else {vErrors.push(err115);}errors++;}}if(data50.id !== undefined){let data51 = data50.id;if(typeof data51 === "string"){if(!pattern4.test(data51)){const err116 = {instancePath:instancePath+"/groups/" + i2+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err116];}else {vErrors.push(err116);}errors++;}}else {const err117 = {instancePath:instancePath+"/groups/" + i2+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err117];}else {vErrors.push(err117);}errors++;}}if(data50.label !== undefined){let data52 = data50.label;if(typeof data52 === "string"){if(func3(data52) < 1){const err118 = {instancePath:instancePath+"/groups/" + i2+"/label",schemaPath:"#/properties/groups/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err118];}else {vErrors.push(err118);}errors++;}}else {const err119 = {instancePath:instancePath+"/groups/" + i2+"/label",schemaPath:"#/properties/groups/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err119];}else {vErrors.push(err119);}errors++;}}if(data50.lane !== undefined){let data53 = data50.lane;if(typeof data53 === "string"){if(!pattern4.test(data53)){const err120 = {instancePath:instancePath+"/groups/" + i2+"/lane",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err120];}else {vErrors.push(err120);}errors++;}}else {const err121 = {instancePath:instancePath+"/groups/" + i2+"/lane",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err121];}else {vErrors.push(err121);}errors++;}}if(data50.fromCol !== undefined){let data54 = data50.fromCol;if(!(((typeof data54 == "number") && (!(data54 % 1) && !isNaN(data54))) && (isFinite(data54)))){const err122 = {instancePath:instancePath+"/groups/" + i2+"/fromCol",schemaPath:"#/properties/groups/items/properties/fromCol/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err122];}else {vErrors.push(err122);}errors++;}if((typeof data54 == "number") && (isFinite(data54))){if(data54 > 5 || isNaN(data54)){const err123 = {instancePath:instancePath+"/groups/" + i2+"/fromCol",schemaPath:"#/properties/groups/items/properties/fromCol/maximum",keyword:"maximum",params:{comparison: "<=", limit: 5},message:"must be <= 5"};if(vErrors === null){vErrors = [err123];}else {vErrors.push(err123);}errors++;}if(data54 < 0 || isNaN(data54)){const err124 = {instancePath:instancePath+"/groups/" + i2+"/fromCol",schemaPath:"#/properties/groups/items/properties/fromCol/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err124];}else {vErrors.push(err124);}errors++;}}}if(data50.toCol !== undefined){let data55 = data50.toCol;if(!(((typeof data55 == "number") && (!(data55 % 1) && !isNaN(data55))) && (isFinite(data55)))){const err125 = {instancePath:instancePath+"/groups/" + i2+"/toCol",schemaPath:"#/properties/groups/items/properties/toCol/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err125];}else {vErrors.push(err125);}errors++;}if((typeof data55 == "number") && (isFinite(data55))){if(data55 > 5 || isNaN(data55)){const err126 = {instancePath:instancePath+"/groups/" + i2+"/toCol",schemaPath:"#/properties/groups/items/properties/toCol/maximum",keyword:"maximum",params:{comparison: "<=", limit: 5},message:"must be <= 5"};if(vErrors === null){vErrors = [err126];}else {vErrors.push(err126);}errors++;}if(data55 < 0 || isNaN(data55)){const err127 = {instancePath:instancePath+"/groups/" + i2+"/toCol",schemaPath:"#/properties/groups/items/properties/toCol/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err127];}else {vErrors.push(err127);}errors++;}}}if(data50.variant !== undefined){let data56 = data50.variant;if(!((((data56 === "default") || (data56 === "emphasis")) || (data56 === "security")) || (data56 === "dashed"))){const err128 = {instancePath:instancePath+"/groups/" + i2+"/variant",schemaPath:"#/properties/groups/items/properties/variant/enum",keyword:"enum",params:{allowedValues: schema31.properties.groups.items.properties.variant.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err128];}else {vErrors.push(err128);}errors++;}}}else {const err129 = {instancePath:instancePath+"/groups/" + i2,schemaPath:"#/properties/groups/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err129];}else {vErrors.push(err129);}errors++;}}}else {const err130 = {instancePath:instancePath+"/groups",schemaPath:"#/properties/groups/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err130];}else {vErrors.push(err130);}errors++;}}if(data.mainPath !== undefined){let data57 = data.mainPath;if(Array.isArray(data57)){if(data57.length < 2){const err131 = {instancePath:instancePath+"/mainPath",schemaPath:"#/properties/mainPath/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err131];}else {vErrors.push(err131);}errors++;}const len5 = data57.length;for(let i3=0; i3<len5; i3++){let data58 = data57[i3];if(typeof data58 === "string"){if(!pattern4.test(data58)){const err132 = {instancePath:instancePath+"/mainPath/" + i3,schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err132];}else {vErrors.push(err132);}errors++;}}else {const err133 = {instancePath:instancePath+"/mainPath/" + i3,schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err133];}else {vErrors.push(err133);}errors++;}}}else {const err134 = {instancePath:instancePath+"/mainPath",schemaPath:"#/properties/mainPath/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err134];}else {vErrors.push(err134);}errors++;}}if(data.nodes !== undefined){let data59 = data.nodes;if(Array.isArray(data59)){if(data59.length < 1){const err135 = {instancePath:instancePath+"/nodes",schemaPath:"#/properties/nodes/minItems",keyword:"minItems",params:{limit: 1},message:"must NOT have fewer than 1 items"};if(vErrors === null){vErrors = [err135];}else {vErrors.push(err135);}errors++;}const len6 = data59.length;for(let i4=0; i4<len6; i4++){let data60 = data59[i4];if(data60 && typeof data60 == "object" && !Array.isArray(data60)){if(data60.id === undefined){const err136 = {instancePath:instancePath+"/nodes/" + i4,schemaPath:"#/properties/nodes/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err136];}else {vErrors.push(err136);}errors++;}if(data60.lane === undefined){const err137 = {instancePath:instancePath+"/nodes/" + i4,schemaPath:"#/properties/nodes/items/required",keyword:"required",params:{missingProperty: "lane"},message:"must have required property '"+"lane"+"'"};if(vErrors === null){vErrors = [err137];}else {vErrors.push(err137);}errors++;}if(data60.col === undefined){const err138 = {instancePath:instancePath+"/nodes/" + i4,schemaPath:"#/properties/nodes/items/required",keyword:"required",params:{missingProperty: "col"},message:"must have required property '"+"col"+"'"};if(vErrors === null){vErrors = [err138];}else {vErrors.push(err138);}errors++;}if(data60.type === undefined){const err139 = {instancePath:instancePath+"/nodes/" + i4,schemaPath:"#/properties/nodes/items/required",keyword:"required",params:{missingProperty: "type"},message:"must have required property '"+"type"+"'"};if(vErrors === null){vErrors = [err139];}else {vErrors.push(err139);}errors++;}if(data60.label === undefined){const err140 = {instancePath:instancePath+"/nodes/" + i4,schemaPath:"#/properties/nodes/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err140];}else {vErrors.push(err140);}errors++;}for(const key14 in data60){if(!(func1.call(schema31.properties.nodes.items.properties, key14))){const err141 = {instancePath:instancePath+"/nodes/" + i4,schemaPath:"#/properties/nodes/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key14},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err141];}else {vErrors.push(err141);}errors++;}}if(data60.id !== undefined){let data61 = data60.id;if(typeof data61 === "string"){if(!pattern4.test(data61)){const err142 = {instancePath:instancePath+"/nodes/" + i4+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err142];}else {vErrors.push(err142);}errors++;}}else {const err143 = {instancePath:instancePath+"/nodes/" + i4+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err143];}else {vErrors.push(err143);}errors++;}}if(data60.lane !== undefined){let data62 = data60.lane;if(typeof data62 === "string"){if(!pattern4.test(data62)){const err144 = {instancePath:instancePath+"/nodes/" + i4+"/lane",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err144];}else {vErrors.push(err144);}errors++;}}else {const err145 = {instancePath:instancePath+"/nodes/" + i4+"/lane",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err145];}else {vErrors.push(err145);}errors++;}}if(data60.col !== undefined){let data63 = data60.col;if(!(((typeof data63 == "number") && (!(data63 % 1) && !isNaN(data63))) && (isFinite(data63)))){const err146 = {instancePath:instancePath+"/nodes/" + i4+"/col",schemaPath:"#/properties/nodes/items/properties/col/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err146];}else {vErrors.push(err146);}errors++;}if((typeof data63 == "number") && (isFinite(data63))){if(data63 > 5 || isNaN(data63)){const err147 = {instancePath:instancePath+"/nodes/" + i4+"/col",schemaPath:"#/properties/nodes/items/properties/col/maximum",keyword:"maximum",params:{comparison: "<=", limit: 5},message:"must be <= 5"};if(vErrors === null){vErrors = [err147];}else {vErrors.push(err147);}errors++;}if(data63 < 0 || isNaN(data63)){const err148 = {instancePath:instancePath+"/nodes/" + i4+"/col",schemaPath:"#/properties/nodes/items/properties/col/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err148];}else {vErrors.push(err148);}errors++;}}}if(data60.type !== undefined){let data64 = data60.type;if(!(((((((data64 === "frontend") || (data64 === "backend")) || (data64 === "database")) || (data64 === "cloud")) || (data64 === "security")) || (data64 === "messagebus")) || (data64 === "external"))){const err149 = {instancePath:instancePath+"/nodes/" + i4+"/type",schemaPath:"common.schema.json#/$defs/componentType/enum",keyword:"enum",params:{allowedValues: schema51.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err149];}else {vErrors.push(err149);}errors++;}}if(data60.label !== undefined){let data65 = data60.label;if(typeof data65 === "string"){if(func3(data65) < 1){const err150 = {instancePath:instancePath+"/nodes/" + i4+"/label",schemaPath:"#/properties/nodes/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err150];}else {vErrors.push(err150);}errors++;}}else {const err151 = {instancePath:instancePath+"/nodes/" + i4+"/label",schemaPath:"#/properties/nodes/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err151];}else {vErrors.push(err151);}errors++;}}if(data60.sublabel !== undefined){if(typeof data60.sublabel !== "string"){const err152 = {instancePath:instancePath+"/nodes/" + i4+"/sublabel",schemaPath:"#/properties/nodes/items/properties/sublabel/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err152];}else {vErrors.push(err152);}errors++;}}if(data60.tag !== undefined){if(typeof data60.tag !== "string"){const err153 = {instancePath:instancePath+"/nodes/" + i4+"/tag",schemaPath:"#/properties/nodes/items/properties/tag/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err153];}else {vErrors.push(err153);}errors++;}}if(data60.width !== undefined){let data68 = data60.width;if((typeof data68 == "number") && (isFinite(data68))){if(data68 < 32 || isNaN(data68)){const err154 = {instancePath:instancePath+"/nodes/" + i4+"/width",schemaPath:"#/properties/nodes/items/properties/width/minimum",keyword:"minimum",params:{comparison: ">=", limit: 32},message:"must be >= 32"};if(vErrors === null){vErrors = [err154];}else {vErrors.push(err154);}errors++;}}else {const err155 = {instancePath:instancePath+"/nodes/" + i4+"/width",schemaPath:"#/properties/nodes/items/properties/width/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err155];}else {vErrors.push(err155);}errors++;}}if(data60.height !== undefined){let data69 = data60.height;if((typeof data69 == "number") && (isFinite(data69))){if(data69 < 32 || isNaN(data69)){const err156 = {instancePath:instancePath+"/nodes/" + i4+"/height",schemaPath:"#/properties/nodes/items/properties/height/minimum",keyword:"minimum",params:{comparison: ">=", limit: 32},message:"must be >= 32"};if(vErrors === null){vErrors = [err156];}else {vErrors.push(err156);}errors++;}}else {const err157 = {instancePath:instancePath+"/nodes/" + i4+"/height",schemaPath:"#/properties/nodes/items/properties/height/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err157];}else {vErrors.push(err157);}errors++;}}if(data60.yOffset !== undefined){let data70 = data60.yOffset;if(!((typeof data70 == "number") && (isFinite(data70)))){const err158 = {instancePath:instancePath+"/nodes/" + i4+"/yOffset",schemaPath:"#/properties/nodes/items/properties/yOffset/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err158];}else {vErrors.push(err158);}errors++;}}}else {const err159 = {instancePath:instancePath+"/nodes/" + i4,schemaPath:"#/properties/nodes/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err159];}else {vErrors.push(err159);}errors++;}}}else {const err160 = {instancePath:instancePath+"/nodes",schemaPath:"#/properties/nodes/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err160];}else {vErrors.push(err160);}errors++;}}if(data.edges !== undefined){let data71 = data.edges;if(Array.isArray(data71)){const len7 = data71.length;for(let i5=0; i5<len7; i5++){let data72 = data71[i5];if(data72 && typeof data72 == "object" && !Array.isArray(data72)){if(data72.from === undefined){const err161 = {instancePath:instancePath+"/edges/" + i5,schemaPath:"#/properties/edges/items/required",keyword:"required",params:{missingProperty: "from"},message:"must have required property '"+"from"+"'"};if(vErrors === null){vErrors = [err161];}else {vErrors.push(err161);}errors++;}if(data72.to === undefined){const err162 = {instancePath:instancePath+"/edges/" + i5,schemaPath:"#/properties/edges/items/required",keyword:"required",params:{missingProperty: "to"},message:"must have required property '"+"to"+"'"};if(vErrors === null){vErrors = [err162];}else {vErrors.push(err162);}errors++;}for(const key15 in data72){if(!(func1.call(schema31.properties.edges.items.properties, key15))){const err163 = {instancePath:instancePath+"/edges/" + i5,schemaPath:"#/properties/edges/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key15},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err163];}else {vErrors.push(err163);}errors++;}}if(data72.id !== undefined){let data73 = data72.id;if(typeof data73 === "string"){if(!pattern4.test(data73)){const err164 = {instancePath:instancePath+"/edges/" + i5+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err164];}else {vErrors.push(err164);}errors++;}}else {const err165 = {instancePath:instancePath+"/edges/" + i5+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err165];}else {vErrors.push(err165);}errors++;}}if(data72.from !== undefined){let data74 = data72.from;if(typeof data74 === "string"){if(!pattern4.test(data74)){const err166 = {instancePath:instancePath+"/edges/" + i5+"/from",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err166];}else {vErrors.push(err166);}errors++;}}else {const err167 = {instancePath:instancePath+"/edges/" + i5+"/from",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err167];}else {vErrors.push(err167);}errors++;}}if(data72.to !== undefined){let data75 = data72.to;if(typeof data75 === "string"){if(!pattern4.test(data75)){const err168 = {instancePath:instancePath+"/edges/" + i5+"/to",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err168];}else {vErrors.push(err168);}errors++;}}else {const err169 = {instancePath:instancePath+"/edges/" + i5+"/to",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err169];}else {vErrors.push(err169);}errors++;}}if(data72.label !== undefined){if(typeof data72.label !== "string"){const err170 = {instancePath:instancePath+"/edges/" + i5+"/label",schemaPath:"#/properties/edges/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err170];}else {vErrors.push(err170);}errors++;}}if(data72.variant !== undefined){let data77 = data72.variant;if(!((((data77 === "default") || (data77 === "emphasis")) || (data77 === "security")) || (data77 === "dashed"))){const err171 = {instancePath:instancePath+"/edges/" + i5+"/variant",schemaPath:"common.schema.json#/$defs/variant/enum",keyword:"enum",params:{allowedValues: schema55.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err171];}else {vErrors.push(err171);}errors++;}}if(data72.role !== undefined){let data78 = data72.role;if(!(((((data78 === "main") || (data78 === "branch")) || (data78 === "async")) || (data78 === "return")) || (data78 === "error"))){const err172 = {instancePath:instancePath+"/edges/" + i5+"/role",schemaPath:"#/properties/edges/items/properties/role/enum",keyword:"enum",params:{allowedValues: schema31.properties.edges.items.properties.role.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err172];}else {vErrors.push(err172);}errors++;}}if(data72.fromSide !== undefined){let data79 = data72.fromSide;if(!((((data79 === "left") || (data79 === "right")) || (data79 === "top")) || (data79 === "bottom"))){const err173 = {instancePath:instancePath+"/edges/" + i5+"/fromSide",schemaPath:"#/$defs/side/enum",keyword:"enum",params:{allowedValues: schema56.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err173];}else {vErrors.push(err173);}errors++;}}if(data72.toSide !== undefined){let data80 = data72.toSide;if(!((((data80 === "left") || (data80 === "right")) || (data80 === "top")) || (data80 === "bottom"))){const err174 = {instancePath:instancePath+"/edges/" + i5+"/toSide",schemaPath:"#/$defs/side/enum",keyword:"enum",params:{allowedValues: schema56.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err174];}else {vErrors.push(err174);}errors++;}}if(data72.route !== undefined){let data81 = data72.route;if(!(((((((data81 === "auto") || (data81 === "straight")) || (data81 === "drop")) || (data81 === "outside-right")) || (data81 === "return-left")) || (data81 === "bottom-channel")) || (data81 === "up-channel"))){const err175 = {instancePath:instancePath+"/edges/" + i5+"/route",schemaPath:"#/properties/edges/items/properties/route/enum",keyword:"enum",params:{allowedValues: schema31.properties.edges.items.properties.route.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err175];}else {vErrors.push(err175);}errors++;}}if(data72.via !== undefined){let data82 = data72.via;if(Array.isArray(data82)){const len8 = data82.length;for(let i6=0; i6<len8; i6++){let data83 = data82[i6];if(Array.isArray(data83)){if(data83.length > 2){const err176 = {instancePath:instancePath+"/edges/" + i5+"/via/" + i6,schemaPath:"common.schema.json#/$defs/point/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err176];}else {vErrors.push(err176);}errors++;}if(data83.length < 2){const err177 = {instancePath:instancePath+"/edges/" + i5+"/via/" + i6,schemaPath:"common.schema.json#/$defs/point/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err177];}else {vErrors.push(err177);}errors++;}const len9 = data83.length;if(len9 > 0){let data84 = data83[0];if(!((typeof data84 == "number") && (isFinite(data84)))){const err178 = {instancePath:instancePath+"/edges/" + i5+"/via/" + i6+"/0",schemaPath:"common.schema.json#/$defs/point/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err178];}else {vErrors.push(err178);}errors++;}}if(len9 > 1){let data85 = data83[1];if(!((typeof data85 == "number") && (isFinite(data85)))){const err179 = {instancePath:instancePath+"/edges/" + i5+"/via/" + i6+"/1",schemaPath:"common.schema.json#/$defs/point/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err179];}else {vErrors.push(err179);}errors++;}}const len10 = data83.length;if(!(len10 <= 2)){const err180 = {instancePath:instancePath+"/edges/" + i5+"/via/" + i6,schemaPath:"common.schema.json#/$defs/point/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err180];}else {vErrors.push(err180);}errors++;}}else {const err181 = {instancePath:instancePath+"/edges/" + i5+"/via/" + i6,schemaPath:"common.schema.json#/$defs/point/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err181];}else {vErrors.push(err181);}errors++;}}}else {const err182 = {instancePath:instancePath+"/edges/" + i5+"/via",schemaPath:"#/properties/edges/items/properties/via/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err182];}else {vErrors.push(err182);}errors++;}}if(data72.labelAt !== undefined){let data86 = data72.labelAt;if(Array.isArray(data86)){if(data86.length > 2){const err183 = {instancePath:instancePath+"/edges/" + i5+"/labelAt",schemaPath:"common.schema.json#/$defs/point/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err183];}else {vErrors.push(err183);}errors++;}if(data86.length < 2){const err184 = {instancePath:instancePath+"/edges/" + i5+"/labelAt",schemaPath:"common.schema.json#/$defs/point/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err184];}else {vErrors.push(err184);}errors++;}const len11 = data86.length;if(len11 > 0){let data87 = data86[0];if(!((typeof data87 == "number") && (isFinite(data87)))){const err185 = {instancePath:instancePath+"/edges/" + i5+"/labelAt/0",schemaPath:"common.schema.json#/$defs/point/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err185];}else {vErrors.push(err185);}errors++;}}if(len11 > 1){let data88 = data86[1];if(!((typeof data88 == "number") && (isFinite(data88)))){const err186 = {instancePath:instancePath+"/edges/" + i5+"/labelAt/1",schemaPath:"common.schema.json#/$defs/point/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err186];}else {vErrors.push(err186);}errors++;}}const len12 = data86.length;if(!(len12 <= 2)){const err187 = {instancePath:instancePath+"/edges/" + i5+"/labelAt",schemaPath:"common.schema.json#/$defs/point/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err187];}else {vErrors.push(err187);}errors++;}}else {const err188 = {instancePath:instancePath+"/edges/" + i5+"/labelAt",schemaPath:"common.schema.json#/$defs/point/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err188];}else {vErrors.push(err188);}errors++;}}if(data72.labelDx !== undefined){let data89 = data72.labelDx;if(!((typeof data89 == "number") && (isFinite(data89)))){const err189 = {instancePath:instancePath+"/edges/" + i5+"/labelDx",schemaPath:"#/properties/edges/items/properties/labelDx/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err189];}else {vErrors.push(err189);}errors++;}}if(data72.labelDy !== undefined){let data90 = data72.labelDy;if(!((typeof data90 == "number") && (isFinite(data90)))){const err190 = {instancePath:instancePath+"/edges/" + i5+"/labelDy",schemaPath:"#/properties/edges/items/properties/labelDy/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err190];}else {vErrors.push(err190);}errors++;}}if(data72.labelSegment !== undefined){let data91 = data72.labelSegment;if(!(((typeof data91 == "number") && (!(data91 % 1) && !isNaN(data91))) && (isFinite(data91)))){const err191 = {instancePath:instancePath+"/edges/" + i5+"/labelSegment",schemaPath:"#/properties/edges/items/properties/labelSegment/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err191];}else {vErrors.push(err191);}errors++;}if((typeof data91 == "number") && (isFinite(data91))){if(data91 < 0 || isNaN(data91)){const err192 = {instancePath:instancePath+"/edges/" + i5+"/labelSegment",schemaPath:"#/properties/edges/items/properties/labelSegment/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err192];}else {vErrors.push(err192);}errors++;}}}if(data72.channelX !== undefined){let data92 = data72.channelX;if(!((typeof data92 == "number") && (isFinite(data92)))){const err193 = {instancePath:instancePath+"/edges/" + i5+"/channelX",schemaPath:"#/properties/edges/items/properties/channelX/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err193];}else {vErrors.push(err193);}errors++;}}if(data72.channelY !== undefined){let data93 = data72.channelY;if(!((typeof data93 == "number") && (isFinite(data93)))){const err194 = {instancePath:instancePath+"/edges/" + i5+"/channelY",schemaPath:"#/properties/edges/items/properties/channelY/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err194];}else {vErrors.push(err194);}errors++;}}if(data72.bias !== undefined){let data94 = data72.bias;if((typeof data94 == "number") && (isFinite(data94))){if(data94 > 1 || isNaN(data94)){const err195 = {instancePath:instancePath+"/edges/" + i5+"/bias",schemaPath:"#/properties/edges/items/properties/bias/maximum",keyword:"maximum",params:{comparison: "<=", limit: 1},message:"must be <= 1"};if(vErrors === null){vErrors = [err195];}else {vErrors.push(err195);}errors++;}if(data94 < 0 || isNaN(data94)){const err196 = {instancePath:instancePath+"/edges/" + i5+"/bias",schemaPath:"#/properties/edges/items/properties/bias/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err196];}else {vErrors.push(err196);}errors++;}}else {const err197 = {instancePath:instancePath+"/edges/" + i5+"/bias",schemaPath:"#/properties/edges/items/properties/bias/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err197];}else {vErrors.push(err197);}errors++;}}if(data72.width !== undefined){let data95 = data72.width;if((typeof data95 == "number") && (isFinite(data95))){if(data95 < 0.5 || isNaN(data95)){const err198 = {instancePath:instancePath+"/edges/" + i5+"/width",schemaPath:"#/properties/edges/items/properties/width/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0.5},message:"must be >= 0.5"};if(vErrors === null){vErrors = [err198];}else {vErrors.push(err198);}errors++;}}else {const err199 = {instancePath:instancePath+"/edges/" + i5+"/width",schemaPath:"#/properties/edges/items/properties/width/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err199];}else {vErrors.push(err199);}errors++;}}}else {const err200 = {instancePath:instancePath+"/edges/" + i5,schemaPath:"#/properties/edges/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err200];}else {vErrors.push(err200);}errors++;}}}else {const err201 = {instancePath:instancePath+"/edges",schemaPath:"#/properties/edges/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err201];}else {vErrors.push(err201);}errors++;}}if(data.cards !== undefined){let data96 = data.cards;if(Array.isArray(data96)){const len13 = data96.length;for(let i7=0; i7<len13; i7++){let data97 = data96[i7];if(data97 && typeof data97 == "object" && !Array.isArray(data97)){if(data97.dot === undefined){const err202 = {instancePath:instancePath+"/cards/" + i7,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "dot"},message:"must have required property '"+"dot"+"'"};if(vErrors === null){vErrors = [err202];}else {vErrors.push(err202);}errors++;}if(data97.title === undefined){const err203 = {instancePath:instancePath+"/cards/" + i7,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "title"},message:"must have required property '"+"title"+"'"};if(vErrors === null){vErrors = [err203];}else {vErrors.push(err203);}errors++;}if(data97.items === undefined){const err204 = {instancePath:instancePath+"/cards/" + i7,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "items"},message:"must have required property '"+"items"+"'"};if(vErrors === null){vErrors = [err204];}else {vErrors.push(err204);}errors++;}for(const key16 in data97){if(!(((key16 === "dot") || (key16 === "title")) || (key16 === "items"))){const err205 = {instancePath:instancePath+"/cards/" + i7,schemaPath:"common.schema.json#/$defs/cards/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key16},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err205];}else {vErrors.push(err205);}errors++;}}if(data97.dot !== undefined){let data98 = data97.dot;if(!(((((((data98 === "cyan") || (data98 === "emerald")) || (data98 === "violet")) || (data98 === "amber")) || (data98 === "rose")) || (data98 === "orange")) || (data98 === "slate"))){const err206 = {instancePath:instancePath+"/cards/" + i7+"/dot",schemaPath:"common.schema.json#/$defs/cards/items/properties/dot/enum",keyword:"enum",params:{allowedValues: schema60.items.properties.dot.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err206];}else {vErrors.push(err206);}errors++;}}if(data97.title !== undefined){let data99 = data97.title;if(typeof data99 === "string"){if(func3(data99) < 1){const err207 = {instancePath:instancePath+"/cards/" + i7+"/title",schemaPath:"common.schema.json#/$defs/cards/items/properties/title/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err207];}else {vErrors.push(err207);}errors++;}}else {const err208 = {instancePath:instancePath+"/cards/" + i7+"/title",schemaPath:"common.schema.json#/$defs/cards/items/properties/title/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err208];}else {vErrors.push(err208);}errors++;}}if(data97.items !== undefined){let data100 = data97.items;if(Array.isArray(data100)){const len14 = data100.length;for(let i8=0; i8<len14; i8++){if(typeof data100[i8] !== "string"){const err209 = {instancePath:instancePath+"/cards/" + i7+"/items/" + i8,schemaPath:"common.schema.json#/$defs/cards/items/properties/items/items/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err209];}else {vErrors.push(err209);}errors++;}}}else {const err210 = {instancePath:instancePath+"/cards/" + i7+"/items",schemaPath:"common.schema.json#/$defs/cards/items/properties/items/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err210];}else {vErrors.push(err210);}errors++;}}}else {const err211 = {instancePath:instancePath+"/cards/" + i7,schemaPath:"common.schema.json#/$defs/cards/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err211];}else {vErrors.push(err211);}errors++;}}}else {const err212 = {instancePath:instancePath+"/cards",schemaPath:"common.schema.json#/$defs/cards/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err212];}else {vErrors.push(err212);}errors++;}}}else {const err213 = {instancePath,schemaPath:"#/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err213];}else {vErrors.push(err213);}errors++;}validate20.errors = vErrors;return errors === 0;}validate20.evaluated = {"props":true,"dynamicProps":false,"dynamicItems":false};export const sequence = validate24;const schema61 = {"$schema":"https://json-schema.org/draft/2020-12/schema","$id":"https://github.com/tt-a1i/archify/schemas/sequence.schema.json","title":"Archify Sequence Diagram","type":"object","additionalProperties":false,"required":["schema_version","diagram_type","meta","participants","messages"],"properties":{"schema_version":{"const":1},"diagram_type":{"const":"sequence"},"meta":{"type":"object","additionalProperties":false,"required":["title"],"properties":{"title":{"type":"string","minLength":1},"subtitle":{"type":"string"},"output":{"type":"string"},"animation":{"enum":["trace","none"]},"visual_preset":{"enum":["classic","signal-flow","blueprint","editorial"]},"quality_profile":{"enum":["standard","showcase"]},"views":{"$ref":"common.schema.json#/$defs/guidedViews"},"legend":{"type":"object","additionalProperties":false,"properties":{"mode":{"$ref":"common.schema.json#/$defs/legendMode"},"entries":{"type":"object","additionalProperties":false,"properties":{"default":{"$ref":"common.schema.json#/$defs/legendEntry"},"emphasis":{"$ref":"common.schema.json#/$defs/legendEntry"},"security":{"$ref":"common.schema.json#/$defs/legendEntry"},"dashed":{"$ref":"common.schema.json#/$defs/legendEntry"},"return":{"$ref":"common.schema.json#/$defs/legendEntry"}}}}},"viewBox":{"type":"array","prefixItems":[{"type":"number","minimum":480},{"type":"number","minimum":480}],"items":false,"minItems":2,"maxItems":2}}},"participants":{"type":"array","minItems":2,"items":{"type":"object","additionalProperties":false,"required":["id","type","label"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"type":{"$ref":"common.schema.json#/$defs/componentType"},"label":{"type":"string","minLength":1},"sublabel":{"type":"string"}}}},"segments":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to","label"],"properties":{"from":{"type":"number"},"to":{"type":"number"},"label":{"type":"string","minLength":1}}}},"messages":{"type":"array","minItems":1,"items":{"type":"object","additionalProperties":false,"required":["from","to","y","label"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"from":{"$ref":"common.schema.json#/$defs/id"},"to":{"$ref":"common.schema.json#/$defs/id"},"y":{"type":"number","minimum":160},"label":{"type":"string","minLength":1},"variant":{"enum":["default","emphasis","security","dashed","return"]},"note":{"type":"string"}}}},"activations":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["participant","from","to"],"properties":{"participant":{"$ref":"common.schema.json#/$defs/id"},"from":{"type":"number"},"to":{"type":"number"},"type":{"$ref":"common.schema.json#/$defs/componentType"}}}},"cards":{"$ref":"common.schema.json#/$defs/cards"}}};function validate25(data, {instancePath="", parentData, parentDataProperty, rootData=data, dynamicAnchors={}}={}){let vErrors = null;let errors = 0;const evaluated0 = validate25.evaluated;if(evaluated0.dynamicProps){evaluated0.props = undefined;}if(evaluated0.dynamicItems){evaluated0.items = undefined;}if(Array.isArray(data)){if(data.length > 5){const err0 = {instancePath,schemaPath:"#/maxItems",keyword:"maxItems",params:{limit: 5},message:"must NOT have more than 5 items"};if(vErrors === null){vErrors = [err0];}else {vErrors.push(err0);}errors++;}const len0 = data.length;for(let i0=0; i0<len0; i0++){let data0 = data[i0];if(data0 && typeof data0 == "object" && !Array.isArray(data0)){if(data0.id === undefined){const err1 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err1];}else {vErrors.push(err1);}errors++;}if(data0.label === undefined){const err2 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err2];}else {vErrors.push(err2);}errors++;}if(data0.focus === undefined){const err3 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "focus"},message:"must have required property '"+"focus"+"'"};if(vErrors === null){vErrors = [err3];}else {vErrors.push(err3);}errors++;}for(const key0 in data0){if(!((((key0 === "id") || (key0 === "label")) || (key0 === "focus")) || (key0 === "note"))){const err4 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key0},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err4];}else {vErrors.push(err4);}errors++;}}if(data0.id !== undefined){let data1 = data0.id;if(typeof data1 === "string"){if(!pattern4.test(data1)){const err5 = {instancePath:instancePath+"/" + i0+"/id",schemaPath:"#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err5];}else {vErrors.push(err5);}errors++;}}else {const err6 = {instancePath:instancePath+"/" + i0+"/id",schemaPath:"#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err6];}else {vErrors.push(err6);}errors++;}}if(data0.label !== undefined){let data2 = data0.label;if(typeof data2 === "string"){if(func3(data2) > 48){const err7 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/maxLength",keyword:"maxLength",params:{limit: 48},message:"must NOT have more than 48 characters"};if(vErrors === null){vErrors = [err7];}else {vErrors.push(err7);}errors++;}if(func3(data2) < 1){const err8 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err8];}else {vErrors.push(err8);}errors++;}}else {const err9 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err9];}else {vErrors.push(err9);}errors++;}}if(data0.focus !== undefined){let data3 = data0.focus;if(Array.isArray(data3)){if(data3.length < 1){const err10 = {instancePath:instancePath+"/" + i0+"/focus",schemaPath:"#/items/properties/focus/minItems",keyword:"minItems",params:{limit: 1},message:"must NOT have fewer than 1 items"};if(vErrors === null){vErrors = [err10];}else {vErrors.push(err10);}errors++;}const len1 = data3.length;for(let i1=0; i1<len1; i1++){let data4 = data3[i1];if(typeof data4 === "string"){if(!pattern4.test(data4)){const err11 = {instancePath:instancePath+"/" + i0+"/focus/" + i1,schemaPath:"#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err11];}else {vErrors.push(err11);}errors++;}}else {const err12 = {instancePath:instancePath+"/" + i0+"/focus/" + i1,schemaPath:"#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err12];}else {vErrors.push(err12);}errors++;}}}else {const err13 = {instancePath:instancePath+"/" + i0+"/focus",schemaPath:"#/items/properties/focus/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err13];}else {vErrors.push(err13);}errors++;}}if(data0.note !== undefined){let data5 = data0.note;if(typeof data5 === "string"){if(func3(data5) > 140){const err14 = {instancePath:instancePath+"/" + i0+"/note",schemaPath:"#/items/properties/note/maxLength",keyword:"maxLength",params:{limit: 140},message:"must NOT have more than 140 characters"};if(vErrors === null){vErrors = [err14];}else {vErrors.push(err14);}errors++;}}else {const err15 = {instancePath:instancePath+"/" + i0+"/note",schemaPath:"#/items/properties/note/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err15];}else {vErrors.push(err15);}errors++;}}}else {const err16 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err16];}else {vErrors.push(err16);}errors++;}}}else {const err17 = {instancePath,schemaPath:"#/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err17];}else {vErrors.push(err17);}errors++;}validate25.errors = vErrors;return errors === 0;}validate25.evaluated = {"items":true,"dynamicProps":false,"dynamicItems":false};function validate24(data, {instancePath="", parentData, parentDataProperty, rootData=data, dynamicAnchors={}}={}){/*# sourceURL="https://github.com/tt-a1i/archify/schemas/sequence.schema.json" */;let vErrors = null;let errors = 0;const evaluated0 = validate24.evaluated;if(evaluated0.dynamicProps){evaluated0.props = undefined;}if(evaluated0.dynamicItems){evaluated0.items = undefined;}if(data && typeof data == "object" && !Array.isArray(data)){if(data.schema_version === undefined){const err0 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "schema_version"},message:"must have required property '"+"schema_version"+"'"};if(vErrors === null){vErrors = [err0];}else {vErrors.push(err0);}errors++;}if(data.diagram_type === undefined){const err1 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "diagram_type"},message:"must have required property '"+"diagram_type"+"'"};if(vErrors === null){vErrors = [err1];}else {vErrors.push(err1);}errors++;}if(data.meta === undefined){const err2 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "meta"},message:"must have required property '"+"meta"+"'"};if(vErrors === null){vErrors = [err2];}else {vErrors.push(err2);}errors++;}if(data.participants === undefined){const err3 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "participants"},message:"must have required property '"+"participants"+"'"};if(vErrors === null){vErrors = [err3];}else {vErrors.push(err3);}errors++;}if(data.messages === undefined){const err4 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "messages"},message:"must have required property '"+"messages"+"'"};if(vErrors === null){vErrors = [err4];}else {vErrors.push(err4);}errors++;}for(const key0 in data){if(!((((((((key0 === "schema_version") || (key0 === "diagram_type")) || (key0 === "meta")) || (key0 === "participants")) || (key0 === "segments")) || (key0 === "messages")) || (key0 === "activations")) || (key0 === "cards"))){const err5 = {instancePath,schemaPath:"#/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key0},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err5];}else {vErrors.push(err5);}errors++;}}if(data.schema_version !== undefined){if(1 !== data.schema_version){const err6 = {instancePath:instancePath+"/schema_version",schemaPath:"#/properties/schema_version/const",keyword:"const",params:{allowedValue: 1},message:"must be equal to constant"};if(vErrors === null){vErrors = [err6];}else {vErrors.push(err6);}errors++;}}if(data.diagram_type !== undefined){if("sequence" !== data.diagram_type){const err7 = {instancePath:instancePath+"/diagram_type",schemaPath:"#/properties/diagram_type/const",keyword:"const",params:{allowedValue: "sequence"},message:"must be equal to constant"};if(vErrors === null){vErrors = [err7];}else {vErrors.push(err7);}errors++;}}if(data.meta !== undefined){let data2 = data.meta;if(data2 && typeof data2 == "object" && !Array.isArray(data2)){if(data2.title === undefined){const err8 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/required",keyword:"required",params:{missingProperty: "title"},message:"must have required property '"+"title"+"'"};if(vErrors === null){vErrors = [err8];}else {vErrors.push(err8);}errors++;}for(const key1 in data2){if(!(func1.call(schema61.properties.meta.properties, key1))){const err9 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key1},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err9];}else {vErrors.push(err9);}errors++;}}if(data2.title !== undefined){let data3 = data2.title;if(typeof data3 === "string"){if(func3(data3) < 1){const err10 = {instancePath:instancePath+"/meta/title",schemaPath:"#/properties/meta/properties/title/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err10];}else {vErrors.push(err10);}errors++;}}else {const err11 = {instancePath:instancePath+"/meta/title",schemaPath:"#/properties/meta/properties/title/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err11];}else {vErrors.push(err11);}errors++;}}if(data2.subtitle !== undefined){if(typeof data2.subtitle !== "string"){const err12 = {instancePath:instancePath+"/meta/subtitle",schemaPath:"#/properties/meta/properties/subtitle/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err12];}else {vErrors.push(err12);}errors++;}}if(data2.output !== undefined){if(typeof data2.output !== "string"){const err13 = {instancePath:instancePath+"/meta/output",schemaPath:"#/properties/meta/properties/output/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err13];}else {vErrors.push(err13);}errors++;}}if(data2.animation !== undefined){let data6 = data2.animation;if(!((data6 === "trace") || (data6 === "none"))){const err14 = {instancePath:instancePath+"/meta/animation",schemaPath:"#/properties/meta/properties/animation/enum",keyword:"enum",params:{allowedValues: schema61.properties.meta.properties.animation.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err14];}else {vErrors.push(err14);}errors++;}}if(data2.visual_preset !== undefined){let data7 = data2.visual_preset;if(!((((data7 === "classic") || (data7 === "signal-flow")) || (data7 === "blueprint")) || (data7 === "editorial"))){const err15 = {instancePath:instancePath+"/meta/visual_preset",schemaPath:"#/properties/meta/properties/visual_preset/enum",keyword:"enum",params:{allowedValues: schema61.properties.meta.properties.visual_preset.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err15];}else {vErrors.push(err15);}errors++;}}if(data2.quality_profile !== undefined){let data8 = data2.quality_profile;if(!((data8 === "standard") || (data8 === "showcase"))){const err16 = {instancePath:instancePath+"/meta/quality_profile",schemaPath:"#/properties/meta/properties/quality_profile/enum",keyword:"enum",params:{allowedValues: schema61.properties.meta.properties.quality_profile.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err16];}else {vErrors.push(err16);}errors++;}}if(data2.views !== undefined){if(!(validate25(data2.views, {instancePath:instancePath+"/meta/views",parentData:data2,parentDataProperty:"views",rootData,dynamicAnchors}))){vErrors = vErrors === null ? validate25.errors : vErrors.concat(validate25.errors);errors = vErrors.length;}}if(data2.legend !== undefined){let data10 = data2.legend;if(data10 && typeof data10 == "object" && !Array.isArray(data10)){for(const key2 in data10){if(!((key2 === "mode") || (key2 === "entries"))){const err17 = {instancePath:instancePath+"/meta/legend",schemaPath:"#/properties/meta/properties/legend/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key2},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err17];}else {vErrors.push(err17);}errors++;}}if(data10.mode !== undefined){let data11 = data10.mode;if(!(((data11 === "auto") || (data11 === "all")) || (data11 === "hidden"))){const err18 = {instancePath:instancePath+"/meta/legend/mode",schemaPath:"common.schema.json#/$defs/legendMode/enum",keyword:"enum",params:{allowedValues: schema36.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err18];}else {vErrors.push(err18);}errors++;}}if(data10.entries !== undefined){let data12 = data10.entries;if(data12 && typeof data12 == "object" && !Array.isArray(data12)){for(const key3 in data12){if(!(((((key3 === "default") || (key3 === "emphasis")) || (key3 === "security")) || (key3 === "dashed")) || (key3 === "return"))){const err19 = {instancePath:instancePath+"/meta/legend/entries",schemaPath:"#/properties/meta/properties/legend/properties/entries/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key3},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err19];}else {vErrors.push(err19);}errors++;}}if(data12.default !== undefined){let data13 = data12.default;if(data13 && typeof data13 == "object" && !Array.isArray(data13)){if(Object.keys(data13).length < 1){const err20 = {instancePath:instancePath+"/meta/legend/entries/default",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err20];}else {vErrors.push(err20);}errors++;}for(const key4 in data13){if(!((key4 === "label") || (key4 === "visible"))){const err21 = {instancePath:instancePath+"/meta/legend/entries/default",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key4},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err21];}else {vErrors.push(err21);}errors++;}}if(data13.label !== undefined){let data14 = data13.label;if(typeof data14 === "string"){if(func3(data14) > 80){const err22 = {instancePath:instancePath+"/meta/legend/entries/default/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err22];}else {vErrors.push(err22);}errors++;}if(func3(data14) < 1){const err23 = {instancePath:instancePath+"/meta/legend/entries/default/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err23];}else {vErrors.push(err23);}errors++;}}else {const err24 = {instancePath:instancePath+"/meta/legend/entries/default/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err24];}else {vErrors.push(err24);}errors++;}}if(data13.visible !== undefined){if(typeof data13.visible !== "boolean"){const err25 = {instancePath:instancePath+"/meta/legend/entries/default/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err25];}else {vErrors.push(err25);}errors++;}}}else {const err26 = {instancePath:instancePath+"/meta/legend/entries/default",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err26];}else {vErrors.push(err26);}errors++;}}if(data12.emphasis !== undefined){let data16 = data12.emphasis;if(data16 && typeof data16 == "object" && !Array.isArray(data16)){if(Object.keys(data16).length < 1){const err27 = {instancePath:instancePath+"/meta/legend/entries/emphasis",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err27];}else {vErrors.push(err27);}errors++;}for(const key5 in data16){if(!((key5 === "label") || (key5 === "visible"))){const err28 = {instancePath:instancePath+"/meta/legend/entries/emphasis",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key5},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err28];}else {vErrors.push(err28);}errors++;}}if(data16.label !== undefined){let data17 = data16.label;if(typeof data17 === "string"){if(func3(data17) > 80){const err29 = {instancePath:instancePath+"/meta/legend/entries/emphasis/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err29];}else {vErrors.push(err29);}errors++;}if(func3(data17) < 1){const err30 = {instancePath:instancePath+"/meta/legend/entries/emphasis/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err30];}else {vErrors.push(err30);}errors++;}}else {const err31 = {instancePath:instancePath+"/meta/legend/entries/emphasis/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err31];}else {vErrors.push(err31);}errors++;}}if(data16.visible !== undefined){if(typeof data16.visible !== "boolean"){const err32 = {instancePath:instancePath+"/meta/legend/entries/emphasis/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err32];}else {vErrors.push(err32);}errors++;}}}else {const err33 = {instancePath:instancePath+"/meta/legend/entries/emphasis",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err33];}else {vErrors.push(err33);}errors++;}}if(data12.security !== undefined){let data19 = data12.security;if(data19 && typeof data19 == "object" && !Array.isArray(data19)){if(Object.keys(data19).length < 1){const err34 = {instancePath:instancePath+"/meta/legend/entries/security",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err34];}else {vErrors.push(err34);}errors++;}for(const key6 in data19){if(!((key6 === "label") || (key6 === "visible"))){const err35 = {instancePath:instancePath+"/meta/legend/entries/security",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key6},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err35];}else {vErrors.push(err35);}errors++;}}if(data19.label !== undefined){let data20 = data19.label;if(typeof data20 === "string"){if(func3(data20) > 80){const err36 = {instancePath:instancePath+"/meta/legend/entries/security/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err36];}else {vErrors.push(err36);}errors++;}if(func3(data20) < 1){const err37 = {instancePath:instancePath+"/meta/legend/entries/security/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err37];}else {vErrors.push(err37);}errors++;}}else {const err38 = {instancePath:instancePath+"/meta/legend/entries/security/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err38];}else {vErrors.push(err38);}errors++;}}if(data19.visible !== undefined){if(typeof data19.visible !== "boolean"){const err39 = {instancePath:instancePath+"/meta/legend/entries/security/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err39];}else {vErrors.push(err39);}errors++;}}}else {const err40 = {instancePath:instancePath+"/meta/legend/entries/security",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err40];}else {vErrors.push(err40);}errors++;}}if(data12.dashed !== undefined){let data22 = data12.dashed;if(data22 && typeof data22 == "object" && !Array.isArray(data22)){if(Object.keys(data22).length < 1){const err41 = {instancePath:instancePath+"/meta/legend/entries/dashed",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err41];}else {vErrors.push(err41);}errors++;}for(const key7 in data22){if(!((key7 === "label") || (key7 === "visible"))){const err42 = {instancePath:instancePath+"/meta/legend/entries/dashed",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key7},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err42];}else {vErrors.push(err42);}errors++;}}if(data22.label !== undefined){let data23 = data22.label;if(typeof data23 === "string"){if(func3(data23) > 80){const err43 = {instancePath:instancePath+"/meta/legend/entries/dashed/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err43];}else {vErrors.push(err43);}errors++;}if(func3(data23) < 1){const err44 = {instancePath:instancePath+"/meta/legend/entries/dashed/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err44];}else {vErrors.push(err44);}errors++;}}else {const err45 = {instancePath:instancePath+"/meta/legend/entries/dashed/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err45];}else {vErrors.push(err45);}errors++;}}if(data22.visible !== undefined){if(typeof data22.visible !== "boolean"){const err46 = {instancePath:instancePath+"/meta/legend/entries/dashed/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err46];}else {vErrors.push(err46);}errors++;}}}else {const err47 = {instancePath:instancePath+"/meta/legend/entries/dashed",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err47];}else {vErrors.push(err47);}errors++;}}if(data12.return !== undefined){let data25 = data12.return;if(data25 && typeof data25 == "object" && !Array.isArray(data25)){if(Object.keys(data25).length < 1){const err48 = {instancePath:instancePath+"/meta/legend/entries/return",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err48];}else {vErrors.push(err48);}errors++;}for(const key8 in data25){if(!((key8 === "label") || (key8 === "visible"))){const err49 = {instancePath:instancePath+"/meta/legend/entries/return",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key8},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err49];}else {vErrors.push(err49);}errors++;}}if(data25.label !== undefined){let data26 = data25.label;if(typeof data26 === "string"){if(func3(data26) > 80){const err50 = {instancePath:instancePath+"/meta/legend/entries/return/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err50];}else {vErrors.push(err50);}errors++;}if(func3(data26) < 1){const err51 = {instancePath:instancePath+"/meta/legend/entries/return/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err51];}else {vErrors.push(err51);}errors++;}}else {const err52 = {instancePath:instancePath+"/meta/legend/entries/return/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err52];}else {vErrors.push(err52);}errors++;}}if(data25.visible !== undefined){if(typeof data25.visible !== "boolean"){const err53 = {instancePath:instancePath+"/meta/legend/entries/return/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err53];}else {vErrors.push(err53);}errors++;}}}else {const err54 = {instancePath:instancePath+"/meta/legend/entries/return",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err54];}else {vErrors.push(err54);}errors++;}}}else {const err55 = {instancePath:instancePath+"/meta/legend/entries",schemaPath:"#/properties/meta/properties/legend/properties/entries/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err55];}else {vErrors.push(err55);}errors++;}}}else {const err56 = {instancePath:instancePath+"/meta/legend",schemaPath:"#/properties/meta/properties/legend/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err56];}else {vErrors.push(err56);}errors++;}}if(data2.viewBox !== undefined){let data28 = data2.viewBox;if(Array.isArray(data28)){if(data28.length > 2){const err57 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err57];}else {vErrors.push(err57);}errors++;}if(data28.length < 2){const err58 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err58];}else {vErrors.push(err58);}errors++;}const len0 = data28.length;if(len0 > 0){let data29 = data28[0];if((typeof data29 == "number") && (isFinite(data29))){if(data29 < 480 || isNaN(data29)){const err59 = {instancePath:instancePath+"/meta/viewBox/0",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/0/minimum",keyword:"minimum",params:{comparison: ">=", limit: 480},message:"must be >= 480"};if(vErrors === null){vErrors = [err59];}else {vErrors.push(err59);}errors++;}}else {const err60 = {instancePath:instancePath+"/meta/viewBox/0",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err60];}else {vErrors.push(err60);}errors++;}}if(len0 > 1){let data30 = data28[1];if((typeof data30 == "number") && (isFinite(data30))){if(data30 < 480 || isNaN(data30)){const err61 = {instancePath:instancePath+"/meta/viewBox/1",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/1/minimum",keyword:"minimum",params:{comparison: ">=", limit: 480},message:"must be >= 480"};if(vErrors === null){vErrors = [err61];}else {vErrors.push(err61);}errors++;}}else {const err62 = {instancePath:instancePath+"/meta/viewBox/1",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err62];}else {vErrors.push(err62);}errors++;}}const len1 = data28.length;if(!(len1 <= 2)){const err63 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err63];}else {vErrors.push(err63);}errors++;}}else {const err64 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err64];}else {vErrors.push(err64);}errors++;}}}else {const err65 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err65];}else {vErrors.push(err65);}errors++;}}if(data.participants !== undefined){let data31 = data.participants;if(Array.isArray(data31)){if(data31.length < 2){const err66 = {instancePath:instancePath+"/participants",schemaPath:"#/properties/participants/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err66];}else {vErrors.push(err66);}errors++;}const len2 = data31.length;for(let i0=0; i0<len2; i0++){let data32 = data31[i0];if(data32 && typeof data32 == "object" && !Array.isArray(data32)){if(data32.id === undefined){const err67 = {instancePath:instancePath+"/participants/" + i0,schemaPath:"#/properties/participants/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err67];}else {vErrors.push(err67);}errors++;}if(data32.type === undefined){const err68 = {instancePath:instancePath+"/participants/" + i0,schemaPath:"#/properties/participants/items/required",keyword:"required",params:{missingProperty: "type"},message:"must have required property '"+"type"+"'"};if(vErrors === null){vErrors = [err68];}else {vErrors.push(err68);}errors++;}if(data32.label === undefined){const err69 = {instancePath:instancePath+"/participants/" + i0,schemaPath:"#/properties/participants/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err69];}else {vErrors.push(err69);}errors++;}for(const key9 in data32){if(!((((key9 === "id") || (key9 === "type")) || (key9 === "label")) || (key9 === "sublabel"))){const err70 = {instancePath:instancePath+"/participants/" + i0,schemaPath:"#/properties/participants/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key9},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err70];}else {vErrors.push(err70);}errors++;}}if(data32.id !== undefined){let data33 = data32.id;if(typeof data33 === "string"){if(!pattern4.test(data33)){const err71 = {instancePath:instancePath+"/participants/" + i0+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err71];}else {vErrors.push(err71);}errors++;}}else {const err72 = {instancePath:instancePath+"/participants/" + i0+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err72];}else {vErrors.push(err72);}errors++;}}if(data32.type !== undefined){let data34 = data32.type;if(!(((((((data34 === "frontend") || (data34 === "backend")) || (data34 === "database")) || (data34 === "cloud")) || (data34 === "security")) || (data34 === "messagebus")) || (data34 === "external"))){const err73 = {instancePath:instancePath+"/participants/" + i0+"/type",schemaPath:"common.schema.json#/$defs/componentType/enum",keyword:"enum",params:{allowedValues: schema51.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err73];}else {vErrors.push(err73);}errors++;}}if(data32.label !== undefined){let data35 = data32.label;if(typeof data35 === "string"){if(func3(data35) < 1){const err74 = {instancePath:instancePath+"/participants/" + i0+"/label",schemaPath:"#/properties/participants/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err74];}else {vErrors.push(err74);}errors++;}}else {const err75 = {instancePath:instancePath+"/participants/" + i0+"/label",schemaPath:"#/properties/participants/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err75];}else {vErrors.push(err75);}errors++;}}if(data32.sublabel !== undefined){if(typeof data32.sublabel !== "string"){const err76 = {instancePath:instancePath+"/participants/" + i0+"/sublabel",schemaPath:"#/properties/participants/items/properties/sublabel/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err76];}else {vErrors.push(err76);}errors++;}}}else {const err77 = {instancePath:instancePath+"/participants/" + i0,schemaPath:"#/properties/participants/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err77];}else {vErrors.push(err77);}errors++;}}}else {const err78 = {instancePath:instancePath+"/participants",schemaPath:"#/properties/participants/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err78];}else {vErrors.push(err78);}errors++;}}if(data.segments !== undefined){let data37 = data.segments;if(Array.isArray(data37)){const len3 = data37.length;for(let i1=0; i1<len3; i1++){let data38 = data37[i1];if(data38 && typeof data38 == "object" && !Array.isArray(data38)){if(data38.from === undefined){const err79 = {instancePath:instancePath+"/segments/" + i1,schemaPath:"#/properties/segments/items/required",keyword:"required",params:{missingProperty: "from"},message:"must have required property '"+"from"+"'"};if(vErrors === null){vErrors = [err79];}else {vErrors.push(err79);}errors++;}if(data38.to === undefined){const err80 = {instancePath:instancePath+"/segments/" + i1,schemaPath:"#/properties/segments/items/required",keyword:"required",params:{missingProperty: "to"},message:"must have required property '"+"to"+"'"};if(vErrors === null){vErrors = [err80];}else {vErrors.push(err80);}errors++;}if(data38.label === undefined){const err81 = {instancePath:instancePath+"/segments/" + i1,schemaPath:"#/properties/segments/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err81];}else {vErrors.push(err81);}errors++;}for(const key10 in data38){if(!(((key10 === "from") || (key10 === "to")) || (key10 === "label"))){const err82 = {instancePath:instancePath+"/segments/" + i1,schemaPath:"#/properties/segments/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key10},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err82];}else {vErrors.push(err82);}errors++;}}if(data38.from !== undefined){let data39 = data38.from;if(!((typeof data39 == "number") && (isFinite(data39)))){const err83 = {instancePath:instancePath+"/segments/" + i1+"/from",schemaPath:"#/properties/segments/items/properties/from/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err83];}else {vErrors.push(err83);}errors++;}}if(data38.to !== undefined){let data40 = data38.to;if(!((typeof data40 == "number") && (isFinite(data40)))){const err84 = {instancePath:instancePath+"/segments/" + i1+"/to",schemaPath:"#/properties/segments/items/properties/to/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err84];}else {vErrors.push(err84);}errors++;}}if(data38.label !== undefined){let data41 = data38.label;if(typeof data41 === "string"){if(func3(data41) < 1){const err85 = {instancePath:instancePath+"/segments/" + i1+"/label",schemaPath:"#/properties/segments/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err85];}else {vErrors.push(err85);}errors++;}}else {const err86 = {instancePath:instancePath+"/segments/" + i1+"/label",schemaPath:"#/properties/segments/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err86];}else {vErrors.push(err86);}errors++;}}}else {const err87 = {instancePath:instancePath+"/segments/" + i1,schemaPath:"#/properties/segments/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err87];}else {vErrors.push(err87);}errors++;}}}else {const err88 = {instancePath:instancePath+"/segments",schemaPath:"#/properties/segments/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err88];}else {vErrors.push(err88);}errors++;}}if(data.messages !== undefined){let data42 = data.messages;if(Array.isArray(data42)){if(data42.length < 1){const err89 = {instancePath:instancePath+"/messages",schemaPath:"#/properties/messages/minItems",keyword:"minItems",params:{limit: 1},message:"must NOT have fewer than 1 items"};if(vErrors === null){vErrors = [err89];}else {vErrors.push(err89);}errors++;}const len4 = data42.length;for(let i2=0; i2<len4; i2++){let data43 = data42[i2];if(data43 && typeof data43 == "object" && !Array.isArray(data43)){if(data43.from === undefined){const err90 = {instancePath:instancePath+"/messages/" + i2,schemaPath:"#/properties/messages/items/required",keyword:"required",params:{missingProperty: "from"},message:"must have required property '"+"from"+"'"};if(vErrors === null){vErrors = [err90];}else {vErrors.push(err90);}errors++;}if(data43.to === undefined){const err91 = {instancePath:instancePath+"/messages/" + i2,schemaPath:"#/properties/messages/items/required",keyword:"required",params:{missingProperty: "to"},message:"must have required property '"+"to"+"'"};if(vErrors === null){vErrors = [err91];}else {vErrors.push(err91);}errors++;}if(data43.y === undefined){const err92 = {instancePath:instancePath+"/messages/" + i2,schemaPath:"#/properties/messages/items/required",keyword:"required",params:{missingProperty: "y"},message:"must have required property '"+"y"+"'"};if(vErrors === null){vErrors = [err92];}else {vErrors.push(err92);}errors++;}if(data43.label === undefined){const err93 = {instancePath:instancePath+"/messages/" + i2,schemaPath:"#/properties/messages/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err93];}else {vErrors.push(err93);}errors++;}for(const key11 in data43){if(!(((((((key11 === "id") || (key11 === "from")) || (key11 === "to")) || (key11 === "y")) || (key11 === "label")) || (key11 === "variant")) || (key11 === "note"))){const err94 = {instancePath:instancePath+"/messages/" + i2,schemaPath:"#/properties/messages/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key11},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err94];}else {vErrors.push(err94);}errors++;}}if(data43.id !== undefined){let data44 = data43.id;if(typeof data44 === "string"){if(!pattern4.test(data44)){const err95 = {instancePath:instancePath+"/messages/" + i2+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err95];}else {vErrors.push(err95);}errors++;}}else {const err96 = {instancePath:instancePath+"/messages/" + i2+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err96];}else {vErrors.push(err96);}errors++;}}if(data43.from !== undefined){let data45 = data43.from;if(typeof data45 === "string"){if(!pattern4.test(data45)){const err97 = {instancePath:instancePath+"/messages/" + i2+"/from",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err97];}else {vErrors.push(err97);}errors++;}}else {const err98 = {instancePath:instancePath+"/messages/" + i2+"/from",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err98];}else {vErrors.push(err98);}errors++;}}if(data43.to !== undefined){let data46 = data43.to;if(typeof data46 === "string"){if(!pattern4.test(data46)){const err99 = {instancePath:instancePath+"/messages/" + i2+"/to",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err99];}else {vErrors.push(err99);}errors++;}}else {const err100 = {instancePath:instancePath+"/messages/" + i2+"/to",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err100];}else {vErrors.push(err100);}errors++;}}if(data43.y !== undefined){let data47 = data43.y;if((typeof data47 == "number") && (isFinite(data47))){if(data47 < 160 || isNaN(data47)){const err101 = {instancePath:instancePath+"/messages/" + i2+"/y",schemaPath:"#/properties/messages/items/properties/y/minimum",keyword:"minimum",params:{comparison: ">=", limit: 160},message:"must be >= 160"};if(vErrors === null){vErrors = [err101];}else {vErrors.push(err101);}errors++;}}else {const err102 = {instancePath:instancePath+"/messages/" + i2+"/y",schemaPath:"#/properties/messages/items/properties/y/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err102];}else {vErrors.push(err102);}errors++;}}if(data43.label !== undefined){let data48 = data43.label;if(typeof data48 === "string"){if(func3(data48) < 1){const err103 = {instancePath:instancePath+"/messages/" + i2+"/label",schemaPath:"#/properties/messages/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err103];}else {vErrors.push(err103);}errors++;}}else {const err104 = {instancePath:instancePath+"/messages/" + i2+"/label",schemaPath:"#/properties/messages/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err104];}else {vErrors.push(err104);}errors++;}}if(data43.variant !== undefined){let data49 = data43.variant;if(!(((((data49 === "default") || (data49 === "emphasis")) || (data49 === "security")) || (data49 === "dashed")) || (data49 === "return"))){const err105 = {instancePath:instancePath+"/messages/" + i2+"/variant",schemaPath:"#/properties/messages/items/properties/variant/enum",keyword:"enum",params:{allowedValues: schema61.properties.messages.items.properties.variant.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err105];}else {vErrors.push(err105);}errors++;}}if(data43.note !== undefined){if(typeof data43.note !== "string"){const err106 = {instancePath:instancePath+"/messages/" + i2+"/note",schemaPath:"#/properties/messages/items/properties/note/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err106];}else {vErrors.push(err106);}errors++;}}}else {const err107 = {instancePath:instancePath+"/messages/" + i2,schemaPath:"#/properties/messages/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err107];}else {vErrors.push(err107);}errors++;}}}else {const err108 = {instancePath:instancePath+"/messages",schemaPath:"#/properties/messages/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err108];}else {vErrors.push(err108);}errors++;}}if(data.activations !== undefined){let data51 = data.activations;if(Array.isArray(data51)){const len5 = data51.length;for(let i3=0; i3<len5; i3++){let data52 = data51[i3];if(data52 && typeof data52 == "object" && !Array.isArray(data52)){if(data52.participant === undefined){const err109 = {instancePath:instancePath+"/activations/" + i3,schemaPath:"#/properties/activations/items/required",keyword:"required",params:{missingProperty: "participant"},message:"must have required property '"+"participant"+"'"};if(vErrors === null){vErrors = [err109];}else {vErrors.push(err109);}errors++;}if(data52.from === undefined){const err110 = {instancePath:instancePath+"/activations/" + i3,schemaPath:"#/properties/activations/items/required",keyword:"required",params:{missingProperty: "from"},message:"must have required property '"+"from"+"'"};if(vErrors === null){vErrors = [err110];}else {vErrors.push(err110);}errors++;}if(data52.to === undefined){const err111 = {instancePath:instancePath+"/activations/" + i3,schemaPath:"#/properties/activations/items/required",keyword:"required",params:{missingProperty: "to"},message:"must have required property '"+"to"+"'"};if(vErrors === null){vErrors = [err111];}else {vErrors.push(err111);}errors++;}for(const key12 in data52){if(!((((key12 === "participant") || (key12 === "from")) || (key12 === "to")) || (key12 === "type"))){const err112 = {instancePath:instancePath+"/activations/" + i3,schemaPath:"#/properties/activations/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key12},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err112];}else {vErrors.push(err112);}errors++;}}if(data52.participant !== undefined){let data53 = data52.participant;if(typeof data53 === "string"){if(!pattern4.test(data53)){const err113 = {instancePath:instancePath+"/activations/" + i3+"/participant",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err113];}else {vErrors.push(err113);}errors++;}}else {const err114 = {instancePath:instancePath+"/activations/" + i3+"/participant",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err114];}else {vErrors.push(err114);}errors++;}}if(data52.from !== undefined){let data54 = data52.from;if(!((typeof data54 == "number") && (isFinite(data54)))){const err115 = {instancePath:instancePath+"/activations/" + i3+"/from",schemaPath:"#/properties/activations/items/properties/from/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err115];}else {vErrors.push(err115);}errors++;}}if(data52.to !== undefined){let data55 = data52.to;if(!((typeof data55 == "number") && (isFinite(data55)))){const err116 = {instancePath:instancePath+"/activations/" + i3+"/to",schemaPath:"#/properties/activations/items/properties/to/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err116];}else {vErrors.push(err116);}errors++;}}if(data52.type !== undefined){let data56 = data52.type;if(!(((((((data56 === "frontend") || (data56 === "backend")) || (data56 === "database")) || (data56 === "cloud")) || (data56 === "security")) || (data56 === "messagebus")) || (data56 === "external"))){const err117 = {instancePath:instancePath+"/activations/" + i3+"/type",schemaPath:"common.schema.json#/$defs/componentType/enum",keyword:"enum",params:{allowedValues: schema51.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err117];}else {vErrors.push(err117);}errors++;}}}else {const err118 = {instancePath:instancePath+"/activations/" + i3,schemaPath:"#/properties/activations/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err118];}else {vErrors.push(err118);}errors++;}}}else {const err119 = {instancePath:instancePath+"/activations",schemaPath:"#/properties/activations/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err119];}else {vErrors.push(err119);}errors++;}}if(data.cards !== undefined){let data57 = data.cards;if(Array.isArray(data57)){const len6 = data57.length;for(let i4=0; i4<len6; i4++){let data58 = data57[i4];if(data58 && typeof data58 == "object" && !Array.isArray(data58)){if(data58.dot === undefined){const err120 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "dot"},message:"must have required property '"+"dot"+"'"};if(vErrors === null){vErrors = [err120];}else {vErrors.push(err120);}errors++;}if(data58.title === undefined){const err121 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "title"},message:"must have required property '"+"title"+"'"};if(vErrors === null){vErrors = [err121];}else {vErrors.push(err121);}errors++;}if(data58.items === undefined){const err122 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "items"},message:"must have required property '"+"items"+"'"};if(vErrors === null){vErrors = [err122];}else {vErrors.push(err122);}errors++;}for(const key13 in data58){if(!(((key13 === "dot") || (key13 === "title")) || (key13 === "items"))){const err123 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key13},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err123];}else {vErrors.push(err123);}errors++;}}if(data58.dot !== undefined){let data59 = data58.dot;if(!(((((((data59 === "cyan") || (data59 === "emerald")) || (data59 === "violet")) || (data59 === "amber")) || (data59 === "rose")) || (data59 === "orange")) || (data59 === "slate"))){const err124 = {instancePath:instancePath+"/cards/" + i4+"/dot",schemaPath:"common.schema.json#/$defs/cards/items/properties/dot/enum",keyword:"enum",params:{allowedValues: schema60.items.properties.dot.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err124];}else {vErrors.push(err124);}errors++;}}if(data58.title !== undefined){let data60 = data58.title;if(typeof data60 === "string"){if(func3(data60) < 1){const err125 = {instancePath:instancePath+"/cards/" + i4+"/title",schemaPath:"common.schema.json#/$defs/cards/items/properties/title/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err125];}else {vErrors.push(err125);}errors++;}}else {const err126 = {instancePath:instancePath+"/cards/" + i4+"/title",schemaPath:"common.schema.json#/$defs/cards/items/properties/title/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err126];}else {vErrors.push(err126);}errors++;}}if(data58.items !== undefined){let data61 = data58.items;if(Array.isArray(data61)){const len7 = data61.length;for(let i5=0; i5<len7; i5++){if(typeof data61[i5] !== "string"){const err127 = {instancePath:instancePath+"/cards/" + i4+"/items/" + i5,schemaPath:"common.schema.json#/$defs/cards/items/properties/items/items/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err127];}else {vErrors.push(err127);}errors++;}}}else {const err128 = {instancePath:instancePath+"/cards/" + i4+"/items",schemaPath:"common.schema.json#/$defs/cards/items/properties/items/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err128];}else {vErrors.push(err128);}errors++;}}}else {const err129 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err129];}else {vErrors.push(err129);}errors++;}}}else {const err130 = {instancePath:instancePath+"/cards",schemaPath:"common.schema.json#/$defs/cards/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err130];}else {vErrors.push(err130);}errors++;}}}else {const err131 = {instancePath,schemaPath:"#/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err131];}else {vErrors.push(err131);}errors++;}validate24.errors = vErrors;return errors === 0;}validate24.evaluated = {"props":true,"dynamicProps":false,"dynamicItems":false};export const dataflow = validate27;const schema79 = {"$schema":"https://json-schema.org/draft/2020-12/schema","$id":"https://github.com/tt-a1i/archify/schemas/dataflow.schema.json","title":"Archify Data Flow Diagram","type":"object","additionalProperties":false,"required":["schema_version","diagram_type","meta","stages","nodes","flows"],"properties":{"schema_version":{"const":1},"diagram_type":{"const":"dataflow"},"meta":{"type":"object","additionalProperties":false,"required":["title"],"properties":{"title":{"type":"string","minLength":1},"subtitle":{"type":"string"},"output":{"type":"string"},"animation":{"enum":["trace","none"]},"visual_preset":{"enum":["classic","signal-flow","blueprint","editorial"]},"quality_profile":{"enum":["standard","showcase"]},"views":{"$ref":"common.schema.json#/$defs/guidedViews"},"legend":{"type":"object","additionalProperties":false,"properties":{"mode":{"$ref":"common.schema.json#/$defs/legendMode"},"entries":{"type":"object","additionalProperties":false,"properties":{"default":{"$ref":"common.schema.json#/$defs/legendEntry"},"emphasis":{"$ref":"common.schema.json#/$defs/legendEntry"},"security":{"$ref":"common.schema.json#/$defs/legendEntry"},"dashed":{"$ref":"common.schema.json#/$defs/legendEntry"},"database":{"$ref":"common.schema.json#/$defs/legendEntry"}}}}},"viewBox":{"type":"array","prefixItems":[{"type":"number","minimum":360},{"type":"number","minimum":360}],"items":false,"minItems":2,"maxItems":2}}},"stages":{"type":"array","minItems":2,"maxItems":5,"items":{"type":"object","additionalProperties":false,"required":["label"],"properties":{"label":{"type":"string","minLength":1}}}},"nodes":{"type":"array","minItems":2,"items":{"type":"object","additionalProperties":false,"required":["id","type","label","stage","row"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"type":{"$ref":"common.schema.json#/$defs/componentType"},"label":{"type":"string","minLength":1},"sublabel":{"type":"string"},"tag":{"type":"string"},"stage":{"type":"integer","minimum":0},"row":{"type":"integer","minimum":0},"width":{"type":"number","minimum":48},"height":{"type":"number","minimum":36},"yOffset":{"type":"number"}}}},"flows":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to","label"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"from":{"$ref":"common.schema.json#/$defs/id"},"to":{"$ref":"common.schema.json#/$defs/id"},"label":{"type":"string","minLength":1},"classification":{"type":"string"},"variant":{"$ref":"common.schema.json#/$defs/variant"},"route":{"enum":["auto","straight","vertical-channel","bottom-channel","top-channel"]},"fromSide":{"enum":["left","right","top","bottom"]},"toSide":{"enum":["left","right","top","bottom"]},"channelX":{"type":"number"},"channelY":{"type":"number"},"labelAt":{"$ref":"common.schema.json#/$defs/point"},"labelDx":{"type":"number"},"labelDy":{"type":"number"},"labelSegment":{"type":"integer","minimum":0},"via":{"type":"array","items":{"$ref":"common.schema.json#/$defs/point"}},"width":{"type":"number","minimum":0.5}}}},"cards":{"$ref":"common.schema.json#/$defs/cards"}}};function validate28(data, {instancePath="", parentData, parentDataProperty, rootData=data, dynamicAnchors={}}={}){let vErrors = null;let errors = 0;const evaluated0 = validate28.evaluated;if(evaluated0.dynamicProps){evaluated0.props = undefined;}if(evaluated0.dynamicItems){evaluated0.items = undefined;}if(Array.isArray(data)){if(data.length > 5){const err0 = {instancePath,schemaPath:"#/maxItems",keyword:"maxItems",params:{limit: 5},message:"must NOT have more than 5 items"};if(vErrors === null){vErrors = [err0];}else {vErrors.push(err0);}errors++;}const len0 = data.length;for(let i0=0; i0<len0; i0++){let data0 = data[i0];if(data0 && typeof data0 == "object" && !Array.isArray(data0)){if(data0.id === undefined){const err1 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err1];}else {vErrors.push(err1);}errors++;}if(data0.label === undefined){const err2 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err2];}else {vErrors.push(err2);}errors++;}if(data0.focus === undefined){const err3 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "focus"},message:"must have required property '"+"focus"+"'"};if(vErrors === null){vErrors = [err3];}else {vErrors.push(err3);}errors++;}for(const key0 in data0){if(!((((key0 === "id") || (key0 === "label")) || (key0 === "focus")) || (key0 === "note"))){const err4 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key0},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err4];}else {vErrors.push(err4);}errors++;}}if(data0.id !== undefined){let data1 = data0.id;if(typeof data1 === "string"){if(!pattern4.test(data1)){const err5 = {instancePath:instancePath+"/" + i0+"/id",schemaPath:"#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err5];}else {vErrors.push(err5);}errors++;}}else {const err6 = {instancePath:instancePath+"/" + i0+"/id",schemaPath:"#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err6];}else {vErrors.push(err6);}errors++;}}if(data0.label !== undefined){let data2 = data0.label;if(typeof data2 === "string"){if(func3(data2) > 48){const err7 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/maxLength",keyword:"maxLength",params:{limit: 48},message:"must NOT have more than 48 characters"};if(vErrors === null){vErrors = [err7];}else {vErrors.push(err7);}errors++;}if(func3(data2) < 1){const err8 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err8];}else {vErrors.push(err8);}errors++;}}else {const err9 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err9];}else {vErrors.push(err9);}errors++;}}if(data0.focus !== undefined){let data3 = data0.focus;if(Array.isArray(data3)){if(data3.length < 1){const err10 = {instancePath:instancePath+"/" + i0+"/focus",schemaPath:"#/items/properties/focus/minItems",keyword:"minItems",params:{limit: 1},message:"must NOT have fewer than 1 items"};if(vErrors === null){vErrors = [err10];}else {vErrors.push(err10);}errors++;}const len1 = data3.length;for(let i1=0; i1<len1; i1++){let data4 = data3[i1];if(typeof data4 === "string"){if(!pattern4.test(data4)){const err11 = {instancePath:instancePath+"/" + i0+"/focus/" + i1,schemaPath:"#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err11];}else {vErrors.push(err11);}errors++;}}else {const err12 = {instancePath:instancePath+"/" + i0+"/focus/" + i1,schemaPath:"#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err12];}else {vErrors.push(err12);}errors++;}}}else {const err13 = {instancePath:instancePath+"/" + i0+"/focus",schemaPath:"#/items/properties/focus/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err13];}else {vErrors.push(err13);}errors++;}}if(data0.note !== undefined){let data5 = data0.note;if(typeof data5 === "string"){if(func3(data5) > 140){const err14 = {instancePath:instancePath+"/" + i0+"/note",schemaPath:"#/items/properties/note/maxLength",keyword:"maxLength",params:{limit: 140},message:"must NOT have more than 140 characters"};if(vErrors === null){vErrors = [err14];}else {vErrors.push(err14);}errors++;}}else {const err15 = {instancePath:instancePath+"/" + i0+"/note",schemaPath:"#/items/properties/note/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err15];}else {vErrors.push(err15);}errors++;}}}else {const err16 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err16];}else {vErrors.push(err16);}errors++;}}}else {const err17 = {instancePath,schemaPath:"#/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err17];}else {vErrors.push(err17);}errors++;}validate28.errors = vErrors;return errors === 0;}validate28.evaluated = {"items":true,"dynamicProps":false,"dynamicItems":false};function validate27(data, {instancePath="", parentData, parentDataProperty, rootData=data, dynamicAnchors={}}={}){/*# sourceURL="https://github.com/tt-a1i/archify/schemas/dataflow.schema.json" */;let vErrors = null;let errors = 0;const evaluated0 = validate27.evaluated;if(evaluated0.dynamicProps){evaluated0.props = undefined;}if(evaluated0.dynamicItems){evaluated0.items = undefined;}if(data && typeof data == "object" && !Array.isArray(data)){if(data.schema_version === undefined){const err0 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "schema_version"},message:"must have required property '"+"schema_version"+"'"};if(vErrors === null){vErrors = [err0];}else {vErrors.push(err0);}errors++;}if(data.diagram_type === undefined){const err1 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "diagram_type"},message:"must have required property '"+"diagram_type"+"'"};if(vErrors === null){vErrors = [err1];}else {vErrors.push(err1);}errors++;}if(data.meta === undefined){const err2 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "meta"},message:"must have required property '"+"meta"+"'"};if(vErrors === null){vErrors = [err2];}else {vErrors.push(err2);}errors++;}if(data.stages === undefined){const err3 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "stages"},message:"must have required property '"+"stages"+"'"};if(vErrors === null){vErrors = [err3];}else {vErrors.push(err3);}errors++;}if(data.nodes === undefined){const err4 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "nodes"},message:"must have required property '"+"nodes"+"'"};if(vErrors === null){vErrors = [err4];}else {vErrors.push(err4);}errors++;}if(data.flows === undefined){const err5 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "flows"},message:"must have required property '"+"flows"+"'"};if(vErrors === null){vErrors = [err5];}else {vErrors.push(err5);}errors++;}for(const key0 in data){if(!(((((((key0 === "schema_version") || (key0 === "diagram_type")) || (key0 === "meta")) || (key0 === "stages")) || (key0 === "nodes")) || (key0 === "flows")) || (key0 === "cards"))){const err6 = {instancePath,schemaPath:"#/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key0},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err6];}else {vErrors.push(err6);}errors++;}}if(data.schema_version !== undefined){if(1 !== data.schema_version){const err7 = {instancePath:instancePath+"/schema_version",schemaPath:"#/properties/schema_version/const",keyword:"const",params:{allowedValue: 1},message:"must be equal to constant"};if(vErrors === null){vErrors = [err7];}else {vErrors.push(err7);}errors++;}}if(data.diagram_type !== undefined){if("dataflow" !== data.diagram_type){const err8 = {instancePath:instancePath+"/diagram_type",schemaPath:"#/properties/diagram_type/const",keyword:"const",params:{allowedValue: "dataflow"},message:"must be equal to constant"};if(vErrors === null){vErrors = [err8];}else {vErrors.push(err8);}errors++;}}if(data.meta !== undefined){let data2 = data.meta;if(data2 && typeof data2 == "object" && !Array.isArray(data2)){if(data2.title === undefined){const err9 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/required",keyword:"required",params:{missingProperty: "title"},message:"must have required property '"+"title"+"'"};if(vErrors === null){vErrors = [err9];}else {vErrors.push(err9);}errors++;}for(const key1 in data2){if(!(func1.call(schema79.properties.meta.properties, key1))){const err10 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key1},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err10];}else {vErrors.push(err10);}errors++;}}if(data2.title !== undefined){let data3 = data2.title;if(typeof data3 === "string"){if(func3(data3) < 1){const err11 = {instancePath:instancePath+"/meta/title",schemaPath:"#/properties/meta/properties/title/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err11];}else {vErrors.push(err11);}errors++;}}else {const err12 = {instancePath:instancePath+"/meta/title",schemaPath:"#/properties/meta/properties/title/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err12];}else {vErrors.push(err12);}errors++;}}if(data2.subtitle !== undefined){if(typeof data2.subtitle !== "string"){const err13 = {instancePath:instancePath+"/meta/subtitle",schemaPath:"#/properties/meta/properties/subtitle/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err13];}else {vErrors.push(err13);}errors++;}}if(data2.output !== undefined){if(typeof data2.output !== "string"){const err14 = {instancePath:instancePath+"/meta/output",schemaPath:"#/properties/meta/properties/output/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err14];}else {vErrors.push(err14);}errors++;}}if(data2.animation !== undefined){let data6 = data2.animation;if(!((data6 === "trace") || (data6 === "none"))){const err15 = {instancePath:instancePath+"/meta/animation",schemaPath:"#/properties/meta/properties/animation/enum",keyword:"enum",params:{allowedValues: schema79.properties.meta.properties.animation.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err15];}else {vErrors.push(err15);}errors++;}}if(data2.visual_preset !== undefined){let data7 = data2.visual_preset;if(!((((data7 === "classic") || (data7 === "signal-flow")) || (data7 === "blueprint")) || (data7 === "editorial"))){const err16 = {instancePath:instancePath+"/meta/visual_preset",schemaPath:"#/properties/meta/properties/visual_preset/enum",keyword:"enum",params:{allowedValues: schema79.properties.meta.properties.visual_preset.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err16];}else {vErrors.push(err16);}errors++;}}if(data2.quality_profile !== undefined){let data8 = data2.quality_profile;if(!((data8 === "standard") || (data8 === "showcase"))){const err17 = {instancePath:instancePath+"/meta/quality_profile",schemaPath:"#/properties/meta/properties/quality_profile/enum",keyword:"enum",params:{allowedValues: schema79.properties.meta.properties.quality_profile.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err17];}else {vErrors.push(err17);}errors++;}}if(data2.views !== undefined){if(!(validate28(data2.views, {instancePath:instancePath+"/meta/views",parentData:data2,parentDataProperty:"views",rootData,dynamicAnchors}))){vErrors = vErrors === null ? validate28.errors : vErrors.concat(validate28.errors);errors = vErrors.length;}}if(data2.legend !== undefined){let data10 = data2.legend;if(data10 && typeof data10 == "object" && !Array.isArray(data10)){for(const key2 in data10){if(!((key2 === "mode") || (key2 === "entries"))){const err18 = {instancePath:instancePath+"/meta/legend",schemaPath:"#/properties/meta/properties/legend/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key2},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err18];}else {vErrors.push(err18);}errors++;}}if(data10.mode !== undefined){let data11 = data10.mode;if(!(((data11 === "auto") || (data11 === "all")) || (data11 === "hidden"))){const err19 = {instancePath:instancePath+"/meta/legend/mode",schemaPath:"common.schema.json#/$defs/legendMode/enum",keyword:"enum",params:{allowedValues: schema36.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err19];}else {vErrors.push(err19);}errors++;}}if(data10.entries !== undefined){let data12 = data10.entries;if(data12 && typeof data12 == "object" && !Array.isArray(data12)){for(const key3 in data12){if(!(((((key3 === "default") || (key3 === "emphasis")) || (key3 === "security")) || (key3 === "dashed")) || (key3 === "database"))){const err20 = {instancePath:instancePath+"/meta/legend/entries",schemaPath:"#/properties/meta/properties/legend/properties/entries/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key3},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err20];}else {vErrors.push(err20);}errors++;}}if(data12.default !== undefined){let data13 = data12.default;if(data13 && typeof data13 == "object" && !Array.isArray(data13)){if(Object.keys(data13).length < 1){const err21 = {instancePath:instancePath+"/meta/legend/entries/default",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err21];}else {vErrors.push(err21);}errors++;}for(const key4 in data13){if(!((key4 === "label") || (key4 === "visible"))){const err22 = {instancePath:instancePath+"/meta/legend/entries/default",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key4},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err22];}else {vErrors.push(err22);}errors++;}}if(data13.label !== undefined){let data14 = data13.label;if(typeof data14 === "string"){if(func3(data14) > 80){const err23 = {instancePath:instancePath+"/meta/legend/entries/default/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err23];}else {vErrors.push(err23);}errors++;}if(func3(data14) < 1){const err24 = {instancePath:instancePath+"/meta/legend/entries/default/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err24];}else {vErrors.push(err24);}errors++;}}else {const err25 = {instancePath:instancePath+"/meta/legend/entries/default/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err25];}else {vErrors.push(err25);}errors++;}}if(data13.visible !== undefined){if(typeof data13.visible !== "boolean"){const err26 = {instancePath:instancePath+"/meta/legend/entries/default/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err26];}else {vErrors.push(err26);}errors++;}}}else {const err27 = {instancePath:instancePath+"/meta/legend/entries/default",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err27];}else {vErrors.push(err27);}errors++;}}if(data12.emphasis !== undefined){let data16 = data12.emphasis;if(data16 && typeof data16 == "object" && !Array.isArray(data16)){if(Object.keys(data16).length < 1){const err28 = {instancePath:instancePath+"/meta/legend/entries/emphasis",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err28];}else {vErrors.push(err28);}errors++;}for(const key5 in data16){if(!((key5 === "label") || (key5 === "visible"))){const err29 = {instancePath:instancePath+"/meta/legend/entries/emphasis",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key5},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err29];}else {vErrors.push(err29);}errors++;}}if(data16.label !== undefined){let data17 = data16.label;if(typeof data17 === "string"){if(func3(data17) > 80){const err30 = {instancePath:instancePath+"/meta/legend/entries/emphasis/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err30];}else {vErrors.push(err30);}errors++;}if(func3(data17) < 1){const err31 = {instancePath:instancePath+"/meta/legend/entries/emphasis/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err31];}else {vErrors.push(err31);}errors++;}}else {const err32 = {instancePath:instancePath+"/meta/legend/entries/emphasis/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err32];}else {vErrors.push(err32);}errors++;}}if(data16.visible !== undefined){if(typeof data16.visible !== "boolean"){const err33 = {instancePath:instancePath+"/meta/legend/entries/emphasis/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err33];}else {vErrors.push(err33);}errors++;}}}else {const err34 = {instancePath:instancePath+"/meta/legend/entries/emphasis",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err34];}else {vErrors.push(err34);}errors++;}}if(data12.security !== undefined){let data19 = data12.security;if(data19 && typeof data19 == "object" && !Array.isArray(data19)){if(Object.keys(data19).length < 1){const err35 = {instancePath:instancePath+"/meta/legend/entries/security",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err35];}else {vErrors.push(err35);}errors++;}for(const key6 in data19){if(!((key6 === "label") || (key6 === "visible"))){const err36 = {instancePath:instancePath+"/meta/legend/entries/security",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key6},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err36];}else {vErrors.push(err36);}errors++;}}if(data19.label !== undefined){let data20 = data19.label;if(typeof data20 === "string"){if(func3(data20) > 80){const err37 = {instancePath:instancePath+"/meta/legend/entries/security/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err37];}else {vErrors.push(err37);}errors++;}if(func3(data20) < 1){const err38 = {instancePath:instancePath+"/meta/legend/entries/security/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err38];}else {vErrors.push(err38);}errors++;}}else {const err39 = {instancePath:instancePath+"/meta/legend/entries/security/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err39];}else {vErrors.push(err39);}errors++;}}if(data19.visible !== undefined){if(typeof data19.visible !== "boolean"){const err40 = {instancePath:instancePath+"/meta/legend/entries/security/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err40];}else {vErrors.push(err40);}errors++;}}}else {const err41 = {instancePath:instancePath+"/meta/legend/entries/security",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err41];}else {vErrors.push(err41);}errors++;}}if(data12.dashed !== undefined){let data22 = data12.dashed;if(data22 && typeof data22 == "object" && !Array.isArray(data22)){if(Object.keys(data22).length < 1){const err42 = {instancePath:instancePath+"/meta/legend/entries/dashed",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err42];}else {vErrors.push(err42);}errors++;}for(const key7 in data22){if(!((key7 === "label") || (key7 === "visible"))){const err43 = {instancePath:instancePath+"/meta/legend/entries/dashed",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key7},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err43];}else {vErrors.push(err43);}errors++;}}if(data22.label !== undefined){let data23 = data22.label;if(typeof data23 === "string"){if(func3(data23) > 80){const err44 = {instancePath:instancePath+"/meta/legend/entries/dashed/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err44];}else {vErrors.push(err44);}errors++;}if(func3(data23) < 1){const err45 = {instancePath:instancePath+"/meta/legend/entries/dashed/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err45];}else {vErrors.push(err45);}errors++;}}else {const err46 = {instancePath:instancePath+"/meta/legend/entries/dashed/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err46];}else {vErrors.push(err46);}errors++;}}if(data22.visible !== undefined){if(typeof data22.visible !== "boolean"){const err47 = {instancePath:instancePath+"/meta/legend/entries/dashed/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err47];}else {vErrors.push(err47);}errors++;}}}else {const err48 = {instancePath:instancePath+"/meta/legend/entries/dashed",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err48];}else {vErrors.push(err48);}errors++;}}if(data12.database !== undefined){let data25 = data12.database;if(data25 && typeof data25 == "object" && !Array.isArray(data25)){if(Object.keys(data25).length < 1){const err49 = {instancePath:instancePath+"/meta/legend/entries/database",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err49];}else {vErrors.push(err49);}errors++;}for(const key8 in data25){if(!((key8 === "label") || (key8 === "visible"))){const err50 = {instancePath:instancePath+"/meta/legend/entries/database",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key8},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err50];}else {vErrors.push(err50);}errors++;}}if(data25.label !== undefined){let data26 = data25.label;if(typeof data26 === "string"){if(func3(data26) > 80){const err51 = {instancePath:instancePath+"/meta/legend/entries/database/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err51];}else {vErrors.push(err51);}errors++;}if(func3(data26) < 1){const err52 = {instancePath:instancePath+"/meta/legend/entries/database/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err52];}else {vErrors.push(err52);}errors++;}}else {const err53 = {instancePath:instancePath+"/meta/legend/entries/database/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err53];}else {vErrors.push(err53);}errors++;}}if(data25.visible !== undefined){if(typeof data25.visible !== "boolean"){const err54 = {instancePath:instancePath+"/meta/legend/entries/database/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err54];}else {vErrors.push(err54);}errors++;}}}else {const err55 = {instancePath:instancePath+"/meta/legend/entries/database",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err55];}else {vErrors.push(err55);}errors++;}}}else {const err56 = {instancePath:instancePath+"/meta/legend/entries",schemaPath:"#/properties/meta/properties/legend/properties/entries/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err56];}else {vErrors.push(err56);}errors++;}}}else {const err57 = {instancePath:instancePath+"/meta/legend",schemaPath:"#/properties/meta/properties/legend/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err57];}else {vErrors.push(err57);}errors++;}}if(data2.viewBox !== undefined){let data28 = data2.viewBox;if(Array.isArray(data28)){if(data28.length > 2){const err58 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err58];}else {vErrors.push(err58);}errors++;}if(data28.length < 2){const err59 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err59];}else {vErrors.push(err59);}errors++;}const len0 = data28.length;if(len0 > 0){let data29 = data28[0];if((typeof data29 == "number") && (isFinite(data29))){if(data29 < 360 || isNaN(data29)){const err60 = {instancePath:instancePath+"/meta/viewBox/0",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/0/minimum",keyword:"minimum",params:{comparison: ">=", limit: 360},message:"must be >= 360"};if(vErrors === null){vErrors = [err60];}else {vErrors.push(err60);}errors++;}}else {const err61 = {instancePath:instancePath+"/meta/viewBox/0",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err61];}else {vErrors.push(err61);}errors++;}}if(len0 > 1){let data30 = data28[1];if((typeof data30 == "number") && (isFinite(data30))){if(data30 < 360 || isNaN(data30)){const err62 = {instancePath:instancePath+"/meta/viewBox/1",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/1/minimum",keyword:"minimum",params:{comparison: ">=", limit: 360},message:"must be >= 360"};if(vErrors === null){vErrors = [err62];}else {vErrors.push(err62);}errors++;}}else {const err63 = {instancePath:instancePath+"/meta/viewBox/1",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err63];}else {vErrors.push(err63);}errors++;}}const len1 = data28.length;if(!(len1 <= 2)){const err64 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err64];}else {vErrors.push(err64);}errors++;}}else {const err65 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err65];}else {vErrors.push(err65);}errors++;}}}else {const err66 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err66];}else {vErrors.push(err66);}errors++;}}if(data.stages !== undefined){let data31 = data.stages;if(Array.isArray(data31)){if(data31.length > 5){const err67 = {instancePath:instancePath+"/stages",schemaPath:"#/properties/stages/maxItems",keyword:"maxItems",params:{limit: 5},message:"must NOT have more than 5 items"};if(vErrors === null){vErrors = [err67];}else {vErrors.push(err67);}errors++;}if(data31.length < 2){const err68 = {instancePath:instancePath+"/stages",schemaPath:"#/properties/stages/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err68];}else {vErrors.push(err68);}errors++;}const len2 = data31.length;for(let i0=0; i0<len2; i0++){let data32 = data31[i0];if(data32 && typeof data32 == "object" && !Array.isArray(data32)){if(data32.label === undefined){const err69 = {instancePath:instancePath+"/stages/" + i0,schemaPath:"#/properties/stages/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err69];}else {vErrors.push(err69);}errors++;}for(const key9 in data32){if(!(key9 === "label")){const err70 = {instancePath:instancePath+"/stages/" + i0,schemaPath:"#/properties/stages/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key9},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err70];}else {vErrors.push(err70);}errors++;}}if(data32.label !== undefined){let data33 = data32.label;if(typeof data33 === "string"){if(func3(data33) < 1){const err71 = {instancePath:instancePath+"/stages/" + i0+"/label",schemaPath:"#/properties/stages/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err71];}else {vErrors.push(err71);}errors++;}}else {const err72 = {instancePath:instancePath+"/stages/" + i0+"/label",schemaPath:"#/properties/stages/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err72];}else {vErrors.push(err72);}errors++;}}}else {const err73 = {instancePath:instancePath+"/stages/" + i0,schemaPath:"#/properties/stages/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err73];}else {vErrors.push(err73);}errors++;}}}else {const err74 = {instancePath:instancePath+"/stages",schemaPath:"#/properties/stages/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err74];}else {vErrors.push(err74);}errors++;}}if(data.nodes !== undefined){let data34 = data.nodes;if(Array.isArray(data34)){if(data34.length < 2){const err75 = {instancePath:instancePath+"/nodes",schemaPath:"#/properties/nodes/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err75];}else {vErrors.push(err75);}errors++;}const len3 = data34.length;for(let i1=0; i1<len3; i1++){let data35 = data34[i1];if(data35 && typeof data35 == "object" && !Array.isArray(data35)){if(data35.id === undefined){const err76 = {instancePath:instancePath+"/nodes/" + i1,schemaPath:"#/properties/nodes/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err76];}else {vErrors.push(err76);}errors++;}if(data35.type === undefined){const err77 = {instancePath:instancePath+"/nodes/" + i1,schemaPath:"#/properties/nodes/items/required",keyword:"required",params:{missingProperty: "type"},message:"must have required property '"+"type"+"'"};if(vErrors === null){vErrors = [err77];}else {vErrors.push(err77);}errors++;}if(data35.label === undefined){const err78 = {instancePath:instancePath+"/nodes/" + i1,schemaPath:"#/properties/nodes/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err78];}else {vErrors.push(err78);}errors++;}if(data35.stage === undefined){const err79 = {instancePath:instancePath+"/nodes/" + i1,schemaPath:"#/properties/nodes/items/required",keyword:"required",params:{missingProperty: "stage"},message:"must have required property '"+"stage"+"'"};if(vErrors === null){vErrors = [err79];}else {vErrors.push(err79);}errors++;}if(data35.row === undefined){const err80 = {instancePath:instancePath+"/nodes/" + i1,schemaPath:"#/properties/nodes/items/required",keyword:"required",params:{missingProperty: "row"},message:"must have required property '"+"row"+"'"};if(vErrors === null){vErrors = [err80];}else {vErrors.push(err80);}errors++;}for(const key10 in data35){if(!(func1.call(schema79.properties.nodes.items.properties, key10))){const err81 = {instancePath:instancePath+"/nodes/" + i1,schemaPath:"#/properties/nodes/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key10},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err81];}else {vErrors.push(err81);}errors++;}}if(data35.id !== undefined){let data36 = data35.id;if(typeof data36 === "string"){if(!pattern4.test(data36)){const err82 = {instancePath:instancePath+"/nodes/" + i1+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err82];}else {vErrors.push(err82);}errors++;}}else {const err83 = {instancePath:instancePath+"/nodes/" + i1+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err83];}else {vErrors.push(err83);}errors++;}}if(data35.type !== undefined){let data37 = data35.type;if(!(((((((data37 === "frontend") || (data37 === "backend")) || (data37 === "database")) || (data37 === "cloud")) || (data37 === "security")) || (data37 === "messagebus")) || (data37 === "external"))){const err84 = {instancePath:instancePath+"/nodes/" + i1+"/type",schemaPath:"common.schema.json#/$defs/componentType/enum",keyword:"enum",params:{allowedValues: schema51.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err84];}else {vErrors.push(err84);}errors++;}}if(data35.label !== undefined){let data38 = data35.label;if(typeof data38 === "string"){if(func3(data38) < 1){const err85 = {instancePath:instancePath+"/nodes/" + i1+"/label",schemaPath:"#/properties/nodes/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err85];}else {vErrors.push(err85);}errors++;}}else {const err86 = {instancePath:instancePath+"/nodes/" + i1+"/label",schemaPath:"#/properties/nodes/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err86];}else {vErrors.push(err86);}errors++;}}if(data35.sublabel !== undefined){if(typeof data35.sublabel !== "string"){const err87 = {instancePath:instancePath+"/nodes/" + i1+"/sublabel",schemaPath:"#/properties/nodes/items/properties/sublabel/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err87];}else {vErrors.push(err87);}errors++;}}if(data35.tag !== undefined){if(typeof data35.tag !== "string"){const err88 = {instancePath:instancePath+"/nodes/" + i1+"/tag",schemaPath:"#/properties/nodes/items/properties/tag/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err88];}else {vErrors.push(err88);}errors++;}}if(data35.stage !== undefined){let data41 = data35.stage;if(!(((typeof data41 == "number") && (!(data41 % 1) && !isNaN(data41))) && (isFinite(data41)))){const err89 = {instancePath:instancePath+"/nodes/" + i1+"/stage",schemaPath:"#/properties/nodes/items/properties/stage/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err89];}else {vErrors.push(err89);}errors++;}if((typeof data41 == "number") && (isFinite(data41))){if(data41 < 0 || isNaN(data41)){const err90 = {instancePath:instancePath+"/nodes/" + i1+"/stage",schemaPath:"#/properties/nodes/items/properties/stage/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err90];}else {vErrors.push(err90);}errors++;}}}if(data35.row !== undefined){let data42 = data35.row;if(!(((typeof data42 == "number") && (!(data42 % 1) && !isNaN(data42))) && (isFinite(data42)))){const err91 = {instancePath:instancePath+"/nodes/" + i1+"/row",schemaPath:"#/properties/nodes/items/properties/row/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err91];}else {vErrors.push(err91);}errors++;}if((typeof data42 == "number") && (isFinite(data42))){if(data42 < 0 || isNaN(data42)){const err92 = {instancePath:instancePath+"/nodes/" + i1+"/row",schemaPath:"#/properties/nodes/items/properties/row/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err92];}else {vErrors.push(err92);}errors++;}}}if(data35.width !== undefined){let data43 = data35.width;if((typeof data43 == "number") && (isFinite(data43))){if(data43 < 48 || isNaN(data43)){const err93 = {instancePath:instancePath+"/nodes/" + i1+"/width",schemaPath:"#/properties/nodes/items/properties/width/minimum",keyword:"minimum",params:{comparison: ">=", limit: 48},message:"must be >= 48"};if(vErrors === null){vErrors = [err93];}else {vErrors.push(err93);}errors++;}}else {const err94 = {instancePath:instancePath+"/nodes/" + i1+"/width",schemaPath:"#/properties/nodes/items/properties/width/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err94];}else {vErrors.push(err94);}errors++;}}if(data35.height !== undefined){let data44 = data35.height;if((typeof data44 == "number") && (isFinite(data44))){if(data44 < 36 || isNaN(data44)){const err95 = {instancePath:instancePath+"/nodes/" + i1+"/height",schemaPath:"#/properties/nodes/items/properties/height/minimum",keyword:"minimum",params:{comparison: ">=", limit: 36},message:"must be >= 36"};if(vErrors === null){vErrors = [err95];}else {vErrors.push(err95);}errors++;}}else {const err96 = {instancePath:instancePath+"/nodes/" + i1+"/height",schemaPath:"#/properties/nodes/items/properties/height/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err96];}else {vErrors.push(err96);}errors++;}}if(data35.yOffset !== undefined){let data45 = data35.yOffset;if(!((typeof data45 == "number") && (isFinite(data45)))){const err97 = {instancePath:instancePath+"/nodes/" + i1+"/yOffset",schemaPath:"#/properties/nodes/items/properties/yOffset/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err97];}else {vErrors.push(err97);}errors++;}}}else {const err98 = {instancePath:instancePath+"/nodes/" + i1,schemaPath:"#/properties/nodes/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err98];}else {vErrors.push(err98);}errors++;}}}else {const err99 = {instancePath:instancePath+"/nodes",schemaPath:"#/properties/nodes/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err99];}else {vErrors.push(err99);}errors++;}}if(data.flows !== undefined){let data46 = data.flows;if(Array.isArray(data46)){const len4 = data46.length;for(let i2=0; i2<len4; i2++){let data47 = data46[i2];if(data47 && typeof data47 == "object" && !Array.isArray(data47)){if(data47.from === undefined){const err100 = {instancePath:instancePath+"/flows/" + i2,schemaPath:"#/properties/flows/items/required",keyword:"required",params:{missingProperty: "from"},message:"must have required property '"+"from"+"'"};if(vErrors === null){vErrors = [err100];}else {vErrors.push(err100);}errors++;}if(data47.to === undefined){const err101 = {instancePath:instancePath+"/flows/" + i2,schemaPath:"#/properties/flows/items/required",keyword:"required",params:{missingProperty: "to"},message:"must have required property '"+"to"+"'"};if(vErrors === null){vErrors = [err101];}else {vErrors.push(err101);}errors++;}if(data47.label === undefined){const err102 = {instancePath:instancePath+"/flows/" + i2,schemaPath:"#/properties/flows/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err102];}else {vErrors.push(err102);}errors++;}for(const key11 in data47){if(!(func1.call(schema79.properties.flows.items.properties, key11))){const err103 = {instancePath:instancePath+"/flows/" + i2,schemaPath:"#/properties/flows/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key11},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err103];}else {vErrors.push(err103);}errors++;}}if(data47.id !== undefined){let data48 = data47.id;if(typeof data48 === "string"){if(!pattern4.test(data48)){const err104 = {instancePath:instancePath+"/flows/" + i2+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err104];}else {vErrors.push(err104);}errors++;}}else {const err105 = {instancePath:instancePath+"/flows/" + i2+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err105];}else {vErrors.push(err105);}errors++;}}if(data47.from !== undefined){let data49 = data47.from;if(typeof data49 === "string"){if(!pattern4.test(data49)){const err106 = {instancePath:instancePath+"/flows/" + i2+"/from",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err106];}else {vErrors.push(err106);}errors++;}}else {const err107 = {instancePath:instancePath+"/flows/" + i2+"/from",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err107];}else {vErrors.push(err107);}errors++;}}if(data47.to !== undefined){let data50 = data47.to;if(typeof data50 === "string"){if(!pattern4.test(data50)){const err108 = {instancePath:instancePath+"/flows/" + i2+"/to",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err108];}else {vErrors.push(err108);}errors++;}}else {const err109 = {instancePath:instancePath+"/flows/" + i2+"/to",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err109];}else {vErrors.push(err109);}errors++;}}if(data47.label !== undefined){let data51 = data47.label;if(typeof data51 === "string"){if(func3(data51) < 1){const err110 = {instancePath:instancePath+"/flows/" + i2+"/label",schemaPath:"#/properties/flows/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err110];}else {vErrors.push(err110);}errors++;}}else {const err111 = {instancePath:instancePath+"/flows/" + i2+"/label",schemaPath:"#/properties/flows/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err111];}else {vErrors.push(err111);}errors++;}}if(data47.classification !== undefined){if(typeof data47.classification !== "string"){const err112 = {instancePath:instancePath+"/flows/" + i2+"/classification",schemaPath:"#/properties/flows/items/properties/classification/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err112];}else {vErrors.push(err112);}errors++;}}if(data47.variant !== undefined){let data53 = data47.variant;if(!((((data53 === "default") || (data53 === "emphasis")) || (data53 === "security")) || (data53 === "dashed"))){const err113 = {instancePath:instancePath+"/flows/" + i2+"/variant",schemaPath:"common.schema.json#/$defs/variant/enum",keyword:"enum",params:{allowedValues: schema55.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err113];}else {vErrors.push(err113);}errors++;}}if(data47.route !== undefined){let data54 = data47.route;if(!(((((data54 === "auto") || (data54 === "straight")) || (data54 === "vertical-channel")) || (data54 === "bottom-channel")) || (data54 === "top-channel"))){const err114 = {instancePath:instancePath+"/flows/" + i2+"/route",schemaPath:"#/properties/flows/items/properties/route/enum",keyword:"enum",params:{allowedValues: schema79.properties.flows.items.properties.route.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err114];}else {vErrors.push(err114);}errors++;}}if(data47.fromSide !== undefined){let data55 = data47.fromSide;if(!((((data55 === "left") || (data55 === "right")) || (data55 === "top")) || (data55 === "bottom"))){const err115 = {instancePath:instancePath+"/flows/" + i2+"/fromSide",schemaPath:"#/properties/flows/items/properties/fromSide/enum",keyword:"enum",params:{allowedValues: schema79.properties.flows.items.properties.fromSide.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err115];}else {vErrors.push(err115);}errors++;}}if(data47.toSide !== undefined){let data56 = data47.toSide;if(!((((data56 === "left") || (data56 === "right")) || (data56 === "top")) || (data56 === "bottom"))){const err116 = {instancePath:instancePath+"/flows/" + i2+"/toSide",schemaPath:"#/properties/flows/items/properties/toSide/enum",keyword:"enum",params:{allowedValues: schema79.properties.flows.items.properties.toSide.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err116];}else {vErrors.push(err116);}errors++;}}if(data47.channelX !== undefined){let data57 = data47.channelX;if(!((typeof data57 == "number") && (isFinite(data57)))){const err117 = {instancePath:instancePath+"/flows/" + i2+"/channelX",schemaPath:"#/properties/flows/items/properties/channelX/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err117];}else {vErrors.push(err117);}errors++;}}if(data47.channelY !== undefined){let data58 = data47.channelY;if(!((typeof data58 == "number") && (isFinite(data58)))){const err118 = {instancePath:instancePath+"/flows/" + i2+"/channelY",schemaPath:"#/properties/flows/items/properties/channelY/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err118];}else {vErrors.push(err118);}errors++;}}if(data47.labelAt !== undefined){let data59 = data47.labelAt;if(Array.isArray(data59)){if(data59.length > 2){const err119 = {instancePath:instancePath+"/flows/" + i2+"/labelAt",schemaPath:"common.schema.json#/$defs/point/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err119];}else {vErrors.push(err119);}errors++;}if(data59.length < 2){const err120 = {instancePath:instancePath+"/flows/" + i2+"/labelAt",schemaPath:"common.schema.json#/$defs/point/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err120];}else {vErrors.push(err120);}errors++;}const len5 = data59.length;if(len5 > 0){let data60 = data59[0];if(!((typeof data60 == "number") && (isFinite(data60)))){const err121 = {instancePath:instancePath+"/flows/" + i2+"/labelAt/0",schemaPath:"common.schema.json#/$defs/point/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err121];}else {vErrors.push(err121);}errors++;}}if(len5 > 1){let data61 = data59[1];if(!((typeof data61 == "number") && (isFinite(data61)))){const err122 = {instancePath:instancePath+"/flows/" + i2+"/labelAt/1",schemaPath:"common.schema.json#/$defs/point/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err122];}else {vErrors.push(err122);}errors++;}}const len6 = data59.length;if(!(len6 <= 2)){const err123 = {instancePath:instancePath+"/flows/" + i2+"/labelAt",schemaPath:"common.schema.json#/$defs/point/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err123];}else {vErrors.push(err123);}errors++;}}else {const err124 = {instancePath:instancePath+"/flows/" + i2+"/labelAt",schemaPath:"common.schema.json#/$defs/point/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err124];}else {vErrors.push(err124);}errors++;}}if(data47.labelDx !== undefined){let data62 = data47.labelDx;if(!((typeof data62 == "number") && (isFinite(data62)))){const err125 = {instancePath:instancePath+"/flows/" + i2+"/labelDx",schemaPath:"#/properties/flows/items/properties/labelDx/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err125];}else {vErrors.push(err125);}errors++;}}if(data47.labelDy !== undefined){let data63 = data47.labelDy;if(!((typeof data63 == "number") && (isFinite(data63)))){const err126 = {instancePath:instancePath+"/flows/" + i2+"/labelDy",schemaPath:"#/properties/flows/items/properties/labelDy/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err126];}else {vErrors.push(err126);}errors++;}}if(data47.labelSegment !== undefined){let data64 = data47.labelSegment;if(!(((typeof data64 == "number") && (!(data64 % 1) && !isNaN(data64))) && (isFinite(data64)))){const err127 = {instancePath:instancePath+"/flows/" + i2+"/labelSegment",schemaPath:"#/properties/flows/items/properties/labelSegment/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err127];}else {vErrors.push(err127);}errors++;}if((typeof data64 == "number") && (isFinite(data64))){if(data64 < 0 || isNaN(data64)){const err128 = {instancePath:instancePath+"/flows/" + i2+"/labelSegment",schemaPath:"#/properties/flows/items/properties/labelSegment/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err128];}else {vErrors.push(err128);}errors++;}}}if(data47.via !== undefined){let data65 = data47.via;if(Array.isArray(data65)){const len7 = data65.length;for(let i3=0; i3<len7; i3++){let data66 = data65[i3];if(Array.isArray(data66)){if(data66.length > 2){const err129 = {instancePath:instancePath+"/flows/" + i2+"/via/" + i3,schemaPath:"common.schema.json#/$defs/point/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err129];}else {vErrors.push(err129);}errors++;}if(data66.length < 2){const err130 = {instancePath:instancePath+"/flows/" + i2+"/via/" + i3,schemaPath:"common.schema.json#/$defs/point/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err130];}else {vErrors.push(err130);}errors++;}const len8 = data66.length;if(len8 > 0){let data67 = data66[0];if(!((typeof data67 == "number") && (isFinite(data67)))){const err131 = {instancePath:instancePath+"/flows/" + i2+"/via/" + i3+"/0",schemaPath:"common.schema.json#/$defs/point/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err131];}else {vErrors.push(err131);}errors++;}}if(len8 > 1){let data68 = data66[1];if(!((typeof data68 == "number") && (isFinite(data68)))){const err132 = {instancePath:instancePath+"/flows/" + i2+"/via/" + i3+"/1",schemaPath:"common.schema.json#/$defs/point/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err132];}else {vErrors.push(err132);}errors++;}}const len9 = data66.length;if(!(len9 <= 2)){const err133 = {instancePath:instancePath+"/flows/" + i2+"/via/" + i3,schemaPath:"common.schema.json#/$defs/point/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err133];}else {vErrors.push(err133);}errors++;}}else {const err134 = {instancePath:instancePath+"/flows/" + i2+"/via/" + i3,schemaPath:"common.schema.json#/$defs/point/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err134];}else {vErrors.push(err134);}errors++;}}}else {const err135 = {instancePath:instancePath+"/flows/" + i2+"/via",schemaPath:"#/properties/flows/items/properties/via/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err135];}else {vErrors.push(err135);}errors++;}}if(data47.width !== undefined){let data69 = data47.width;if((typeof data69 == "number") && (isFinite(data69))){if(data69 < 0.5 || isNaN(data69)){const err136 = {instancePath:instancePath+"/flows/" + i2+"/width",schemaPath:"#/properties/flows/items/properties/width/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0.5},message:"must be >= 0.5"};if(vErrors === null){vErrors = [err136];}else {vErrors.push(err136);}errors++;}}else {const err137 = {instancePath:instancePath+"/flows/" + i2+"/width",schemaPath:"#/properties/flows/items/properties/width/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err137];}else {vErrors.push(err137);}errors++;}}}else {const err138 = {instancePath:instancePath+"/flows/" + i2,schemaPath:"#/properties/flows/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err138];}else {vErrors.push(err138);}errors++;}}}else {const err139 = {instancePath:instancePath+"/flows",schemaPath:"#/properties/flows/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err139];}else {vErrors.push(err139);}errors++;}}if(data.cards !== undefined){let data70 = data.cards;if(Array.isArray(data70)){const len10 = data70.length;for(let i4=0; i4<len10; i4++){let data71 = data70[i4];if(data71 && typeof data71 == "object" && !Array.isArray(data71)){if(data71.dot === undefined){const err140 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "dot"},message:"must have required property '"+"dot"+"'"};if(vErrors === null){vErrors = [err140];}else {vErrors.push(err140);}errors++;}if(data71.title === undefined){const err141 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "title"},message:"must have required property '"+"title"+"'"};if(vErrors === null){vErrors = [err141];}else {vErrors.push(err141);}errors++;}if(data71.items === undefined){const err142 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "items"},message:"must have required property '"+"items"+"'"};if(vErrors === null){vErrors = [err142];}else {vErrors.push(err142);}errors++;}for(const key12 in data71){if(!(((key12 === "dot") || (key12 === "title")) || (key12 === "items"))){const err143 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key12},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err143];}else {vErrors.push(err143);}errors++;}}if(data71.dot !== undefined){let data72 = data71.dot;if(!(((((((data72 === "cyan") || (data72 === "emerald")) || (data72 === "violet")) || (data72 === "amber")) || (data72 === "rose")) || (data72 === "orange")) || (data72 === "slate"))){const err144 = {instancePath:instancePath+"/cards/" + i4+"/dot",schemaPath:"common.schema.json#/$defs/cards/items/properties/dot/enum",keyword:"enum",params:{allowedValues: schema60.items.properties.dot.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err144];}else {vErrors.push(err144);}errors++;}}if(data71.title !== undefined){let data73 = data71.title;if(typeof data73 === "string"){if(func3(data73) < 1){const err145 = {instancePath:instancePath+"/cards/" + i4+"/title",schemaPath:"common.schema.json#/$defs/cards/items/properties/title/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err145];}else {vErrors.push(err145);}errors++;}}else {const err146 = {instancePath:instancePath+"/cards/" + i4+"/title",schemaPath:"common.schema.json#/$defs/cards/items/properties/title/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err146];}else {vErrors.push(err146);}errors++;}}if(data71.items !== undefined){let data74 = data71.items;if(Array.isArray(data74)){const len11 = data74.length;for(let i5=0; i5<len11; i5++){if(typeof data74[i5] !== "string"){const err147 = {instancePath:instancePath+"/cards/" + i4+"/items/" + i5,schemaPath:"common.schema.json#/$defs/cards/items/properties/items/items/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err147];}else {vErrors.push(err147);}errors++;}}}else {const err148 = {instancePath:instancePath+"/cards/" + i4+"/items",schemaPath:"common.schema.json#/$defs/cards/items/properties/items/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err148];}else {vErrors.push(err148);}errors++;}}}else {const err149 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err149];}else {vErrors.push(err149);}errors++;}}}else {const err150 = {instancePath:instancePath+"/cards",schemaPath:"common.schema.json#/$defs/cards/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err150];}else {vErrors.push(err150);}errors++;}}}else {const err151 = {instancePath,schemaPath:"#/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err151];}else {vErrors.push(err151);}errors++;}validate27.errors = vErrors;return errors === 0;}validate27.evaluated = {"props":true,"dynamicProps":false,"dynamicItems":false};export const lifecycle = validate30;const schema98 = {"$schema":"https://json-schema.org/draft/2020-12/schema","$id":"https://github.com/tt-a1i/archify/schemas/lifecycle.schema.json","title":"Archify Lifecycle Diagram","type":"object","additionalProperties":false,"required":["schema_version","diagram_type","meta","lanes","states","transitions"],"properties":{"schema_version":{"const":1},"diagram_type":{"const":"lifecycle"},"meta":{"type":"object","additionalProperties":false,"required":["title"],"properties":{"title":{"type":"string","minLength":1},"subtitle":{"type":"string"},"output":{"type":"string"},"animation":{"enum":["trace","none"]},"visual_preset":{"enum":["classic","signal-flow","blueprint","editorial"]},"quality_profile":{"enum":["standard","showcase"]},"views":{"$ref":"common.schema.json#/$defs/guidedViews"},"legend":{"type":"object","additionalProperties":false,"properties":{"mode":{"$ref":"common.schema.json#/$defs/legendMode"},"entries":{"type":"object","additionalProperties":false,"properties":{"start":{"$ref":"common.schema.json#/$defs/legendEntry"},"active":{"$ref":"common.schema.json#/$defs/legendEntry"},"waiting":{"$ref":"common.schema.json#/$defs/legendEntry"},"decision":{"$ref":"common.schema.json#/$defs/legendEntry"},"success":{"$ref":"common.schema.json#/$defs/legendEntry"},"failure":{"$ref":"common.schema.json#/$defs/legendEntry"},"neutral":{"$ref":"common.schema.json#/$defs/legendEntry"},"external":{"$ref":"common.schema.json#/$defs/legendEntry"}}}}},"viewBox":{"type":"array","prefixItems":[{"type":"number","minimum":420},{"type":"number","minimum":566}],"items":false,"minItems":2,"maxItems":2}}},"lanes":{"type":"array","minItems":1,"maxItems":4,"items":{"type":"object","additionalProperties":false,"required":["id","label"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"label":{"type":"string","minLength":1}}}},"states":{"type":"array","minItems":2,"items":{"type":"object","additionalProperties":false,"required":["id","type","label","lane","col"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"type":{"enum":["start","active","waiting","decision","success","failure","neutral","external"]},"label":{"type":"string","minLength":1},"sublabel":{"type":"string"},"tag":{"type":"string"},"step":{"type":"string"},"lane":{"$ref":"common.schema.json#/$defs/id"},"col":{"type":"integer","minimum":0,"maximum":4},"width":{"type":"number","minimum":48},"height":{"type":"number","minimum":36},"yOffset":{"type":"number"}}}},"transitions":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"from":{"$ref":"common.schema.json#/$defs/id"},"to":{"$ref":"common.schema.json#/$defs/id"},"label":{"type":"string"},"note":{"type":"string"},"variant":{"$ref":"common.schema.json#/$defs/variant"},"route":{"enum":["auto","straight","drop","bottom-channel","top-channel","right-channel","left-channel"]},"fromSide":{"enum":["left","right","top","bottom"]},"toSide":{"enum":["left","right","top","bottom"]},"channelX":{"type":"number"},"channelY":{"type":"number"},"cornerRadius":{"type":"number","minimum":0},"labelAt":{"$ref":"common.schema.json#/$defs/point"},"labelDx":{"type":"number"},"labelDy":{"type":"number"},"labelSegment":{"type":"integer","minimum":0},"via":{"type":"array","items":{"$ref":"common.schema.json#/$defs/point"}},"width":{"type":"number","minimum":0.5}}}},"cards":{"$ref":"common.schema.json#/$defs/cards"}}};function validate31(data, {instancePath="", parentData, parentDataProperty, rootData=data, dynamicAnchors={}}={}){let vErrors = null;let errors = 0;const evaluated0 = validate31.evaluated;if(evaluated0.dynamicProps){evaluated0.props = undefined;}if(evaluated0.dynamicItems){evaluated0.items = undefined;}if(Array.isArray(data)){if(data.length > 5){const err0 = {instancePath,schemaPath:"#/maxItems",keyword:"maxItems",params:{limit: 5},message:"must NOT have more than 5 items"};if(vErrors === null){vErrors = [err0];}else {vErrors.push(err0);}errors++;}const len0 = data.length;for(let i0=0; i0<len0; i0++){let data0 = data[i0];if(data0 && typeof data0 == "object" && !Array.isArray(data0)){if(data0.id === undefined){const err1 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err1];}else {vErrors.push(err1);}errors++;}if(data0.label === undefined){const err2 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err2];}else {vErrors.push(err2);}errors++;}if(data0.focus === undefined){const err3 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "focus"},message:"must have required property '"+"focus"+"'"};if(vErrors === null){vErrors = [err3];}else {vErrors.push(err3);}errors++;}for(const key0 in data0){if(!((((key0 === "id") || (key0 === "label")) || (key0 === "focus")) || (key0 === "note"))){const err4 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key0},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err4];}else {vErrors.push(err4);}errors++;}}if(data0.id !== undefined){let data1 = data0.id;if(typeof data1 === "string"){if(!pattern4.test(data1)){const err5 = {instancePath:instancePath+"/" + i0+"/id",schemaPath:"#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err5];}else {vErrors.push(err5);}errors++;}}else {const err6 = {instancePath:instancePath+"/" + i0+"/id",schemaPath:"#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err6];}else {vErrors.push(err6);}errors++;}}if(data0.label !== undefined){let data2 = data0.label;if(typeof data2 === "string"){if(func3(data2) > 48){const err7 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/maxLength",keyword:"maxLength",params:{limit: 48},message:"must NOT have more than 48 characters"};if(vErrors === null){vErrors = [err7];}else {vErrors.push(err7);}errors++;}if(func3(data2) < 1){const err8 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err8];}else {vErrors.push(err8);}errors++;}}else {const err9 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err9];}else {vErrors.push(err9);}errors++;}}if(data0.focus !== undefined){let data3 = data0.focus;if(Array.isArray(data3)){if(data3.length < 1){const err10 = {instancePath:instancePath+"/" + i0+"/focus",schemaPath:"#/items/properties/focus/minItems",keyword:"minItems",params:{limit: 1},message:"must NOT have fewer than 1 items"};if(vErrors === null){vErrors = [err10];}else {vErrors.push(err10);}errors++;}const len1 = data3.length;for(let i1=0; i1<len1; i1++){let data4 = data3[i1];if(typeof data4 === "string"){if(!pattern4.test(data4)){const err11 = {instancePath:instancePath+"/" + i0+"/focus/" + i1,schemaPath:"#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err11];}else {vErrors.push(err11);}errors++;}}else {const err12 = {instancePath:instancePath+"/" + i0+"/focus/" + i1,schemaPath:"#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err12];}else {vErrors.push(err12);}errors++;}}}else {const err13 = {instancePath:instancePath+"/" + i0+"/focus",schemaPath:"#/items/properties/focus/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err13];}else {vErrors.push(err13);}errors++;}}if(data0.note !== undefined){let data5 = data0.note;if(typeof data5 === "string"){if(func3(data5) > 140){const err14 = {instancePath:instancePath+"/" + i0+"/note",schemaPath:"#/items/properties/note/maxLength",keyword:"maxLength",params:{limit: 140},message:"must NOT have more than 140 characters"};if(vErrors === null){vErrors = [err14];}else {vErrors.push(err14);}errors++;}}else {const err15 = {instancePath:instancePath+"/" + i0+"/note",schemaPath:"#/items/properties/note/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err15];}else {vErrors.push(err15);}errors++;}}}else {const err16 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err16];}else {vErrors.push(err16);}errors++;}}}else {const err17 = {instancePath,schemaPath:"#/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err17];}else {vErrors.push(err17);}errors++;}validate31.errors = vErrors;return errors === 0;}validate31.evaluated = {"items":true,"dynamicProps":false,"dynamicItems":false};function validate30(data, {instancePath="", parentData, parentDataProperty, rootData=data, dynamicAnchors={}}={}){/*# sourceURL="https://github.com/tt-a1i/archify/schemas/lifecycle.schema.json" */;let vErrors = null;let errors = 0;const evaluated0 = validate30.evaluated;if(evaluated0.dynamicProps){evaluated0.props = undefined;}if(evaluated0.dynamicItems){evaluated0.items = undefined;}if(data && typeof data == "object" && !Array.isArray(data)){if(data.schema_version === undefined){const err0 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "schema_version"},message:"must have required property '"+"schema_version"+"'"};if(vErrors === null){vErrors = [err0];}else {vErrors.push(err0);}errors++;}if(data.diagram_type === undefined){const err1 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "diagram_type"},message:"must have required property '"+"diagram_type"+"'"};if(vErrors === null){vErrors = [err1];}else {vErrors.push(err1);}errors++;}if(data.meta === undefined){const err2 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "meta"},message:"must have required property '"+"meta"+"'"};if(vErrors === null){vErrors = [err2];}else {vErrors.push(err2);}errors++;}if(data.lanes === undefined){const err3 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "lanes"},message:"must have required property '"+"lanes"+"'"};if(vErrors === null){vErrors = [err3];}else {vErrors.push(err3);}errors++;}if(data.states === undefined){const err4 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "states"},message:"must have required property '"+"states"+"'"};if(vErrors === null){vErrors = [err4];}else {vErrors.push(err4);}errors++;}if(data.transitions === undefined){const err5 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "transitions"},message:"must have required property '"+"transitions"+"'"};if(vErrors === null){vErrors = [err5];}else {vErrors.push(err5);}errors++;}for(const key0 in data){if(!(((((((key0 === "schema_version") || (key0 === "diagram_type")) || (key0 === "meta")) || (key0 === "lanes")) || (key0 === "states")) || (key0 === "transitions")) || (key0 === "cards"))){const err6 = {instancePath,schemaPath:"#/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key0},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err6];}else {vErrors.push(err6);}errors++;}}if(data.schema_version !== undefined){if(1 !== data.schema_version){const err7 = {instancePath:instancePath+"/schema_version",schemaPath:"#/properties/schema_version/const",keyword:"const",params:{allowedValue: 1},message:"must be equal to constant"};if(vErrors === null){vErrors = [err7];}else {vErrors.push(err7);}errors++;}}if(data.diagram_type !== undefined){if("lifecycle" !== data.diagram_type){const err8 = {instancePath:instancePath+"/diagram_type",schemaPath:"#/properties/diagram_type/const",keyword:"const",params:{allowedValue: "lifecycle"},message:"must be equal to constant"};if(vErrors === null){vErrors = [err8];}else {vErrors.push(err8);}errors++;}}if(data.meta !== undefined){let data2 = data.meta;if(data2 && typeof data2 == "object" && !Array.isArray(data2)){if(data2.title === undefined){const err9 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/required",keyword:"required",params:{missingProperty: "title"},message:"must have required property '"+"title"+"'"};if(vErrors === null){vErrors = [err9];}else {vErrors.push(err9);}errors++;}for(const key1 in data2){if(!(func1.call(schema98.properties.meta.properties, key1))){const err10 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key1},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err10];}else {vErrors.push(err10);}errors++;}}if(data2.title !== undefined){let data3 = data2.title;if(typeof data3 === "string"){if(func3(data3) < 1){const err11 = {instancePath:instancePath+"/meta/title",schemaPath:"#/properties/meta/properties/title/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err11];}else {vErrors.push(err11);}errors++;}}else {const err12 = {instancePath:instancePath+"/meta/title",schemaPath:"#/properties/meta/properties/title/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err12];}else {vErrors.push(err12);}errors++;}}if(data2.subtitle !== undefined){if(typeof data2.subtitle !== "string"){const err13 = {instancePath:instancePath+"/meta/subtitle",schemaPath:"#/properties/meta/properties/subtitle/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err13];}else {vErrors.push(err13);}errors++;}}if(data2.output !== undefined){if(typeof data2.output !== "string"){const err14 = {instancePath:instancePath+"/meta/output",schemaPath:"#/properties/meta/properties/output/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err14];}else {vErrors.push(err14);}errors++;}}if(data2.animation !== undefined){let data6 = data2.animation;if(!((data6 === "trace") || (data6 === "none"))){const err15 = {instancePath:instancePath+"/meta/animation",schemaPath:"#/properties/meta/properties/animation/enum",keyword:"enum",params:{allowedValues: schema98.properties.meta.properties.animation.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err15];}else {vErrors.push(err15);}errors++;}}if(data2.visual_preset !== undefined){let data7 = data2.visual_preset;if(!((((data7 === "classic") || (data7 === "signal-flow")) || (data7 === "blueprint")) || (data7 === "editorial"))){const err16 = {instancePath:instancePath+"/meta/visual_preset",schemaPath:"#/properties/meta/properties/visual_preset/enum",keyword:"enum",params:{allowedValues: schema98.properties.meta.properties.visual_preset.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err16];}else {vErrors.push(err16);}errors++;}}if(data2.quality_profile !== undefined){let data8 = data2.quality_profile;if(!((data8 === "standard") || (data8 === "showcase"))){const err17 = {instancePath:instancePath+"/meta/quality_profile",schemaPath:"#/properties/meta/properties/quality_profile/enum",keyword:"enum",params:{allowedValues: schema98.properties.meta.properties.quality_profile.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err17];}else {vErrors.push(err17);}errors++;}}if(data2.views !== undefined){if(!(validate31(data2.views, {instancePath:instancePath+"/meta/views",parentData:data2,parentDataProperty:"views",rootData,dynamicAnchors}))){vErrors = vErrors === null ? validate31.errors : vErrors.concat(validate31.errors);errors = vErrors.length;}}if(data2.legend !== undefined){let data10 = data2.legend;if(data10 && typeof data10 == "object" && !Array.isArray(data10)){for(const key2 in data10){if(!((key2 === "mode") || (key2 === "entries"))){const err18 = {instancePath:instancePath+"/meta/legend",schemaPath:"#/properties/meta/properties/legend/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key2},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err18];}else {vErrors.push(err18);}errors++;}}if(data10.mode !== undefined){let data11 = data10.mode;if(!(((data11 === "auto") || (data11 === "all")) || (data11 === "hidden"))){const err19 = {instancePath:instancePath+"/meta/legend/mode",schemaPath:"common.schema.json#/$defs/legendMode/enum",keyword:"enum",params:{allowedValues: schema36.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err19];}else {vErrors.push(err19);}errors++;}}if(data10.entries !== undefined){let data12 = data10.entries;if(data12 && typeof data12 == "object" && !Array.isArray(data12)){for(const key3 in data12){if(!((((((((key3 === "start") || (key3 === "active")) || (key3 === "waiting")) || (key3 === "decision")) || (key3 === "success")) || (key3 === "failure")) || (key3 === "neutral")) || (key3 === "external"))){const err20 = {instancePath:instancePath+"/meta/legend/entries",schemaPath:"#/properties/meta/properties/legend/properties/entries/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key3},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err20];}else {vErrors.push(err20);}errors++;}}if(data12.start !== undefined){let data13 = data12.start;if(data13 && typeof data13 == "object" && !Array.isArray(data13)){if(Object.keys(data13).length < 1){const err21 = {instancePath:instancePath+"/meta/legend/entries/start",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err21];}else {vErrors.push(err21);}errors++;}for(const key4 in data13){if(!((key4 === "label") || (key4 === "visible"))){const err22 = {instancePath:instancePath+"/meta/legend/entries/start",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key4},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err22];}else {vErrors.push(err22);}errors++;}}if(data13.label !== undefined){let data14 = data13.label;if(typeof data14 === "string"){if(func3(data14) > 80){const err23 = {instancePath:instancePath+"/meta/legend/entries/start/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err23];}else {vErrors.push(err23);}errors++;}if(func3(data14) < 1){const err24 = {instancePath:instancePath+"/meta/legend/entries/start/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err24];}else {vErrors.push(err24);}errors++;}}else {const err25 = {instancePath:instancePath+"/meta/legend/entries/start/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err25];}else {vErrors.push(err25);}errors++;}}if(data13.visible !== undefined){if(typeof data13.visible !== "boolean"){const err26 = {instancePath:instancePath+"/meta/legend/entries/start/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err26];}else {vErrors.push(err26);}errors++;}}}else {const err27 = {instancePath:instancePath+"/meta/legend/entries/start",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err27];}else {vErrors.push(err27);}errors++;}}if(data12.active !== undefined){let data16 = data12.active;if(data16 && typeof data16 == "object" && !Array.isArray(data16)){if(Object.keys(data16).length < 1){const err28 = {instancePath:instancePath+"/meta/legend/entries/active",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err28];}else {vErrors.push(err28);}errors++;}for(const key5 in data16){if(!((key5 === "label") || (key5 === "visible"))){const err29 = {instancePath:instancePath+"/meta/legend/entries/active",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key5},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err29];}else {vErrors.push(err29);}errors++;}}if(data16.label !== undefined){let data17 = data16.label;if(typeof data17 === "string"){if(func3(data17) > 80){const err30 = {instancePath:instancePath+"/meta/legend/entries/active/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err30];}else {vErrors.push(err30);}errors++;}if(func3(data17) < 1){const err31 = {instancePath:instancePath+"/meta/legend/entries/active/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err31];}else {vErrors.push(err31);}errors++;}}else {const err32 = {instancePath:instancePath+"/meta/legend/entries/active/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err32];}else {vErrors.push(err32);}errors++;}}if(data16.visible !== undefined){if(typeof data16.visible !== "boolean"){const err33 = {instancePath:instancePath+"/meta/legend/entries/active/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err33];}else {vErrors.push(err33);}errors++;}}}else {const err34 = {instancePath:instancePath+"/meta/legend/entries/active",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err34];}else {vErrors.push(err34);}errors++;}}if(data12.waiting !== undefined){let data19 = data12.waiting;if(data19 && typeof data19 == "object" && !Array.isArray(data19)){if(Object.keys(data19).length < 1){const err35 = {instancePath:instancePath+"/meta/legend/entries/waiting",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err35];}else {vErrors.push(err35);}errors++;}for(const key6 in data19){if(!((key6 === "label") || (key6 === "visible"))){const err36 = {instancePath:instancePath+"/meta/legend/entries/waiting",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key6},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err36];}else {vErrors.push(err36);}errors++;}}if(data19.label !== undefined){let data20 = data19.label;if(typeof data20 === "string"){if(func3(data20) > 80){const err37 = {instancePath:instancePath+"/meta/legend/entries/waiting/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err37];}else {vErrors.push(err37);}errors++;}if(func3(data20) < 1){const err38 = {instancePath:instancePath+"/meta/legend/entries/waiting/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err38];}else {vErrors.push(err38);}errors++;}}else {const err39 = {instancePath:instancePath+"/meta/legend/entries/waiting/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err39];}else {vErrors.push(err39);}errors++;}}if(data19.visible !== undefined){if(typeof data19.visible !== "boolean"){const err40 = {instancePath:instancePath+"/meta/legend/entries/waiting/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err40];}else {vErrors.push(err40);}errors++;}}}else {const err41 = {instancePath:instancePath+"/meta/legend/entries/waiting",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err41];}else {vErrors.push(err41);}errors++;}}if(data12.decision !== undefined){let data22 = data12.decision;if(data22 && typeof data22 == "object" && !Array.isArray(data22)){if(Object.keys(data22).length < 1){const err42 = {instancePath:instancePath+"/meta/legend/entries/decision",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err42];}else {vErrors.push(err42);}errors++;}for(const key7 in data22){if(!((key7 === "label") || (key7 === "visible"))){const err43 = {instancePath:instancePath+"/meta/legend/entries/decision",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key7},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err43];}else {vErrors.push(err43);}errors++;}}if(data22.label !== undefined){let data23 = data22.label;if(typeof data23 === "string"){if(func3(data23) > 80){const err44 = {instancePath:instancePath+"/meta/legend/entries/decision/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err44];}else {vErrors.push(err44);}errors++;}if(func3(data23) < 1){const err45 = {instancePath:instancePath+"/meta/legend/entries/decision/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err45];}else {vErrors.push(err45);}errors++;}}else {const err46 = {instancePath:instancePath+"/meta/legend/entries/decision/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err46];}else {vErrors.push(err46);}errors++;}}if(data22.visible !== undefined){if(typeof data22.visible !== "boolean"){const err47 = {instancePath:instancePath+"/meta/legend/entries/decision/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err47];}else {vErrors.push(err47);}errors++;}}}else {const err48 = {instancePath:instancePath+"/meta/legend/entries/decision",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err48];}else {vErrors.push(err48);}errors++;}}if(data12.success !== undefined){let data25 = data12.success;if(data25 && typeof data25 == "object" && !Array.isArray(data25)){if(Object.keys(data25).length < 1){const err49 = {instancePath:instancePath+"/meta/legend/entries/success",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err49];}else {vErrors.push(err49);}errors++;}for(const key8 in data25){if(!((key8 === "label") || (key8 === "visible"))){const err50 = {instancePath:instancePath+"/meta/legend/entries/success",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key8},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err50];}else {vErrors.push(err50);}errors++;}}if(data25.label !== undefined){let data26 = data25.label;if(typeof data26 === "string"){if(func3(data26) > 80){const err51 = {instancePath:instancePath+"/meta/legend/entries/success/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err51];}else {vErrors.push(err51);}errors++;}if(func3(data26) < 1){const err52 = {instancePath:instancePath+"/meta/legend/entries/success/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err52];}else {vErrors.push(err52);}errors++;}}else {const err53 = {instancePath:instancePath+"/meta/legend/entries/success/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err53];}else {vErrors.push(err53);}errors++;}}if(data25.visible !== undefined){if(typeof data25.visible !== "boolean"){const err54 = {instancePath:instancePath+"/meta/legend/entries/success/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err54];}else {vErrors.push(err54);}errors++;}}}else {const err55 = {instancePath:instancePath+"/meta/legend/entries/success",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err55];}else {vErrors.push(err55);}errors++;}}if(data12.failure !== undefined){let data28 = data12.failure;if(data28 && typeof data28 == "object" && !Array.isArray(data28)){if(Object.keys(data28).length < 1){const err56 = {instancePath:instancePath+"/meta/legend/entries/failure",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err56];}else {vErrors.push(err56);}errors++;}for(const key9 in data28){if(!((key9 === "label") || (key9 === "visible"))){const err57 = {instancePath:instancePath+"/meta/legend/entries/failure",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key9},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err57];}else {vErrors.push(err57);}errors++;}}if(data28.label !== undefined){let data29 = data28.label;if(typeof data29 === "string"){if(func3(data29) > 80){const err58 = {instancePath:instancePath+"/meta/legend/entries/failure/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err58];}else {vErrors.push(err58);}errors++;}if(func3(data29) < 1){const err59 = {instancePath:instancePath+"/meta/legend/entries/failure/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err59];}else {vErrors.push(err59);}errors++;}}else {const err60 = {instancePath:instancePath+"/meta/legend/entries/failure/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err60];}else {vErrors.push(err60);}errors++;}}if(data28.visible !== undefined){if(typeof data28.visible !== "boolean"){const err61 = {instancePath:instancePath+"/meta/legend/entries/failure/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err61];}else {vErrors.push(err61);}errors++;}}}else {const err62 = {instancePath:instancePath+"/meta/legend/entries/failure",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err62];}else {vErrors.push(err62);}errors++;}}if(data12.neutral !== undefined){let data31 = data12.neutral;if(data31 && typeof data31 == "object" && !Array.isArray(data31)){if(Object.keys(data31).length < 1){const err63 = {instancePath:instancePath+"/meta/legend/entries/neutral",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err63];}else {vErrors.push(err63);}errors++;}for(const key10 in data31){if(!((key10 === "label") || (key10 === "visible"))){const err64 = {instancePath:instancePath+"/meta/legend/entries/neutral",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key10},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err64];}else {vErrors.push(err64);}errors++;}}if(data31.label !== undefined){let data32 = data31.label;if(typeof data32 === "string"){if(func3(data32) > 80){const err65 = {instancePath:instancePath+"/meta/legend/entries/neutral/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err65];}else {vErrors.push(err65);}errors++;}if(func3(data32) < 1){const err66 = {instancePath:instancePath+"/meta/legend/entries/neutral/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err66];}else {vErrors.push(err66);}errors++;}}else {const err67 = {instancePath:instancePath+"/meta/legend/entries/neutral/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err67];}else {vErrors.push(err67);}errors++;}}if(data31.visible !== undefined){if(typeof data31.visible !== "boolean"){const err68 = {instancePath:instancePath+"/meta/legend/entries/neutral/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err68];}else {vErrors.push(err68);}errors++;}}}else {const err69 = {instancePath:instancePath+"/meta/legend/entries/neutral",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err69];}else {vErrors.push(err69);}errors++;}}if(data12.external !== undefined){let data34 = data12.external;if(data34 && typeof data34 == "object" && !Array.isArray(data34)){if(Object.keys(data34).length < 1){const err70 = {instancePath:instancePath+"/meta/legend/entries/external",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err70];}else {vErrors.push(err70);}errors++;}for(const key11 in data34){if(!((key11 === "label") || (key11 === "visible"))){const err71 = {instancePath:instancePath+"/meta/legend/entries/external",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key11},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err71];}else {vErrors.push(err71);}errors++;}}if(data34.label !== undefined){let data35 = data34.label;if(typeof data35 === "string"){if(func3(data35) > 80){const err72 = {instancePath:instancePath+"/meta/legend/entries/external/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err72];}else {vErrors.push(err72);}errors++;}if(func3(data35) < 1){const err73 = {instancePath:instancePath+"/meta/legend/entries/external/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err73];}else {vErrors.push(err73);}errors++;}}else {const err74 = {instancePath:instancePath+"/meta/legend/entries/external/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err74];}else {vErrors.push(err74);}errors++;}}if(data34.visible !== undefined){if(typeof data34.visible !== "boolean"){const err75 = {instancePath:instancePath+"/meta/legend/entries/external/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err75];}else {vErrors.push(err75);}errors++;}}}else {const err76 = {instancePath:instancePath+"/meta/legend/entries/external",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err76];}else {vErrors.push(err76);}errors++;}}}else {const err77 = {instancePath:instancePath+"/meta/legend/entries",schemaPath:"#/properties/meta/properties/legend/properties/entries/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err77];}else {vErrors.push(err77);}errors++;}}}else {const err78 = {instancePath:instancePath+"/meta/legend",schemaPath:"#/properties/meta/properties/legend/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err78];}else {vErrors.push(err78);}errors++;}}if(data2.viewBox !== undefined){let data37 = data2.viewBox;if(Array.isArray(data37)){if(data37.length > 2){const err79 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err79];}else {vErrors.push(err79);}errors++;}if(data37.length < 2){const err80 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err80];}else {vErrors.push(err80);}errors++;}const len0 = data37.length;if(len0 > 0){let data38 = data37[0];if((typeof data38 == "number") && (isFinite(data38))){if(data38 < 420 || isNaN(data38)){const err81 = {instancePath:instancePath+"/meta/viewBox/0",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/0/minimum",keyword:"minimum",params:{comparison: ">=", limit: 420},message:"must be >= 420"};if(vErrors === null){vErrors = [err81];}else {vErrors.push(err81);}errors++;}}else {const err82 = {instancePath:instancePath+"/meta/viewBox/0",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err82];}else {vErrors.push(err82);}errors++;}}if(len0 > 1){let data39 = data37[1];if((typeof data39 == "number") && (isFinite(data39))){if(data39 < 566 || isNaN(data39)){const err83 = {instancePath:instancePath+"/meta/viewBox/1",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/1/minimum",keyword:"minimum",params:{comparison: ">=", limit: 566},message:"must be >= 566"};if(vErrors === null){vErrors = [err83];}else {vErrors.push(err83);}errors++;}}else {const err84 = {instancePath:instancePath+"/meta/viewBox/1",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err84];}else {vErrors.push(err84);}errors++;}}const len1 = data37.length;if(!(len1 <= 2)){const err85 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err85];}else {vErrors.push(err85);}errors++;}}else {const err86 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err86];}else {vErrors.push(err86);}errors++;}}}else {const err87 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err87];}else {vErrors.push(err87);}errors++;}}if(data.lanes !== undefined){let data40 = data.lanes;if(Array.isArray(data40)){if(data40.length > 4){const err88 = {instancePath:instancePath+"/lanes",schemaPath:"#/properties/lanes/maxItems",keyword:"maxItems",params:{limit: 4},message:"must NOT have more than 4 items"};if(vErrors === null){vErrors = [err88];}else {vErrors.push(err88);}errors++;}if(data40.length < 1){const err89 = {instancePath:instancePath+"/lanes",schemaPath:"#/properties/lanes/minItems",keyword:"minItems",params:{limit: 1},message:"must NOT have fewer than 1 items"};if(vErrors === null){vErrors = [err89];}else {vErrors.push(err89);}errors++;}const len2 = data40.length;for(let i0=0; i0<len2; i0++){let data41 = data40[i0];if(data41 && typeof data41 == "object" && !Array.isArray(data41)){if(data41.id === undefined){const err90 = {instancePath:instancePath+"/lanes/" + i0,schemaPath:"#/properties/lanes/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err90];}else {vErrors.push(err90);}errors++;}if(data41.label === undefined){const err91 = {instancePath:instancePath+"/lanes/" + i0,schemaPath:"#/properties/lanes/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err91];}else {vErrors.push(err91);}errors++;}for(const key12 in data41){if(!((key12 === "id") || (key12 === "label"))){const err92 = {instancePath:instancePath+"/lanes/" + i0,schemaPath:"#/properties/lanes/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key12},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err92];}else {vErrors.push(err92);}errors++;}}if(data41.id !== undefined){let data42 = data41.id;if(typeof data42 === "string"){if(!pattern4.test(data42)){const err93 = {instancePath:instancePath+"/lanes/" + i0+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err93];}else {vErrors.push(err93);}errors++;}}else {const err94 = {instancePath:instancePath+"/lanes/" + i0+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err94];}else {vErrors.push(err94);}errors++;}}if(data41.label !== undefined){let data43 = data41.label;if(typeof data43 === "string"){if(func3(data43) < 1){const err95 = {instancePath:instancePath+"/lanes/" + i0+"/label",schemaPath:"#/properties/lanes/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err95];}else {vErrors.push(err95);}errors++;}}else {const err96 = {instancePath:instancePath+"/lanes/" + i0+"/label",schemaPath:"#/properties/lanes/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err96];}else {vErrors.push(err96);}errors++;}}}else {const err97 = {instancePath:instancePath+"/lanes/" + i0,schemaPath:"#/properties/lanes/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err97];}else {vErrors.push(err97);}errors++;}}}else {const err98 = {instancePath:instancePath+"/lanes",schemaPath:"#/properties/lanes/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err98];}else {vErrors.push(err98);}errors++;}}if(data.states !== undefined){let data44 = data.states;if(Array.isArray(data44)){if(data44.length < 2){const err99 = {instancePath:instancePath+"/states",schemaPath:"#/properties/states/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err99];}else {vErrors.push(err99);}errors++;}const len3 = data44.length;for(let i1=0; i1<len3; i1++){let data45 = data44[i1];if(data45 && typeof data45 == "object" && !Array.isArray(data45)){if(data45.id === undefined){const err100 = {instancePath:instancePath+"/states/" + i1,schemaPath:"#/properties/states/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err100];}else {vErrors.push(err100);}errors++;}if(data45.type === undefined){const err101 = {instancePath:instancePath+"/states/" + i1,schemaPath:"#/properties/states/items/required",keyword:"required",params:{missingProperty: "type"},message:"must have required property '"+"type"+"'"};if(vErrors === null){vErrors = [err101];}else {vErrors.push(err101);}errors++;}if(data45.label === undefined){const err102 = {instancePath:instancePath+"/states/" + i1,schemaPath:"#/properties/states/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err102];}else {vErrors.push(err102);}errors++;}if(data45.lane === undefined){const err103 = {instancePath:instancePath+"/states/" + i1,schemaPath:"#/properties/states/items/required",keyword:"required",params:{missingProperty: "lane"},message:"must have required property '"+"lane"+"'"};if(vErrors === null){vErrors = [err103];}else {vErrors.push(err103);}errors++;}if(data45.col === undefined){const err104 = {instancePath:instancePath+"/states/" + i1,schemaPath:"#/properties/states/items/required",keyword:"required",params:{missingProperty: "col"},message:"must have required property '"+"col"+"'"};if(vErrors === null){vErrors = [err104];}else {vErrors.push(err104);}errors++;}for(const key13 in data45){if(!(func1.call(schema98.properties.states.items.properties, key13))){const err105 = {instancePath:instancePath+"/states/" + i1,schemaPath:"#/properties/states/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key13},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err105];}else {vErrors.push(err105);}errors++;}}if(data45.id !== undefined){let data46 = data45.id;if(typeof data46 === "string"){if(!pattern4.test(data46)){const err106 = {instancePath:instancePath+"/states/" + i1+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err106];}else {vErrors.push(err106);}errors++;}}else {const err107 = {instancePath:instancePath+"/states/" + i1+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err107];}else {vErrors.push(err107);}errors++;}}if(data45.type !== undefined){let data47 = data45.type;if(!((((((((data47 === "start") || (data47 === "active")) || (data47 === "waiting")) || (data47 === "decision")) || (data47 === "success")) || (data47 === "failure")) || (data47 === "neutral")) || (data47 === "external"))){const err108 = {instancePath:instancePath+"/states/" + i1+"/type",schemaPath:"#/properties/states/items/properties/type/enum",keyword:"enum",params:{allowedValues: schema98.properties.states.items.properties.type.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err108];}else {vErrors.push(err108);}errors++;}}if(data45.label !== undefined){let data48 = data45.label;if(typeof data48 === "string"){if(func3(data48) < 1){const err109 = {instancePath:instancePath+"/states/" + i1+"/label",schemaPath:"#/properties/states/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err109];}else {vErrors.push(err109);}errors++;}}else {const err110 = {instancePath:instancePath+"/states/" + i1+"/label",schemaPath:"#/properties/states/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err110];}else {vErrors.push(err110);}errors++;}}if(data45.sublabel !== undefined){if(typeof data45.sublabel !== "string"){const err111 = {instancePath:instancePath+"/states/" + i1+"/sublabel",schemaPath:"#/properties/states/items/properties/sublabel/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err111];}else {vErrors.push(err111);}errors++;}}if(data45.tag !== undefined){if(typeof data45.tag !== "string"){const err112 = {instancePath:instancePath+"/states/" + i1+"/tag",schemaPath:"#/properties/states/items/properties/tag/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err112];}else {vErrors.push(err112);}errors++;}}if(data45.step !== undefined){if(typeof data45.step !== "string"){const err113 = {instancePath:instancePath+"/states/" + i1+"/step",schemaPath:"#/properties/states/items/properties/step/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err113];}else {vErrors.push(err113);}errors++;}}if(data45.lane !== undefined){let data52 = data45.lane;if(typeof data52 === "string"){if(!pattern4.test(data52)){const err114 = {instancePath:instancePath+"/states/" + i1+"/lane",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err114];}else {vErrors.push(err114);}errors++;}}else {const err115 = {instancePath:instancePath+"/states/" + i1+"/lane",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err115];}else {vErrors.push(err115);}errors++;}}if(data45.col !== undefined){let data53 = data45.col;if(!(((typeof data53 == "number") && (!(data53 % 1) && !isNaN(data53))) && (isFinite(data53)))){const err116 = {instancePath:instancePath+"/states/" + i1+"/col",schemaPath:"#/properties/states/items/properties/col/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err116];}else {vErrors.push(err116);}errors++;}if((typeof data53 == "number") && (isFinite(data53))){if(data53 > 4 || isNaN(data53)){const err117 = {instancePath:instancePath+"/states/" + i1+"/col",schemaPath:"#/properties/states/items/properties/col/maximum",keyword:"maximum",params:{comparison: "<=", limit: 4},message:"must be <= 4"};if(vErrors === null){vErrors = [err117];}else {vErrors.push(err117);}errors++;}if(data53 < 0 || isNaN(data53)){const err118 = {instancePath:instancePath+"/states/" + i1+"/col",schemaPath:"#/properties/states/items/properties/col/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err118];}else {vErrors.push(err118);}errors++;}}}if(data45.width !== undefined){let data54 = data45.width;if((typeof data54 == "number") && (isFinite(data54))){if(data54 < 48 || isNaN(data54)){const err119 = {instancePath:instancePath+"/states/" + i1+"/width",schemaPath:"#/properties/states/items/properties/width/minimum",keyword:"minimum",params:{comparison: ">=", limit: 48},message:"must be >= 48"};if(vErrors === null){vErrors = [err119];}else {vErrors.push(err119);}errors++;}}else {const err120 = {instancePath:instancePath+"/states/" + i1+"/width",schemaPath:"#/properties/states/items/properties/width/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err120];}else {vErrors.push(err120);}errors++;}}if(data45.height !== undefined){let data55 = data45.height;if((typeof data55 == "number") && (isFinite(data55))){if(data55 < 36 || isNaN(data55)){const err121 = {instancePath:instancePath+"/states/" + i1+"/height",schemaPath:"#/properties/states/items/properties/height/minimum",keyword:"minimum",params:{comparison: ">=", limit: 36},message:"must be >= 36"};if(vErrors === null){vErrors = [err121];}else {vErrors.push(err121);}errors++;}}else {const err122 = {instancePath:instancePath+"/states/" + i1+"/height",schemaPath:"#/properties/states/items/properties/height/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err122];}else {vErrors.push(err122);}errors++;}}if(data45.yOffset !== undefined){let data56 = data45.yOffset;if(!((typeof data56 == "number") && (isFinite(data56)))){const err123 = {instancePath:instancePath+"/states/" + i1+"/yOffset",schemaPath:"#/properties/states/items/properties/yOffset/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err123];}else {vErrors.push(err123);}errors++;}}}else {const err124 = {instancePath:instancePath+"/states/" + i1,schemaPath:"#/properties/states/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err124];}else {vErrors.push(err124);}errors++;}}}else {const err125 = {instancePath:instancePath+"/states",schemaPath:"#/properties/states/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err125];}else {vErrors.push(err125);}errors++;}}if(data.transitions !== undefined){let data57 = data.transitions;if(Array.isArray(data57)){const len4 = data57.length;for(let i2=0; i2<len4; i2++){let data58 = data57[i2];if(data58 && typeof data58 == "object" && !Array.isArray(data58)){if(data58.from === undefined){const err126 = {instancePath:instancePath+"/transitions/" + i2,schemaPath:"#/properties/transitions/items/required",keyword:"required",params:{missingProperty: "from"},message:"must have required property '"+"from"+"'"};if(vErrors === null){vErrors = [err126];}else {vErrors.push(err126);}errors++;}if(data58.to === undefined){const err127 = {instancePath:instancePath+"/transitions/" + i2,schemaPath:"#/properties/transitions/items/required",keyword:"required",params:{missingProperty: "to"},message:"must have required property '"+"to"+"'"};if(vErrors === null){vErrors = [err127];}else {vErrors.push(err127);}errors++;}for(const key14 in data58){if(!(func1.call(schema98.properties.transitions.items.properties, key14))){const err128 = {instancePath:instancePath+"/transitions/" + i2,schemaPath:"#/properties/transitions/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key14},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err128];}else {vErrors.push(err128);}errors++;}}if(data58.id !== undefined){let data59 = data58.id;if(typeof data59 === "string"){if(!pattern4.test(data59)){const err129 = {instancePath:instancePath+"/transitions/" + i2+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err129];}else {vErrors.push(err129);}errors++;}}else {const err130 = {instancePath:instancePath+"/transitions/" + i2+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err130];}else {vErrors.push(err130);}errors++;}}if(data58.from !== undefined){let data60 = data58.from;if(typeof data60 === "string"){if(!pattern4.test(data60)){const err131 = {instancePath:instancePath+"/transitions/" + i2+"/from",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err131];}else {vErrors.push(err131);}errors++;}}else {const err132 = {instancePath:instancePath+"/transitions/" + i2+"/from",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err132];}else {vErrors.push(err132);}errors++;}}if(data58.to !== undefined){let data61 = data58.to;if(typeof data61 === "string"){if(!pattern4.test(data61)){const err133 = {instancePath:instancePath+"/transitions/" + i2+"/to",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err133];}else {vErrors.push(err133);}errors++;}}else {const err134 = {instancePath:instancePath+"/transitions/" + i2+"/to",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err134];}else {vErrors.push(err134);}errors++;}}if(data58.label !== undefined){if(typeof data58.label !== "string"){const err135 = {instancePath:instancePath+"/transitions/" + i2+"/label",schemaPath:"#/properties/transitions/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err135];}else {vErrors.push(err135);}errors++;}}if(data58.note !== undefined){if(typeof data58.note !== "string"){const err136 = {instancePath:instancePath+"/transitions/" + i2+"/note",schemaPath:"#/properties/transitions/items/properties/note/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err136];}else {vErrors.push(err136);}errors++;}}if(data58.variant !== undefined){let data64 = data58.variant;if(!((((data64 === "default") || (data64 === "emphasis")) || (data64 === "security")) || (data64 === "dashed"))){const err137 = {instancePath:instancePath+"/transitions/" + i2+"/variant",schemaPath:"common.schema.json#/$defs/variant/enum",keyword:"enum",params:{allowedValues: schema55.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err137];}else {vErrors.push(err137);}errors++;}}if(data58.route !== undefined){let data65 = data58.route;if(!(((((((data65 === "auto") || (data65 === "straight")) || (data65 === "drop")) || (data65 === "bottom-channel")) || (data65 === "top-channel")) || (data65 === "right-channel")) || (data65 === "left-channel"))){const err138 = {instancePath:instancePath+"/transitions/" + i2+"/route",schemaPath:"#/properties/transitions/items/properties/route/enum",keyword:"enum",params:{allowedValues: schema98.properties.transitions.items.properties.route.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err138];}else {vErrors.push(err138);}errors++;}}if(data58.fromSide !== undefined){let data66 = data58.fromSide;if(!((((data66 === "left") || (data66 === "right")) || (data66 === "top")) || (data66 === "bottom"))){const err139 = {instancePath:instancePath+"/transitions/" + i2+"/fromSide",schemaPath:"#/properties/transitions/items/properties/fromSide/enum",keyword:"enum",params:{allowedValues: schema98.properties.transitions.items.properties.fromSide.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err139];}else {vErrors.push(err139);}errors++;}}if(data58.toSide !== undefined){let data67 = data58.toSide;if(!((((data67 === "left") || (data67 === "right")) || (data67 === "top")) || (data67 === "bottom"))){const err140 = {instancePath:instancePath+"/transitions/" + i2+"/toSide",schemaPath:"#/properties/transitions/items/properties/toSide/enum",keyword:"enum",params:{allowedValues: schema98.properties.transitions.items.properties.toSide.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err140];}else {vErrors.push(err140);}errors++;}}if(data58.channelX !== undefined){let data68 = data58.channelX;if(!((typeof data68 == "number") && (isFinite(data68)))){const err141 = {instancePath:instancePath+"/transitions/" + i2+"/channelX",schemaPath:"#/properties/transitions/items/properties/channelX/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err141];}else {vErrors.push(err141);}errors++;}}if(data58.channelY !== undefined){let data69 = data58.channelY;if(!((typeof data69 == "number") && (isFinite(data69)))){const err142 = {instancePath:instancePath+"/transitions/" + i2+"/channelY",schemaPath:"#/properties/transitions/items/properties/channelY/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err142];}else {vErrors.push(err142);}errors++;}}if(data58.cornerRadius !== undefined){let data70 = data58.cornerRadius;if((typeof data70 == "number") && (isFinite(data70))){if(data70 < 0 || isNaN(data70)){const err143 = {instancePath:instancePath+"/transitions/" + i2+"/cornerRadius",schemaPath:"#/properties/transitions/items/properties/cornerRadius/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err143];}else {vErrors.push(err143);}errors++;}}else {const err144 = {instancePath:instancePath+"/transitions/" + i2+"/cornerRadius",schemaPath:"#/properties/transitions/items/properties/cornerRadius/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err144];}else {vErrors.push(err144);}errors++;}}if(data58.labelAt !== undefined){let data71 = data58.labelAt;if(Array.isArray(data71)){if(data71.length > 2){const err145 = {instancePath:instancePath+"/transitions/" + i2+"/labelAt",schemaPath:"common.schema.json#/$defs/point/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err145];}else {vErrors.push(err145);}errors++;}if(data71.length < 2){const err146 = {instancePath:instancePath+"/transitions/" + i2+"/labelAt",schemaPath:"common.schema.json#/$defs/point/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err146];}else {vErrors.push(err146);}errors++;}const len5 = data71.length;if(len5 > 0){let data72 = data71[0];if(!((typeof data72 == "number") && (isFinite(data72)))){const err147 = {instancePath:instancePath+"/transitions/" + i2+"/labelAt/0",schemaPath:"common.schema.json#/$defs/point/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err147];}else {vErrors.push(err147);}errors++;}}if(len5 > 1){let data73 = data71[1];if(!((typeof data73 == "number") && (isFinite(data73)))){const err148 = {instancePath:instancePath+"/transitions/" + i2+"/labelAt/1",schemaPath:"common.schema.json#/$defs/point/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err148];}else {vErrors.push(err148);}errors++;}}const len6 = data71.length;if(!(len6 <= 2)){const err149 = {instancePath:instancePath+"/transitions/" + i2+"/labelAt",schemaPath:"common.schema.json#/$defs/point/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err149];}else {vErrors.push(err149);}errors++;}}else {const err150 = {instancePath:instancePath+"/transitions/" + i2+"/labelAt",schemaPath:"common.schema.json#/$defs/point/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err150];}else {vErrors.push(err150);}errors++;}}if(data58.labelDx !== undefined){let data74 = data58.labelDx;if(!((typeof data74 == "number") && (isFinite(data74)))){const err151 = {instancePath:instancePath+"/transitions/" + i2+"/labelDx",schemaPath:"#/properties/transitions/items/properties/labelDx/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err151];}else {vErrors.push(err151);}errors++;}}if(data58.labelDy !== undefined){let data75 = data58.labelDy;if(!((typeof data75 == "number") && (isFinite(data75)))){const err152 = {instancePath:instancePath+"/transitions/" + i2+"/labelDy",schemaPath:"#/properties/transitions/items/properties/labelDy/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err152];}else {vErrors.push(err152);}errors++;}}if(data58.labelSegment !== undefined){let data76 = data58.labelSegment;if(!(((typeof data76 == "number") && (!(data76 % 1) && !isNaN(data76))) && (isFinite(data76)))){const err153 = {instancePath:instancePath+"/transitions/" + i2+"/labelSegment",schemaPath:"#/properties/transitions/items/properties/labelSegment/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err153];}else {vErrors.push(err153);}errors++;}if((typeof data76 == "number") && (isFinite(data76))){if(data76 < 0 || isNaN(data76)){const err154 = {instancePath:instancePath+"/transitions/" + i2+"/labelSegment",schemaPath:"#/properties/transitions/items/properties/labelSegment/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err154];}else {vErrors.push(err154);}errors++;}}}if(data58.via !== undefined){let data77 = data58.via;if(Array.isArray(data77)){const len7 = data77.length;for(let i3=0; i3<len7; i3++){let data78 = data77[i3];if(Array.isArray(data78)){if(data78.length > 2){const err155 = {instancePath:instancePath+"/transitions/" + i2+"/via/" + i3,schemaPath:"common.schema.json#/$defs/point/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err155];}else {vErrors.push(err155);}errors++;}if(data78.length < 2){const err156 = {instancePath:instancePath+"/transitions/" + i2+"/via/" + i3,schemaPath:"common.schema.json#/$defs/point/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err156];}else {vErrors.push(err156);}errors++;}const len8 = data78.length;if(len8 > 0){let data79 = data78[0];if(!((typeof data79 == "number") && (isFinite(data79)))){const err157 = {instancePath:instancePath+"/transitions/" + i2+"/via/" + i3+"/0",schemaPath:"common.schema.json#/$defs/point/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err157];}else {vErrors.push(err157);}errors++;}}if(len8 > 1){let data80 = data78[1];if(!((typeof data80 == "number") && (isFinite(data80)))){const err158 = {instancePath:instancePath+"/transitions/" + i2+"/via/" + i3+"/1",schemaPath:"common.schema.json#/$defs/point/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err158];}else {vErrors.push(err158);}errors++;}}const len9 = data78.length;if(!(len9 <= 2)){const err159 = {instancePath:instancePath+"/transitions/" + i2+"/via/" + i3,schemaPath:"common.schema.json#/$defs/point/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err159];}else {vErrors.push(err159);}errors++;}}else {const err160 = {instancePath:instancePath+"/transitions/" + i2+"/via/" + i3,schemaPath:"common.schema.json#/$defs/point/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err160];}else {vErrors.push(err160);}errors++;}}}else {const err161 = {instancePath:instancePath+"/transitions/" + i2+"/via",schemaPath:"#/properties/transitions/items/properties/via/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err161];}else {vErrors.push(err161);}errors++;}}if(data58.width !== undefined){let data81 = data58.width;if((typeof data81 == "number") && (isFinite(data81))){if(data81 < 0.5 || isNaN(data81)){const err162 = {instancePath:instancePath+"/transitions/" + i2+"/width",schemaPath:"#/properties/transitions/items/properties/width/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0.5},message:"must be >= 0.5"};if(vErrors === null){vErrors = [err162];}else {vErrors.push(err162);}errors++;}}else {const err163 = {instancePath:instancePath+"/transitions/" + i2+"/width",schemaPath:"#/properties/transitions/items/properties/width/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err163];}else {vErrors.push(err163);}errors++;}}}else {const err164 = {instancePath:instancePath+"/transitions/" + i2,schemaPath:"#/properties/transitions/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err164];}else {vErrors.push(err164);}errors++;}}}else {const err165 = {instancePath:instancePath+"/transitions",schemaPath:"#/properties/transitions/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err165];}else {vErrors.push(err165);}errors++;}}if(data.cards !== undefined){let data82 = data.cards;if(Array.isArray(data82)){const len10 = data82.length;for(let i4=0; i4<len10; i4++){let data83 = data82[i4];if(data83 && typeof data83 == "object" && !Array.isArray(data83)){if(data83.dot === undefined){const err166 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "dot"},message:"must have required property '"+"dot"+"'"};if(vErrors === null){vErrors = [err166];}else {vErrors.push(err166);}errors++;}if(data83.title === undefined){const err167 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "title"},message:"must have required property '"+"title"+"'"};if(vErrors === null){vErrors = [err167];}else {vErrors.push(err167);}errors++;}if(data83.items === undefined){const err168 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "items"},message:"must have required property '"+"items"+"'"};if(vErrors === null){vErrors = [err168];}else {vErrors.push(err168);}errors++;}for(const key15 in data83){if(!(((key15 === "dot") || (key15 === "title")) || (key15 === "items"))){const err169 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key15},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err169];}else {vErrors.push(err169);}errors++;}}if(data83.dot !== undefined){let data84 = data83.dot;if(!(((((((data84 === "cyan") || (data84 === "emerald")) || (data84 === "violet")) || (data84 === "amber")) || (data84 === "rose")) || (data84 === "orange")) || (data84 === "slate"))){const err170 = {instancePath:instancePath+"/cards/" + i4+"/dot",schemaPath:"common.schema.json#/$defs/cards/items/properties/dot/enum",keyword:"enum",params:{allowedValues: schema60.items.properties.dot.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err170];}else {vErrors.push(err170);}errors++;}}if(data83.title !== undefined){let data85 = data83.title;if(typeof data85 === "string"){if(func3(data85) < 1){const err171 = {instancePath:instancePath+"/cards/" + i4+"/title",schemaPath:"common.schema.json#/$defs/cards/items/properties/title/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err171];}else {vErrors.push(err171);}errors++;}}else {const err172 = {instancePath:instancePath+"/cards/" + i4+"/title",schemaPath:"common.schema.json#/$defs/cards/items/properties/title/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err172];}else {vErrors.push(err172);}errors++;}}if(data83.items !== undefined){let data86 = data83.items;if(Array.isArray(data86)){const len11 = data86.length;for(let i5=0; i5<len11; i5++){if(typeof data86[i5] !== "string"){const err173 = {instancePath:instancePath+"/cards/" + i4+"/items/" + i5,schemaPath:"common.schema.json#/$defs/cards/items/properties/items/items/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err173];}else {vErrors.push(err173);}errors++;}}}else {const err174 = {instancePath:instancePath+"/cards/" + i4+"/items",schemaPath:"common.schema.json#/$defs/cards/items/properties/items/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err174];}else {vErrors.push(err174);}errors++;}}}else {const err175 = {instancePath:instancePath+"/cards/" + i4,schemaPath:"common.schema.json#/$defs/cards/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err175];}else {vErrors.push(err175);}errors++;}}}else {const err176 = {instancePath:instancePath+"/cards",schemaPath:"common.schema.json#/$defs/cards/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err176];}else {vErrors.push(err176);}errors++;}}}else {const err177 = {instancePath,schemaPath:"#/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err177];}else {vErrors.push(err177);}errors++;}validate30.errors = vErrors;return errors === 0;}validate30.evaluated = {"props":true,"dynamicProps":false,"dynamicItems":false};export const architecture = validate33;const schema121 = {"$schema":"https://json-schema.org/draft/2020-12/schema","$id":"https://github.com/tt-a1i/archify/schemas/architecture.schema.json","title":"Archify Architecture Diagram","type":"object","additionalProperties":false,"required":["schema_version","diagram_type","meta","components"],"properties":{"schema_version":{"const":1},"diagram_type":{"const":"architecture"},"meta":{"type":"object","additionalProperties":false,"required":["title"],"properties":{"title":{"type":"string","minLength":1},"subtitle":{"type":"string"},"output":{"type":"string"},"animation":{"enum":["trace","none"]},"visual_preset":{"enum":["classic","signal-flow","blueprint","editorial"]},"quality_profile":{"enum":["standard","showcase"]},"engineering_profile":{"enum":["deployment-ownership"]},"repository":{"type":"object","additionalProperties":false,"required":["url","revision"],"properties":{"url":{"type":"string","pattern":"^https://github\\.com/[A-Za-z0-9_.-]+/[A-Za-z0-9_.-]+(?:\\.git)?/?$"},"revision":{"type":"string","pattern":"^[a-fA-F0-9]{40}$"}}},"views":{"$ref":"common.schema.json#/$defs/guidedViews"},"legend":{"type":"object","additionalProperties":false,"properties":{"mode":{"$ref":"common.schema.json#/$defs/legendMode"},"entries":{"type":"object","additionalProperties":false,"properties":{"frontend":{"$ref":"common.schema.json#/$defs/legendEntry"},"backend":{"$ref":"common.schema.json#/$defs/legendEntry"},"database":{"$ref":"common.schema.json#/$defs/legendEntry"},"cloud":{"$ref":"common.schema.json#/$defs/legendEntry"},"security":{"$ref":"common.schema.json#/$defs/legendEntry"},"messagebus":{"$ref":"common.schema.json#/$defs/legendEntry"},"external":{"$ref":"common.schema.json#/$defs/legendEntry"}}}}},"viewBox":{"type":"array","prefixItems":[{"type":"number","minimum":320},{"type":"number","minimum":240}],"items":false,"minItems":2,"maxItems":2}}},"layout":{"type":"object","additionalProperties":false,"required":["mode"],"properties":{"mode":{"enum":["grid"]},"origin":{"$ref":"common.schema.json#/$defs/point"},"cols":{"type":"integer","minimum":1,"maximum":12},"gapX":{"type":"number","minimum":0},"gapY":{"type":"number","minimum":0},"cellW":{"type":"number","minimum":40},"cellH":{"type":"number","minimum":24}}},"components":{"type":"array","minItems":1,"items":{"type":"object","additionalProperties":false,"required":["id","type","label"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"type":{"$ref":"common.schema.json#/$defs/componentType"},"label":{"type":"string","minLength":1},"sublabel":{"type":"string"},"tag":{"type":"string"},"sources":{"type":"array","minItems":1,"maxItems":3,"items":{"type":"object","additionalProperties":false,"required":["path"],"properties":{"path":{"type":"string","minLength":1,"maxLength":240},"line":{"type":"integer","minimum":1},"end_line":{"type":"integer","minimum":1},"label":{"type":"string","minLength":1,"maxLength":48}}}},"row":{"type":"integer","minimum":0},"col":{"type":"integer","minimum":0},"pos":{"$ref":"common.schema.json#/$defs/point"},"size":{"type":"array","prefixItems":[{"type":"number","exclusiveMinimum":0},{"type":"number","exclusiveMinimum":0}],"items":false,"minItems":2,"maxItems":2}}}},"boundaries":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["kind","label","wraps"],"properties":{"kind":{"enum":["region","security-group"]},"label":{"type":"string","minLength":1},"wraps":{"type":"array","minItems":1,"items":{"$ref":"common.schema.json#/$defs/id"}},"pad":{"type":"number","minimum":0}}}},"connections":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["from","to"],"properties":{"id":{"$ref":"common.schema.json#/$defs/id"},"from":{"$ref":"common.schema.json#/$defs/id"},"to":{"$ref":"common.schema.json#/$defs/id"},"label":{"type":"string"},"variant":{"$ref":"common.schema.json#/$defs/variant"},"fromSide":{"enum":["left","right","top","bottom"]},"toSide":{"enum":["left","right","top","bottom"]},"route":{"enum":["auto","straight","orthogonal-h","orthogonal-v"]},"via":{"type":"array","items":{"$ref":"common.schema.json#/$defs/point"}},"labelAt":{"$ref":"common.schema.json#/$defs/point"},"labelDx":{"type":"number"},"labelDy":{"type":"number"},"labelSegment":{"type":"integer","minimum":0},"width":{"type":"number","minimum":0.5}}}},"cards":{"$ref":"common.schema.json#/$defs/cards"}}};const pattern37 = new RegExp("^https://github\\.com/[A-Za-z0-9_.-]+/[A-Za-z0-9_.-]+(?:\\.git)?/?$", "u");const pattern38 = new RegExp("^[a-fA-F0-9]{40}$", "u");function validate34(data, {instancePath="", parentData, parentDataProperty, rootData=data, dynamicAnchors={}}={}){let vErrors = null;let errors = 0;const evaluated0 = validate34.evaluated;if(evaluated0.dynamicProps){evaluated0.props = undefined;}if(evaluated0.dynamicItems){evaluated0.items = undefined;}if(Array.isArray(data)){if(data.length > 5){const err0 = {instancePath,schemaPath:"#/maxItems",keyword:"maxItems",params:{limit: 5},message:"must NOT have more than 5 items"};if(vErrors === null){vErrors = [err0];}else {vErrors.push(err0);}errors++;}const len0 = data.length;for(let i0=0; i0<len0; i0++){let data0 = data[i0];if(data0 && typeof data0 == "object" && !Array.isArray(data0)){if(data0.id === undefined){const err1 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err1];}else {vErrors.push(err1);}errors++;}if(data0.label === undefined){const err2 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err2];}else {vErrors.push(err2);}errors++;}if(data0.focus === undefined){const err3 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/required",keyword:"required",params:{missingProperty: "focus"},message:"must have required property '"+"focus"+"'"};if(vErrors === null){vErrors = [err3];}else {vErrors.push(err3);}errors++;}for(const key0 in data0){if(!((((key0 === "id") || (key0 === "label")) || (key0 === "focus")) || (key0 === "note"))){const err4 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key0},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err4];}else {vErrors.push(err4);}errors++;}}if(data0.id !== undefined){let data1 = data0.id;if(typeof data1 === "string"){if(!pattern4.test(data1)){const err5 = {instancePath:instancePath+"/" + i0+"/id",schemaPath:"#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err5];}else {vErrors.push(err5);}errors++;}}else {const err6 = {instancePath:instancePath+"/" + i0+"/id",schemaPath:"#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err6];}else {vErrors.push(err6);}errors++;}}if(data0.label !== undefined){let data2 = data0.label;if(typeof data2 === "string"){if(func3(data2) > 48){const err7 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/maxLength",keyword:"maxLength",params:{limit: 48},message:"must NOT have more than 48 characters"};if(vErrors === null){vErrors = [err7];}else {vErrors.push(err7);}errors++;}if(func3(data2) < 1){const err8 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err8];}else {vErrors.push(err8);}errors++;}}else {const err9 = {instancePath:instancePath+"/" + i0+"/label",schemaPath:"#/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err9];}else {vErrors.push(err9);}errors++;}}if(data0.focus !== undefined){let data3 = data0.focus;if(Array.isArray(data3)){if(data3.length < 1){const err10 = {instancePath:instancePath+"/" + i0+"/focus",schemaPath:"#/items/properties/focus/minItems",keyword:"minItems",params:{limit: 1},message:"must NOT have fewer than 1 items"};if(vErrors === null){vErrors = [err10];}else {vErrors.push(err10);}errors++;}const len1 = data3.length;for(let i1=0; i1<len1; i1++){let data4 = data3[i1];if(typeof data4 === "string"){if(!pattern4.test(data4)){const err11 = {instancePath:instancePath+"/" + i0+"/focus/" + i1,schemaPath:"#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err11];}else {vErrors.push(err11);}errors++;}}else {const err12 = {instancePath:instancePath+"/" + i0+"/focus/" + i1,schemaPath:"#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err12];}else {vErrors.push(err12);}errors++;}}}else {const err13 = {instancePath:instancePath+"/" + i0+"/focus",schemaPath:"#/items/properties/focus/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err13];}else {vErrors.push(err13);}errors++;}}if(data0.note !== undefined){let data5 = data0.note;if(typeof data5 === "string"){if(func3(data5) > 140){const err14 = {instancePath:instancePath+"/" + i0+"/note",schemaPath:"#/items/properties/note/maxLength",keyword:"maxLength",params:{limit: 140},message:"must NOT have more than 140 characters"};if(vErrors === null){vErrors = [err14];}else {vErrors.push(err14);}errors++;}}else {const err15 = {instancePath:instancePath+"/" + i0+"/note",schemaPath:"#/items/properties/note/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err15];}else {vErrors.push(err15);}errors++;}}}else {const err16 = {instancePath:instancePath+"/" + i0,schemaPath:"#/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err16];}else {vErrors.push(err16);}errors++;}}}else {const err17 = {instancePath,schemaPath:"#/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err17];}else {vErrors.push(err17);}errors++;}validate34.errors = vErrors;return errors === 0;}validate34.evaluated = {"items":true,"dynamicProps":false,"dynamicItems":false};function validate33(data, {instancePath="", parentData, parentDataProperty, rootData=data, dynamicAnchors={}}={}){/*# sourceURL="https://github.com/tt-a1i/archify/schemas/architecture.schema.json" */;let vErrors = null;let errors = 0;const evaluated0 = validate33.evaluated;if(evaluated0.dynamicProps){evaluated0.props = undefined;}if(evaluated0.dynamicItems){evaluated0.items = undefined;}if(data && typeof data == "object" && !Array.isArray(data)){if(data.schema_version === undefined){const err0 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "schema_version"},message:"must have required property '"+"schema_version"+"'"};if(vErrors === null){vErrors = [err0];}else {vErrors.push(err0);}errors++;}if(data.diagram_type === undefined){const err1 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "diagram_type"},message:"must have required property '"+"diagram_type"+"'"};if(vErrors === null){vErrors = [err1];}else {vErrors.push(err1);}errors++;}if(data.meta === undefined){const err2 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "meta"},message:"must have required property '"+"meta"+"'"};if(vErrors === null){vErrors = [err2];}else {vErrors.push(err2);}errors++;}if(data.components === undefined){const err3 = {instancePath,schemaPath:"#/required",keyword:"required",params:{missingProperty: "components"},message:"must have required property '"+"components"+"'"};if(vErrors === null){vErrors = [err3];}else {vErrors.push(err3);}errors++;}for(const key0 in data){if(!((((((((key0 === "schema_version") || (key0 === "diagram_type")) || (key0 === "meta")) || (key0 === "layout")) || (key0 === "components")) || (key0 === "boundaries")) || (key0 === "connections")) || (key0 === "cards"))){const err4 = {instancePath,schemaPath:"#/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key0},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err4];}else {vErrors.push(err4);}errors++;}}if(data.schema_version !== undefined){if(1 !== data.schema_version){const err5 = {instancePath:instancePath+"/schema_version",schemaPath:"#/properties/schema_version/const",keyword:"const",params:{allowedValue: 1},message:"must be equal to constant"};if(vErrors === null){vErrors = [err5];}else {vErrors.push(err5);}errors++;}}if(data.diagram_type !== undefined){if("architecture" !== data.diagram_type){const err6 = {instancePath:instancePath+"/diagram_type",schemaPath:"#/properties/diagram_type/const",keyword:"const",params:{allowedValue: "architecture"},message:"must be equal to constant"};if(vErrors === null){vErrors = [err6];}else {vErrors.push(err6);}errors++;}}if(data.meta !== undefined){let data2 = data.meta;if(data2 && typeof data2 == "object" && !Array.isArray(data2)){if(data2.title === undefined){const err7 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/required",keyword:"required",params:{missingProperty: "title"},message:"must have required property '"+"title"+"'"};if(vErrors === null){vErrors = [err7];}else {vErrors.push(err7);}errors++;}for(const key1 in data2){if(!(func1.call(schema121.properties.meta.properties, key1))){const err8 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key1},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err8];}else {vErrors.push(err8);}errors++;}}if(data2.title !== undefined){let data3 = data2.title;if(typeof data3 === "string"){if(func3(data3) < 1){const err9 = {instancePath:instancePath+"/meta/title",schemaPath:"#/properties/meta/properties/title/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err9];}else {vErrors.push(err9);}errors++;}}else {const err10 = {instancePath:instancePath+"/meta/title",schemaPath:"#/properties/meta/properties/title/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err10];}else {vErrors.push(err10);}errors++;}}if(data2.subtitle !== undefined){if(typeof data2.subtitle !== "string"){const err11 = {instancePath:instancePath+"/meta/subtitle",schemaPath:"#/properties/meta/properties/subtitle/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err11];}else {vErrors.push(err11);}errors++;}}if(data2.output !== undefined){if(typeof data2.output !== "string"){const err12 = {instancePath:instancePath+"/meta/output",schemaPath:"#/properties/meta/properties/output/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err12];}else {vErrors.push(err12);}errors++;}}if(data2.animation !== undefined){let data6 = data2.animation;if(!((data6 === "trace") || (data6 === "none"))){const err13 = {instancePath:instancePath+"/meta/animation",schemaPath:"#/properties/meta/properties/animation/enum",keyword:"enum",params:{allowedValues: schema121.properties.meta.properties.animation.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err13];}else {vErrors.push(err13);}errors++;}}if(data2.visual_preset !== undefined){let data7 = data2.visual_preset;if(!((((data7 === "classic") || (data7 === "signal-flow")) || (data7 === "blueprint")) || (data7 === "editorial"))){const err14 = {instancePath:instancePath+"/meta/visual_preset",schemaPath:"#/properties/meta/properties/visual_preset/enum",keyword:"enum",params:{allowedValues: schema121.properties.meta.properties.visual_preset.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err14];}else {vErrors.push(err14);}errors++;}}if(data2.quality_profile !== undefined){let data8 = data2.quality_profile;if(!((data8 === "standard") || (data8 === "showcase"))){const err15 = {instancePath:instancePath+"/meta/quality_profile",schemaPath:"#/properties/meta/properties/quality_profile/enum",keyword:"enum",params:{allowedValues: schema121.properties.meta.properties.quality_profile.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err15];}else {vErrors.push(err15);}errors++;}}if(data2.engineering_profile !== undefined){if(!(data2.engineering_profile === "deployment-ownership")){const err16 = {instancePath:instancePath+"/meta/engineering_profile",schemaPath:"#/properties/meta/properties/engineering_profile/enum",keyword:"enum",params:{allowedValues: schema121.properties.meta.properties.engineering_profile.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err16];}else {vErrors.push(err16);}errors++;}}if(data2.repository !== undefined){let data10 = data2.repository;if(data10 && typeof data10 == "object" && !Array.isArray(data10)){if(data10.url === undefined){const err17 = {instancePath:instancePath+"/meta/repository",schemaPath:"#/properties/meta/properties/repository/required",keyword:"required",params:{missingProperty: "url"},message:"must have required property '"+"url"+"'"};if(vErrors === null){vErrors = [err17];}else {vErrors.push(err17);}errors++;}if(data10.revision === undefined){const err18 = {instancePath:instancePath+"/meta/repository",schemaPath:"#/properties/meta/properties/repository/required",keyword:"required",params:{missingProperty: "revision"},message:"must have required property '"+"revision"+"'"};if(vErrors === null){vErrors = [err18];}else {vErrors.push(err18);}errors++;}for(const key2 in data10){if(!((key2 === "url") || (key2 === "revision"))){const err19 = {instancePath:instancePath+"/meta/repository",schemaPath:"#/properties/meta/properties/repository/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key2},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err19];}else {vErrors.push(err19);}errors++;}}if(data10.url !== undefined){let data11 = data10.url;if(typeof data11 === "string"){if(!pattern37.test(data11)){const err20 = {instancePath:instancePath+"/meta/repository/url",schemaPath:"#/properties/meta/properties/repository/properties/url/pattern",keyword:"pattern",params:{pattern: "^https://github\\.com/[A-Za-z0-9_.-]+/[A-Za-z0-9_.-]+(?:\\.git)?/?$"},message:"must match pattern \""+"^https://github\\.com/[A-Za-z0-9_.-]+/[A-Za-z0-9_.-]+(?:\\.git)?/?$"+"\""};if(vErrors === null){vErrors = [err20];}else {vErrors.push(err20);}errors++;}}else {const err21 = {instancePath:instancePath+"/meta/repository/url",schemaPath:"#/properties/meta/properties/repository/properties/url/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err21];}else {vErrors.push(err21);}errors++;}}if(data10.revision !== undefined){let data12 = data10.revision;if(typeof data12 === "string"){if(!pattern38.test(data12)){const err22 = {instancePath:instancePath+"/meta/repository/revision",schemaPath:"#/properties/meta/properties/repository/properties/revision/pattern",keyword:"pattern",params:{pattern: "^[a-fA-F0-9]{40}$"},message:"must match pattern \""+"^[a-fA-F0-9]{40}$"+"\""};if(vErrors === null){vErrors = [err22];}else {vErrors.push(err22);}errors++;}}else {const err23 = {instancePath:instancePath+"/meta/repository/revision",schemaPath:"#/properties/meta/properties/repository/properties/revision/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err23];}else {vErrors.push(err23);}errors++;}}}else {const err24 = {instancePath:instancePath+"/meta/repository",schemaPath:"#/properties/meta/properties/repository/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err24];}else {vErrors.push(err24);}errors++;}}if(data2.views !== undefined){if(!(validate34(data2.views, {instancePath:instancePath+"/meta/views",parentData:data2,parentDataProperty:"views",rootData,dynamicAnchors}))){vErrors = vErrors === null ? validate34.errors : vErrors.concat(validate34.errors);errors = vErrors.length;}}if(data2.legend !== undefined){let data14 = data2.legend;if(data14 && typeof data14 == "object" && !Array.isArray(data14)){for(const key3 in data14){if(!((key3 === "mode") || (key3 === "entries"))){const err25 = {instancePath:instancePath+"/meta/legend",schemaPath:"#/properties/meta/properties/legend/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key3},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err25];}else {vErrors.push(err25);}errors++;}}if(data14.mode !== undefined){let data15 = data14.mode;if(!(((data15 === "auto") || (data15 === "all")) || (data15 === "hidden"))){const err26 = {instancePath:instancePath+"/meta/legend/mode",schemaPath:"common.schema.json#/$defs/legendMode/enum",keyword:"enum",params:{allowedValues: schema36.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err26];}else {vErrors.push(err26);}errors++;}}if(data14.entries !== undefined){let data16 = data14.entries;if(data16 && typeof data16 == "object" && !Array.isArray(data16)){for(const key4 in data16){if(!(((((((key4 === "frontend") || (key4 === "backend")) || (key4 === "database")) || (key4 === "cloud")) || (key4 === "security")) || (key4 === "messagebus")) || (key4 === "external"))){const err27 = {instancePath:instancePath+"/meta/legend/entries",schemaPath:"#/properties/meta/properties/legend/properties/entries/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key4},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err27];}else {vErrors.push(err27);}errors++;}}if(data16.frontend !== undefined){let data17 = data16.frontend;if(data17 && typeof data17 == "object" && !Array.isArray(data17)){if(Object.keys(data17).length < 1){const err28 = {instancePath:instancePath+"/meta/legend/entries/frontend",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err28];}else {vErrors.push(err28);}errors++;}for(const key5 in data17){if(!((key5 === "label") || (key5 === "visible"))){const err29 = {instancePath:instancePath+"/meta/legend/entries/frontend",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key5},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err29];}else {vErrors.push(err29);}errors++;}}if(data17.label !== undefined){let data18 = data17.label;if(typeof data18 === "string"){if(func3(data18) > 80){const err30 = {instancePath:instancePath+"/meta/legend/entries/frontend/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err30];}else {vErrors.push(err30);}errors++;}if(func3(data18) < 1){const err31 = {instancePath:instancePath+"/meta/legend/entries/frontend/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err31];}else {vErrors.push(err31);}errors++;}}else {const err32 = {instancePath:instancePath+"/meta/legend/entries/frontend/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err32];}else {vErrors.push(err32);}errors++;}}if(data17.visible !== undefined){if(typeof data17.visible !== "boolean"){const err33 = {instancePath:instancePath+"/meta/legend/entries/frontend/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err33];}else {vErrors.push(err33);}errors++;}}}else {const err34 = {instancePath:instancePath+"/meta/legend/entries/frontend",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err34];}else {vErrors.push(err34);}errors++;}}if(data16.backend !== undefined){let data20 = data16.backend;if(data20 && typeof data20 == "object" && !Array.isArray(data20)){if(Object.keys(data20).length < 1){const err35 = {instancePath:instancePath+"/meta/legend/entries/backend",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err35];}else {vErrors.push(err35);}errors++;}for(const key6 in data20){if(!((key6 === "label") || (key6 === "visible"))){const err36 = {instancePath:instancePath+"/meta/legend/entries/backend",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key6},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err36];}else {vErrors.push(err36);}errors++;}}if(data20.label !== undefined){let data21 = data20.label;if(typeof data21 === "string"){if(func3(data21) > 80){const err37 = {instancePath:instancePath+"/meta/legend/entries/backend/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err37];}else {vErrors.push(err37);}errors++;}if(func3(data21) < 1){const err38 = {instancePath:instancePath+"/meta/legend/entries/backend/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err38];}else {vErrors.push(err38);}errors++;}}else {const err39 = {instancePath:instancePath+"/meta/legend/entries/backend/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err39];}else {vErrors.push(err39);}errors++;}}if(data20.visible !== undefined){if(typeof data20.visible !== "boolean"){const err40 = {instancePath:instancePath+"/meta/legend/entries/backend/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err40];}else {vErrors.push(err40);}errors++;}}}else {const err41 = {instancePath:instancePath+"/meta/legend/entries/backend",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err41];}else {vErrors.push(err41);}errors++;}}if(data16.database !== undefined){let data23 = data16.database;if(data23 && typeof data23 == "object" && !Array.isArray(data23)){if(Object.keys(data23).length < 1){const err42 = {instancePath:instancePath+"/meta/legend/entries/database",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err42];}else {vErrors.push(err42);}errors++;}for(const key7 in data23){if(!((key7 === "label") || (key7 === "visible"))){const err43 = {instancePath:instancePath+"/meta/legend/entries/database",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key7},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err43];}else {vErrors.push(err43);}errors++;}}if(data23.label !== undefined){let data24 = data23.label;if(typeof data24 === "string"){if(func3(data24) > 80){const err44 = {instancePath:instancePath+"/meta/legend/entries/database/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err44];}else {vErrors.push(err44);}errors++;}if(func3(data24) < 1){const err45 = {instancePath:instancePath+"/meta/legend/entries/database/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err45];}else {vErrors.push(err45);}errors++;}}else {const err46 = {instancePath:instancePath+"/meta/legend/entries/database/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err46];}else {vErrors.push(err46);}errors++;}}if(data23.visible !== undefined){if(typeof data23.visible !== "boolean"){const err47 = {instancePath:instancePath+"/meta/legend/entries/database/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err47];}else {vErrors.push(err47);}errors++;}}}else {const err48 = {instancePath:instancePath+"/meta/legend/entries/database",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err48];}else {vErrors.push(err48);}errors++;}}if(data16.cloud !== undefined){let data26 = data16.cloud;if(data26 && typeof data26 == "object" && !Array.isArray(data26)){if(Object.keys(data26).length < 1){const err49 = {instancePath:instancePath+"/meta/legend/entries/cloud",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err49];}else {vErrors.push(err49);}errors++;}for(const key8 in data26){if(!((key8 === "label") || (key8 === "visible"))){const err50 = {instancePath:instancePath+"/meta/legend/entries/cloud",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key8},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err50];}else {vErrors.push(err50);}errors++;}}if(data26.label !== undefined){let data27 = data26.label;if(typeof data27 === "string"){if(func3(data27) > 80){const err51 = {instancePath:instancePath+"/meta/legend/entries/cloud/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err51];}else {vErrors.push(err51);}errors++;}if(func3(data27) < 1){const err52 = {instancePath:instancePath+"/meta/legend/entries/cloud/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err52];}else {vErrors.push(err52);}errors++;}}else {const err53 = {instancePath:instancePath+"/meta/legend/entries/cloud/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err53];}else {vErrors.push(err53);}errors++;}}if(data26.visible !== undefined){if(typeof data26.visible !== "boolean"){const err54 = {instancePath:instancePath+"/meta/legend/entries/cloud/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err54];}else {vErrors.push(err54);}errors++;}}}else {const err55 = {instancePath:instancePath+"/meta/legend/entries/cloud",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err55];}else {vErrors.push(err55);}errors++;}}if(data16.security !== undefined){let data29 = data16.security;if(data29 && typeof data29 == "object" && !Array.isArray(data29)){if(Object.keys(data29).length < 1){const err56 = {instancePath:instancePath+"/meta/legend/entries/security",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err56];}else {vErrors.push(err56);}errors++;}for(const key9 in data29){if(!((key9 === "label") || (key9 === "visible"))){const err57 = {instancePath:instancePath+"/meta/legend/entries/security",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key9},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err57];}else {vErrors.push(err57);}errors++;}}if(data29.label !== undefined){let data30 = data29.label;if(typeof data30 === "string"){if(func3(data30) > 80){const err58 = {instancePath:instancePath+"/meta/legend/entries/security/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err58];}else {vErrors.push(err58);}errors++;}if(func3(data30) < 1){const err59 = {instancePath:instancePath+"/meta/legend/entries/security/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err59];}else {vErrors.push(err59);}errors++;}}else {const err60 = {instancePath:instancePath+"/meta/legend/entries/security/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err60];}else {vErrors.push(err60);}errors++;}}if(data29.visible !== undefined){if(typeof data29.visible !== "boolean"){const err61 = {instancePath:instancePath+"/meta/legend/entries/security/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err61];}else {vErrors.push(err61);}errors++;}}}else {const err62 = {instancePath:instancePath+"/meta/legend/entries/security",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err62];}else {vErrors.push(err62);}errors++;}}if(data16.messagebus !== undefined){let data32 = data16.messagebus;if(data32 && typeof data32 == "object" && !Array.isArray(data32)){if(Object.keys(data32).length < 1){const err63 = {instancePath:instancePath+"/meta/legend/entries/messagebus",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err63];}else {vErrors.push(err63);}errors++;}for(const key10 in data32){if(!((key10 === "label") || (key10 === "visible"))){const err64 = {instancePath:instancePath+"/meta/legend/entries/messagebus",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key10},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err64];}else {vErrors.push(err64);}errors++;}}if(data32.label !== undefined){let data33 = data32.label;if(typeof data33 === "string"){if(func3(data33) > 80){const err65 = {instancePath:instancePath+"/meta/legend/entries/messagebus/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err65];}else {vErrors.push(err65);}errors++;}if(func3(data33) < 1){const err66 = {instancePath:instancePath+"/meta/legend/entries/messagebus/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err66];}else {vErrors.push(err66);}errors++;}}else {const err67 = {instancePath:instancePath+"/meta/legend/entries/messagebus/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err67];}else {vErrors.push(err67);}errors++;}}if(data32.visible !== undefined){if(typeof data32.visible !== "boolean"){const err68 = {instancePath:instancePath+"/meta/legend/entries/messagebus/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err68];}else {vErrors.push(err68);}errors++;}}}else {const err69 = {instancePath:instancePath+"/meta/legend/entries/messagebus",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err69];}else {vErrors.push(err69);}errors++;}}if(data16.external !== undefined){let data35 = data16.external;if(data35 && typeof data35 == "object" && !Array.isArray(data35)){if(Object.keys(data35).length < 1){const err70 = {instancePath:instancePath+"/meta/legend/entries/external",schemaPath:"common.schema.json#/$defs/legendEntry/minProperties",keyword:"minProperties",params:{limit: 1},message:"must NOT have fewer than 1 properties"};if(vErrors === null){vErrors = [err70];}else {vErrors.push(err70);}errors++;}for(const key11 in data35){if(!((key11 === "label") || (key11 === "visible"))){const err71 = {instancePath:instancePath+"/meta/legend/entries/external",schemaPath:"common.schema.json#/$defs/legendEntry/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key11},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err71];}else {vErrors.push(err71);}errors++;}}if(data35.label !== undefined){let data36 = data35.label;if(typeof data36 === "string"){if(func3(data36) > 80){const err72 = {instancePath:instancePath+"/meta/legend/entries/external/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/maxLength",keyword:"maxLength",params:{limit: 80},message:"must NOT have more than 80 characters"};if(vErrors === null){vErrors = [err72];}else {vErrors.push(err72);}errors++;}if(func3(data36) < 1){const err73 = {instancePath:instancePath+"/meta/legend/entries/external/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err73];}else {vErrors.push(err73);}errors++;}}else {const err74 = {instancePath:instancePath+"/meta/legend/entries/external/label",schemaPath:"common.schema.json#/$defs/legendEntry/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err74];}else {vErrors.push(err74);}errors++;}}if(data35.visible !== undefined){if(typeof data35.visible !== "boolean"){const err75 = {instancePath:instancePath+"/meta/legend/entries/external/visible",schemaPath:"common.schema.json#/$defs/legendEntry/properties/visible/type",keyword:"type",params:{type: "boolean"},message:"must be boolean"};if(vErrors === null){vErrors = [err75];}else {vErrors.push(err75);}errors++;}}}else {const err76 = {instancePath:instancePath+"/meta/legend/entries/external",schemaPath:"common.schema.json#/$defs/legendEntry/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err76];}else {vErrors.push(err76);}errors++;}}}else {const err77 = {instancePath:instancePath+"/meta/legend/entries",schemaPath:"#/properties/meta/properties/legend/properties/entries/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err77];}else {vErrors.push(err77);}errors++;}}}else {const err78 = {instancePath:instancePath+"/meta/legend",schemaPath:"#/properties/meta/properties/legend/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err78];}else {vErrors.push(err78);}errors++;}}if(data2.viewBox !== undefined){let data38 = data2.viewBox;if(Array.isArray(data38)){if(data38.length > 2){const err79 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err79];}else {vErrors.push(err79);}errors++;}if(data38.length < 2){const err80 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err80];}else {vErrors.push(err80);}errors++;}const len0 = data38.length;if(len0 > 0){let data39 = data38[0];if((typeof data39 == "number") && (isFinite(data39))){if(data39 < 320 || isNaN(data39)){const err81 = {instancePath:instancePath+"/meta/viewBox/0",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/0/minimum",keyword:"minimum",params:{comparison: ">=", limit: 320},message:"must be >= 320"};if(vErrors === null){vErrors = [err81];}else {vErrors.push(err81);}errors++;}}else {const err82 = {instancePath:instancePath+"/meta/viewBox/0",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err82];}else {vErrors.push(err82);}errors++;}}if(len0 > 1){let data40 = data38[1];if((typeof data40 == "number") && (isFinite(data40))){if(data40 < 240 || isNaN(data40)){const err83 = {instancePath:instancePath+"/meta/viewBox/1",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/1/minimum",keyword:"minimum",params:{comparison: ">=", limit: 240},message:"must be >= 240"};if(vErrors === null){vErrors = [err83];}else {vErrors.push(err83);}errors++;}}else {const err84 = {instancePath:instancePath+"/meta/viewBox/1",schemaPath:"#/properties/meta/properties/viewBox/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err84];}else {vErrors.push(err84);}errors++;}}const len1 = data38.length;if(!(len1 <= 2)){const err85 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err85];}else {vErrors.push(err85);}errors++;}}else {const err86 = {instancePath:instancePath+"/meta/viewBox",schemaPath:"#/properties/meta/properties/viewBox/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err86];}else {vErrors.push(err86);}errors++;}}}else {const err87 = {instancePath:instancePath+"/meta",schemaPath:"#/properties/meta/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err87];}else {vErrors.push(err87);}errors++;}}if(data.layout !== undefined){let data41 = data.layout;if(data41 && typeof data41 == "object" && !Array.isArray(data41)){if(data41.mode === undefined){const err88 = {instancePath:instancePath+"/layout",schemaPath:"#/properties/layout/required",keyword:"required",params:{missingProperty: "mode"},message:"must have required property '"+"mode"+"'"};if(vErrors === null){vErrors = [err88];}else {vErrors.push(err88);}errors++;}for(const key12 in data41){if(!(((((((key12 === "mode") || (key12 === "origin")) || (key12 === "cols")) || (key12 === "gapX")) || (key12 === "gapY")) || (key12 === "cellW")) || (key12 === "cellH"))){const err89 = {instancePath:instancePath+"/layout",schemaPath:"#/properties/layout/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key12},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err89];}else {vErrors.push(err89);}errors++;}}if(data41.mode !== undefined){if(!(data41.mode === "grid")){const err90 = {instancePath:instancePath+"/layout/mode",schemaPath:"#/properties/layout/properties/mode/enum",keyword:"enum",params:{allowedValues: schema121.properties.layout.properties.mode.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err90];}else {vErrors.push(err90);}errors++;}}if(data41.origin !== undefined){let data43 = data41.origin;if(Array.isArray(data43)){if(data43.length > 2){const err91 = {instancePath:instancePath+"/layout/origin",schemaPath:"common.schema.json#/$defs/point/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err91];}else {vErrors.push(err91);}errors++;}if(data43.length < 2){const err92 = {instancePath:instancePath+"/layout/origin",schemaPath:"common.schema.json#/$defs/point/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err92];}else {vErrors.push(err92);}errors++;}const len2 = data43.length;if(len2 > 0){let data44 = data43[0];if(!((typeof data44 == "number") && (isFinite(data44)))){const err93 = {instancePath:instancePath+"/layout/origin/0",schemaPath:"common.schema.json#/$defs/point/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err93];}else {vErrors.push(err93);}errors++;}}if(len2 > 1){let data45 = data43[1];if(!((typeof data45 == "number") && (isFinite(data45)))){const err94 = {instancePath:instancePath+"/layout/origin/1",schemaPath:"common.schema.json#/$defs/point/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err94];}else {vErrors.push(err94);}errors++;}}const len3 = data43.length;if(!(len3 <= 2)){const err95 = {instancePath:instancePath+"/layout/origin",schemaPath:"common.schema.json#/$defs/point/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err95];}else {vErrors.push(err95);}errors++;}}else {const err96 = {instancePath:instancePath+"/layout/origin",schemaPath:"common.schema.json#/$defs/point/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err96];}else {vErrors.push(err96);}errors++;}}if(data41.cols !== undefined){let data46 = data41.cols;if(!(((typeof data46 == "number") && (!(data46 % 1) && !isNaN(data46))) && (isFinite(data46)))){const err97 = {instancePath:instancePath+"/layout/cols",schemaPath:"#/properties/layout/properties/cols/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err97];}else {vErrors.push(err97);}errors++;}if((typeof data46 == "number") && (isFinite(data46))){if(data46 > 12 || isNaN(data46)){const err98 = {instancePath:instancePath+"/layout/cols",schemaPath:"#/properties/layout/properties/cols/maximum",keyword:"maximum",params:{comparison: "<=", limit: 12},message:"must be <= 12"};if(vErrors === null){vErrors = [err98];}else {vErrors.push(err98);}errors++;}if(data46 < 1 || isNaN(data46)){const err99 = {instancePath:instancePath+"/layout/cols",schemaPath:"#/properties/layout/properties/cols/minimum",keyword:"minimum",params:{comparison: ">=", limit: 1},message:"must be >= 1"};if(vErrors === null){vErrors = [err99];}else {vErrors.push(err99);}errors++;}}}if(data41.gapX !== undefined){let data47 = data41.gapX;if((typeof data47 == "number") && (isFinite(data47))){if(data47 < 0 || isNaN(data47)){const err100 = {instancePath:instancePath+"/layout/gapX",schemaPath:"#/properties/layout/properties/gapX/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err100];}else {vErrors.push(err100);}errors++;}}else {const err101 = {instancePath:instancePath+"/layout/gapX",schemaPath:"#/properties/layout/properties/gapX/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err101];}else {vErrors.push(err101);}errors++;}}if(data41.gapY !== undefined){let data48 = data41.gapY;if((typeof data48 == "number") && (isFinite(data48))){if(data48 < 0 || isNaN(data48)){const err102 = {instancePath:instancePath+"/layout/gapY",schemaPath:"#/properties/layout/properties/gapY/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err102];}else {vErrors.push(err102);}errors++;}}else {const err103 = {instancePath:instancePath+"/layout/gapY",schemaPath:"#/properties/layout/properties/gapY/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err103];}else {vErrors.push(err103);}errors++;}}if(data41.cellW !== undefined){let data49 = data41.cellW;if((typeof data49 == "number") && (isFinite(data49))){if(data49 < 40 || isNaN(data49)){const err104 = {instancePath:instancePath+"/layout/cellW",schemaPath:"#/properties/layout/properties/cellW/minimum",keyword:"minimum",params:{comparison: ">=", limit: 40},message:"must be >= 40"};if(vErrors === null){vErrors = [err104];}else {vErrors.push(err104);}errors++;}}else {const err105 = {instancePath:instancePath+"/layout/cellW",schemaPath:"#/properties/layout/properties/cellW/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err105];}else {vErrors.push(err105);}errors++;}}if(data41.cellH !== undefined){let data50 = data41.cellH;if((typeof data50 == "number") && (isFinite(data50))){if(data50 < 24 || isNaN(data50)){const err106 = {instancePath:instancePath+"/layout/cellH",schemaPath:"#/properties/layout/properties/cellH/minimum",keyword:"minimum",params:{comparison: ">=", limit: 24},message:"must be >= 24"};if(vErrors === null){vErrors = [err106];}else {vErrors.push(err106);}errors++;}}else {const err107 = {instancePath:instancePath+"/layout/cellH",schemaPath:"#/properties/layout/properties/cellH/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err107];}else {vErrors.push(err107);}errors++;}}}else {const err108 = {instancePath:instancePath+"/layout",schemaPath:"#/properties/layout/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err108];}else {vErrors.push(err108);}errors++;}}if(data.components !== undefined){let data51 = data.components;if(Array.isArray(data51)){if(data51.length < 1){const err109 = {instancePath:instancePath+"/components",schemaPath:"#/properties/components/minItems",keyword:"minItems",params:{limit: 1},message:"must NOT have fewer than 1 items"};if(vErrors === null){vErrors = [err109];}else {vErrors.push(err109);}errors++;}const len4 = data51.length;for(let i0=0; i0<len4; i0++){let data52 = data51[i0];if(data52 && typeof data52 == "object" && !Array.isArray(data52)){if(data52.id === undefined){const err110 = {instancePath:instancePath+"/components/" + i0,schemaPath:"#/properties/components/items/required",keyword:"required",params:{missingProperty: "id"},message:"must have required property '"+"id"+"'"};if(vErrors === null){vErrors = [err110];}else {vErrors.push(err110);}errors++;}if(data52.type === undefined){const err111 = {instancePath:instancePath+"/components/" + i0,schemaPath:"#/properties/components/items/required",keyword:"required",params:{missingProperty: "type"},message:"must have required property '"+"type"+"'"};if(vErrors === null){vErrors = [err111];}else {vErrors.push(err111);}errors++;}if(data52.label === undefined){const err112 = {instancePath:instancePath+"/components/" + i0,schemaPath:"#/properties/components/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err112];}else {vErrors.push(err112);}errors++;}for(const key13 in data52){if(!(func1.call(schema121.properties.components.items.properties, key13))){const err113 = {instancePath:instancePath+"/components/" + i0,schemaPath:"#/properties/components/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key13},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err113];}else {vErrors.push(err113);}errors++;}}if(data52.id !== undefined){let data53 = data52.id;if(typeof data53 === "string"){if(!pattern4.test(data53)){const err114 = {instancePath:instancePath+"/components/" + i0+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err114];}else {vErrors.push(err114);}errors++;}}else {const err115 = {instancePath:instancePath+"/components/" + i0+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err115];}else {vErrors.push(err115);}errors++;}}if(data52.type !== undefined){let data54 = data52.type;if(!(((((((data54 === "frontend") || (data54 === "backend")) || (data54 === "database")) || (data54 === "cloud")) || (data54 === "security")) || (data54 === "messagebus")) || (data54 === "external"))){const err116 = {instancePath:instancePath+"/components/" + i0+"/type",schemaPath:"common.schema.json#/$defs/componentType/enum",keyword:"enum",params:{allowedValues: schema51.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err116];}else {vErrors.push(err116);}errors++;}}if(data52.label !== undefined){let data55 = data52.label;if(typeof data55 === "string"){if(func3(data55) < 1){const err117 = {instancePath:instancePath+"/components/" + i0+"/label",schemaPath:"#/properties/components/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err117];}else {vErrors.push(err117);}errors++;}}else {const err118 = {instancePath:instancePath+"/components/" + i0+"/label",schemaPath:"#/properties/components/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err118];}else {vErrors.push(err118);}errors++;}}if(data52.sublabel !== undefined){if(typeof data52.sublabel !== "string"){const err119 = {instancePath:instancePath+"/components/" + i0+"/sublabel",schemaPath:"#/properties/components/items/properties/sublabel/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err119];}else {vErrors.push(err119);}errors++;}}if(data52.tag !== undefined){if(typeof data52.tag !== "string"){const err120 = {instancePath:instancePath+"/components/" + i0+"/tag",schemaPath:"#/properties/components/items/properties/tag/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err120];}else {vErrors.push(err120);}errors++;}}if(data52.sources !== undefined){let data58 = data52.sources;if(Array.isArray(data58)){if(data58.length > 3){const err121 = {instancePath:instancePath+"/components/" + i0+"/sources",schemaPath:"#/properties/components/items/properties/sources/maxItems",keyword:"maxItems",params:{limit: 3},message:"must NOT have more than 3 items"};if(vErrors === null){vErrors = [err121];}else {vErrors.push(err121);}errors++;}if(data58.length < 1){const err122 = {instancePath:instancePath+"/components/" + i0+"/sources",schemaPath:"#/properties/components/items/properties/sources/minItems",keyword:"minItems",params:{limit: 1},message:"must NOT have fewer than 1 items"};if(vErrors === null){vErrors = [err122];}else {vErrors.push(err122);}errors++;}const len5 = data58.length;for(let i1=0; i1<len5; i1++){let data59 = data58[i1];if(data59 && typeof data59 == "object" && !Array.isArray(data59)){if(data59.path === undefined){const err123 = {instancePath:instancePath+"/components/" + i0+"/sources/" + i1,schemaPath:"#/properties/components/items/properties/sources/items/required",keyword:"required",params:{missingProperty: "path"},message:"must have required property '"+"path"+"'"};if(vErrors === null){vErrors = [err123];}else {vErrors.push(err123);}errors++;}for(const key14 in data59){if(!((((key14 === "path") || (key14 === "line")) || (key14 === "end_line")) || (key14 === "label"))){const err124 = {instancePath:instancePath+"/components/" + i0+"/sources/" + i1,schemaPath:"#/properties/components/items/properties/sources/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key14},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err124];}else {vErrors.push(err124);}errors++;}}if(data59.path !== undefined){let data60 = data59.path;if(typeof data60 === "string"){if(func3(data60) > 240){const err125 = {instancePath:instancePath+"/components/" + i0+"/sources/" + i1+"/path",schemaPath:"#/properties/components/items/properties/sources/items/properties/path/maxLength",keyword:"maxLength",params:{limit: 240},message:"must NOT have more than 240 characters"};if(vErrors === null){vErrors = [err125];}else {vErrors.push(err125);}errors++;}if(func3(data60) < 1){const err126 = {instancePath:instancePath+"/components/" + i0+"/sources/" + i1+"/path",schemaPath:"#/properties/components/items/properties/sources/items/properties/path/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err126];}else {vErrors.push(err126);}errors++;}}else {const err127 = {instancePath:instancePath+"/components/" + i0+"/sources/" + i1+"/path",schemaPath:"#/properties/components/items/properties/sources/items/properties/path/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err127];}else {vErrors.push(err127);}errors++;}}if(data59.line !== undefined){let data61 = data59.line;if(!(((typeof data61 == "number") && (!(data61 % 1) && !isNaN(data61))) && (isFinite(data61)))){const err128 = {instancePath:instancePath+"/components/" + i0+"/sources/" + i1+"/line",schemaPath:"#/properties/components/items/properties/sources/items/properties/line/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err128];}else {vErrors.push(err128);}errors++;}if((typeof data61 == "number") && (isFinite(data61))){if(data61 < 1 || isNaN(data61)){const err129 = {instancePath:instancePath+"/components/" + i0+"/sources/" + i1+"/line",schemaPath:"#/properties/components/items/properties/sources/items/properties/line/minimum",keyword:"minimum",params:{comparison: ">=", limit: 1},message:"must be >= 1"};if(vErrors === null){vErrors = [err129];}else {vErrors.push(err129);}errors++;}}}if(data59.end_line !== undefined){let data62 = data59.end_line;if(!(((typeof data62 == "number") && (!(data62 % 1) && !isNaN(data62))) && (isFinite(data62)))){const err130 = {instancePath:instancePath+"/components/" + i0+"/sources/" + i1+"/end_line",schemaPath:"#/properties/components/items/properties/sources/items/properties/end_line/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err130];}else {vErrors.push(err130);}errors++;}if((typeof data62 == "number") && (isFinite(data62))){if(data62 < 1 || isNaN(data62)){const err131 = {instancePath:instancePath+"/components/" + i0+"/sources/" + i1+"/end_line",schemaPath:"#/properties/components/items/properties/sources/items/properties/end_line/minimum",keyword:"minimum",params:{comparison: ">=", limit: 1},message:"must be >= 1"};if(vErrors === null){vErrors = [err131];}else {vErrors.push(err131);}errors++;}}}if(data59.label !== undefined){let data63 = data59.label;if(typeof data63 === "string"){if(func3(data63) > 48){const err132 = {instancePath:instancePath+"/components/" + i0+"/sources/" + i1+"/label",schemaPath:"#/properties/components/items/properties/sources/items/properties/label/maxLength",keyword:"maxLength",params:{limit: 48},message:"must NOT have more than 48 characters"};if(vErrors === null){vErrors = [err132];}else {vErrors.push(err132);}errors++;}if(func3(data63) < 1){const err133 = {instancePath:instancePath+"/components/" + i0+"/sources/" + i1+"/label",schemaPath:"#/properties/components/items/properties/sources/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err133];}else {vErrors.push(err133);}errors++;}}else {const err134 = {instancePath:instancePath+"/components/" + i0+"/sources/" + i1+"/label",schemaPath:"#/properties/components/items/properties/sources/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err134];}else {vErrors.push(err134);}errors++;}}}else {const err135 = {instancePath:instancePath+"/components/" + i0+"/sources/" + i1,schemaPath:"#/properties/components/items/properties/sources/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err135];}else {vErrors.push(err135);}errors++;}}}else {const err136 = {instancePath:instancePath+"/components/" + i0+"/sources",schemaPath:"#/properties/components/items/properties/sources/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err136];}else {vErrors.push(err136);}errors++;}}if(data52.row !== undefined){let data64 = data52.row;if(!(((typeof data64 == "number") && (!(data64 % 1) && !isNaN(data64))) && (isFinite(data64)))){const err137 = {instancePath:instancePath+"/components/" + i0+"/row",schemaPath:"#/properties/components/items/properties/row/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err137];}else {vErrors.push(err137);}errors++;}if((typeof data64 == "number") && (isFinite(data64))){if(data64 < 0 || isNaN(data64)){const err138 = {instancePath:instancePath+"/components/" + i0+"/row",schemaPath:"#/properties/components/items/properties/row/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err138];}else {vErrors.push(err138);}errors++;}}}if(data52.col !== undefined){let data65 = data52.col;if(!(((typeof data65 == "number") && (!(data65 % 1) && !isNaN(data65))) && (isFinite(data65)))){const err139 = {instancePath:instancePath+"/components/" + i0+"/col",schemaPath:"#/properties/components/items/properties/col/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err139];}else {vErrors.push(err139);}errors++;}if((typeof data65 == "number") && (isFinite(data65))){if(data65 < 0 || isNaN(data65)){const err140 = {instancePath:instancePath+"/components/" + i0+"/col",schemaPath:"#/properties/components/items/properties/col/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err140];}else {vErrors.push(err140);}errors++;}}}if(data52.pos !== undefined){let data66 = data52.pos;if(Array.isArray(data66)){if(data66.length > 2){const err141 = {instancePath:instancePath+"/components/" + i0+"/pos",schemaPath:"common.schema.json#/$defs/point/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err141];}else {vErrors.push(err141);}errors++;}if(data66.length < 2){const err142 = {instancePath:instancePath+"/components/" + i0+"/pos",schemaPath:"common.schema.json#/$defs/point/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err142];}else {vErrors.push(err142);}errors++;}const len6 = data66.length;if(len6 > 0){let data67 = data66[0];if(!((typeof data67 == "number") && (isFinite(data67)))){const err143 = {instancePath:instancePath+"/components/" + i0+"/pos/0",schemaPath:"common.schema.json#/$defs/point/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err143];}else {vErrors.push(err143);}errors++;}}if(len6 > 1){let data68 = data66[1];if(!((typeof data68 == "number") && (isFinite(data68)))){const err144 = {instancePath:instancePath+"/components/" + i0+"/pos/1",schemaPath:"common.schema.json#/$defs/point/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err144];}else {vErrors.push(err144);}errors++;}}const len7 = data66.length;if(!(len7 <= 2)){const err145 = {instancePath:instancePath+"/components/" + i0+"/pos",schemaPath:"common.schema.json#/$defs/point/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err145];}else {vErrors.push(err145);}errors++;}}else {const err146 = {instancePath:instancePath+"/components/" + i0+"/pos",schemaPath:"common.schema.json#/$defs/point/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err146];}else {vErrors.push(err146);}errors++;}}if(data52.size !== undefined){let data69 = data52.size;if(Array.isArray(data69)){if(data69.length > 2){const err147 = {instancePath:instancePath+"/components/" + i0+"/size",schemaPath:"#/properties/components/items/properties/size/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err147];}else {vErrors.push(err147);}errors++;}if(data69.length < 2){const err148 = {instancePath:instancePath+"/components/" + i0+"/size",schemaPath:"#/properties/components/items/properties/size/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err148];}else {vErrors.push(err148);}errors++;}const len8 = data69.length;if(len8 > 0){let data70 = data69[0];if((typeof data70 == "number") && (isFinite(data70))){if(data70 <= 0 || isNaN(data70)){const err149 = {instancePath:instancePath+"/components/" + i0+"/size/0",schemaPath:"#/properties/components/items/properties/size/prefixItems/0/exclusiveMinimum",keyword:"exclusiveMinimum",params:{comparison: ">", limit: 0},message:"must be > 0"};if(vErrors === null){vErrors = [err149];}else {vErrors.push(err149);}errors++;}}else {const err150 = {instancePath:instancePath+"/components/" + i0+"/size/0",schemaPath:"#/properties/components/items/properties/size/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err150];}else {vErrors.push(err150);}errors++;}}if(len8 > 1){let data71 = data69[1];if((typeof data71 == "number") && (isFinite(data71))){if(data71 <= 0 || isNaN(data71)){const err151 = {instancePath:instancePath+"/components/" + i0+"/size/1",schemaPath:"#/properties/components/items/properties/size/prefixItems/1/exclusiveMinimum",keyword:"exclusiveMinimum",params:{comparison: ">", limit: 0},message:"must be > 0"};if(vErrors === null){vErrors = [err151];}else {vErrors.push(err151);}errors++;}}else {const err152 = {instancePath:instancePath+"/components/" + i0+"/size/1",schemaPath:"#/properties/components/items/properties/size/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err152];}else {vErrors.push(err152);}errors++;}}const len9 = data69.length;if(!(len9 <= 2)){const err153 = {instancePath:instancePath+"/components/" + i0+"/size",schemaPath:"#/properties/components/items/properties/size/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err153];}else {vErrors.push(err153);}errors++;}}else {const err154 = {instancePath:instancePath+"/components/" + i0+"/size",schemaPath:"#/properties/components/items/properties/size/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err154];}else {vErrors.push(err154);}errors++;}}}else {const err155 = {instancePath:instancePath+"/components/" + i0,schemaPath:"#/properties/components/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err155];}else {vErrors.push(err155);}errors++;}}}else {const err156 = {instancePath:instancePath+"/components",schemaPath:"#/properties/components/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err156];}else {vErrors.push(err156);}errors++;}}if(data.boundaries !== undefined){let data72 = data.boundaries;if(Array.isArray(data72)){const len10 = data72.length;for(let i2=0; i2<len10; i2++){let data73 = data72[i2];if(data73 && typeof data73 == "object" && !Array.isArray(data73)){if(data73.kind === undefined){const err157 = {instancePath:instancePath+"/boundaries/" + i2,schemaPath:"#/properties/boundaries/items/required",keyword:"required",params:{missingProperty: "kind"},message:"must have required property '"+"kind"+"'"};if(vErrors === null){vErrors = [err157];}else {vErrors.push(err157);}errors++;}if(data73.label === undefined){const err158 = {instancePath:instancePath+"/boundaries/" + i2,schemaPath:"#/properties/boundaries/items/required",keyword:"required",params:{missingProperty: "label"},message:"must have required property '"+"label"+"'"};if(vErrors === null){vErrors = [err158];}else {vErrors.push(err158);}errors++;}if(data73.wraps === undefined){const err159 = {instancePath:instancePath+"/boundaries/" + i2,schemaPath:"#/properties/boundaries/items/required",keyword:"required",params:{missingProperty: "wraps"},message:"must have required property '"+"wraps"+"'"};if(vErrors === null){vErrors = [err159];}else {vErrors.push(err159);}errors++;}for(const key15 in data73){if(!((((key15 === "kind") || (key15 === "label")) || (key15 === "wraps")) || (key15 === "pad"))){const err160 = {instancePath:instancePath+"/boundaries/" + i2,schemaPath:"#/properties/boundaries/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key15},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err160];}else {vErrors.push(err160);}errors++;}}if(data73.kind !== undefined){let data74 = data73.kind;if(!((data74 === "region") || (data74 === "security-group"))){const err161 = {instancePath:instancePath+"/boundaries/" + i2+"/kind",schemaPath:"#/properties/boundaries/items/properties/kind/enum",keyword:"enum",params:{allowedValues: schema121.properties.boundaries.items.properties.kind.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err161];}else {vErrors.push(err161);}errors++;}}if(data73.label !== undefined){let data75 = data73.label;if(typeof data75 === "string"){if(func3(data75) < 1){const err162 = {instancePath:instancePath+"/boundaries/" + i2+"/label",schemaPath:"#/properties/boundaries/items/properties/label/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err162];}else {vErrors.push(err162);}errors++;}}else {const err163 = {instancePath:instancePath+"/boundaries/" + i2+"/label",schemaPath:"#/properties/boundaries/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err163];}else {vErrors.push(err163);}errors++;}}if(data73.wraps !== undefined){let data76 = data73.wraps;if(Array.isArray(data76)){if(data76.length < 1){const err164 = {instancePath:instancePath+"/boundaries/" + i2+"/wraps",schemaPath:"#/properties/boundaries/items/properties/wraps/minItems",keyword:"minItems",params:{limit: 1},message:"must NOT have fewer than 1 items"};if(vErrors === null){vErrors = [err164];}else {vErrors.push(err164);}errors++;}const len11 = data76.length;for(let i3=0; i3<len11; i3++){let data77 = data76[i3];if(typeof data77 === "string"){if(!pattern4.test(data77)){const err165 = {instancePath:instancePath+"/boundaries/" + i2+"/wraps/" + i3,schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err165];}else {vErrors.push(err165);}errors++;}}else {const err166 = {instancePath:instancePath+"/boundaries/" + i2+"/wraps/" + i3,schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err166];}else {vErrors.push(err166);}errors++;}}}else {const err167 = {instancePath:instancePath+"/boundaries/" + i2+"/wraps",schemaPath:"#/properties/boundaries/items/properties/wraps/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err167];}else {vErrors.push(err167);}errors++;}}if(data73.pad !== undefined){let data78 = data73.pad;if((typeof data78 == "number") && (isFinite(data78))){if(data78 < 0 || isNaN(data78)){const err168 = {instancePath:instancePath+"/boundaries/" + i2+"/pad",schemaPath:"#/properties/boundaries/items/properties/pad/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err168];}else {vErrors.push(err168);}errors++;}}else {const err169 = {instancePath:instancePath+"/boundaries/" + i2+"/pad",schemaPath:"#/properties/boundaries/items/properties/pad/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err169];}else {vErrors.push(err169);}errors++;}}}else {const err170 = {instancePath:instancePath+"/boundaries/" + i2,schemaPath:"#/properties/boundaries/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err170];}else {vErrors.push(err170);}errors++;}}}else {const err171 = {instancePath:instancePath+"/boundaries",schemaPath:"#/properties/boundaries/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err171];}else {vErrors.push(err171);}errors++;}}if(data.connections !== undefined){let data79 = data.connections;if(Array.isArray(data79)){const len12 = data79.length;for(let i4=0; i4<len12; i4++){let data80 = data79[i4];if(data80 && typeof data80 == "object" && !Array.isArray(data80)){if(data80.from === undefined){const err172 = {instancePath:instancePath+"/connections/" + i4,schemaPath:"#/properties/connections/items/required",keyword:"required",params:{missingProperty: "from"},message:"must have required property '"+"from"+"'"};if(vErrors === null){vErrors = [err172];}else {vErrors.push(err172);}errors++;}if(data80.to === undefined){const err173 = {instancePath:instancePath+"/connections/" + i4,schemaPath:"#/properties/connections/items/required",keyword:"required",params:{missingProperty: "to"},message:"must have required property '"+"to"+"'"};if(vErrors === null){vErrors = [err173];}else {vErrors.push(err173);}errors++;}for(const key16 in data80){if(!(func1.call(schema121.properties.connections.items.properties, key16))){const err174 = {instancePath:instancePath+"/connections/" + i4,schemaPath:"#/properties/connections/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key16},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err174];}else {vErrors.push(err174);}errors++;}}if(data80.id !== undefined){let data81 = data80.id;if(typeof data81 === "string"){if(!pattern4.test(data81)){const err175 = {instancePath:instancePath+"/connections/" + i4+"/id",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err175];}else {vErrors.push(err175);}errors++;}}else {const err176 = {instancePath:instancePath+"/connections/" + i4+"/id",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err176];}else {vErrors.push(err176);}errors++;}}if(data80.from !== undefined){let data82 = data80.from;if(typeof data82 === "string"){if(!pattern4.test(data82)){const err177 = {instancePath:instancePath+"/connections/" + i4+"/from",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err177];}else {vErrors.push(err177);}errors++;}}else {const err178 = {instancePath:instancePath+"/connections/" + i4+"/from",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err178];}else {vErrors.push(err178);}errors++;}}if(data80.to !== undefined){let data83 = data80.to;if(typeof data83 === "string"){if(!pattern4.test(data83)){const err179 = {instancePath:instancePath+"/connections/" + i4+"/to",schemaPath:"common.schema.json#/$defs/id/pattern",keyword:"pattern",params:{pattern: "^[a-zA-Z][a-zA-Z0-9_-]*$"},message:"must match pattern \""+"^[a-zA-Z][a-zA-Z0-9_-]*$"+"\""};if(vErrors === null){vErrors = [err179];}else {vErrors.push(err179);}errors++;}}else {const err180 = {instancePath:instancePath+"/connections/" + i4+"/to",schemaPath:"common.schema.json#/$defs/id/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err180];}else {vErrors.push(err180);}errors++;}}if(data80.label !== undefined){if(typeof data80.label !== "string"){const err181 = {instancePath:instancePath+"/connections/" + i4+"/label",schemaPath:"#/properties/connections/items/properties/label/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err181];}else {vErrors.push(err181);}errors++;}}if(data80.variant !== undefined){let data85 = data80.variant;if(!((((data85 === "default") || (data85 === "emphasis")) || (data85 === "security")) || (data85 === "dashed"))){const err182 = {instancePath:instancePath+"/connections/" + i4+"/variant",schemaPath:"common.schema.json#/$defs/variant/enum",keyword:"enum",params:{allowedValues: schema55.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err182];}else {vErrors.push(err182);}errors++;}}if(data80.fromSide !== undefined){let data86 = data80.fromSide;if(!((((data86 === "left") || (data86 === "right")) || (data86 === "top")) || (data86 === "bottom"))){const err183 = {instancePath:instancePath+"/connections/" + i4+"/fromSide",schemaPath:"#/properties/connections/items/properties/fromSide/enum",keyword:"enum",params:{allowedValues: schema121.properties.connections.items.properties.fromSide.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err183];}else {vErrors.push(err183);}errors++;}}if(data80.toSide !== undefined){let data87 = data80.toSide;if(!((((data87 === "left") || (data87 === "right")) || (data87 === "top")) || (data87 === "bottom"))){const err184 = {instancePath:instancePath+"/connections/" + i4+"/toSide",schemaPath:"#/properties/connections/items/properties/toSide/enum",keyword:"enum",params:{allowedValues: schema121.properties.connections.items.properties.toSide.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err184];}else {vErrors.push(err184);}errors++;}}if(data80.route !== undefined){let data88 = data80.route;if(!((((data88 === "auto") || (data88 === "straight")) || (data88 === "orthogonal-h")) || (data88 === "orthogonal-v"))){const err185 = {instancePath:instancePath+"/connections/" + i4+"/route",schemaPath:"#/properties/connections/items/properties/route/enum",keyword:"enum",params:{allowedValues: schema121.properties.connections.items.properties.route.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err185];}else {vErrors.push(err185);}errors++;}}if(data80.via !== undefined){let data89 = data80.via;if(Array.isArray(data89)){const len13 = data89.length;for(let i5=0; i5<len13; i5++){let data90 = data89[i5];if(Array.isArray(data90)){if(data90.length > 2){const err186 = {instancePath:instancePath+"/connections/" + i4+"/via/" + i5,schemaPath:"common.schema.json#/$defs/point/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err186];}else {vErrors.push(err186);}errors++;}if(data90.length < 2){const err187 = {instancePath:instancePath+"/connections/" + i4+"/via/" + i5,schemaPath:"common.schema.json#/$defs/point/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err187];}else {vErrors.push(err187);}errors++;}const len14 = data90.length;if(len14 > 0){let data91 = data90[0];if(!((typeof data91 == "number") && (isFinite(data91)))){const err188 = {instancePath:instancePath+"/connections/" + i4+"/via/" + i5+"/0",schemaPath:"common.schema.json#/$defs/point/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err188];}else {vErrors.push(err188);}errors++;}}if(len14 > 1){let data92 = data90[1];if(!((typeof data92 == "number") && (isFinite(data92)))){const err189 = {instancePath:instancePath+"/connections/" + i4+"/via/" + i5+"/1",schemaPath:"common.schema.json#/$defs/point/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err189];}else {vErrors.push(err189);}errors++;}}const len15 = data90.length;if(!(len15 <= 2)){const err190 = {instancePath:instancePath+"/connections/" + i4+"/via/" + i5,schemaPath:"common.schema.json#/$defs/point/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err190];}else {vErrors.push(err190);}errors++;}}else {const err191 = {instancePath:instancePath+"/connections/" + i4+"/via/" + i5,schemaPath:"common.schema.json#/$defs/point/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err191];}else {vErrors.push(err191);}errors++;}}}else {const err192 = {instancePath:instancePath+"/connections/" + i4+"/via",schemaPath:"#/properties/connections/items/properties/via/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err192];}else {vErrors.push(err192);}errors++;}}if(data80.labelAt !== undefined){let data93 = data80.labelAt;if(Array.isArray(data93)){if(data93.length > 2){const err193 = {instancePath:instancePath+"/connections/" + i4+"/labelAt",schemaPath:"common.schema.json#/$defs/point/maxItems",keyword:"maxItems",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err193];}else {vErrors.push(err193);}errors++;}if(data93.length < 2){const err194 = {instancePath:instancePath+"/connections/" + i4+"/labelAt",schemaPath:"common.schema.json#/$defs/point/minItems",keyword:"minItems",params:{limit: 2},message:"must NOT have fewer than 2 items"};if(vErrors === null){vErrors = [err194];}else {vErrors.push(err194);}errors++;}const len16 = data93.length;if(len16 > 0){let data94 = data93[0];if(!((typeof data94 == "number") && (isFinite(data94)))){const err195 = {instancePath:instancePath+"/connections/" + i4+"/labelAt/0",schemaPath:"common.schema.json#/$defs/point/prefixItems/0/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err195];}else {vErrors.push(err195);}errors++;}}if(len16 > 1){let data95 = data93[1];if(!((typeof data95 == "number") && (isFinite(data95)))){const err196 = {instancePath:instancePath+"/connections/" + i4+"/labelAt/1",schemaPath:"common.schema.json#/$defs/point/prefixItems/1/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err196];}else {vErrors.push(err196);}errors++;}}const len17 = data93.length;if(!(len17 <= 2)){const err197 = {instancePath:instancePath+"/connections/" + i4+"/labelAt",schemaPath:"common.schema.json#/$defs/point/items",keyword:"items",params:{limit: 2},message:"must NOT have more than 2 items"};if(vErrors === null){vErrors = [err197];}else {vErrors.push(err197);}errors++;}}else {const err198 = {instancePath:instancePath+"/connections/" + i4+"/labelAt",schemaPath:"common.schema.json#/$defs/point/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err198];}else {vErrors.push(err198);}errors++;}}if(data80.labelDx !== undefined){let data96 = data80.labelDx;if(!((typeof data96 == "number") && (isFinite(data96)))){const err199 = {instancePath:instancePath+"/connections/" + i4+"/labelDx",schemaPath:"#/properties/connections/items/properties/labelDx/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err199];}else {vErrors.push(err199);}errors++;}}if(data80.labelDy !== undefined){let data97 = data80.labelDy;if(!((typeof data97 == "number") && (isFinite(data97)))){const err200 = {instancePath:instancePath+"/connections/" + i4+"/labelDy",schemaPath:"#/properties/connections/items/properties/labelDy/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err200];}else {vErrors.push(err200);}errors++;}}if(data80.labelSegment !== undefined){let data98 = data80.labelSegment;if(!(((typeof data98 == "number") && (!(data98 % 1) && !isNaN(data98))) && (isFinite(data98)))){const err201 = {instancePath:instancePath+"/connections/" + i4+"/labelSegment",schemaPath:"#/properties/connections/items/properties/labelSegment/type",keyword:"type",params:{type: "integer"},message:"must be integer"};if(vErrors === null){vErrors = [err201];}else {vErrors.push(err201);}errors++;}if((typeof data98 == "number") && (isFinite(data98))){if(data98 < 0 || isNaN(data98)){const err202 = {instancePath:instancePath+"/connections/" + i4+"/labelSegment",schemaPath:"#/properties/connections/items/properties/labelSegment/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0},message:"must be >= 0"};if(vErrors === null){vErrors = [err202];}else {vErrors.push(err202);}errors++;}}}if(data80.width !== undefined){let data99 = data80.width;if((typeof data99 == "number") && (isFinite(data99))){if(data99 < 0.5 || isNaN(data99)){const err203 = {instancePath:instancePath+"/connections/" + i4+"/width",schemaPath:"#/properties/connections/items/properties/width/minimum",keyword:"minimum",params:{comparison: ">=", limit: 0.5},message:"must be >= 0.5"};if(vErrors === null){vErrors = [err203];}else {vErrors.push(err203);}errors++;}}else {const err204 = {instancePath:instancePath+"/connections/" + i4+"/width",schemaPath:"#/properties/connections/items/properties/width/type",keyword:"type",params:{type: "number"},message:"must be number"};if(vErrors === null){vErrors = [err204];}else {vErrors.push(err204);}errors++;}}}else {const err205 = {instancePath:instancePath+"/connections/" + i4,schemaPath:"#/properties/connections/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err205];}else {vErrors.push(err205);}errors++;}}}else {const err206 = {instancePath:instancePath+"/connections",schemaPath:"#/properties/connections/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err206];}else {vErrors.push(err206);}errors++;}}if(data.cards !== undefined){let data100 = data.cards;if(Array.isArray(data100)){const len18 = data100.length;for(let i6=0; i6<len18; i6++){let data101 = data100[i6];if(data101 && typeof data101 == "object" && !Array.isArray(data101)){if(data101.dot === undefined){const err207 = {instancePath:instancePath+"/cards/" + i6,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "dot"},message:"must have required property '"+"dot"+"'"};if(vErrors === null){vErrors = [err207];}else {vErrors.push(err207);}errors++;}if(data101.title === undefined){const err208 = {instancePath:instancePath+"/cards/" + i6,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "title"},message:"must have required property '"+"title"+"'"};if(vErrors === null){vErrors = [err208];}else {vErrors.push(err208);}errors++;}if(data101.items === undefined){const err209 = {instancePath:instancePath+"/cards/" + i6,schemaPath:"common.schema.json#/$defs/cards/items/required",keyword:"required",params:{missingProperty: "items"},message:"must have required property '"+"items"+"'"};if(vErrors === null){vErrors = [err209];}else {vErrors.push(err209);}errors++;}for(const key17 in data101){if(!(((key17 === "dot") || (key17 === "title")) || (key17 === "items"))){const err210 = {instancePath:instancePath+"/cards/" + i6,schemaPath:"common.schema.json#/$defs/cards/items/additionalProperties",keyword:"additionalProperties",params:{additionalProperty: key17},message:"must NOT have additional properties"};if(vErrors === null){vErrors = [err210];}else {vErrors.push(err210);}errors++;}}if(data101.dot !== undefined){let data102 = data101.dot;if(!(((((((data102 === "cyan") || (data102 === "emerald")) || (data102 === "violet")) || (data102 === "amber")) || (data102 === "rose")) || (data102 === "orange")) || (data102 === "slate"))){const err211 = {instancePath:instancePath+"/cards/" + i6+"/dot",schemaPath:"common.schema.json#/$defs/cards/items/properties/dot/enum",keyword:"enum",params:{allowedValues: schema60.items.properties.dot.enum},message:"must be equal to one of the allowed values"};if(vErrors === null){vErrors = [err211];}else {vErrors.push(err211);}errors++;}}if(data101.title !== undefined){let data103 = data101.title;if(typeof data103 === "string"){if(func3(data103) < 1){const err212 = {instancePath:instancePath+"/cards/" + i6+"/title",schemaPath:"common.schema.json#/$defs/cards/items/properties/title/minLength",keyword:"minLength",params:{limit: 1},message:"must NOT have fewer than 1 characters"};if(vErrors === null){vErrors = [err212];}else {vErrors.push(err212);}errors++;}}else {const err213 = {instancePath:instancePath+"/cards/" + i6+"/title",schemaPath:"common.schema.json#/$defs/cards/items/properties/title/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err213];}else {vErrors.push(err213);}errors++;}}if(data101.items !== undefined){let data104 = data101.items;if(Array.isArray(data104)){const len19 = data104.length;for(let i7=0; i7<len19; i7++){if(typeof data104[i7] !== "string"){const err214 = {instancePath:instancePath+"/cards/" + i6+"/items/" + i7,schemaPath:"common.schema.json#/$defs/cards/items/properties/items/items/type",keyword:"type",params:{type: "string"},message:"must be string"};if(vErrors === null){vErrors = [err214];}else {vErrors.push(err214);}errors++;}}}else {const err215 = {instancePath:instancePath+"/cards/" + i6+"/items",schemaPath:"common.schema.json#/$defs/cards/items/properties/items/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err215];}else {vErrors.push(err215);}errors++;}}}else {const err216 = {instancePath:instancePath+"/cards/" + i6,schemaPath:"common.schema.json#/$defs/cards/items/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err216];}else {vErrors.push(err216);}errors++;}}}else {const err217 = {instancePath:instancePath+"/cards",schemaPath:"common.schema.json#/$defs/cards/type",keyword:"type",params:{type: "array"},message:"must be array"};if(vErrors === null){vErrors = [err217];}else {vErrors.push(err217);}errors++;}}}else {const err218 = {instancePath,schemaPath:"#/type",keyword:"type",params:{type: "object"},message:"must be object"};if(vErrors === null){vErrors = [err218];}else {vErrors.push(err218);}errors++;}validate33.errors = vErrors;return errors === 0;}validate33.evaluated = {"props":true,"dynamicProps":false,"dynamicItems":false};diff --git a/archify/renderers/shared/legend.mjs b/archify/renderers/shared/legend.mjsnew file mode 100644index 00000000..53496da0--- /dev/null+++ b/archify/renderers/shared/legend.mjs@@ -0,0 +1,215 @@+import { throwDiagnosticError } from './diagnostics.mjs';+import { rectsOverlap, segmentIntersectsRect } from './geometry.mjs';+import { esc, textUnits } from './utils.mjs';++const DEFAULT_FONT_SIZE = 8;+const DEFAULT_ITEM_GAP = 22;+const DEFAULT_LINE_GAP = 22;+const DEFAULT_SWATCH_GAP = 7;+const TEXT_ADVANCE_EM = 0.62;+const INTERACTIVE_BADGE_ALLOWANCE = 21;++export function relationshipLegendObstacles(relations, { pointsFor, labelRectFor } = {}) {+ const obstacles = [];+ for (const [index, relation] of (Array.isArray(relations) ? relations : []).entries()) {+ const points = typeof pointsFor === 'function' ? pointsFor(relation, index) : [];+ const finitePoints = (Array.isArray(points) ? points : []).filter((point) => (+ Array.isArray(point) && point.length === 2 && point.every(Number.isFinite)+ ));+ for (let pointIndex = 0; pointIndex < finitePoints.length - 1; pointIndex += 1) {+ obstacles.push({+ kind: 'relationship-segment',+ start: finitePoints[pointIndex],+ end: finitePoints[pointIndex + 1],+ });+ }+ const labelRect = typeof labelRectFor === 'function' ? labelRectFor(relation, index) : null;+ if (labelRect && [labelRect.x, labelRect.y, labelRect.width, labelRect.height].every(Number.isFinite)) {+ obstacles.push({ kind: 'relationship-label', ...labelRect });+ }+ }+ return obstacles;+}++export function resolveLegend(config, catalog, presentKinds) {+ const mode = config?.mode || 'auto';+ if (mode === 'hidden') return [];+ const present = presentKinds instanceof Set ? presentKinds : new Set(presentKinds || []);+ const overrides = config?.entries || {};++ return catalog.flatMap((catalogEntry) => {+ const override = overrides[catalogEntry.kind] || {};+ const selectedByMode = mode === 'all' || present.has(catalogEntry.kind);+ const visible = override.visible === true || (selectedByMode && override.visible !== false);+ if (!visible) return [];+ return [{+ ...catalogEntry,+ label: override.label || catalogEntry.label,+ present: present.has(catalogEntry.kind),+ interactive: catalogEntry.interactive !== false && present.has(catalogEntry.kind),+ }];+ });+}++function measuredEntryWidth(entry, fontSize, swatchGap) {+ const swatchWidth = entry.swatchWidth ?? 14;+ return Math.ceil(+ swatchWidth+ + swatchGap+ + textUnits(entry.label) * fontSize * TEXT_ADVANCE_EM+ + (entry.interactive ? INTERACTIVE_BADGE_ALLOWANCE : 0),+ );+}++// One pure footprint calculation owns both auto-viewBox sizing and final SVG+// placement. Callers must not maintain a second approximation of legend width+// or row count; that would make generated geometry disagree with validation.+export function legendFootprint(entries, {+ width,+ fontSize = DEFAULT_FONT_SIZE,+ itemGap = DEFAULT_ITEM_GAP,+ lineGap = DEFAULT_LINE_GAP,+ swatchGap = DEFAULT_SWATCH_GAP,+} = {}) {+ if (!entries.length) {+ return { measured: [], rows: [], rowCount: 0, minWidth: 0, extraHeight: 0 };+ }+ const measured = entries.map((entry) => ({+ ...entry,+ width: measuredEntryWidth(entry, fontSize, entry.swatchGap ?? swatchGap),+ }));+ const rows = [[]];+ let cursor = 0;+ for (const entry of measured) {+ const row = rows.at(-1);+ const required = (row.length ? itemGap : 0) + entry.width;+ if (row.length && cursor + required > width) {+ rows.push([entry]);+ cursor = entry.width;+ } else {+ row.push(entry);+ cursor += required;+ }+ }+ return {+ measured,+ rows,+ rowCount: rows.length,+ minWidth: Math.max(...measured.map((entry) => entry.width)),+ extraHeight: (rows.length - 1) * lineGap,+ };+}++export function measureLegend(entries, {+ x,+ baselineY,+ width,+ fontSize = DEFAULT_FONT_SIZE,+ itemGap = DEFAULT_ITEM_GAP,+ lineGap = DEFAULT_LINE_GAP,+ swatchGap = DEFAULT_SWATCH_GAP,+ minTitleY = 0,+ obstacles = [],+ unfit = 'error',+ diagramType = 'diagram',+} = {}) {+ if (!entries.length) return { entries: [], rowCount: 0, titleY: null };+ const footprint = legendFootprint(entries, { width, fontSize, itemGap, lineGap, swatchGap });+ const tooWide = footprint.measured.find((entry) => entry.width > width);+ if (tooWide) {+ if (unfit === 'hide') return null;+ const message = `[legend/label-too-wide] ${diagramType} legend label for "${tooWide.kind}" needs ${tooWide.width}px but only ${width}px is available.`;+ throwDiagnosticError(message, [{+ code: 'legend/label-too-wide',+ severity: 'error',+ message,+ subject: { diagramType, path: `/meta/legend/entries/${tooWide.kind}/label` },+ evidence: { kind: tooWide.kind, measuredWidthPx: tooWide.width, availableWidthPx: width },+ supportedFixes: ['shorten the legend label or use a wider viewBox'],+ }]);+ }++ const titleY = baselineY - footprint.extraHeight - 20;+ const legendTopY = titleY - 10;+ if (legendTopY < minTitleY) {+ if (unfit === 'hide') return null;+ const message = `[legend/vertical-overflow] ${diagramType} legend needs ${footprint.rowCount} rows, which would start at y=${legendTopY} above the available legend band at y=${minTitleY}.`;+ throwDiagnosticError(message, [{+ code: 'legend/vertical-overflow',+ severity: 'error',+ message,+ subject: { diagramType, path: '/meta/legend' },+ evidence: { rowCount: footprint.rowCount, requiredTopY: legendTopY, availableTopY: minTitleY },+ supportedFixes: ['shorten legend labels, hide nonessential entries, or use a wider viewBox'],+ }]);+ }++ const positioned = [];+ footprint.rows.forEach((row, rowIndex) => {+ let entryX = x;+ const baseline = baselineY - (footprint.rowCount - rowIndex - 1) * lineGap;+ for (const entry of row) {+ positioned.push({ ...entry, x: entryX, baseline, row: rowIndex });+ entryX += entry.width + itemGap;+ }+ });++ const legendRects = [+ { kind: 'title', x, y: legendTopY, width: 42, height: 13 },+ ...positioned.map((entry) => ({+ kind: entry.kind,+ x: entry.x,+ y: entry.baseline - 9,+ width: entry.width,+ height: 12,+ })),+ ];+ const collision = legendRects.find((legendRect) => obstacles.some((obstacle) => (+ Array.isArray(obstacle.start) && Array.isArray(obstacle.end)+ ? segmentIntersectsRect({ start: obstacle.start, end: obstacle.end }, legendRect)+ : rectsOverlap(obstacle, legendRect)+ )));+ if (collision) {+ if (unfit === 'hide') return null;+ const message = `[legend/content-overlap] ${diagramType} legend entry "${collision.kind}" overlaps authored relationship geometry.`;+ throwDiagnosticError(message, [{+ code: 'legend/content-overlap',+ severity: 'error',+ message,+ subject: { diagramType, path: '/meta/legend' },+ evidence: { legendKind: collision.kind, legendRect: collision },+ supportedFixes: ['shorten or hide legend entries, use a wider viewBox, or move the authored relationship route/label out of the legend band'],+ }]);+ }++ return {+ entries: positioned,+ rowCount: footprint.rowCount,+ titleY,+ fontSize,+ };+}++export function renderLegend({ entries, layout, renderSwatch }) {+ if (!entries.length) return '';+ const measured = measureLegend(entries, layout);+ if (!measured) return '';+ const hasInteractiveEntries = measured.entries.some((entry) => entry.interactive);+ const rootAttributes = hasInteractiveEntries ? ' data-legend data-legend-bridge' : ' data-legend';+ const parts = [+ ` <g${rootAttributes}>`,+ ` <text x="${layout.x}" y="${measured.titleY}" class="t-primary" font-size="10" font-weight="600">Legend</text>`,+ ];++ for (const entry of measured.entries) {+ const interactive = entry.interactive+ ? ` data-legend-kind="${esc(entry.kind)}" data-legend-label="${esc(entry.label)}"`+ : '';+ parts.push(` <g data-legend-semantic-kind="${esc(entry.kind)}"${interactive} data-legend-x="${entry.x}" data-legend-baseline="${entry.baseline}" data-legend-width="${entry.width}">`);+ parts.push(` ${renderSwatch(entry)}`);+ parts.push(` <text x="${entry.x + (entry.swatchWidth ?? 14) + (entry.swatchGap ?? DEFAULT_SWATCH_GAP)}" y="${entry.baseline}" class="t-muted" font-size="${measured.fontSize}">${esc(entry.label)}</text>`);+ parts.push(' </g>');+ }+ parts.push(' </g>');+ return parts.join('\n');+}diff --git a/archify/renderers/workflow/README.md b/archify/renderers/workflow/README.mdindex c6b4da79..3635da77 100644--- a/archify/renderers/workflow/README.md+++ b/archify/renderers/workflow/README.md@@ -56,6 +56,14 @@ The schema lives at:archify/schemas/workflow.schema.json```+## Legend++The default legend derives component kinds from `nodes[].type`. Supported+`meta.legend.entries` keys, in stable order, are `frontend`, `backend`,+`security`, `messagebus`, `database`, `cloud`, and `external`. Labels and+visibility may be overridden through the shared legend contract; only kinds+backed by rendered nodes receive Semantic Legend controls.+## Layout budget| Constant | Value |diff --git a/archify/renderers/workflow/render-workflow.mjs b/archify/renderers/workflow/render-workflow.mjsindex 16f69cef..14a1ab7b 100644--- a/archify/renderers/workflow/render-workflow.mjs+++ b/archify/renderers/workflow/render-workflow.mjs@@ -3,6 +3,7 @@ import { fileURLToPath } from 'node:url';import { esc, renderDefinitions, renderSemanticSigil, textUnits } from '../shared/utils.mjs';import { animateAttr, focusEdgeAttrs, focusNodeAttrs, focusNodeTitle, loadDiagram, writeDiagram, svgAccessibleText, svgRootAttrs } from '../shared/cli.mjs';import { throwDiagnosticProblems } from '../shared/diagnostics.mjs';+import { resolveLegend, renderLegend as renderResolvedLegend } from '../shared/legend.mjs';import {asArray,isFinitePoint,@@ -576,31 +577,33 @@ function renderEdgeLabel(edge, index) {</g>`;}+const LEGEND_CATALOG = [+ ['frontend', 'User UI'],+ ['backend', 'Agent logic'],+ ['security', 'Policy'],+ ['messagebus', 'Tool action'],+ ['database', 'Context / trace'],+ ['cloud', 'Cloud service'],+ ['external', 'External system'],+].map(([kind, label]) => ({ kind, label }));+function renderLegend() {- const y = legendY();- return ` <g data-legend-bridge>- <text x="175" y="${y - 20}" class="t-primary" font-size="10" font-weight="600">Legend</text>- <g data-legend-kind="frontend">- <rect x="175" y="${y - 8}" width="14" height="9" rx="2" class="c-frontend" stroke-width="1"/>- <text x="195" y="${y}" class="t-muted" font-size="7">User UI</text>- </g>- <g data-legend-kind="backend">- <rect x="260" y="${y - 8}" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>- <text x="280" y="${y}" class="t-muted" font-size="7">Agent logic</text>- </g>- <g data-legend-kind="security">- <rect x="370" y="${y - 8}" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>- <text x="390" y="${y}" class="t-muted" font-size="7">Policy</text>- </g>- <g data-legend-kind="messagebus">- <rect x="455" y="${y - 8}" width="14" height="9" rx="2" class="c-messagebus" stroke-width="1"/>- <text x="475" y="${y}" class="t-muted" font-size="7">Tool action</text>- </g>- <g data-legend-kind="database">- <rect x="565" y="${y - 8}" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>- <text x="585" y="${y}" class="t-muted" font-size="7">Context / trace</text>- </g>- </g>`;+ const presentKinds = new Set([...nodes.values()].map((node) => node.type));+ const entries = resolveLegend(workflow.meta?.legend, LEGEND_CATALOG, presentKinds);+ return renderResolvedLegend({+ entries,+ layout: {+ x: 20,+ baselineY: legendY(),+ width: viewBox[0] - 40,+ fontSize: 7,+ itemGap: 7,+ minTitleY: lastLaneBottom() + 8,+ unfit: workflow.meta?.legend === undefined ? 'hide' : 'error',+ diagramType: 'workflow',+ },+ renderSwatch: (entry) => `<rect x="${entry.x}" y="${entry.baseline - 8}" width="14" height="9" rx="2" class="${componentFill[entry.kind] || 'c-external'}" stroke-width="1"/>`,+ });}function renderSvg() {diff --git a/archify/schemas/README.md b/archify/schemas/README.mdindex e07e7bf7..11d281b4 100644--- a/archify/schemas/README.md+++ b/archify/schemas/README.md@@ -29,6 +29,54 @@ It may also include up to five guided `views`. Each view has a unique `id`, areader-facing `label`, a non-empty `focus` list of existing semantic node IDs,and an optional short `note`.+### Legend presentation contract++Every `meta` object accepts the same optional legend shape without changing+`schema_version: 1`:++```json+"legend": {+ "mode": "auto",+ "entries": {+ "security": { "label": "restricted data", "visible": true }+ }+}+```++`mode` is `auto` (the default), `all`, or `hidden`. `auto` includes only kinds+present in typed IR; `all` includes the renderer's full stable catalog;+`hidden` removes the complete legend and takes precedence over entry overrides.+Architecture documents that omit an explicit `viewBox` size that automatic+viewBox from the same measured resolved legend footprint used for final SVG+layout. Across all renderers, legacy documents that omit `meta.legend` use a+compatibility-safe implicit `auto`: if the resolved legend cannot fit an+explicit authored viewBox without overlap, Archify omits the complete legend+instead of turning a previously valid schema-v1 document into a hard failure.+Once an author adds `meta.legend` (including explicit `mode: "auto"`), the+layout is intentional and unfit labels or bands fail with a path-prefixed+diagnostic. An entry may set a non-empty, bounded `label`, boolean `visible`,+or both.+`visible: false` removes a resolved entry and `visible: true` forces a supported+but unused kind into the visual legend. Unknown kinds and properties fail+strict validation.++Supported keys are renderer-owned:++| Renderer | `meta.legend.entries` keys |+|---|---|+| Architecture | `frontend`, `backend`, `database`, `cloud`, `security`, `messagebus`, `external` |+| Workflow | `frontend`, `backend`, `security`, `messagebus`, `database`, `cloud`, `external` |+| Sequence | `emphasis`, `return`, `security`, `dashed`, `default` |+| Dataflow | `emphasis`, `security`, `dashed`, `database`, `default` |+| Lifecycle | `start`, `active`, `waiting`, `decision`, `success`, `failure`, `neutral`, `external` |++Labels are presentation only: they do not rename the stable kind, change+nodes/relationships, or create Semantic Lens edge facts. Sequence message and+Dataflow flow-variant entries are visual keys. Component/state entries backed+by exact compiled node facts receive the interactive Semantic Legend bridge;+this includes Dataflow `database` when a real `nodes[].type: "database"` fact+exists.+Every relationship collection (`connections`, `edges`, `messages`, `flows`, and`transitions`) accepts an optional author-controlled `id` using the shared IDpattern. The renderer keeps its source-order runtime key separately, while the@@ -57,6 +105,8 @@ The five diagram schemas reference `common.schema.json#/$defs/...`:`messagebus`, `external`- `variant` — `default`, `emphasis`, `security`, `dashed` (sequence messagesextend this list locally with `return`)+- `legendMode` and `legendEntry` — the shared strict mode and label/visibility+ override shapes used by each renderer-owned key map- `guidedViews` — the bounded, read-only reader paths accepted by `meta.views`- `cards` — the summary-card blocks rendered below the SVGdiff --git a/archify/schemas/architecture.schema.json b/archify/schemas/architecture.schema.jsonindex 03c10309..e925bd7f 100644--- a/archify/schemas/architecture.schema.json+++ b/archify/schemas/architecture.schema.json@@ -33,6 +33,26 @@}},"views": { "$ref": "common.schema.json#/$defs/guidedViews" },+ "legend": {+ "type": "object",+ "additionalProperties": false,+ "properties": {+ "mode": { "$ref": "common.schema.json#/$defs/legendMode" },+ "entries": {+ "type": "object",+ "additionalProperties": false,+ "properties": {+ "frontend": { "$ref": "common.schema.json#/$defs/legendEntry" },+ "backend": { "$ref": "common.schema.json#/$defs/legendEntry" },+ "database": { "$ref": "common.schema.json#/$defs/legendEntry" },+ "cloud": { "$ref": "common.schema.json#/$defs/legendEntry" },+ "security": { "$ref": "common.schema.json#/$defs/legendEntry" },+ "messagebus": { "$ref": "common.schema.json#/$defs/legendEntry" },+ "external": { "$ref": "common.schema.json#/$defs/legendEntry" }+ }+ }+ }+ },"viewBox": {"type": "array","prefixItems": [diff --git a/archify/schemas/common.schema.json b/archify/schemas/common.schema.jsonindex 6eb7a705..828233a1 100644--- a/archify/schemas/common.schema.json+++ b/archify/schemas/common.schema.json@@ -23,6 +23,18 @@"variant": {"enum": ["default", "emphasis", "security", "dashed"]},+ "legendMode": {+ "enum": ["auto", "all", "hidden"]+ },+ "legendEntry": {+ "type": "object",+ "additionalProperties": false,+ "minProperties": 1,+ "properties": {+ "label": { "type": "string", "minLength": 1, "maxLength": 80 },+ "visible": { "type": "boolean" }+ }+ },"guidedViews": {"type": "array","maxItems": 5,diff --git a/archify/schemas/dataflow.schema.json b/archify/schemas/dataflow.schema.jsonindex 0b43e0be..e29c4b3e 100644--- a/archify/schemas/dataflow.schema.json+++ b/archify/schemas/dataflow.schema.json@@ -59,6 +59,24 @@"views": {"$ref": "common.schema.json#/$defs/guidedViews"},+ "legend": {+ "type": "object",+ "additionalProperties": false,+ "properties": {+ "mode": { "$ref": "common.schema.json#/$defs/legendMode" },+ "entries": {+ "type": "object",+ "additionalProperties": false,+ "properties": {+ "default": { "$ref": "common.schema.json#/$defs/legendEntry" },+ "emphasis": { "$ref": "common.schema.json#/$defs/legendEntry" },+ "security": { "$ref": "common.schema.json#/$defs/legendEntry" },+ "dashed": { "$ref": "common.schema.json#/$defs/legendEntry" },+ "database": { "$ref": "common.schema.json#/$defs/legendEntry" }+ }+ }+ }+ },"viewBox": {"type": "array","prefixItems": [diff --git a/archify/schemas/lifecycle.schema.json b/archify/schemas/lifecycle.schema.jsonindex 82704618..52fdd769 100644--- a/archify/schemas/lifecycle.schema.json+++ b/archify/schemas/lifecycle.schema.json@@ -59,6 +59,27 @@"views": {"$ref": "common.schema.json#/$defs/guidedViews"},+ "legend": {+ "type": "object",+ "additionalProperties": false,+ "properties": {+ "mode": { "$ref": "common.schema.json#/$defs/legendMode" },+ "entries": {+ "type": "object",+ "additionalProperties": false,+ "properties": {+ "start": { "$ref": "common.schema.json#/$defs/legendEntry" },+ "active": { "$ref": "common.schema.json#/$defs/legendEntry" },+ "waiting": { "$ref": "common.schema.json#/$defs/legendEntry" },+ "decision": { "$ref": "common.schema.json#/$defs/legendEntry" },+ "success": { "$ref": "common.schema.json#/$defs/legendEntry" },+ "failure": { "$ref": "common.schema.json#/$defs/legendEntry" },+ "neutral": { "$ref": "common.schema.json#/$defs/legendEntry" },+ "external": { "$ref": "common.schema.json#/$defs/legendEntry" }+ }+ }+ }+ },"viewBox": {"type": "array","prefixItems": [diff --git a/archify/schemas/sequence.schema.json b/archify/schemas/sequence.schema.jsonindex 4cf114c5..f63761ca 100644--- a/archify/schemas/sequence.schema.json+++ b/archify/schemas/sequence.schema.json@@ -58,6 +58,24 @@"views": {"$ref": "common.schema.json#/$defs/guidedViews"},+ "legend": {+ "type": "object",+ "additionalProperties": false,+ "properties": {+ "mode": { "$ref": "common.schema.json#/$defs/legendMode" },+ "entries": {+ "type": "object",+ "additionalProperties": false,+ "properties": {+ "default": { "$ref": "common.schema.json#/$defs/legendEntry" },+ "emphasis": { "$ref": "common.schema.json#/$defs/legendEntry" },+ "security": { "$ref": "common.schema.json#/$defs/legendEntry" },+ "dashed": { "$ref": "common.schema.json#/$defs/legendEntry" },+ "return": { "$ref": "common.schema.json#/$defs/legendEntry" }+ }+ }+ }+ },"viewBox": {"type": "array","prefixItems": [diff --git a/archify/schemas/workflow.schema.json b/archify/schemas/workflow.schema.jsonindex 98df53a9..1d7a4e1d 100644--- a/archify/schemas/workflow.schema.json+++ b/archify/schemas/workflow.schema.json@@ -59,6 +59,26 @@"views": {"$ref": "common.schema.json#/$defs/guidedViews"},+ "legend": {+ "type": "object",+ "additionalProperties": false,+ "properties": {+ "mode": { "$ref": "common.schema.json#/$defs/legendMode" },+ "entries": {+ "type": "object",+ "additionalProperties": false,+ "properties": {+ "frontend": { "$ref": "common.schema.json#/$defs/legendEntry" },+ "backend": { "$ref": "common.schema.json#/$defs/legendEntry" },+ "database": { "$ref": "common.schema.json#/$defs/legendEntry" },+ "cloud": { "$ref": "common.schema.json#/$defs/legendEntry" },+ "security": { "$ref": "common.schema.json#/$defs/legendEntry" },+ "messagebus": { "$ref": "common.schema.json#/$defs/legendEntry" },+ "external": { "$ref": "common.schema.json#/$defs/legendEntry" }+ }+ }+ }+ },"viewBox": {"type": "array","prefixItems": [diff --git a/archify/test/architecture-delta.test.mjs b/archify/test/architecture-delta.test.mjsindex b2fea950..51f1426a 100644--- a/archify/test/architecture-delta.test.mjs+++ b/archify/test/architecture-delta.test.mjs@@ -66,6 +66,34 @@ test('architecture compare classifies authored facts separately from geometry anassert.deepEqual(boundaryReceipt.changes.boundaries.find((change) => change.label === 'Fraud edge').classifications, ['scope']);});+test('legend-only changes are presentation changes and never topology changes', () => {+ const base = read(baseFixture);+ const head = read(baseFixture);+ head.meta.legend = {+ entries: {+ security: { label: 'Trust boundary', visible: true },+ database: { visible: false },+ },+ };++ const receipt = compareArchitecture(base, head);+ assert.equal(receipt.summary.presentationChanged, true);+ assert.deepEqual(receipt.summary.components, {+ added: 0,+ changed: 0,+ evidenceChanged: 0,+ removed: 0,+ moved: 0,+ });+ assert.deepEqual(receipt.summary.connections, {+ added: 0,+ changed: 0,+ removed: 0,+ rerouted: 0,+ });+ assert.deepEqual(receipt.changes, { components: [], connections: [], boundaries: [] });+});+test('canonical architecture ignores formatting, entity order, and set-like order', () => {const original = read(baseFixture);const reordered = JSON.parse(JSON.stringify(original));diff --git a/archify/test/legend-contract.test.mjs b/archify/test/legend-contract.test.mjsnew file mode 100644index 00000000..de4c6c17--- /dev/null+++ b/archify/test/legend-contract.test.mjs@@ -0,0 +1,404 @@+import { test } from 'node:test';+import assert from 'node:assert/strict';+import { spawnSync } from 'node:child_process';+import fs from 'node:fs';+import os from 'node:os';+import path from 'node:path';+import { fileURLToPath } from 'node:url';++const __dirname = path.dirname(fileURLToPath(import.meta.url));+const skillRoot = path.resolve(__dirname, '..');+const cli = path.join(skillRoot, 'bin/archify.mjs');+const tmp = fs.mkdtempSync(path.join(os.tmpdir(), 'archify-legend-contract-'));+let sequence = 0;++const FIXTURES = {+ architecture: {+ schema_version: 1,+ diagram_type: 'architecture',+ meta: { title: 'Legend architecture', viewBox: [720, 420] },+ components: [+ { id: 'ui', type: 'frontend', label: 'UI', pos: [60, 90] },+ { id: 'store', type: 'database', label: 'Store', pos: [300, 90] },+ ],+ connections: [],+ },+ workflow: {+ schema_version: 1,+ diagram_type: 'workflow',+ meta: { title: 'Legend workflow', viewBox: [720, 360] },+ lanes: [{ id: 'main', label: 'Main' }],+ nodes: [+ { id: 'ui', lane: 'main', col: 0, type: 'frontend', label: 'UI' },+ { id: 'agent', lane: 'main', col: 2, type: 'backend', label: 'Agent' },+ ],+ edges: [],+ },+ sequence: {+ schema_version: 1,+ diagram_type: 'sequence',+ meta: { title: 'Legend sequence', viewBox: [720, 560] },+ participants: [+ { id: 'client', type: 'frontend', label: 'Client' },+ { id: 'api', type: 'backend', label: 'API' },+ ],+ messages: [+ { from: 'client', to: 'api', y: 220, label: 'request', variant: 'emphasis' },+ { from: 'api', to: 'client', y: 280, label: 'response', variant: 'return' },+ ],+ },+ dataflow: {+ schema_version: 1,+ diagram_type: 'dataflow',+ meta: { title: 'Default Flow Only' },+ stages: [{ label: 'Input' }, { label: 'Output' }],+ nodes: [+ { id: 'input', type: 'backend', label: 'Input', stage: 0, row: 0 },+ { id: 'output', type: 'backend', label: 'Output', stage: 1, row: 0 },+ ],+ flows: [+ { from: 'input', to: 'output', label: 'request', route: 'straight' },+ ],+ },+ lifecycle: {+ schema_version: 1,+ diagram_type: 'lifecycle',+ meta: { title: 'No Waiting or Failure', viewBox: [720, 566] },+ lanes: [{ id: 'main', label: 'Lifecycle' }],+ states: [+ { id: 'started', type: 'start', label: 'Started', lane: 'main', col: 0 },+ { id: 'running', type: 'active', label: 'Running', lane: 'main', col: 1 },+ { id: 'completed', type: 'success', label: 'Completed', lane: 'main', col: 2 },+ ],+ transitions: [+ { from: 'started', to: 'running' },+ { from: 'running', to: 'completed' },+ ],+ },+};++const CATALOGS = {+ architecture: ['frontend', 'backend', 'database', 'cloud', 'security', 'messagebus', 'external'],+ workflow: ['frontend', 'backend', 'security', 'messagebus', 'database', 'cloud', 'external'],+ sequence: ['emphasis', 'return', 'security', 'dashed', 'default'],+ dataflow: ['emphasis', 'security', 'dashed', 'database', 'default'],+ lifecycle: ['start', 'active', 'waiting', 'decision', 'success', 'failure', 'neutral', 'external'],+};++const AUTO_KINDS = {+ architecture: ['frontend', 'database'],+ workflow: ['frontend', 'backend'],+ sequence: ['emphasis', 'return'],+ dataflow: ['default'],+ lifecycle: ['start', 'active', 'success'],+};++function clone(value) {+ return JSON.parse(JSON.stringify(value));+}++function withLegend(type, legend) {+ const doc = clone(FIXTURES[type]);+ if (legend !== undefined) doc.meta.legend = legend;+ return doc;+}++function run(type, doc, command = 'render') {+ const id = sequence++;+ const input = path.join(tmp, `${id}-${type}.json`);+ const output = path.join(tmp, `${id}-${type}.html`);+ fs.writeFileSync(input, JSON.stringify(doc));+ const args = command === 'render'+ ? [cli, 'render', type, input, output]+ : [cli, 'validate', type, input, '--json'];+ const result = spawnSync(process.execPath, args, { cwd: skillRoot, encoding: 'utf8' });+ return {+ ...result,+ html: result.status === 0 && command === 'render' ? fs.readFileSync(output, 'utf8') : '',+ };+}++function render(type, doc) {+ const result = run(type, doc);+ assert.equal(result.status, 0, result.stderr || result.stdout);+ return result.html;+}++function canonicalSvg(html) {+ return html.match(/<svg\b[\s\S]*?<\/svg>/)?.[0] || '';+}++function attrValues(source, attribute) {+ const pattern = new RegExp(`${attribute}="([^"]+)"`, 'g');+ return [...source.matchAll(pattern)].map((match) => match[1]);+}++function legendKinds(html) {+ return attrValues(canonicalSvg(html), 'data-legend-semantic-kind');+}++function validateFailure(type, doc) {+ const result = run(type, doc, 'validate');+ assert.notEqual(result.status, 0, `expected ${type} validation to fail`);+ const payload = JSON.parse(result.stdout);+ assert.equal(payload.ok, false);+ return payload;+}++test('public typed renderers default to auto and expose only authored semantic kinds', () => {+ for (const type of Object.keys(FIXTURES)) {+ const html = render(type, FIXTURES[type]);+ assert.deepEqual(legendKinds(html), AUTO_KINDS[type], type);+ }+});++test('Dataflow database node facts are interactive while flow variants stay visual-only', () => {+ const withDatabase = clone(FIXTURES.dataflow);+ withDatabase.nodes[1].type = 'database';+ const databaseSvg = canonicalSvg(render('dataflow', withDatabase));+ assert.deepEqual(attrValues(databaseSvg, 'data-legend-semantic-kind'), ['database', 'default']);+ assert.deepEqual(attrValues(databaseSvg, 'data-legend-kind'), ['database']);+ assert.equal((databaseSvg.match(/data-legend-bridge(?:\s|>)/g) || []).length, 1);+ assert.ok(attrValues(databaseSvg, 'data-node-kind').includes('database'));++ const forcedWithoutFact = canonicalSvg(render('dataflow', withLegend('dataflow', {+ entries: { database: { visible: true } },+ })));+ assert.deepEqual(attrValues(forcedWithoutFact, 'data-legend-semantic-kind'), ['database', 'default']);+ assert.deepEqual(attrValues(forcedWithoutFact, 'data-legend-kind'), []);+ assert.doesNotMatch(forcedWithoutFact, /data-legend-bridge/);+});++test('Issue #52 dataflow and lifecycle reproductions publish truthful default legends', () => {+ const dataflow = canonicalSvg(render('dataflow', FIXTURES.dataflow));+ assert.deepEqual(attrValues(dataflow, 'data-legend-semantic-kind'), ['default']);+ assert.doesNotMatch(dataflow, /policy \/ PII|async batch|primary data|data store/i);+ assert.doesNotMatch(dataflow, /data-legend-bridge|data-legend-kind=/);++ const lifecycle = canonicalSvg(render('lifecycle', FIXTURES.lifecycle));+ const lifecycleLegend = lifecycle.slice(lifecycle.indexOf('<!-- Legend -->'));+ assert.deepEqual(attrValues(lifecycleLegend, 'data-legend-semantic-kind'), ['start', 'active', 'success']);+ assert.doesNotMatch(lifecycleLegend, /waiting|failure \/ exit/i);+ assert.deepEqual(attrValues(lifecycleLegend, 'data-legend-kind'), ['start', 'active', 'success']);+});++test('all mode follows each renderer-owned stable catalog order', () => {+ for (const type of Object.keys(FIXTURES)) {+ const html = render(type, withLegend(type, { mode: 'all' }));+ assert.deepEqual(legendKinds(html), CATALOGS[type], type);+ }+});++test('hidden mode removes the complete legend and overrides visible true', () => {+ for (const type of Object.keys(FIXTURES)) {+ const forcedKind = CATALOGS[type].at(-1);+ const html = render(type, withLegend(type, {+ mode: 'hidden',+ entries: { [forcedKind]: { label: 'Must stay hidden', visible: true } },+ }));+ const svg = canonicalSvg(html);+ assert.doesNotMatch(svg, />Legend</);+ assert.doesNotMatch(svg, /data-legend(?:-semantic-kind|-kind|-bridge)?=/);+ assert.doesNotMatch(svg, /Must stay hidden/);+ }+});++test('visibility overrides apply after auto/all and empty legends leave no chrome', () => {+ const cases = {+ architecture: { hidden: 'frontend', forced: 'external' },+ workflow: { hidden: 'frontend', forced: 'security' },+ sequence: { hidden: 'emphasis', forced: 'dashed' },+ dataflow: { hidden: 'default', forced: 'database' },+ lifecycle: { hidden: 'active', forced: 'waiting' },+ };+ for (const [type, kinds] of Object.entries(cases)) {+ const html = render(type, withLegend(type, {+ entries: {+ [kinds.hidden]: { visible: false },+ [kinds.forced]: { visible: true },+ },+ }));+ const expected = AUTO_KINDS[type]+ .filter((kind) => kind !== kinds.hidden)+ .concat(kinds.forced)+ .sort((left, right) => CATALOGS[type].indexOf(left) - CATALOGS[type].indexOf(right));+ assert.deepEqual(legendKinds(html), expected, type);+ }++ const allMinusSecurity = render('sequence', withLegend('sequence', {+ mode: 'all',+ entries: { security: { visible: false } },+ }));+ assert.deepEqual(+ legendKinds(allMinusSecurity),+ CATALOGS.sequence.filter((kind) => kind !== 'security'),+ );++ for (const type of Object.keys(FIXTURES)) {+ const entries = Object.fromEntries(AUTO_KINDS[type].map((kind) => [kind, { visible: false }]));+ const empty = canonicalSvg(render(type, withLegend(type, { entries })));+ assert.doesNotMatch(empty, />Legend</, type);+ assert.doesNotMatch(empty, /data-legend/, type);+ }+});++test('label overrides round-trip through all five public renderers', () => {+ for (const type of Object.keys(FIXTURES)) {+ const kind = AUTO_KINDS[type][0];+ const label = `Custom ${type} label`;+ const svg = canonicalSvg(render(type, withLegend(type, {+ entries: { [kind]: { label } },+ })));+ assert.match(svg, new RegExp(`data-legend-semantic-kind="${kind}"`), type);+ assert.match(svg, new RegExp(`>${label}<`), type);+ if (['architecture', 'workflow', 'lifecycle'].includes(type)) {+ assert.match(svg, new RegExp(`data-legend-kind="${kind}"[^>]+data-legend-label="${label}"`), type);+ } else {+ assert.doesNotMatch(svg, /data-legend-kind=/, type);+ }+ }+});++test('label overrides preserve stable kinds and exact Semantic Legend boundaries', () => {+ const architecture = render('architecture', withLegend('architecture', {+ entries: {+ frontend: { label: 'Reader <UI> & "ops"' },+ external: { label: 'Future integration', visible: true },+ },+ }));+ const svg = canonicalSvg(architecture);+ const baselineSvg = canonicalSvg(render('architecture', FIXTURES.architecture));+ assert.deepEqual(attrValues(svg, 'data-node-id'), attrValues(baselineSvg, 'data-node-id'));+ assert.deepEqual(attrValues(svg, 'data-node-kind'), attrValues(baselineSvg, 'data-node-kind'));+ assert.deepEqual(attrValues(svg, 'data-edge-from'), attrValues(baselineSvg, 'data-edge-from'));+ assert.match(svg, />Reader <UI> & "ops"</);+ assert.doesNotMatch(svg, /<UI>/);+ assert.match(svg, />Future integration</);+ assert.deepEqual(attrValues(svg, 'data-legend-semantic-kind'), ['frontend', 'database', 'external']);+ assert.deepEqual(attrValues(svg, 'data-legend-kind'), ['frontend', 'database']);+ assert.match(svg, /data-legend-kind="frontend"[^>]+data-legend-label="Reader <UI> & "ops""/);+ assert.match(architecture, /entry\.getAttribute\('data-legend-label'\)/);++ for (const type of ['sequence', 'dataflow']) {+ const kind = type === 'sequence' ? 'emphasis' : 'default';+ const html = canonicalSvg(render(type, withLegend(type, {+ entries: { [kind]: { label: 'Visible only' } },+ })));+ assert.match(html, />Visible only</);+ assert.doesNotMatch(html, /data-legend-bridge|data-legend-kind=/);+ }+});++test('strict per-renderer schemas reject malformed legend contracts with path-prefixed errors', () => {+ const known = {+ architecture: 'frontend', workflow: 'frontend', sequence: 'default', dataflow: 'default', lifecycle: 'start',+ };+ const cases = [+ [{ mode: 'sometimes' }, '/meta/legend/mode'],+ [{ entries: { unknown_kind: { visible: true } } }, '/meta/legend/entries'],+ [(type) => ({ entries: { [known[type]]: { label: '' } } }), '/meta/legend/entries/'],+ [(type) => ({ entries: { [known[type]]: { visible: 'yes' } } }), '/meta/legend/entries/'],+ [(type) => ({ entries: { [known[type]]: { color: '#fff' } } }), '/meta/legend/entries/'],+ [{ mode: 'auto', extra: true }, '/meta/legend'],+ ];+ for (const type of Object.keys(FIXTURES)) {+ for (const [legendOrFactory, pathPrefix] of cases) {+ const legend = typeof legendOrFactory === 'function' ? legendOrFactory(type) : legendOrFactory;+ const failure = validateFailure(type, withLegend(type, legend));+ assert.ok(+ failure.diagnostics.some((diagnostic) => diagnostic.subject.path.startsWith(pathPrefix)),+ `${type}: expected a diagnostic under ${pathPrefix}: ${JSON.stringify(failure.diagnostics)}`,+ );+ }+ }+});++test('measured legends fail explicitly instead of wrapping into diagram content', () => {+ const label = '界'.repeat(40);+ const entries = Object.fromEntries(CATALOGS.workflow.map((kind) => [kind, { label }]));+ const failure = validateFailure('workflow', withLegend('workflow', { mode: 'all', entries }));+ const diagnostic = failure.diagnostics.find((entry) => entry.code === 'legend/vertical-overflow');+ assert.ok(diagnostic, JSON.stringify(failure.diagnostics));+ assert.equal(diagnostic.subject.path, '/meta/legend');+ assert.ok(diagnostic.evidence.rowCount > 1);++ const routedEntries = Object.fromEntries(CATALOGS.architecture.map((kind) => [+ kind,+ { label: `Long ${kind} convention` },+ ]));+ const routed = withLegend('architecture', { mode: 'all', entries: routedEntries });+ routed.connections = [{+ from: 'ui',+ to: 'store',+ label: 'bottom route',+ fromSide: 'bottom',+ toSide: 'bottom',+ via: [[120, 382], [360, 382]],+ labelAt: [240, 370],+ }];+ const renderFailure = run('architecture', routed);+ assert.notEqual(renderFailure.status, 0);+ assert.match(renderFailure.stderr, /legend\/content-overlap/);+ assert.equal(renderFailure.html, '');+});++test('explicit Architecture viewBox rejects legend title rectangles that overlap content', () => {+ const doc = clone(FIXTURES.architecture);+ doc.meta.viewBox = [320, 320];+ doc.meta.legend = { mode: 'auto' };+ doc.components = [+ { id: 'ui', type: 'frontend', label: 'UI', pos: [40, 216], size: [120, 60] },+ ];+ const failure = validateFailure('architecture', doc);+ const diagnostic = failure.diagnostics.find((entry) => entry.code === 'legend/vertical-overflow');+ assert.ok(diagnostic, JSON.stringify(failure.diagnostics));+ assert.equal(diagnostic.subject.path, '/meta/legend');+ assert.ok(diagnostic.evidence.requiredTopY < diagnostic.evidence.availableTopY);+});++test('a single unfit label fails with a path-specific width diagnostic', () => {+ const failure = validateFailure('architecture', withLegend('architecture', {+ entries: { frontend: { label: '界'.repeat(80) } },+ }));+ const diagnostic = failure.diagnostics.find((entry) => entry.code === 'legend/label-too-wide');+ assert.ok(diagnostic, JSON.stringify(failure.diagnostics));+ assert.equal(diagnostic.subject.path, '/meta/legend/entries/frontend/label');+ assert.ok(diagnostic.evidence.measuredWidthPx > diagnostic.evidence.availableWidthPx);+});++test('measured legend rows share baselines and stay within the viewBox for localized labels', () => {+ const doc = withLegend('lifecycle', {+ mode: 'all',+ entries: {+ start: { label: '开始 / Start of the complete lifecycle' },+ active: { label: '正在执行 active processing' },+ waiting: { label: '等待人工输入' },+ decision: { label: 'Decision gate with deterministic wrapping' },+ success: { label: '成功完成' },+ failure: { label: 'Failure / 失败' },+ neutral: { label: 'Neutral state' },+ external: { label: 'External system' },+ },+ });+ const svg = canonicalSvg(render('lifecycle', doc));+ const viewBox = attrValues(svg.match(/<svg\b[^>]*>/)?.[0] || '', 'viewBox')[0].split(/\s+/).map(Number);+ const tags = [...svg.matchAll(/<g\b[^>]*data-legend-semantic-kind="[^"]+"[^>]*>/g)].map((match) => match[0]);+ assert.equal(tags.length, CATALOGS.lifecycle.length);+ const boxes = tags.map((tag) => ({+ x: Number(attrValues(tag, 'data-legend-x')[0]),+ y: Number(attrValues(tag, 'data-legend-baseline')[0]),+ width: Number(attrValues(tag, 'data-legend-width')[0]),+ }));+ assert.ok(boxes.every((box) => Number.isFinite(box.x) && Number.isFinite(box.y) && Number.isFinite(box.width)));+ assert.ok(boxes.every((box) => box.x >= 0 && box.x + box.width <= viewBox[2]));+ const rows = new Map();+ for (const box of boxes) rows.set(box.y, [...(rows.get(box.y) || []), box]);+ for (const row of rows.values()) {+ const sorted = [...row].sort((left, right) => left.x - right.x);+ for (let index = 1; index < sorted.length; index += 1) {+ assert.ok(sorted[index - 1].x + sorted[index - 1].width <= sorted[index].x);+ }+ }+});++process.on('exit', () => fs.rmSync(tmp, { recursive: true, force: true }));diff --git a/archify/test/semantic-legend-gateway.test.mjs b/archify/test/semantic-legend-gateway.test.mjsindex d4f326d3..b096e70d 100644--- a/archify/test/semantic-legend-gateway.test.mjs+++ b/archify/test/semantic-legend-gateway.test.mjs@@ -39,25 +39,35 @@ function values(svg, attribute) {test('only legends with an exact node-kind meaning publish bridge entries', () => {const architecture = canonicalSvg(render('architecture'));- const architectureKinds = [...new Set(values(architecture, 'data-node-kind'))];- assert.deepEqual(values(architecture, 'data-legend-kind'), architectureKinds);+ const architectureKinds = new Set(values(architecture, 'data-node-kind'));+ assert.deepEqual(new Set(values(architecture, 'data-legend-kind')), architectureKinds);assert.equal((architecture.match(/data-legend-bridge(?:\s|>)/g) || []).length, 1);const workflow = canonicalSvg(render('workflow'));assert.deepEqual(values(workflow, 'data-legend-kind'), [- 'frontend', 'backend', 'security', 'messagebus', 'database',+ 'frontend', 'backend', 'security', 'messagebus', 'database', 'cloud', 'external',]);const lifecycle = canonicalSvg(render('lifecycle'));assert.deepEqual(values(lifecycle, 'data-legend-kind'), [- 'active', 'waiting', 'success', 'failure',+ 'start', 'active', 'waiting', 'decision', 'success', 'failure',]);- for (const mode of ['sequence', 'dataflow']) {- const svg = canonicalSvg(render(mode));- assert.doesNotMatch(svg, /data-legend-bridge|data-legend-kind/, mode);- assert.match(svg, />Legend</, mode);- }+ const sequence = canonicalSvg(render('sequence'));+ assert.deepEqual(values(sequence, 'data-legend-semantic-kind'), [+ 'emphasis', 'return', 'security', 'dashed', 'default',+ ]);+ assert.doesNotMatch(sequence, /data-legend-bridge|data-legend-kind=/);+ assert.match(sequence, />Legend</);++ const dataflow = canonicalSvg(render('dataflow'));+ assert.deepEqual(values(dataflow, 'data-legend-semantic-kind'), [+ 'emphasis', 'security', 'dashed', 'database', 'default',+ ]);+ assert.deepEqual(values(dataflow, 'data-legend-kind'), ['database']);+ assert.equal((dataflow.match(/data-legend-bridge(?:\s|>)/g) || []).length, 1);+ assert.ok(values(dataflow, 'data-node-kind').includes('database'));+ assert.match(dataflow, />Legend</);});test('runtime decoration derives counts from compiled node facts and stays viewer-only', () => {@@ -69,7 +79,8 @@ test('runtime decoration derives counts from compiled node facts and stays vieweassert.match(html, /data-legend-count-badge/);assert.match(html, /entry\.setAttribute\('role', 'button'\)/);assert.match(html, /legendBridge\.setAttribute\('role', legendEntries\.length >= 3 \? 'toolbar' : 'group'\)/);- assert.match(html, /entry\.setAttribute\('aria-label', 'Inspect ' \+ fact\.label/);+ assert.match(html, /var visibleLabel = entry\.getAttribute\('data-legend-label'\) \|\| fact\.label/);+ assert.match(html, /entry\.setAttribute\('aria-label', 'Inspect ' \+ visibleLabel/);assert.match(html, /if \(!legendBridge \|\| html\.getAttribute\('data-embed'\) === 'true'\) return false/);assert.doesNotMatch(svg, /data-legend-bridge-runtime|data-legend-count=|role="toolbar"/);assert.doesNotMatch(svg, /data-legend-kind="[^"]+"[^>]+(?:role=|aria-pressed=)/);@@ -120,6 +131,7 @@ test('bridge state is print-safe, reduced-motion-safe, and absent from canonicalassert.match(html, /clone\.removeAttribute\('data-legend-preview-active'\)/);assert.match(html, /clone\.querySelectorAll\('\[data-legend-bridge-runtime\]'\)/);assert.match(html, /el\.removeAttribute\('data-legend-kind'\)/);+ assert.match(html, /el\.removeAttribute\('data-legend-label'\)/);assert.match(html, /el\.removeAttribute\('data-legend-bridge'\)/);assert.match(html, /\[data-legend-preview-match\], \[data-legend-preview-selected\], \[data-legend-preview-peer\]/);assert.match(html, /\[data-legend-bridge\], \[data-legend-kind\], \[data-legend-bridge-runtime\]/);diff --git a/archify/test/v1-compatibility.test.mjs b/archify/test/v1-compatibility.test.mjsindex 59fab395..59eb20c3 100644--- a/archify/test/v1-compatibility.test.mjs+++ b/archify/test/v1-compatibility.test.mjs@@ -96,6 +96,144 @@ for (const [mode, filename] of Object.entries(OFFICIAL_V1_EXAMPLES)) {});}+test('legacy v1 architecture auto viewBox accommodates all seven implicit auto legend kinds', () => {+ const types = ['frontend', 'backend', 'database', 'cloud', 'security', 'messagebus', 'external'];+ const doc = {+ schema_version: 1,+ diagram_type: 'architecture',+ meta: { title: 'Narrow legacy architecture' },+ components: types.map((type, index) => ({+ id: `component_${index}`,+ type,+ label: type,+ pos: [0, 40 + index * 76],+ size: [120, 52],+ })),+ connections: [],+ };++ const rendered = render('architecture', doc);+ assert.equal(rendered.code, 0, rendered.stderr);+ const html = fs.readFileSync(rendered.output, 'utf8');+ const svg = html.match(/<svg\b[\s\S]*?<\/svg>/)?.[0] || '';+ const viewBox = svg.match(/viewBox="0 0 ([\d.]+) ([\d.]+)"/)?.slice(1).map(Number);+ const baselines = [...svg.matchAll(/data-legend-baseline="([\d.]+)"/g)].map((match) => Number(match[1]));+ assert.deepEqual([...svg.matchAll(/data-legend-semantic-kind="([^"]+)"/g)].map((match) => match[1]), types);+ assert.ok(viewBox && baselines.length === types.length);+ assert.ok(viewBox[0] > 160, 'auto viewBox should widen for its widest measured legend entry');+ assert.ok(Math.max(...baselines) < viewBox[1]);+ assert.ok(Math.min(...baselines) > 40 + (types.length - 1) * 76 + 52);++ const validated = validate('architecture', doc);+ assert.equal(validated.code, 0, validated.stderr);+});++function narrowExplicitViewBoxDocuments() {+ const componentTypes = ['frontend', 'backend', 'database', 'cloud', 'security', 'messagebus', 'external'];+ return {+ architecture: {+ schema_version: 1,+ diagram_type: 'architecture',+ meta: { title: 'Legacy narrow architecture', viewBox: [320, 800] },+ components: componentTypes.map((type, index) => ({+ id: `component_${index}`,+ type,+ label: type,+ pos: [40, 90 + index * 90],+ size: [120, 52],+ })),+ connections: [],+ },+ workflow: {+ schema_version: 1,+ diagram_type: 'workflow',+ meta: { title: 'Legacy narrow workflow', viewBox: [700, 400] },+ lanes: [{ id: 'first', label: 'First' }, { id: 'second', label: 'Second' }],+ nodes: componentTypes.map((type, index) => ({+ id: `node_${index}`,+ lane: index < 3 ? 'first' : 'second',+ col: index < 3 ? index * 2 : [0, 2, 4, 5][index - 3],+ type,+ label: type,+ })),+ edges: [],+ },+ sequence: {+ schema_version: 1,+ diagram_type: 'sequence',+ meta: { title: 'Legacy narrow sequence', viewBox: [480, 480] },+ participants: [+ { id: 'left', type: 'frontend', label: 'Left' },+ { id: 'right', type: 'backend', label: 'Right' },+ ],+ messages: ['emphasis', 'return', 'security', 'dashed', 'default'].map((variant, index) => ({+ from: index % 2 ? 'right' : 'left',+ to: index % 2 ? 'left' : 'right',+ y: 170 + index * 40,+ label: variant,+ variant,+ })),+ },+ dataflow: {+ schema_version: 1,+ diagram_type: 'dataflow',+ meta: { title: 'Legacy narrow dataflow', viewBox: [423, 720] },+ stages: [{ label: 'Input' }, { label: 'Output' }],+ nodes: [+ { id: 'in_0', type: 'backend', label: 'In 0', stage: 0, row: 0 },+ { id: 'out_0', type: 'database', label: 'Out 0', stage: 1, row: 0 },+ { id: 'in_1', type: 'backend', label: 'In 1', stage: 0, row: 1 },+ { id: 'out_1', type: 'backend', label: 'Out 1', stage: 1, row: 1 },+ { id: 'in_2', type: 'backend', label: 'In 2', stage: 0, row: 2 },+ { id: 'out_2', type: 'backend', label: 'Out 2', stage: 1, row: 2 },+ { id: 'in_3', type: 'backend', label: 'In 3', stage: 0, row: 3 },+ { id: 'out_3', type: 'backend', label: 'Out 3', stage: 1, row: 3 },+ ],+ flows: ['emphasis', 'security', 'dashed', 'default'].map((variant, index) => ({+ from: `in_${index}`,+ to: `out_${index}`,+ label: variant,+ variant,+ route: 'straight',+ })),+ },+ lifecycle: {+ schema_version: 1,+ diagram_type: 'lifecycle',+ meta: { title: 'Legacy narrow lifecycle', viewBox: [420, 800] },+ lanes: [{ id: 'main', label: 'Lifecycle' }],+ states: ['start', 'active', 'waiting', 'decision', 'success', 'failure', 'neutral', 'external'].map((type, index) => ({+ id: `state_${index}`,+ type,+ label: type,+ lane: 'main',+ col: index % 2,+ yOffset: Math.floor(index / 2) * 72,+ })),+ transitions: [],+ },+ };+}++test('legacy v1 explicit narrow viewBoxes never hard-fail on an implicit auto legend', () => {+ const expectedNodeCounts = { architecture: 7, workflow: 7, sequence: 2, dataflow: 8, lifecycle: 8 };+ for (const [mode, doc] of Object.entries(narrowExplicitViewBoxDocuments())) {+ assert.equal(doc.meta.legend, undefined);+ const rendered = render(mode, doc);+ assert.equal(rendered.code, 0, `${mode}: ${rendered.stderr}`);+ const svg = fs.readFileSync(rendered.output, 'utf8').match(/<svg\b[\s\S]*?<\/svg>/)?.[0] || '';+ assert.equal((svg.match(/data-node-id=/g) || []).length, expectedNodeCounts[mode], `${mode}: topology must remain intact`);+ if (mode === 'lifecycle') {+ assert.match(svg, />Legend</, 'a fitting implicit legend should remain visible');+ assert.equal((svg.match(/data-legend-semantic-kind=/g) || []).length, 8);+ } else {+ assert.doesNotMatch(svg, />Legend</, `${mode}: an unfit implicit legend should degrade without overlap`);+ }+ const validated = validate(mode, doc);+ assert.equal(validated.code, 0, `${mode}: ${validated.stderr}`);+ }+});+test('legacy v1 architecture geometry remains renderable without an explicit quality profile', () => {const doc = {schema_version: 1,diff --git a/archify/test/webm-artifact.smoke.mjs b/archify/test/webm-artifact.smoke.mjsindex 4b4e55bf..11d6b3c5 100644--- a/archify/test/webm-artifact.smoke.mjs+++ b/archify/test/webm-artifact.smoke.mjs@@ -85,6 +85,75 @@ for (const [mode, example] of Object.entries({routeOutputs[mode] = rendered;}+function renderLegendFixture(mode, name, document) {+ const inputPath = path.join(tmp, `${name}.${mode}.json`);+ const outputPath = path.join(tmp, `${name}.${mode}.html`);+ fs.writeFileSync(inputPath, JSON.stringify(document));+ execFileSync(process.execPath, [+ path.join(skillRoot, `renderers/${mode}/render-${mode}.mjs`),+ inputPath,+ outputPath,+ ], { stdio: ['ignore', 'ignore', 'pipe'] });+ return outputPath;+}++const legendOutputs = {+ dataflow: renderLegendFixture('dataflow', 'issue-52-default-flow', {+ schema_version: 1,+ diagram_type: 'dataflow',+ meta: { title: 'Default Flow With Store' },+ stages: [{ label: 'Input' }, { label: 'Output' }],+ nodes: [+ { id: 'input', type: 'backend', label: 'Input', stage: 0, row: 0 },+ { id: 'output', type: 'database', label: 'Output Store', stage: 1, row: 0 },+ ],+ flows: [{ from: 'input', to: 'output', label: 'request', route: 'straight' }],+ }),+ lifecycle: renderLegendFixture('lifecycle', 'issue-52-no-waiting', {+ schema_version: 1,+ diagram_type: 'lifecycle',+ meta: { title: 'No Waiting or Failure', viewBox: [720, 566] },+ lanes: [{ id: 'main', label: 'Lifecycle' }],+ states: [+ { id: 'started', type: 'start', label: 'Started', lane: 'main', col: 0 },+ { id: 'running', type: 'active', label: 'Running', lane: 'main', col: 1 },+ { id: 'completed', type: 'success', label: 'Completed', lane: 'main', col: 2 },+ ],+ transitions: [{ from: 'started', to: 'running' }, { from: 'running', to: 'completed' }],+ }),+ custom: renderLegendFixture('architecture', 'issue-52-custom-label', {+ schema_version: 1,+ diagram_type: 'architecture',+ meta: {+ title: 'Custom Legend Label',+ viewBox: [720, 420],+ legend: {+ entries: {+ frontend: { label: 'Reader <UI> & ops' },+ external: { label: 'Future integration', visible: true },+ },+ },+ views: [{ id: 'main', label: 'Main', focus: ['ui', 'store'] }],+ },+ components: [+ { id: 'ui', type: 'frontend', label: 'UI', pos: [60, 90] },+ { id: 'store', type: 'database', label: 'Store', pos: [300, 90] },+ ],+ connections: [],+ }),+ hidden: renderLegendFixture('dataflow', 'issue-52-hidden', {+ schema_version: 1,+ diagram_type: 'dataflow',+ meta: { title: 'Hidden Legend', legend: { mode: 'hidden', entries: { database: { visible: true } } } },+ stages: [{ label: 'Input' }, { label: 'Output' }],+ nodes: [+ { id: 'input', type: 'backend', label: 'Input', stage: 0, row: 0 },+ { id: 'output', type: 'backend', label: 'Output', stage: 1, row: 0 },+ ],+ flows: [{ from: 'input', to: 'output', label: 'request', route: 'straight' }],+ }),+};+const parallelSource = JSON.parse(JSON.stringify(source));parallelSource.meta.title = 'Parallel Route Identity';parallelSource.connections[0].label = '';@@ -286,7 +355,8 @@ try {await cdp.send('Runtime.enable', {}, sessionId);async function navigateReady(file, condition, label) {- await cdp.send('Page.navigate', { url: pathToFileURL(file).href }, sessionId);+ const url = file instanceof URL ? file.href : pathToFileURL(file).href;+ await cdp.send('Page.navigate', { url }, sessionId);let ready = false;for (let attempt = 0; attempt < 100 && !ready; attempt += 1) {ready = await evaluate(cdp, sessionId, `document.readyState === "complete" && (${condition})`);@@ -295,6 +365,188 @@ try {assert.equal(ready, true, `${label} did not expose its browser export surface`);}+ async function verifyResolvedLegendContract(outputs) {+ async function inspectKinds(file, expectedKinds, theme) {+ const url = new URL(pathToFileURL(file).href);+ url.searchParams.set('theme', theme);+ await navigateReady(url, '!!(window.Archify && Archify.semanticLens)', `legend ${theme}`);+ const result = await evaluate(cdp, sessionId, `(() => {+ var svg = document.querySelector('.diagram-container > svg');+ var entries = Array.from(svg.querySelectorAll('[data-legend-semantic-kind]'));+ var vb = svg.viewBox.baseVal;+ return {+ theme: document.documentElement.getAttribute('data-theme'),+ kinds: entries.map(function (entry) { return entry.getAttribute('data-legend-semantic-kind'); }),+ bridge: !!svg.querySelector('[data-legend-bridge]'),+ roles: entries.map(function (entry) { return entry.getAttribute('role'); }),+ aria: entries.map(function (entry) { return entry.getAttribute('aria-label'); }),+ counts: entries.map(function (entry) { return entry.getAttribute('data-legend-count'); }),+ tabStops: entries.filter(function (entry) { return entry.getAttribute('tabindex') === '0'; }).length,+ inside: entries.every(function (entry) {+ var box = entry.getBBox();+ return box.x >= vb.x && box.y >= vb.y && box.x + box.width <= vb.x + vb.width && box.y + box.height <= vb.y + vb.height;+ })+ };+ })()`);+ assert.equal(result.theme, theme);+ assert.deepEqual(result.kinds, expectedKinds);+ assert.equal(result.inside, true);+ return result;+ }++ for (const theme of ['dark', 'light']) {+ const dataflow = await inspectKinds(outputs.dataflow, ['database', 'default'], theme);+ assert.equal(dataflow.bridge, true);+ assert.deepEqual(dataflow.roles, ['button', null]);+ assert.deepEqual(dataflow.aria, ['Inspect data store, 1 node', null]);+ assert.deepEqual(dataflow.counts, ['1', null]);+ assert.equal(dataflow.tabStops, 1);+ const lifecycle = await inspectKinds(outputs.lifecycle, ['start', 'active', 'success'], theme);+ assert.equal(lifecycle.bridge, true);+ }++ await navigateReady(outputs.dataflow, '!!(window.Archify && Archify.semanticLens && Archify.exportMenu)', 'Dataflow database legend runtime');+ const databaseRuntime = await evaluate(cdp, sessionId, String.raw`(async function () {+ var entry = document.querySelector('[data-legend-kind="database"]');+ entry.focus();+ entry.dispatchEvent(new KeyboardEvent('keydown', { key: 'Enter', bubbles: true }));+ var originalCreateObjectURL = URL.createObjectURL;+ var originalAnchorClick = HTMLAnchorElement.prototype.click;+ var captured;+ URL.createObjectURL = function (blob) {+ captured = blob.text();+ return 'blob:archify-dataflow-legend-smoke';+ };+ HTMLAnchorElement.prototype.click = function () {};+ try {+ await Archify.exportMenu.run('svg');+ var exportedText = await captured;+ var exported = new DOMParser().parseFromString(exportedText, 'image/svg+xml').documentElement;+ return {+ selected: Archify.semanticLens.active(),+ lensOpen: Archify.semanticLens.isOpen(),+ exportedKinds: Array.from(exported.querySelectorAll('[data-legend-semantic-kind]')).map(function (item) { return item.getAttribute('data-legend-semantic-kind'); }),+ exportedBridgeResidue: exported.querySelectorAll('[data-legend-bridge], [data-legend-kind], [data-legend-label], [data-legend-count], [data-legend-bridge-runtime]').length+ };+ } finally {+ URL.createObjectURL = originalCreateObjectURL;+ HTMLAnchorElement.prototype.click = originalAnchorClick;+ }+ })()`, true);+ assert.deepEqual(databaseRuntime.selected, ['database']);+ assert.equal(databaseRuntime.lensOpen, true);+ assert.deepEqual(databaseRuntime.exportedKinds, ['database', 'default']);+ assert.equal(databaseRuntime.exportedBridgeResidue, 0);++ await navigateReady(outputs.custom, '!!(window.Archify && Archify.semanticLens && Archify.exportMenu)', 'custom legend runtime');+ const runtime = await evaluate(cdp, sessionId, String.raw`(async function () {+ var svg = document.querySelector('.diagram-container > svg');+ var entries = Array.from(svg.querySelectorAll('[data-legend-semantic-kind]'));+ var interactive = entries.filter(function (entry) { return entry.hasAttribute('data-legend-kind'); });+ var first = interactive[0];+ var second = interactive[1];+ first.focus();+ first.dispatchEvent(new KeyboardEvent('keydown', { key: 'ArrowRight', bubbles: true }));+ var arrowMoved = document.activeElement === second;+ second.dispatchEvent(new KeyboardEvent('keydown', { key: 'Enter', bubbles: true }));+ var selected = Archify.semanticLens.active();+ var guidedActivated = Archify.guidedViews.activate('main', { updateUrl: false });+ var guidedActive = Archify.guidedViews.active();+ var visualMatrix = [];+ for (var preset of ['classic', 'signal-flow', 'blueprint', 'editorial']) {+ if (!Archify.preset.apply(preset)) throw new Error('could not apply preset ' + preset);+ for (var theme of ['dark', 'light']) {+ document.documentElement.setAttribute('data-theme', theme);+ visualMatrix.push({+ preset: preset,+ theme: theme,+ kinds: entries.map(function (entry) { return entry.getAttribute('data-legend-semantic-kind'); }),+ labels: entries.map(function (entry) { return entry.querySelector('text').textContent; })+ });+ }+ }++ var originalCreateObjectURL = URL.createObjectURL;+ var originalAnchorClick = HTMLAnchorElement.prototype.click;+ var captured;+ URL.createObjectURL = function (blob) {+ captured = blob.text();+ return 'blob:archify-legend-smoke';+ };+ HTMLAnchorElement.prototype.click = function () {};+ try {+ await Archify.exportMenu.run('svg');+ var exportedText = await captured;+ var exported = new DOMParser().parseFromString(exportedText, 'image/svg+xml').documentElement;+ return {+ labels: interactive.map(function (entry) { return entry.getAttribute('aria-label'); }),+ roles: entries.map(function (entry) { return entry.getAttribute('role'); }),+ counts: interactive.map(function (entry) { return entry.getAttribute('data-legend-count'); }),+ tabStops: interactive.filter(function (entry) { return entry.getAttribute('tabindex') === '0'; }).length,+ arrowMoved: arrowMoved,+ selected: selected,+ lensOpen: Archify.semanticLens.isOpen(),+ guidedActivated: guidedActivated,+ guidedActive: guidedActive,+ visualMatrix: visualMatrix,+ forcedUnusedInteractive: entries.at(-1).hasAttribute('data-legend-kind'),+ exportedKinds: Array.from(exported.querySelectorAll('[data-legend-semantic-kind]')).map(function (entry) { return entry.getAttribute('data-legend-semantic-kind'); }),+ exportedBridgeResidue: exported.querySelectorAll('[data-legend-bridge], [data-legend-kind], [data-legend-label], [data-legend-count], [data-legend-bridge-runtime]').length,+ exportedLabels: Array.from(exported.querySelectorAll('[data-legend-semantic-kind] text')).map(function (text) { return text.textContent; })+ };+ } finally {+ URL.createObjectURL = originalCreateObjectURL;+ HTMLAnchorElement.prototype.click = originalAnchorClick;+ }+ })()`, true);+ assert.deepEqual(runtime.labels, ['Inspect Reader <UI> & ops, 1 node', 'Inspect Database, 1 node']);+ assert.deepEqual(runtime.roles, ['button', 'button', null]);+ assert.deepEqual(runtime.counts, ['1', '1']);+ assert.equal(runtime.tabStops, 1);+ assert.equal(runtime.arrowMoved, true);+ assert.deepEqual(runtime.selected, ['database']);+ assert.equal(runtime.lensOpen, false);+ assert.equal(runtime.guidedActivated, true);+ assert.equal(runtime.guidedActive, 'main');+ assert.equal(runtime.visualMatrix.length, 8);+ for (const entry of runtime.visualMatrix) {+ assert.deepEqual(entry.kinds, ['frontend', 'database', 'external']);+ assert.deepEqual(entry.labels, ['Reader <UI> & ops', 'Database', 'Future integration']);+ }+ assert.equal(runtime.forcedUnusedInteractive, false);+ assert.deepEqual(runtime.exportedKinds, ['frontend', 'database', 'external']);+ assert.equal(runtime.exportedBridgeResidue, 0);+ assert.deepEqual(runtime.exportedLabels, ['Reader <UI> & ops', 'Database', 'Future integration']);++ await cdp.send('Emulation.setEmulatedMedia', { media: 'print' }, sessionId);+ const printState = await evaluate(cdp, sessionId, `(() => ({+ legendDisplay: getComputedStyle(document.querySelector('[data-legend]')).display,+ runtimeBadgesHidden: Array.from(document.querySelectorAll('[data-legend-bridge-runtime]')).every(function (entry) { return getComputedStyle(entry).display === 'none'; })+ }))()`);+ assert.notEqual(printState.legendDisplay, 'none');+ assert.equal(printState.runtimeBadgesHidden, true);+ await cdp.send('Emulation.setEmulatedMedia', { media: '' }, sessionId);++ const embedUrl = new URL(pathToFileURL(outputs.custom).href);+ embedUrl.searchParams.set('embed', '1');+ await navigateReady(embedUrl, '!!(window.Archify && Archify.semanticLens)', 'embedded legend');+ const embed = await evaluate(cdp, sessionId, `(() => ({+ roles: document.querySelectorAll('[data-legend-kind][role]').length,+ runtime: document.querySelectorAll('[data-legend-bridge-runtime]').length,+ kinds: Array.from(document.querySelectorAll('[data-legend-semantic-kind]')).map(function (entry) { return entry.getAttribute('data-legend-semantic-kind'); })+ }))()`);+ assert.deepEqual(embed, { roles: 0, runtime: 0, kinds: ['frontend', 'database', 'external'] });++ await navigateReady(outputs.hidden, '!!(window.Archify && Archify.semanticLens)', 'hidden legend');+ const hidden = await evaluate(cdp, sessionId, `(() => ({+ root: !!document.querySelector('[data-legend]'),+ bridge: !!document.querySelector('[data-legend-bridge]'),+ title: Array.from(document.querySelectorAll('.diagram-container svg text')).some(function (text) { return text.textContent.trim() === 'Legend'; })+ }))()`);+ assert.deepEqual(hidden, { root: false, bridge: false, title: false });+ console.log('ok legend runtime: labels, counts, keyboard, export, print, embed, hidden, and dual themes');+ }+async function verifySemanticPassportDismissal(file) {await navigateReady(file, '!!(window.Archify && Archify.focus && document.querySelector("#btn-focus-clear"))', 'Semantic Passport dismissal');const result = await evaluate(cdp, sessionId, `(() => {@@ -1483,6 +1735,7 @@ try {console.log(`ok ${label} Reach Card: ${reachPayload.size} bytes, ${reachPayload.snapshot.nodeIds.length} nodes, ${reachPayload.snapshot.edges.length} authored links`);}+ await verifyResolvedLegendContract(legendOutputs);await verifySemanticPassportDismissal(path.resolve(skillRoot, '../docs/gallery/artifacts/production-deployment.architecture.html'));await verifyArchitectureDeltaNavigator(path.resolve(skillRoot, '../examples/checkout-platform-delta.html'));await captureShareCard(output, 'architecture-wide');diff --git a/docs/assets/archify-live-proof.gif b/docs/assets/archify-live-proof.gifindex e0581315..102c942a 100644Binary files a/docs/assets/archify-live-proof.gif and b/docs/assets/archify-live-proof.gif differdiff --git a/docs/assets/archify-live-proof.json b/docs/assets/archify-live-proof.jsonindex 59c320ff..67f746e3 100644--- a/docs/assets/archify-live-proof.json+++ b/docs/assets/archify-live-proof.json@@ -7,13 +7,13 @@"fps": 10,"frameCount": 54,"durationSeconds": 5.4,- "bytes": 1621722,- "sha256": "9dfa85f0d04f0d072b94502893956bd45e92c51599fd40c2fd7096e7bd72c3c0",+ "bytes": 1552082,+ "sha256": "48a52b8edc91bccd35706b0d790079088f1fbc34759bcf3bfe12781c8854b5e5","scenes": [{"id": "signal-flow","artifact": "docs/gallery/artifacts/agent-tool-call.workflow.html",- "artifactSha256": "969d6f866a040cbb2923a2ed83b8eb2bc17761f9c8f3cac2070dca9d1a94f312",+ "artifactSha256": "1a1611bce923465b57c88b76b94c31df4ae8c548e95ca0b33ab294a0d8670995","view": "happy-path","eyebrow": "WORKFLOW · SIGNAL FLOW","title": "Agent Tool Call",@@ -22,7 +22,7 @@{"id": "blueprint","artifact": "docs/gallery/artifacts/production-deployment.architecture.html",- "artifactSha256": "ff3f9976979b6c3f1477ff5bed79e6ef0c1ce3d5b484665b7ddcb4decdf058ab",+ "artifactSha256": "0a6b95d5db1bd118a265935d625db0b8d8d5895e4031110c53c8513d482c35bb","view": "request-boundary","eyebrow": "ARCHITECTURE · BLUEPRINT","title": "Production Deployment",@@ -31,7 +31,7 @@{"id": "classic","artifact": "docs/gallery/artifacts/cache-miss.sequence.html",- "artifactSha256": "4c0b4f4f47c2e422f1fd840263879ea2f23f76290e068994b9126f791d9d8bb0",+ "artifactSha256": "a0c435f4066d3c039536c2a82a69dabca5fd49dbb5265a42e6c2c556dd8934b0","view": "cache-fallback","eyebrow": "SEQUENCE · CLASSIC","title": "Cache Miss Request",diff --git a/docs/cases/mco-runtime.architecture.html b/docs/cases/mco-runtime.architecture.htmlindex 0165948b..b3d4e78d 100644--- a/docs/cases/mco-runtime.architecture.html+++ b/docs/cases/mco-runtime.architecture.html@@ -4783,35 +4783,35 @@</g><!-- Legend -->- <g data-legend-bridge>- <text x="40" y="619" class="t-primary" font-size="9" font-weight="600">Legend</text>- <g data-legend-kind="external">- <rect x="40" y="624" width="14" height="9" rx="2" class="c-external" stroke-width="1"/>- <text x="60" y="632" class="t-muted" font-size="8">External</text>+ <g data-legend data-legend-bridge>+ <text x="40" y="612" class="t-primary" font-size="10" font-weight="600">Legend</text>+ <g data-legend-semantic-kind="frontend" data-legend-kind="frontend" data-legend-label="Frontend" data-legend-x="40" data-legend-baseline="632" data-legend-width="82">+ <rect x="40" y="624" width="14" height="9" rx="2" class="c-frontend" stroke-width="1"/>+ <text x="61" y="632" class="t-muted" font-size="8">Frontend</text></g>- <g data-legend-kind="frontend">- <rect x="144" y="624" width="14" height="9" rx="2" class="c-frontend" stroke-width="1"/>- <text x="164" y="632" class="t-muted" font-size="8">Frontend</text>+ <g data-legend-semantic-kind="backend" data-legend-kind="backend" data-legend-label="Backend" data-legend-x="144" data-legend-baseline="632" data-legend-width="77">+ <rect x="144" y="624" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>+ <text x="165" y="632" class="t-muted" font-size="8">Backend</text></g>- <g data-legend-kind="backend">- <rect x="248" y="624" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>- <text x="268" y="632" class="t-muted" font-size="8">Backend</text>+ <g data-legend-semantic-kind="database" data-legend-kind="database" data-legend-label="Database" data-legend-x="243" data-legend-baseline="632" data-legend-width="82">+ <rect x="243" y="624" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>+ <text x="264" y="632" class="t-muted" font-size="8">Database</text></g>- <g data-legend-kind="database">- <rect x="347" y="624" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>- <text x="367" y="632" class="t-muted" font-size="8">Database</text>+ <g data-legend-semantic-kind="cloud" data-legend-kind="cloud" data-legend-label="Cloud" data-legend-x="347" data-legend-baseline="632" data-legend-width="67">+ <rect x="347" y="624" width="14" height="9" rx="2" class="c-cloud" stroke-width="1"/>+ <text x="368" y="632" class="t-muted" font-size="8">Cloud</text></g>- <g data-legend-kind="security">- <rect x="451" y="624" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>- <text x="471" y="632" class="t-muted" font-size="8">Security</text>+ <g data-legend-semantic-kind="security" data-legend-kind="security" data-legend-label="Security" data-legend-x="436" data-legend-baseline="632" data-legend-width="82">+ <rect x="436" y="624" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>+ <text x="457" y="632" class="t-muted" font-size="8">Security</text></g>- <g data-legend-kind="messagebus">- <rect x="555" y="624" width="14" height="9" rx="2" class="c-messagebus" stroke-width="1"/>- <text x="575" y="632" class="t-muted" font-size="8">Message bus</text>+ <g data-legend-semantic-kind="messagebus" data-legend-kind="messagebus" data-legend-label="Message bus" data-legend-x="540" data-legend-baseline="632" data-legend-width="97">+ <rect x="540" y="624" width="14" height="9" rx="2" class="c-messagebus" stroke-width="1"/>+ <text x="561" y="632" class="t-muted" font-size="8">Message bus</text></g>- <g data-legend-kind="cloud">- <rect x="674" y="624" width="14" height="9" rx="2" class="c-cloud" stroke-width="1"/>- <text x="694" y="632" class="t-muted" font-size="8">Cloud</text>+ <g data-legend-semantic-kind="external" data-legend-kind="external" data-legend-label="External" data-legend-x="659" data-legend-baseline="632" data-legend-width="82">+ <rect x="659" y="624" width="14" height="9" rx="2" class="c-external" stroke-width="1"/>+ <text x="680" y="632" class="t-muted" font-size="8">External</text></g></g></svg>@@ -5518,6 +5518,7 @@});Array.prototype.forEach.call(clone.querySelectorAll('[data-legend-kind]'), function (el) {el.removeAttribute('data-legend-kind');+ el.removeAttribute('data-legend-label');el.removeAttribute('data-legend-count');el.removeAttribute('data-legend-zero');el.removeAttribute('data-legend-selected');@@ -12476,7 +12477,8 @@}entry.setAttribute('role', 'button');entry.setAttribute('tabindex', legendEntries.length ? '-1' : '0');- entry.setAttribute('aria-label', 'Inspect ' + fact.label + ', ' + count + ' node' + (count === 1 ? '' : 's'));+ var visibleLabel = entry.getAttribute('data-legend-label') || fact.label;+ entry.setAttribute('aria-label', 'Inspect ' + visibleLabel + ', ' + count + ' node' + (count === 1 ? '' : 's'));entry.setAttribute('aria-pressed', 'false');entry.setAttribute('aria-haspopup', 'dialog');entry.setAttribute('aria-controls', 'semantic-lens');diff --git a/docs/gallery.html b/docs/gallery.htmlindex 42019917..d012803f 100644--- a/docs/gallery.html+++ b/docs/gallery.html@@ -339,7 +339,7 @@<div class="receipt-cell"><span class="receipt-label">Artifact</span><span class="receipt-value ok">9/9 pass</span></div><div class="receipt-cell"><span class="receipt-label">Composition</span><span class="receipt-value ok" title="0 crossings · 0 border runs · 0 micro segments · 0 cramped turns">SHOWCASE · PASS</span></div><div class="receipt-cell"><span class="receipt-label">Graph</span><span class="receipt-value">12N · 11E</span></div>- <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="969d6f866a040cbb2923a2ed83b8eb2bc17761f9c8f3cac2070dca9d1a94f312">969d6f866a04</span></div>+ <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="1a1611bce923465b57c88b76b94c31df4ae8c548e95ca0b33ab294a0d8670995">1a1611bce923</span></div></div><div class="card-actions"><a class="card-link primary" href="gallery/artifacts/agent-tool-call.workflow.html?present=1&play=1#view=happy-path" target="_blank" rel="noopener" data-en="Play named chapter ↗" data-zh="播放命名章节 ↗">Play named chapter ↗</a>@@ -369,7 +369,7 @@<div class="receipt-cell"><span class="receipt-label">Artifact</span><span class="receipt-value ok">9/9 pass</span></div><div class="receipt-cell"><span class="receipt-label">Composition</span><span class="receipt-value ok" title="0 crossings · 0 border runs · 0 micro segments · 0 cramped turns">SHOWCASE · PASS</span></div><div class="receipt-cell"><span class="receipt-label">Graph</span><span class="receipt-value">12N · 12E</span></div>- <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="ff3f9976979b6c3f1477ff5bed79e6ef0c1ce3d5b484665b7ddcb4decdf058ab">ff3f9976979b</span></div>+ <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="0a6b95d5db1bd118a265935d625db0b8d8d5895e4031110c53c8513d482c35bb">0a6b95d5db1b</span></div></div><div class="card-actions"><a class="card-link primary" href="gallery/artifacts/production-deployment.architecture.html?present=1&play=1#view=request-boundary" target="_blank" rel="noopener" data-en="Play named chapter ↗" data-zh="播放命名章节 ↗">Play named chapter ↗</a>@@ -398,7 +398,7 @@<div class="receipt-cell"><span class="receipt-label">Artifact</span><span class="receipt-value ok">9/9 pass</span></div><div class="receipt-cell"><span class="receipt-label">Composition</span><span class="receipt-value ok" title="0 crossings · 0 border runs · 0 micro segments · 0 cramped turns">SHOWCASE · PASS</span></div><div class="receipt-cell"><span class="receipt-label">Graph</span><span class="receipt-value">7N · 12E</span></div>- <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="4c0b4f4f47c2e422f1fd840263879ea2f23f76290e068994b9126f791d9d8bb0">4c0b4f4f47c2</span></div>+ <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="a0c435f4066d3c039536c2a82a69dabca5fd49dbb5265a42e6c2c556dd8934b0">a0c435f4066d</span></div></div><div class="card-actions"><a class="card-link primary" href="gallery/artifacts/cache-miss.sequence.html?present=1&play=1#view=cache-fallback" target="_blank" rel="noopener" data-en="Play named chapter ↗" data-zh="播放命名章节 ↗">Play named chapter ↗</a>@@ -427,7 +427,7 @@<div class="receipt-cell"><span class="receipt-label">Artifact</span><span class="receipt-value ok">9/9 pass</span></div><div class="receipt-cell"><span class="receipt-label">Composition</span><span class="receipt-value ok" title="0 crossings · 0 border runs · 0 micro segments · 0 cramped turns">SHOWCASE · PASS</span></div><div class="receipt-cell"><span class="receipt-label">Graph</span><span class="receipt-value">10N · 10E</span></div>- <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="824ba0b9bfe49baa3b1cc30a6cc5bc0d48b0ad2f6585812d0003f8a45d3a18ce">824ba0b9bfe4</span></div>+ <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="e731f6b71e38ee9d82ba32a7f48c33da8e789948ac14bf31e390ee8714a636ba">e731f6b71e38</span></div></div><div class="card-actions"><a class="card-link primary" href="gallery/artifacts/release-delivery.workflow.html?present=1&play=1#view=approval-to-production" target="_blank" rel="noopener" data-en="Play named chapter ↗" data-zh="播放命名章节 ↗">Play named chapter ↗</a>@@ -456,7 +456,7 @@<div class="receipt-cell"><span class="receipt-label">Artifact</span><span class="receipt-value ok">9/9 pass</span></div><div class="receipt-cell"><span class="receipt-label">Composition</span><span class="receipt-value ok" title="0 crossings · 0 border runs · 0 micro segments · 0 cramped turns">SHOWCASE · PASS</span></div><div class="receipt-cell"><span class="receipt-label">Graph</span><span class="receipt-value">11N · 10E</span></div>- <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="ff3aeb81e75927679c8f19427f436d6f60768572868eb67a1e7c4252d0951d2e">ff3aeb81e759</span></div>+ <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="f561a36dcf781269709274c06b8b1765765823966107c48fdd6134f7307a571e">f561a36dcf78</span></div></div><div class="card-actions"><a class="card-link primary" href="gallery/artifacts/incident-response.workflow.html?present=1&play=1#view=mitigate-and-verify" target="_blank" rel="noopener" data-en="Play named chapter ↗" data-zh="播放命名章节 ↗">Play named chapter ↗</a>@@ -485,7 +485,7 @@<div class="receipt-cell"><span class="receipt-label">Artifact</span><span class="receipt-value ok">9/9 pass</span></div><div class="receipt-cell"><span class="receipt-label">Composition</span><span class="receipt-value ok" title="0 crossings · 0 border runs · 0 micro segments · 0 cramped turns">SHOWCASE · PASS</span></div><div class="receipt-cell"><span class="receipt-label">Graph</span><span class="receipt-value">10N · 10E</span></div>- <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="5c01aff416b7b44f12c1549064907da9d79cfa98714bc61dcc15e318509d24cb">5c01aff416b7</span></div>+ <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="c7d6d53272eecb8f33236e7705d19e511092dc267c446cfd54627aab37fc4cae">c7d6d53272ee</span></div></div><div class="card-actions"><a class="card-link primary" href="gallery/artifacts/product-analytics.dataflow.html?present=1&play=1#view=consent-boundary" target="_blank" rel="noopener" data-en="Play named chapter ↗" data-zh="播放命名章节 ↗">Play named chapter ↗</a>@@ -514,7 +514,7 @@<div class="receipt-cell"><span class="receipt-label">Artifact</span><span class="receipt-value ok">9/9 pass</span></div><div class="receipt-cell"><span class="receipt-label">Composition</span><span class="receipt-value ok" title="0 crossings · 0 border runs · 0 micro segments · 0 cramped turns">SHOWCASE · PASS</span></div><div class="receipt-cell"><span class="receipt-label">Graph</span><span class="receipt-value">7N · 14E</span></div>- <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="c6361d168e6ea7d248a42e053da7fc387dece34e2c5da29e91841b9d8cbbb93b">c6361d168e6e</span></div>+ <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="433af989bf3796728ff540c36b09aac79339547c5f23dc8c49d53d30e8515918">433af989bf37</span></div></div><div class="card-actions"><a class="card-link primary" href="gallery/artifacts/async-job-roundtrip.sequence.html?present=1&play=1#view=work-and-retry" target="_blank" rel="noopener" data-en="Play named chapter ↗" data-zh="播放命名章节 ↗">Play named chapter ↗</a>@@ -543,7 +543,7 @@<div class="receipt-cell"><span class="receipt-label">Artifact</span><span class="receipt-value ok">9/9 pass</span></div><div class="receipt-cell"><span class="receipt-label">Composition</span><span class="receipt-value ok" title="0 crossings · 0 border runs · 0 micro segments · 0 cramped turns">SHOWCASE · PASS</span></div><div class="receipt-cell"><span class="receipt-label">Graph</span><span class="receipt-value">12N · 12E</span></div>- <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="2be7f08e8b3c8a1cd50bef6152db0dfac98ef6e70d3f1fb27438a3e10bd39d84">2be7f08e8b3c</span></div>+ <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="9d1e02bd3c1120c1d569a0f053b1646188e53ae821a9e79f2ecaab3653320aac">9d1e02bd3c11</span></div></div><div class="card-actions"><a class="card-link primary" href="gallery/artifacts/event-stream.dataflow.html?present=1&play=1#view=order-transit" target="_blank" rel="noopener" data-en="Play named chapter ↗" data-zh="播放命名章节 ↗">Play named chapter ↗</a>@@ -572,7 +572,7 @@<div class="receipt-cell"><span class="receipt-label">Artifact</span><span class="receipt-value ok">9/9 pass</span></div><div class="receipt-cell"><span class="receipt-label">Composition</span><span class="receipt-value ok" title="0 crossings · 0 border runs · 0 micro segments · 0 cramped turns">SHOWCASE · PASS</span></div><div class="receipt-cell"><span class="receipt-label">Graph</span><span class="receipt-value">10N · 6E</span></div>- <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="1179a53de66ab1ed58639dcdd25f574a6c102087f810adcce40f3ca158858575">1179a53de66a</span></div>+ <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="6aea53f4a18df5dd795634f3e6f615645f022d82f5e5611c05ecefe349b534e9">6aea53f4a18d</span></div></div><div class="card-actions"><a class="card-link primary" href="gallery/artifacts/agent-run.lifecycle.html?present=1&play=1#view=main-lifecycle" target="_blank" rel="noopener" data-en="Play named chapter ↗" data-zh="播放命名章节 ↗">Play named chapter ↗</a>@@ -601,7 +601,7 @@<div class="receipt-cell"><span class="receipt-label">Artifact</span><span class="receipt-value ok">9/9 pass</span></div><div class="receipt-cell"><span class="receipt-label">Composition</span><span class="receipt-value ok" title="0 crossings · 0 border runs · 0 micro segments · 0 cramped turns">SHOWCASE · PASS</span></div><div class="receipt-cell"><span class="receipt-label">Graph</span><span class="receipt-value">11N · 6E</span></div>- <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="d3cecbf6ecf3bd2d347297de6312a22a8858d1cd5ce71cca5000de6c665bb56f">d3cecbf6ecf3</span></div>+ <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="40f86167ba5f91026abf156a387a3f1cbf09a2fb05d40051b9e28f8d8b9e793a">40f86167ba5f</span></div></div><div class="card-actions"><a class="card-link primary" href="gallery/artifacts/deployment-release.lifecycle.html?present=1&play=1#view=rollback-outcomes" target="_blank" rel="noopener" data-en="Play named chapter ↗" data-zh="播放命名章节 ↗">Play named chapter ↗</a>@@ -630,7 +630,7 @@<div class="receipt-cell"><span class="receipt-label">Artifact</span><span class="receipt-value ok">9/9 pass</span></div><div class="receipt-cell"><span class="receipt-label">Composition</span><span class="receipt-value ok" title="0 crossings · 0 border runs · 0 micro segments · 0 cramped turns">SHOWCASE · PASS</span></div><div class="receipt-cell"><span class="receipt-label">Graph</span><span class="receipt-value">10N · 9E</span></div>- <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="35d9c14c7b9589c3f9f6ede9b8d7d6f276bc861dee126080c7460bca187239d7">35d9c14c7b95</span></div>+ <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="377a5fcf6350bf594d888a7b27641fc6e91121e4e2e98b1a8aabe98b97510f87">377a5fcf6350</span></div></div><div class="card-actions"><a class="card-link primary" href="gallery/artifacts/web-app.architecture.html?present=1&play=1#view=request-path" target="_blank" rel="noopener" data-en="Play named chapter ↗" data-zh="播放命名章节 ↗">Play named chapter ↗</a>@@ -716,8 +716,8 @@ receipt 99 checks / 11 artifacts / deterministic hashes</pre>"engineeringProfile": null,"nodeCount": 12,"edgeCount": 11,- "artifactBytes": 619337,- "artifactSha256": "969d6f866a040cbb2923a2ed83b8eb2bc17761f9c8f3cac2070dca9d1a94f312",+ "artifactBytes": 620978,+ "artifactSha256": "1a1611bce923465b57c88b76b94c31df4ae8c548e95ca0b33ab294a0d8670995","sourceBytes": 6470,"sourceSha256": "a3afc6b30044eb256aa15c6195ddfbbcd1a14880d99967ed5605bc621ffb7e5f","checks": [@@ -814,8 +814,8 @@ receipt 99 checks / 11 artifacts / deterministic hashes</pre>"engineeringProfile": "deployment-ownership","nodeCount": 12,"edgeCount": 12,- "artifactBytes": 619653,- "artifactSha256": "ff3f9976979b6c3f1477ff5bed79e6ef0c1ce3d5b484665b7ddcb4decdf058ab",+ "artifactBytes": 620615,+ "artifactSha256": "0a6b95d5db1bd118a265935d625db0b8d8d5895e4031110c53c8513d482c35bb","sourceBytes": 5546,"sourceSha256": "03e647d057eb20d99f7fb4ba4ddfdd5d58a7a813865338680e968038e6a90e0f","checks": [@@ -912,8 +912,8 @@ receipt 99 checks / 11 artifacts / deterministic hashes</pre>"engineeringProfile": null,"nodeCount": 7,"edgeCount": 12,- "artifactBytes": 613486,- "artifactSha256": "4c0b4f4f47c2e422f1fd840263879ea2f23f76290e068994b9126f791d9d8bb0",+ "artifactBytes": 614562,+ "artifactSha256": "a0c435f4066d3c039536c2a82a69dabca5fd49dbb5265a42e6c2c556dd8934b0","sourceBytes": 4442,"sourceSha256": "30098d81006a18813bab447da698edf74604a1463770f01dc056b0af8cb314ef","checks": [@@ -1010,8 +1010,8 @@ receipt 99 checks / 11 artifacts / deterministic hashes</pre>"engineeringProfile": null,"nodeCount": 10,"edgeCount": 10,- "artifactBytes": 615599,- "artifactSha256": "824ba0b9bfe49baa3b1cc30a6cc5bc0d48b0ad2f6585812d0003f8a45d3a18ce",+ "artifactBytes": 616851,+ "artifactSha256": "e731f6b71e38ee9d82ba32a7f48c33da8e789948ac14bf31e390ee8714a636ba","sourceBytes": 5256,"sourceSha256": "44aa56ac6ca807937dfe84a6404e8b07d6394a38ae2ac53248a1985337dfd671","checks": [@@ -1108,8 +1108,8 @@ receipt 99 checks / 11 artifacts / deterministic hashes</pre>"engineeringProfile": null,"nodeCount": 11,"edgeCount": 10,- "artifactBytes": 615460,- "artifactSha256": "ff3aeb81e75927679c8f19427f436d6f60768572868eb67a1e7c4252d0951d2e",+ "artifactBytes": 617101,+ "artifactSha256": "f561a36dcf781269709274c06b8b1765765823966107c48fdd6134f7307a571e","sourceBytes": 5471,"sourceSha256": "9beb8698b275679a2fc92d4b51288cd5b5fc2115696d06b9168f3d7fef253a72","checks": [@@ -1206,8 +1206,8 @@ receipt 99 checks / 11 artifacts / deterministic hashes</pre>"engineeringProfile": null,"nodeCount": 10,"edgeCount": 10,- "artifactBytes": 616986,- "artifactSha256": "5c01aff416b7b44f12c1549064907da9d79cfa98714bc61dcc15e318509d24cb",+ "artifactBytes": 618137,+ "artifactSha256": "c7d6d53272eecb8f33236e7705d19e511092dc267c446cfd54627aab37fc4cae","sourceBytes": 5719,"sourceSha256": "f71c89288f80255bdedcdc0057bcbc155d1d8b1b7476d024b35f4e27c730c974","checks": [@@ -1304,8 +1304,8 @@ receipt 99 checks / 11 artifacts / deterministic hashes</pre>"engineeringProfile": null,"nodeCount": 7,"edgeCount": 14,- "artifactBytes": 614283,- "artifactSha256": "c6361d168e6ea7d248a42e053da7fc387dece34e2c5da29e91841b9d8cbbb93b",+ "artifactBytes": 615023,+ "artifactSha256": "433af989bf3796728ff540c36b09aac79339547c5f23dc8c49d53d30e8515918","sourceBytes": 4483,"sourceSha256": "1b53d7c4ce7b2d8f6f40b8f33a394abe1d37fc991272b534c1ccd0255920ab52","checks": [@@ -1402,8 +1402,8 @@ receipt 99 checks / 11 artifacts / deterministic hashes</pre>"engineeringProfile": null,"nodeCount": 12,"edgeCount": 12,- "artifactBytes": 620941,- "artifactSha256": "2be7f08e8b3c8a1cd50bef6152db0dfac98ef6e70d3f1fb27438a3e10bd39d84",+ "artifactBytes": 622092,+ "artifactSha256": "9d1e02bd3c1120c1d569a0f053b1646188e53ae821a9e79f2ecaab3653320aac","sourceBytes": 5543,"sourceSha256": "bbfedc2f1b73bf50932490f7f56d45d5f853e970d2fab26660a04947a783969c","checks": [@@ -1500,8 +1500,8 @@ receipt 99 checks / 11 artifacts / deterministic hashes</pre>"engineeringProfile": null,"nodeCount": 10,"edgeCount": 6,- "artifactBytes": 610318,- "artifactSha256": "1179a53de66ab1ed58639dcdd25f574a6c102087f810adcce40f3ca158858575",+ "artifactBytes": 611790,+ "artifactSha256": "6aea53f4a18df5dd795634f3e6f615645f022d82f5e5611c05ecefe349b534e9","sourceBytes": 4527,"sourceSha256": "2e756b3d1ebc2f6c3f62f46c0fbb5584ed7bd6213627259ab43153b18c831cdf","checks": [@@ -1598,8 +1598,8 @@ receipt 99 checks / 11 artifacts / deterministic hashes</pre>"engineeringProfile": null,"nodeCount": 11,"edgeCount": 6,- "artifactBytes": 611308,- "artifactSha256": "d3cecbf6ecf3bd2d347297de6312a22a8858d1cd5ce71cca5000de6c665bb56f",+ "artifactBytes": 612780,+ "artifactSha256": "40f86167ba5f91026abf156a387a3f1cbf09a2fb05d40051b9e28f8d8b9e793a","sourceBytes": 4394,"sourceSha256": "aa614f0c9a82f210e301e382f362dfbd7f290bda4d5501de3c99a6cd81b4c0a4","checks": [@@ -1696,8 +1696,8 @@ receipt 99 checks / 11 artifacts / deterministic hashes</pre>"engineeringProfile": null,"nodeCount": 10,"edgeCount": 9,- "artifactBytes": 610940,- "artifactSha256": "35d9c14c7b9589c3f9f6ede9b8d7d6f276bc861dee126080c7460bca187239d7",+ "artifactBytes": 611902,+ "artifactSha256": "377a5fcf6350bf594d888a7b27641fc6e91121e4e2e98b1a8aabe98b97510f87","sourceBytes": 3863,"sourceSha256": "01567b5e49cad5139baa071533a028d22f0e80fedfb49095e0d9330aee7f87db","checks": [diff --git a/docs/gallery/artifacts/agent-run.lifecycle.html b/docs/gallery/artifacts/agent-run.lifecycle.htmlindex 7a7580bc..5bb5d2ec 100644--- a/docs/gallery/artifacts/agent-run.lifecycle.html+++ b/docs/gallery/artifacts/agent-run.lifecycle.html@@ -4729,24 +4729,32 @@<!-- Legend -->- <g data-legend-bridge>- <text x="220" y="542" class="t-primary" font-size="10" font-weight="600">Legend</text>- <g data-legend-kind="active">- <rect x="220" y="554" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>- <text x="240" y="562" class="t-muted" font-size="7">active state</text>- </g>- <g data-legend-kind="waiting">- <rect x="325" y="554" width="14" height="9" rx="2" class="c-cloud" stroke-width="1"/>- <text x="345" y="562" class="t-muted" font-size="7">waiting</text>- </g>- <g data-legend-kind="success">- <rect x="415" y="554" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>- <text x="435" y="562" class="t-muted" font-size="7">terminal success</text>- </g>- <g data-legend-kind="failure">- <rect x="560" y="554" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>- <text x="580" y="562" class="t-muted" font-size="7">failure / exit</text>- </g>+ <g data-legend data-legend-bridge>+ <text x="40" y="604" class="t-primary" font-size="10" font-weight="600">Legend</text>+ <g data-legend-semantic-kind="start" data-legend-kind="start" data-legend-label="start" data-legend-x="40" data-legend-baseline="624" data-legend-width="67">+ <rect x="40" y="616" width="14" height="9" rx="2" class="c-frontend" stroke-width="1"/>+ <text x="61" y="624" class="t-muted" font-size="8">start</text>+ </g>+ <g data-legend-semantic-kind="active" data-legend-kind="active" data-legend-label="active state" data-legend-x="129" data-legend-baseline="624" data-legend-width="102">+ <rect x="129" y="616" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>+ <text x="150" y="624" class="t-muted" font-size="8">active state</text>+ </g>+ <g data-legend-semantic-kind="waiting" data-legend-kind="waiting" data-legend-label="waiting" data-legend-x="253" data-legend-baseline="624" data-legend-width="77">+ <rect x="253" y="616" width="14" height="9" rx="2" class="c-cloud" stroke-width="1"/>+ <text x="274" y="624" class="t-muted" font-size="8">waiting</text>+ </g>+ <g data-legend-semantic-kind="decision" data-legend-kind="decision" data-legend-label="decision" data-legend-x="352" data-legend-baseline="624" data-legend-width="82">+ <rect x="352" y="616" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>+ <text x="373" y="624" class="t-muted" font-size="8">decision</text>+ </g>+ <g data-legend-semantic-kind="success" data-legend-kind="success" data-legend-label="terminal success" data-legend-x="456" data-legend-baseline="624" data-legend-width="122">+ <rect x="456" y="616" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>+ <text x="477" y="624" class="t-muted" font-size="8">terminal success</text>+ </g>+ <g data-legend-semantic-kind="failure" data-legend-kind="failure" data-legend-label="failure / exit" data-legend-x="600" data-legend-baseline="624" data-legend-width="112">+ <rect x="600" y="616" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>+ <text x="621" y="624" class="t-muted" font-size="8">failure / exit</text>+ </g></g></svg><p class="intent-trace-status no-print" id="intent-trace-status" role="status" aria-live="polite" aria-atomic="true"></p>@@ -5452,6 +5460,7 @@});Array.prototype.forEach.call(clone.querySelectorAll('[data-legend-kind]'), function (el) {el.removeAttribute('data-legend-kind');+ el.removeAttribute('data-legend-label');el.removeAttribute('data-legend-count');el.removeAttribute('data-legend-zero');el.removeAttribute('data-legend-selected');@@ -12410,7 +12419,8 @@}entry.setAttribute('role', 'button');entry.setAttribute('tabindex', legendEntries.length ? '-1' : '0');- entry.setAttribute('aria-label', 'Inspect ' + fact.label + ', ' + count + ' node' + (count === 1 ? '' : 's'));+ var visibleLabel = entry.getAttribute('data-legend-label') || fact.label;+ entry.setAttribute('aria-label', 'Inspect ' + visibleLabel + ', ' + count + ' node' + (count === 1 ? '' : 's'));entry.setAttribute('aria-pressed', 'false');entry.setAttribute('aria-haspopup', 'dialog');entry.setAttribute('aria-controls', 'semantic-lens');diff --git a/docs/gallery/artifacts/agent-tool-call.workflow.html b/docs/gallery/artifacts/agent-tool-call.workflow.htmlindex 35c7c1a1..1d8e87b2 100644--- a/docs/gallery/artifacts/agent-tool-call.workflow.html+++ b/docs/gallery/artifacts/agent-tool-call.workflow.html@@ -4800,28 +4800,36 @@</g><!-- Legend -->- <g data-legend-bridge>- <text x="175" y="800" class="t-primary" font-size="10" font-weight="600">Legend</text>- <g data-legend-kind="frontend">- <rect x="175" y="812" width="14" height="9" rx="2" class="c-frontend" stroke-width="1"/>- <text x="195" y="820" class="t-muted" font-size="7">User UI</text>- </g>- <g data-legend-kind="backend">- <rect x="260" y="812" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>- <text x="280" y="820" class="t-muted" font-size="7">Agent logic</text>- </g>- <g data-legend-kind="security">- <rect x="370" y="812" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>- <text x="390" y="820" class="t-muted" font-size="7">Policy</text>- </g>- <g data-legend-kind="messagebus">- <rect x="455" y="812" width="14" height="9" rx="2" class="c-messagebus" stroke-width="1"/>- <text x="475" y="820" class="t-muted" font-size="7">Tool action</text>- </g>- <g data-legend-kind="database">- <rect x="565" y="812" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>- <text x="585" y="820" class="t-muted" font-size="7">Context / trace</text>- </g>+ <g data-legend data-legend-bridge>+ <text x="20" y="800" class="t-primary" font-size="10" font-weight="600">Legend</text>+ <g data-legend-semantic-kind="frontend" data-legend-kind="frontend" data-legend-label="User UI" data-legend-x="20" data-legend-baseline="820" data-legend-width="73">+ <rect x="20" y="812" width="14" height="9" rx="2" class="c-frontend" stroke-width="1"/>+ <text x="41" y="820" class="t-muted" font-size="7">User UI</text>+ </g>+ <g data-legend-semantic-kind="backend" data-legend-kind="backend" data-legend-label="Agent logic" data-legend-x="100" data-legend-baseline="820" data-legend-width="90">+ <rect x="100" y="812" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>+ <text x="121" y="820" class="t-muted" font-size="7">Agent logic</text>+ </g>+ <g data-legend-semantic-kind="security" data-legend-kind="security" data-legend-label="Policy" data-legend-x="197" data-legend-baseline="820" data-legend-width="69">+ <rect x="197" y="812" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>+ <text x="218" y="820" class="t-muted" font-size="7">Policy</text>+ </g>+ <g data-legend-semantic-kind="messagebus" data-legend-kind="messagebus" data-legend-label="Tool action" data-legend-x="273" data-legend-baseline="820" data-legend-width="90">+ <rect x="273" y="812" width="14" height="9" rx="2" class="c-messagebus" stroke-width="1"/>+ <text x="294" y="820" class="t-muted" font-size="7">Tool action</text>+ </g>+ <g data-legend-semantic-kind="database" data-legend-kind="database" data-legend-label="Context / trace" data-legend-x="370" data-legend-baseline="820" data-legend-width="108">+ <rect x="370" y="812" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>+ <text x="391" y="820" class="t-muted" font-size="7">Context / trace</text>+ </g>+ <g data-legend-semantic-kind="cloud" data-legend-kind="cloud" data-legend-label="Cloud service" data-legend-x="485" data-legend-baseline="820" data-legend-width="99">+ <rect x="485" y="812" width="14" height="9" rx="2" class="c-cloud" stroke-width="1"/>+ <text x="506" y="820" class="t-muted" font-size="7">Cloud service</text>+ </g>+ <g data-legend-semantic-kind="external" data-legend-kind="external" data-legend-label="External system" data-legend-x="591" data-legend-baseline="820" data-legend-width="108">+ <rect x="591" y="812" width="14" height="9" rx="2" class="c-external" stroke-width="1"/>+ <text x="612" y="820" class="t-muted" font-size="7">External system</text>+ </g></g></svg><p class="intent-trace-status no-print" id="intent-trace-status" role="status" aria-live="polite" aria-atomic="true"></p>@@ -5530,6 +5538,7 @@});Array.prototype.forEach.call(clone.querySelectorAll('[data-legend-kind]'), function (el) {el.removeAttribute('data-legend-kind');+ el.removeAttribute('data-legend-label');el.removeAttribute('data-legend-count');el.removeAttribute('data-legend-zero');el.removeAttribute('data-legend-selected');@@ -12488,7 +12497,8 @@}entry.setAttribute('role', 'button');entry.setAttribute('tabindex', legendEntries.length ? '-1' : '0');- entry.setAttribute('aria-label', 'Inspect ' + fact.label + ', ' + count + ' node' + (count === 1 ? '' : 's'));+ var visibleLabel = entry.getAttribute('data-legend-label') || fact.label;+ entry.setAttribute('aria-label', 'Inspect ' + visibleLabel + ', ' + count + ' node' + (count === 1 ? '' : 's'));entry.setAttribute('aria-pressed', 'false');entry.setAttribute('aria-haspopup', 'dialog');entry.setAttribute('aria-controls', 'semantic-lens');diff --git a/docs/gallery/artifacts/async-job-roundtrip.sequence.html b/docs/gallery/artifacts/async-job-roundtrip.sequence.htmlindex 6b72c906..cd37a22d 100644--- a/docs/gallery/artifacts/async-job-roundtrip.sequence.html+++ b/docs/gallery/artifacts/async-job-roundtrip.sequence.html@@ -4815,15 +4815,25 @@</g><!-- Legend -->- <text x="150" y="846" class="t-primary" font-size="10" font-weight="600">Legend</text>- <path d="M 150 866 L 184 866" class="a-emphasis" stroke-width="1.8" marker-end="url(#arrowhead-emphasis)"/>- <text x="193" y="869" class="t-muted" font-size="8">request</text>- <path d="M 270 866 L 304 866" class="a-default" stroke-width="1.4" stroke-dasharray="3,5" marker-end="url(#arrowhead)"/>- <text x="313" y="869" class="t-muted" font-size="8">return</text>- <path d="M 385 866 L 419 866" class="a-security" stroke-width="1.4" marker-end="url(#arrowhead-security)"/>- <text x="428" y="869" class="t-muted" font-size="8">security</text>- <path d="M 530 866 L 564 866" class="a-dashed" stroke-width="1.4" marker-end="url(#arrowhead-dashed)"/>- <text x="573" y="869" class="t-muted" font-size="8">async trace</text>+ <g data-legend>+ <text x="40" y="846" class="t-primary" font-size="10" font-weight="600">Legend</text>+ <g data-legend-semantic-kind="emphasis" data-legend-x="40" data-legend-baseline="866" data-legend-width="78">+ <path d="M 40 863 L 74 863" class="a-emphasis" stroke-width="1.8" marker-end="url(#arrowhead-emphasis)"/>+ <text x="83" y="866" class="t-muted" font-size="8">request</text>+ </g>+ <g data-legend-semantic-kind="return" data-legend-x="140" data-legend-baseline="866" data-legend-width="73">+ <path d="M 140 863 L 174 863" class="a-default" stroke-width="1.4" stroke-dasharray="3,5" marker-end="url(#arrowhead)"/>+ <text x="183" y="866" class="t-muted" font-size="8">return</text>+ </g>+ <g data-legend-semantic-kind="dashed" data-legend-x="235" data-legend-baseline="866" data-legend-width="98">+ <path d="M 235 863 L 269 863" class="a-dashed" stroke-width="1.4" marker-end="url(#arrowhead-dashed)"/>+ <text x="278" y="866" class="t-muted" font-size="8">async trace</text>+ </g>+ <g data-legend-semantic-kind="default" data-legend-x="355" data-legend-baseline="866" data-legend-width="118">+ <path d="M 355 863 L 389 863" class="a-default" stroke-width="1.4" marker-end="url(#arrowhead)"/>+ <text x="398" y="866" class="t-muted" font-size="8">default message</text>+ </g>+ </g></svg><p class="intent-trace-status no-print" id="intent-trace-status" role="status" aria-live="polite" aria-atomic="true"></p><div class="share-chapter-cue no-print" id="share-chapter-cue" hidden role="status" aria-live="polite">@@ -5528,6 +5538,7 @@});Array.prototype.forEach.call(clone.querySelectorAll('[data-legend-kind]'), function (el) {el.removeAttribute('data-legend-kind');+ el.removeAttribute('data-legend-label');el.removeAttribute('data-legend-count');el.removeAttribute('data-legend-zero');el.removeAttribute('data-legend-selected');@@ -12486,7 +12497,8 @@}entry.setAttribute('role', 'button');entry.setAttribute('tabindex', legendEntries.length ? '-1' : '0');- entry.setAttribute('aria-label', 'Inspect ' + fact.label + ', ' + count + ' node' + (count === 1 ? '' : 's'));+ var visibleLabel = entry.getAttribute('data-legend-label') || fact.label;+ entry.setAttribute('aria-label', 'Inspect ' + visibleLabel + ', ' + count + ' node' + (count === 1 ? '' : 's'));entry.setAttribute('aria-pressed', 'false');entry.setAttribute('aria-haspopup', 'dialog');entry.setAttribute('aria-controls', 'semantic-lens');diff --git a/docs/gallery/artifacts/cache-miss.sequence.html b/docs/gallery/artifacts/cache-miss.sequence.htmlindex d68ad688..4ba124e4 100644--- a/docs/gallery/artifacts/cache-miss.sequence.html+++ b/docs/gallery/artifacts/cache-miss.sequence.html@@ -4799,15 +4799,29 @@</g><!-- Legend -->- <text x="150" y="686" class="t-primary" font-size="10" font-weight="600">Legend</text>- <path d="M 150 706 L 184 706" class="a-emphasis" stroke-width="1.8" marker-end="url(#arrowhead-emphasis)"/>- <text x="193" y="709" class="t-muted" font-size="8">request</text>- <path d="M 270 706 L 304 706" class="a-default" stroke-width="1.4" stroke-dasharray="3,5" marker-end="url(#arrowhead)"/>- <text x="313" y="709" class="t-muted" font-size="8">return</text>- <path d="M 385 706 L 419 706" class="a-security" stroke-width="1.4" marker-end="url(#arrowhead-security)"/>- <text x="428" y="709" class="t-muted" font-size="8">security</text>- <path d="M 530 706 L 564 706" class="a-dashed" stroke-width="1.4" marker-end="url(#arrowhead-dashed)"/>- <text x="573" y="709" class="t-muted" font-size="8">async trace</text>+ <g data-legend>+ <text x="40" y="686" class="t-primary" font-size="10" font-weight="600">Legend</text>+ <g data-legend-semantic-kind="emphasis" data-legend-x="40" data-legend-baseline="706" data-legend-width="78">+ <path d="M 40 703 L 74 703" class="a-emphasis" stroke-width="1.8" marker-end="url(#arrowhead-emphasis)"/>+ <text x="83" y="706" class="t-muted" font-size="8">request</text>+ </g>+ <g data-legend-semantic-kind="return" data-legend-x="140" data-legend-baseline="706" data-legend-width="73">+ <path d="M 140 703 L 174 703" class="a-default" stroke-width="1.4" stroke-dasharray="3,5" marker-end="url(#arrowhead)"/>+ <text x="183" y="706" class="t-muted" font-size="8">return</text>+ </g>+ <g data-legend-semantic-kind="security" data-legend-x="235" data-legend-baseline="706" data-legend-width="83">+ <path d="M 235 703 L 269 703" class="a-security" stroke-width="1.4" marker-end="url(#arrowhead-security)"/>+ <text x="278" y="706" class="t-muted" font-size="8">security</text>+ </g>+ <g data-legend-semantic-kind="dashed" data-legend-x="340" data-legend-baseline="706" data-legend-width="98">+ <path d="M 340 703 L 374 703" class="a-dashed" stroke-width="1.4" marker-end="url(#arrowhead-dashed)"/>+ <text x="383" y="706" class="t-muted" font-size="8">async trace</text>+ </g>+ <g data-legend-semantic-kind="default" data-legend-x="460" data-legend-baseline="706" data-legend-width="118">+ <path d="M 460 703 L 494 703" class="a-default" stroke-width="1.4" marker-end="url(#arrowhead)"/>+ <text x="503" y="706" class="t-muted" font-size="8">default message</text>+ </g>+ </g></svg><p class="intent-trace-status no-print" id="intent-trace-status" role="status" aria-live="polite" aria-atomic="true"></p><div class="share-chapter-cue no-print" id="share-chapter-cue" hidden role="status" aria-live="polite">@@ -5512,6 +5526,7 @@});Array.prototype.forEach.call(clone.querySelectorAll('[data-legend-kind]'), function (el) {el.removeAttribute('data-legend-kind');+ el.removeAttribute('data-legend-label');el.removeAttribute('data-legend-count');el.removeAttribute('data-legend-zero');el.removeAttribute('data-legend-selected');@@ -12470,7 +12485,8 @@}entry.setAttribute('role', 'button');entry.setAttribute('tabindex', legendEntries.length ? '-1' : '0');- entry.setAttribute('aria-label', 'Inspect ' + fact.label + ', ' + count + ' node' + (count === 1 ? '' : 's'));+ var visibleLabel = entry.getAttribute('data-legend-label') || fact.label;+ entry.setAttribute('aria-label', 'Inspect ' + visibleLabel + ', ' + count + ' node' + (count === 1 ? '' : 's'));entry.setAttribute('aria-pressed', 'false');entry.setAttribute('aria-haspopup', 'dialog');entry.setAttribute('aria-controls', 'semantic-lens');diff --git a/docs/gallery/artifacts/deployment-release.lifecycle.html b/docs/gallery/artifacts/deployment-release.lifecycle.htmlindex ee7343a9..64804134 100644--- a/docs/gallery/artifacts/deployment-release.lifecycle.html+++ b/docs/gallery/artifacts/deployment-release.lifecycle.html@@ -4741,24 +4741,32 @@<!-- Legend -->- <g data-legend-bridge>- <text x="220" y="562" class="t-primary" font-size="10" font-weight="600">Legend</text>- <g data-legend-kind="active">- <rect x="220" y="574" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>- <text x="240" y="582" class="t-muted" font-size="7">active state</text>- </g>- <g data-legend-kind="waiting">- <rect x="325" y="574" width="14" height="9" rx="2" class="c-cloud" stroke-width="1"/>- <text x="345" y="582" class="t-muted" font-size="7">waiting</text>- </g>- <g data-legend-kind="success">- <rect x="415" y="574" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>- <text x="435" y="582" class="t-muted" font-size="7">terminal success</text>- </g>- <g data-legend-kind="failure">- <rect x="560" y="574" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>- <text x="580" y="582" class="t-muted" font-size="7">failure / exit</text>- </g>+ <g data-legend data-legend-bridge>+ <text x="40" y="624" class="t-primary" font-size="10" font-weight="600">Legend</text>+ <g data-legend-semantic-kind="start" data-legend-kind="start" data-legend-label="start" data-legend-x="40" data-legend-baseline="644" data-legend-width="67">+ <rect x="40" y="636" width="14" height="9" rx="2" class="c-frontend" stroke-width="1"/>+ <text x="61" y="644" class="t-muted" font-size="8">start</text>+ </g>+ <g data-legend-semantic-kind="active" data-legend-kind="active" data-legend-label="active state" data-legend-x="129" data-legend-baseline="644" data-legend-width="102">+ <rect x="129" y="636" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>+ <text x="150" y="644" class="t-muted" font-size="8">active state</text>+ </g>+ <g data-legend-semantic-kind="waiting" data-legend-kind="waiting" data-legend-label="waiting" data-legend-x="253" data-legend-baseline="644" data-legend-width="77">+ <rect x="253" y="636" width="14" height="9" rx="2" class="c-cloud" stroke-width="1"/>+ <text x="274" y="644" class="t-muted" font-size="8">waiting</text>+ </g>+ <g data-legend-semantic-kind="decision" data-legend-kind="decision" data-legend-label="decision" data-legend-x="352" data-legend-baseline="644" data-legend-width="82">+ <rect x="352" y="636" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>+ <text x="373" y="644" class="t-muted" font-size="8">decision</text>+ </g>+ <g data-legend-semantic-kind="success" data-legend-kind="success" data-legend-label="terminal success" data-legend-x="456" data-legend-baseline="644" data-legend-width="122">+ <rect x="456" y="636" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>+ <text x="477" y="644" class="t-muted" font-size="8">terminal success</text>+ </g>+ <g data-legend-semantic-kind="failure" data-legend-kind="failure" data-legend-label="failure / exit" data-legend-x="600" data-legend-baseline="644" data-legend-width="112">+ <rect x="600" y="636" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>+ <text x="621" y="644" class="t-muted" font-size="8">failure / exit</text>+ </g></g></svg><p class="intent-trace-status no-print" id="intent-trace-status" role="status" aria-live="polite" aria-atomic="true"></p>@@ -5464,6 +5472,7 @@});Array.prototype.forEach.call(clone.querySelectorAll('[data-legend-kind]'), function (el) {el.removeAttribute('data-legend-kind');+ el.removeAttribute('data-legend-label');el.removeAttribute('data-legend-count');el.removeAttribute('data-legend-zero');el.removeAttribute('data-legend-selected');@@ -12422,7 +12431,8 @@}entry.setAttribute('role', 'button');entry.setAttribute('tabindex', legendEntries.length ? '-1' : '0');- entry.setAttribute('aria-label', 'Inspect ' + fact.label + ', ' + count + ' node' + (count === 1 ? '' : 's'));+ var visibleLabel = entry.getAttribute('data-legend-label') || fact.label;+ entry.setAttribute('aria-label', 'Inspect ' + visibleLabel + ', ' + count + ' node' + (count === 1 ? '' : 's'));entry.setAttribute('aria-pressed', 'false');entry.setAttribute('aria-haspopup', 'dialog');entry.setAttribute('aria-controls', 'semantic-lens');diff --git a/docs/gallery/artifacts/event-stream.dataflow.html b/docs/gallery/artifacts/event-stream.dataflow.htmlindex 47f07d00..706850c9 100644--- a/docs/gallery/artifacts/event-stream.dataflow.html+++ b/docs/gallery/artifacts/event-stream.dataflow.html@@ -4823,15 +4823,29 @@</g><!-- Legend -->- <text x="214" y="724" class="t-primary" font-size="10" font-weight="600">Legend</text>- <path d="M 214 744 L 248 744" class="a-emphasis" stroke-width="1.8" marker-end="url(#arrowhead-emphasis)"/>- <text x="257" y="747" class="t-muted" font-size="8">primary data</text>- <path d="M 340 744 L 374 744" class="a-security" stroke-width="1.4" marker-end="url(#arrowhead-security)"/>- <text x="383" y="747" class="t-muted" font-size="8">policy / PII</text>- <path d="M 480 744 L 514 744" class="a-dashed" stroke-width="1.4" marker-end="url(#arrowhead-dashed)"/>- <text x="523" y="747" class="t-muted" font-size="8">async batch</text>- <rect x="625" y="736" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>- <text x="646" y="744" class="t-muted" font-size="8">data store</text>+ <g data-legend data-legend-bridge>+ <text x="40" y="724" class="t-primary" font-size="10" font-weight="600">Legend</text>+ <g data-legend-semantic-kind="emphasis" data-legend-x="40" data-legend-baseline="744" data-legend-width="103">+ <path d="M 40 741 L 74 741" class="a-emphasis" stroke-width="1.8" marker-end="url(#arrowhead-emphasis)"/>+ <text x="83" y="744" class="t-muted" font-size="8">primary data</text>+ </g>+ <g data-legend-semantic-kind="security" data-legend-x="165" data-legend-baseline="744" data-legend-width="103">+ <path d="M 165 741 L 199 741" class="a-security" stroke-width="1.4" marker-end="url(#arrowhead-security)"/>+ <text x="208" y="744" class="t-muted" font-size="8">policy / PII</text>+ </g>+ <g data-legend-semantic-kind="dashed" data-legend-x="290" data-legend-baseline="744" data-legend-width="98">+ <path d="M 290 741 L 324 741" class="a-dashed" stroke-width="1.4" marker-end="url(#arrowhead-dashed)"/>+ <text x="333" y="744" class="t-muted" font-size="8">async batch</text>+ </g>+ <g data-legend-semantic-kind="database" data-legend-kind="database" data-legend-label="data store" data-legend-x="410" data-legend-baseline="744" data-legend-width="92">+ <rect x="410" y="736" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>+ <text x="431" y="744" class="t-muted" font-size="8">data store</text>+ </g>+ <g data-legend-semantic-kind="default" data-legend-x="524" data-legend-baseline="744" data-legend-width="88">+ <path d="M 524 741 L 558 741" class="a-default" stroke-width="1.4" marker-end="url(#arrowhead)"/>+ <text x="567" y="744" class="t-muted" font-size="8">data flow</text>+ </g>+ </g></svg><p class="intent-trace-status no-print" id="intent-trace-status" role="status" aria-live="polite" aria-atomic="true"></p><div class="share-chapter-cue no-print" id="share-chapter-cue" hidden role="status" aria-live="polite">@@ -5536,6 +5550,7 @@});Array.prototype.forEach.call(clone.querySelectorAll('[data-legend-kind]'), function (el) {el.removeAttribute('data-legend-kind');+ el.removeAttribute('data-legend-label');el.removeAttribute('data-legend-count');el.removeAttribute('data-legend-zero');el.removeAttribute('data-legend-selected');@@ -12494,7 +12509,8 @@}entry.setAttribute('role', 'button');entry.setAttribute('tabindex', legendEntries.length ? '-1' : '0');- entry.setAttribute('aria-label', 'Inspect ' + fact.label + ', ' + count + ' node' + (count === 1 ? '' : 's'));+ var visibleLabel = entry.getAttribute('data-legend-label') || fact.label;+ entry.setAttribute('aria-label', 'Inspect ' + visibleLabel + ', ' + count + ' node' + (count === 1 ? '' : 's'));entry.setAttribute('aria-pressed', 'false');entry.setAttribute('aria-haspopup', 'dialog');entry.setAttribute('aria-controls', 'semantic-lens');diff --git a/docs/gallery/artifacts/incident-response.workflow.html b/docs/gallery/artifacts/incident-response.workflow.htmlindex 70284ce2..b4fecc38 100644--- a/docs/gallery/artifacts/incident-response.workflow.html+++ b/docs/gallery/artifacts/incident-response.workflow.html@@ -4772,28 +4772,36 @@<!-- Legend -->- <g data-legend-bridge>- <text x="175" y="800" class="t-primary" font-size="10" font-weight="600">Legend</text>- <g data-legend-kind="frontend">- <rect x="175" y="812" width="14" height="9" rx="2" class="c-frontend" stroke-width="1"/>- <text x="195" y="820" class="t-muted" font-size="7">User UI</text>- </g>- <g data-legend-kind="backend">- <rect x="260" y="812" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>- <text x="280" y="820" class="t-muted" font-size="7">Agent logic</text>- </g>- <g data-legend-kind="security">- <rect x="370" y="812" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>- <text x="390" y="820" class="t-muted" font-size="7">Policy</text>- </g>- <g data-legend-kind="messagebus">- <rect x="455" y="812" width="14" height="9" rx="2" class="c-messagebus" stroke-width="1"/>- <text x="475" y="820" class="t-muted" font-size="7">Tool action</text>- </g>- <g data-legend-kind="database">- <rect x="565" y="812" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>- <text x="585" y="820" class="t-muted" font-size="7">Context / trace</text>- </g>+ <g data-legend data-legend-bridge>+ <text x="20" y="800" class="t-primary" font-size="10" font-weight="600">Legend</text>+ <g data-legend-semantic-kind="frontend" data-legend-kind="frontend" data-legend-label="User UI" data-legend-x="20" data-legend-baseline="820" data-legend-width="73">+ <rect x="20" y="812" width="14" height="9" rx="2" class="c-frontend" stroke-width="1"/>+ <text x="41" y="820" class="t-muted" font-size="7">User UI</text>+ </g>+ <g data-legend-semantic-kind="backend" data-legend-kind="backend" data-legend-label="Agent logic" data-legend-x="100" data-legend-baseline="820" data-legend-width="90">+ <rect x="100" y="812" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>+ <text x="121" y="820" class="t-muted" font-size="7">Agent logic</text>+ </g>+ <g data-legend-semantic-kind="security" data-legend-kind="security" data-legend-label="Policy" data-legend-x="197" data-legend-baseline="820" data-legend-width="69">+ <rect x="197" y="812" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>+ <text x="218" y="820" class="t-muted" font-size="7">Policy</text>+ </g>+ <g data-legend-semantic-kind="messagebus" data-legend-kind="messagebus" data-legend-label="Tool action" data-legend-x="273" data-legend-baseline="820" data-legend-width="90">+ <rect x="273" y="812" width="14" height="9" rx="2" class="c-messagebus" stroke-width="1"/>+ <text x="294" y="820" class="t-muted" font-size="7">Tool action</text>+ </g>+ <g data-legend-semantic-kind="database" data-legend-kind="database" data-legend-label="Context / trace" data-legend-x="370" data-legend-baseline="820" data-legend-width="108">+ <rect x="370" y="812" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>+ <text x="391" y="820" class="t-muted" font-size="7">Context / trace</text>+ </g>+ <g data-legend-semantic-kind="cloud" data-legend-kind="cloud" data-legend-label="Cloud service" data-legend-x="485" data-legend-baseline="820" data-legend-width="99">+ <rect x="485" y="812" width="14" height="9" rx="2" class="c-cloud" stroke-width="1"/>+ <text x="506" y="820" class="t-muted" font-size="7">Cloud service</text>+ </g>+ <g data-legend-semantic-kind="external" data-legend-kind="external" data-legend-label="External system" data-legend-x="591" data-legend-baseline="820" data-legend-width="108">+ <rect x="591" y="812" width="14" height="9" rx="2" class="c-external" stroke-width="1"/>+ <text x="612" y="820" class="t-muted" font-size="7">External system</text>+ </g></g></svg><p class="intent-trace-status no-print" id="intent-trace-status" role="status" aria-live="polite" aria-atomic="true"></p>@@ -5499,6 +5507,7 @@});Array.prototype.forEach.call(clone.querySelectorAll('[data-legend-kind]'), function (el) {el.removeAttribute('data-legend-kind');+ el.removeAttribute('data-legend-label');el.removeAttribute('data-legend-count');el.removeAttribute('data-legend-zero');el.removeAttribute('data-legend-selected');@@ -12457,7 +12466,8 @@}entry.setAttribute('role', 'button');entry.setAttribute('tabindex', legendEntries.length ? '-1' : '0');- entry.setAttribute('aria-label', 'Inspect ' + fact.label + ', ' + count + ' node' + (count === 1 ? '' : 's'));+ var visibleLabel = entry.getAttribute('data-legend-label') || fact.label;+ entry.setAttribute('aria-label', 'Inspect ' + visibleLabel + ', ' + count + ' node' + (count === 1 ? '' : 's'));entry.setAttribute('aria-pressed', 'false');entry.setAttribute('aria-haspopup', 'dialog');entry.setAttribute('aria-controls', 'semantic-lens');diff --git a/docs/gallery/artifacts/product-analytics.dataflow.html b/docs/gallery/artifacts/product-analytics.dataflow.htmlindex b585c2fd..d86ebf25 100644--- a/docs/gallery/artifacts/product-analytics.dataflow.html+++ b/docs/gallery/artifacts/product-analytics.dataflow.html@@ -4784,15 +4784,29 @@</g><!-- Legend -->- <text x="214" y="704" class="t-primary" font-size="10" font-weight="600">Legend</text>- <path d="M 214 724 L 248 724" class="a-emphasis" stroke-width="1.8" marker-end="url(#arrowhead-emphasis)"/>- <text x="257" y="727" class="t-muted" font-size="8">primary data</text>- <path d="M 340 724 L 374 724" class="a-security" stroke-width="1.4" marker-end="url(#arrowhead-security)"/>- <text x="383" y="727" class="t-muted" font-size="8">policy / PII</text>- <path d="M 480 724 L 514 724" class="a-dashed" stroke-width="1.4" marker-end="url(#arrowhead-dashed)"/>- <text x="523" y="727" class="t-muted" font-size="8">async batch</text>- <rect x="625" y="716" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>- <text x="646" y="724" class="t-muted" font-size="8">data store</text>+ <g data-legend data-legend-bridge>+ <text x="40" y="704" class="t-primary" font-size="10" font-weight="600">Legend</text>+ <g data-legend-semantic-kind="emphasis" data-legend-x="40" data-legend-baseline="724" data-legend-width="103">+ <path d="M 40 721 L 74 721" class="a-emphasis" stroke-width="1.8" marker-end="url(#arrowhead-emphasis)"/>+ <text x="83" y="724" class="t-muted" font-size="8">primary data</text>+ </g>+ <g data-legend-semantic-kind="security" data-legend-x="165" data-legend-baseline="724" data-legend-width="103">+ <path d="M 165 721 L 199 721" class="a-security" stroke-width="1.4" marker-end="url(#arrowhead-security)"/>+ <text x="208" y="724" class="t-muted" font-size="8">policy / PII</text>+ </g>+ <g data-legend-semantic-kind="dashed" data-legend-x="290" data-legend-baseline="724" data-legend-width="98">+ <path d="M 290 721 L 324 721" class="a-dashed" stroke-width="1.4" marker-end="url(#arrowhead-dashed)"/>+ <text x="333" y="724" class="t-muted" font-size="8">async batch</text>+ </g>+ <g data-legend-semantic-kind="database" data-legend-kind="database" data-legend-label="data store" data-legend-x="410" data-legend-baseline="724" data-legend-width="92">+ <rect x="410" y="716" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>+ <text x="431" y="724" class="t-muted" font-size="8">data store</text>+ </g>+ <g data-legend-semantic-kind="default" data-legend-x="524" data-legend-baseline="724" data-legend-width="88">+ <path d="M 524 721 L 558 721" class="a-default" stroke-width="1.4" marker-end="url(#arrowhead)"/>+ <text x="567" y="724" class="t-muted" font-size="8">data flow</text>+ </g>+ </g></svg><p class="intent-trace-status no-print" id="intent-trace-status" role="status" aria-live="polite" aria-atomic="true"></p><div class="share-chapter-cue no-print" id="share-chapter-cue" hidden role="status" aria-live="polite">@@ -5497,6 +5511,7 @@});Array.prototype.forEach.call(clone.querySelectorAll('[data-legend-kind]'), function (el) {el.removeAttribute('data-legend-kind');+ el.removeAttribute('data-legend-label');el.removeAttribute('data-legend-count');el.removeAttribute('data-legend-zero');el.removeAttribute('data-legend-selected');@@ -12455,7 +12470,8 @@}entry.setAttribute('role', 'button');entry.setAttribute('tabindex', legendEntries.length ? '-1' : '0');- entry.setAttribute('aria-label', 'Inspect ' + fact.label + ', ' + count + ' node' + (count === 1 ? '' : 's'));+ var visibleLabel = entry.getAttribute('data-legend-label') || fact.label;+ entry.setAttribute('aria-label', 'Inspect ' + visibleLabel + ', ' + count + ' node' + (count === 1 ? '' : 's'));entry.setAttribute('aria-pressed', 'false');entry.setAttribute('aria-haspopup', 'dialog');entry.setAttribute('aria-controls', 'semantic-lens');diff --git a/docs/gallery/artifacts/production-deployment.architecture.html b/docs/gallery/artifacts/production-deployment.architecture.htmlindex 5594a951..f83ed6d7 100644--- a/docs/gallery/artifacts/production-deployment.architecture.html+++ b/docs/gallery/artifacts/production-deployment.architecture.html@@ -4794,31 +4794,31 @@</g><!-- Legend -->- <g data-legend-bridge>- <text x="40" y="731" class="t-primary" font-size="9" font-weight="600">Legend</text>- <g data-legend-kind="external">- <rect x="40" y="736" width="14" height="9" rx="2" class="c-external" stroke-width="1"/>- <text x="60" y="744" class="t-muted" font-size="8">External</text>+ <g data-legend data-legend-bridge>+ <text x="40" y="724" class="t-primary" font-size="10" font-weight="600">Legend</text>+ <g data-legend-semantic-kind="backend" data-legend-kind="backend" data-legend-label="Backend" data-legend-x="40" data-legend-baseline="744" data-legend-width="77">+ <rect x="40" y="736" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>+ <text x="61" y="744" class="t-muted" font-size="8">Backend</text></g>- <g data-legend-kind="cloud">- <rect x="144" y="736" width="14" height="9" rx="2" class="c-cloud" stroke-width="1"/>- <text x="164" y="744" class="t-muted" font-size="8">Cloud</text>+ <g data-legend-semantic-kind="database" data-legend-kind="database" data-legend-label="Database" data-legend-x="139" data-legend-baseline="744" data-legend-width="82">+ <rect x="139" y="736" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>+ <text x="160" y="744" class="t-muted" font-size="8">Database</text></g>- <g data-legend-kind="security">- <rect x="233" y="736" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>- <text x="253" y="744" class="t-muted" font-size="8">Security</text>+ <g data-legend-semantic-kind="cloud" data-legend-kind="cloud" data-legend-label="Cloud" data-legend-x="243" data-legend-baseline="744" data-legend-width="67">+ <rect x="243" y="736" width="14" height="9" rx="2" class="c-cloud" stroke-width="1"/>+ <text x="264" y="744" class="t-muted" font-size="8">Cloud</text></g>- <g data-legend-kind="backend">- <rect x="337" y="736" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>- <text x="357" y="744" class="t-muted" font-size="8">Backend</text>+ <g data-legend-semantic-kind="security" data-legend-kind="security" data-legend-label="Security" data-legend-x="332" data-legend-baseline="744" data-legend-width="82">+ <rect x="332" y="736" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>+ <text x="353" y="744" class="t-muted" font-size="8">Security</text></g>- <g data-legend-kind="database">- <rect x="436" y="736" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>- <text x="456" y="744" class="t-muted" font-size="8">Database</text>+ <g data-legend-semantic-kind="messagebus" data-legend-kind="messagebus" data-legend-label="Message bus" data-legend-x="436" data-legend-baseline="744" data-legend-width="97">+ <rect x="436" y="736" width="14" height="9" rx="2" class="c-messagebus" stroke-width="1"/>+ <text x="457" y="744" class="t-muted" font-size="8">Message bus</text></g>- <g data-legend-kind="messagebus">- <rect x="540" y="736" width="14" height="9" rx="2" class="c-messagebus" stroke-width="1"/>- <text x="560" y="744" class="t-muted" font-size="8">Message bus</text>+ <g data-legend-semantic-kind="external" data-legend-kind="external" data-legend-label="External" data-legend-x="555" data-legend-baseline="744" data-legend-width="82">+ <rect x="555" y="736" width="14" height="9" rx="2" class="c-external" stroke-width="1"/>+ <text x="576" y="744" class="t-muted" font-size="8">External</text></g></g></svg>@@ -5525,6 +5525,7 @@});Array.prototype.forEach.call(clone.querySelectorAll('[data-legend-kind]'), function (el) {el.removeAttribute('data-legend-kind');+ el.removeAttribute('data-legend-label');el.removeAttribute('data-legend-count');el.removeAttribute('data-legend-zero');el.removeAttribute('data-legend-selected');@@ -12483,7 +12484,8 @@}entry.setAttribute('role', 'button');entry.setAttribute('tabindex', legendEntries.length ? '-1' : '0');- entry.setAttribute('aria-label', 'Inspect ' + fact.label + ', ' + count + ' node' + (count === 1 ? '' : 's'));+ var visibleLabel = entry.getAttribute('data-legend-label') || fact.label;+ entry.setAttribute('aria-label', 'Inspect ' + visibleLabel + ', ' + count + ' node' + (count === 1 ? '' : 's'));entry.setAttribute('aria-pressed', 'false');entry.setAttribute('aria-haspopup', 'dialog');entry.setAttribute('aria-controls', 'semantic-lens');diff --git a/docs/gallery/artifacts/release-delivery.workflow.html b/docs/gallery/artifacts/release-delivery.workflow.htmlindex 68202415..9e09b8b0 100644--- a/docs/gallery/artifacts/release-delivery.workflow.html+++ b/docs/gallery/artifacts/release-delivery.workflow.html@@ -4772,28 +4772,32 @@</g><!-- Legend -->- <g data-legend-bridge>- <text x="175" y="800" class="t-primary" font-size="10" font-weight="600">Legend</text>- <g data-legend-kind="frontend">- <rect x="175" y="812" width="14" height="9" rx="2" class="c-frontend" stroke-width="1"/>- <text x="195" y="820" class="t-muted" font-size="7">User UI</text>- </g>- <g data-legend-kind="backend">- <rect x="260" y="812" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>- <text x="280" y="820" class="t-muted" font-size="7">Agent logic</text>- </g>- <g data-legend-kind="security">- <rect x="370" y="812" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>- <text x="390" y="820" class="t-muted" font-size="7">Policy</text>- </g>- <g data-legend-kind="messagebus">- <rect x="455" y="812" width="14" height="9" rx="2" class="c-messagebus" stroke-width="1"/>- <text x="475" y="820" class="t-muted" font-size="7">Tool action</text>- </g>- <g data-legend-kind="database">- <rect x="565" y="812" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>- <text x="585" y="820" class="t-muted" font-size="7">Context / trace</text>- </g>+ <g data-legend data-legend-bridge>+ <text x="20" y="800" class="t-primary" font-size="10" font-weight="600">Legend</text>+ <g data-legend-semantic-kind="frontend" data-legend-kind="frontend" data-legend-label="User UI" data-legend-x="20" data-legend-baseline="820" data-legend-width="73">+ <rect x="20" y="812" width="14" height="9" rx="2" class="c-frontend" stroke-width="1"/>+ <text x="41" y="820" class="t-muted" font-size="7">User UI</text>+ </g>+ <g data-legend-semantic-kind="backend" data-legend-kind="backend" data-legend-label="Agent logic" data-legend-x="100" data-legend-baseline="820" data-legend-width="90">+ <rect x="100" y="812" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>+ <text x="121" y="820" class="t-muted" font-size="7">Agent logic</text>+ </g>+ <g data-legend-semantic-kind="security" data-legend-kind="security" data-legend-label="Policy" data-legend-x="197" data-legend-baseline="820" data-legend-width="69">+ <rect x="197" y="812" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>+ <text x="218" y="820" class="t-muted" font-size="7">Policy</text>+ </g>+ <g data-legend-semantic-kind="messagebus" data-legend-kind="messagebus" data-legend-label="Tool action" data-legend-x="273" data-legend-baseline="820" data-legend-width="90">+ <rect x="273" y="812" width="14" height="9" rx="2" class="c-messagebus" stroke-width="1"/>+ <text x="294" y="820" class="t-muted" font-size="7">Tool action</text>+ </g>+ <g data-legend-semantic-kind="cloud" data-legend-kind="cloud" data-legend-label="Cloud service" data-legend-x="370" data-legend-baseline="820" data-legend-width="99">+ <rect x="370" y="812" width="14" height="9" rx="2" class="c-cloud" stroke-width="1"/>+ <text x="391" y="820" class="t-muted" font-size="7">Cloud service</text>+ </g>+ <g data-legend-semantic-kind="external" data-legend-kind="external" data-legend-label="External system" data-legend-x="476" data-legend-baseline="820" data-legend-width="108">+ <rect x="476" y="812" width="14" height="9" rx="2" class="c-external" stroke-width="1"/>+ <text x="497" y="820" class="t-muted" font-size="7">External system</text>+ </g></g></svg><p class="intent-trace-status no-print" id="intent-trace-status" role="status" aria-live="polite" aria-atomic="true"></p>@@ -5499,6 +5503,7 @@});Array.prototype.forEach.call(clone.querySelectorAll('[data-legend-kind]'), function (el) {el.removeAttribute('data-legend-kind');+ el.removeAttribute('data-legend-label');el.removeAttribute('data-legend-count');el.removeAttribute('data-legend-zero');el.removeAttribute('data-legend-selected');@@ -12457,7 +12462,8 @@}entry.setAttribute('role', 'button');entry.setAttribute('tabindex', legendEntries.length ? '-1' : '0');- entry.setAttribute('aria-label', 'Inspect ' + fact.label + ', ' + count + ' node' + (count === 1 ? '' : 's'));+ var visibleLabel = entry.getAttribute('data-legend-label') || fact.label;+ entry.setAttribute('aria-label', 'Inspect ' + visibleLabel + ', ' + count + ' node' + (count === 1 ? '' : 's'));entry.setAttribute('aria-pressed', 'false');entry.setAttribute('aria-haspopup', 'dialog');entry.setAttribute('aria-controls', 'semantic-lens');diff --git a/docs/gallery/artifacts/web-app.architecture.html b/docs/gallery/artifacts/web-app.architecture.htmlindex 6118f90a..b655a35e 100644--- a/docs/gallery/artifacts/web-app.architecture.html+++ b/docs/gallery/artifacts/web-app.architecture.html@@ -4737,31 +4737,31 @@<!-- Legend -->- <g data-legend-bridge>- <text x="40" y="559" class="t-primary" font-size="9" font-weight="600">Legend</text>- <g data-legend-kind="external">- <rect x="40" y="564" width="14" height="9" rx="2" class="c-external" stroke-width="1"/>- <text x="60" y="572" class="t-muted" font-size="8">External</text>+ <g data-legend data-legend-bridge>+ <text x="40" y="552" class="t-primary" font-size="10" font-weight="600">Legend</text>+ <g data-legend-semantic-kind="backend" data-legend-kind="backend" data-legend-label="Backend" data-legend-x="40" data-legend-baseline="572" data-legend-width="77">+ <rect x="40" y="564" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>+ <text x="61" y="572" class="t-muted" font-size="8">Backend</text></g>- <g data-legend-kind="security">- <rect x="144" y="564" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>- <text x="164" y="572" class="t-muted" font-size="8">Security</text>+ <g data-legend-semantic-kind="database" data-legend-kind="database" data-legend-label="Database" data-legend-x="139" data-legend-baseline="572" data-legend-width="82">+ <rect x="139" y="564" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>+ <text x="160" y="572" class="t-muted" font-size="8">Database</text></g>- <g data-legend-kind="cloud">- <rect x="248" y="564" width="14" height="9" rx="2" class="c-cloud" stroke-width="1"/>- <text x="268" y="572" class="t-muted" font-size="8">Cloud</text>+ <g data-legend-semantic-kind="cloud" data-legend-kind="cloud" data-legend-label="Cloud" data-legend-x="243" data-legend-baseline="572" data-legend-width="67">+ <rect x="243" y="564" width="14" height="9" rx="2" class="c-cloud" stroke-width="1"/>+ <text x="264" y="572" class="t-muted" font-size="8">Cloud</text></g>- <g data-legend-kind="backend">- <rect x="337" y="564" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>- <text x="357" y="572" class="t-muted" font-size="8">Backend</text>+ <g data-legend-semantic-kind="security" data-legend-kind="security" data-legend-label="Security" data-legend-x="332" data-legend-baseline="572" data-legend-width="82">+ <rect x="332" y="564" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>+ <text x="353" y="572" class="t-muted" font-size="8">Security</text></g>- <g data-legend-kind="database">- <rect x="436" y="564" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>- <text x="456" y="572" class="t-muted" font-size="8">Database</text>+ <g data-legend-semantic-kind="messagebus" data-legend-kind="messagebus" data-legend-label="Message bus" data-legend-x="436" data-legend-baseline="572" data-legend-width="97">+ <rect x="436" y="564" width="14" height="9" rx="2" class="c-messagebus" stroke-width="1"/>+ <text x="457" y="572" class="t-muted" font-size="8">Message bus</text></g>- <g data-legend-kind="messagebus">- <rect x="540" y="564" width="14" height="9" rx="2" class="c-messagebus" stroke-width="1"/>- <text x="560" y="572" class="t-muted" font-size="8">Message bus</text>+ <g data-legend-semantic-kind="external" data-legend-kind="external" data-legend-label="External" data-legend-x="555" data-legend-baseline="572" data-legend-width="82">+ <rect x="555" y="564" width="14" height="9" rx="2" class="c-external" stroke-width="1"/>+ <text x="576" y="572" class="t-muted" font-size="8">External</text></g></g></svg>@@ -5466,6 +5466,7 @@});Array.prototype.forEach.call(clone.querySelectorAll('[data-legend-kind]'), function (el) {el.removeAttribute('data-legend-kind');+ el.removeAttribute('data-legend-label');el.removeAttribute('data-legend-count');el.removeAttribute('data-legend-zero');el.removeAttribute('data-legend-selected');@@ -12424,7 +12425,8 @@}entry.setAttribute('role', 'button');entry.setAttribute('tabindex', legendEntries.length ? '-1' : '0');- entry.setAttribute('aria-label', 'Inspect ' + fact.label + ', ' + count + ' node' + (count === 1 ? '' : 's'));+ var visibleLabel = entry.getAttribute('data-legend-label') || fact.label;+ entry.setAttribute('aria-label', 'Inspect ' + visibleLabel + ', ' + count + ' node' + (count === 1 ? '' : 's'));entry.setAttribute('aria-pressed', 'false');entry.setAttribute('aria-haspopup', 'dialog');entry.setAttribute('aria-controls', 'semantic-lens');diff --git a/docs/gallery/manifest.json b/docs/gallery/manifest.jsonindex 0d785237..7a03c42a 100644--- a/docs/gallery/manifest.json+++ b/docs/gallery/manifest.json@@ -27,8 +27,8 @@"engineeringProfile": null,"nodeCount": 12,"edgeCount": 11,- "artifactBytes": 619337,- "artifactSha256": "969d6f866a040cbb2923a2ed83b8eb2bc17761f9c8f3cac2070dca9d1a94f312",+ "artifactBytes": 620978,+ "artifactSha256": "1a1611bce923465b57c88b76b94c31df4ae8c548e95ca0b33ab294a0d8670995","sourceBytes": 6470,"sourceSha256": "a3afc6b30044eb256aa15c6195ddfbbcd1a14880d99967ed5605bc621ffb7e5f","checks": [@@ -125,8 +125,8 @@"engineeringProfile": "deployment-ownership","nodeCount": 12,"edgeCount": 12,- "artifactBytes": 619653,- "artifactSha256": "ff3f9976979b6c3f1477ff5bed79e6ef0c1ce3d5b484665b7ddcb4decdf058ab",+ "artifactBytes": 620615,+ "artifactSha256": "0a6b95d5db1bd118a265935d625db0b8d8d5895e4031110c53c8513d482c35bb","sourceBytes": 5546,"sourceSha256": "03e647d057eb20d99f7fb4ba4ddfdd5d58a7a813865338680e968038e6a90e0f","checks": [@@ -223,8 +223,8 @@"engineeringProfile": null,"nodeCount": 7,"edgeCount": 12,- "artifactBytes": 613486,- "artifactSha256": "4c0b4f4f47c2e422f1fd840263879ea2f23f76290e068994b9126f791d9d8bb0",+ "artifactBytes": 614562,+ "artifactSha256": "a0c435f4066d3c039536c2a82a69dabca5fd49dbb5265a42e6c2c556dd8934b0","sourceBytes": 4442,"sourceSha256": "30098d81006a18813bab447da698edf74604a1463770f01dc056b0af8cb314ef","checks": [@@ -321,8 +321,8 @@"engineeringProfile": null,"nodeCount": 10,"edgeCount": 10,- "artifactBytes": 615599,- "artifactSha256": "824ba0b9bfe49baa3b1cc30a6cc5bc0d48b0ad2f6585812d0003f8a45d3a18ce",+ "artifactBytes": 616851,+ "artifactSha256": "e731f6b71e38ee9d82ba32a7f48c33da8e789948ac14bf31e390ee8714a636ba","sourceBytes": 5256,"sourceSha256": "44aa56ac6ca807937dfe84a6404e8b07d6394a38ae2ac53248a1985337dfd671","checks": [@@ -419,8 +419,8 @@"engineeringProfile": null,"nodeCount": 11,"edgeCount": 10,- "artifactBytes": 615460,- "artifactSha256": "ff3aeb81e75927679c8f19427f436d6f60768572868eb67a1e7c4252d0951d2e",+ "artifactBytes": 617101,+ "artifactSha256": "f561a36dcf781269709274c06b8b1765765823966107c48fdd6134f7307a571e","sourceBytes": 5471,"sourceSha256": "9beb8698b275679a2fc92d4b51288cd5b5fc2115696d06b9168f3d7fef253a72","checks": [@@ -517,8 +517,8 @@"engineeringProfile": null,"nodeCount": 10,"edgeCount": 10,- "artifactBytes": 616986,- "artifactSha256": "5c01aff416b7b44f12c1549064907da9d79cfa98714bc61dcc15e318509d24cb",+ "artifactBytes": 618137,+ "artifactSha256": "c7d6d53272eecb8f33236e7705d19e511092dc267c446cfd54627aab37fc4cae","sourceBytes": 5719,"sourceSha256": "f71c89288f80255bdedcdc0057bcbc155d1d8b1b7476d024b35f4e27c730c974","checks": [@@ -615,8 +615,8 @@"engineeringProfile": null,"nodeCount": 7,"edgeCount": 14,- "artifactBytes": 614283,- "artifactSha256": "c6361d168e6ea7d248a42e053da7fc387dece34e2c5da29e91841b9d8cbbb93b",+ "artifactBytes": 615023,+ "artifactSha256": "433af989bf3796728ff540c36b09aac79339547c5f23dc8c49d53d30e8515918","sourceBytes": 4483,"sourceSha256": "1b53d7c4ce7b2d8f6f40b8f33a394abe1d37fc991272b534c1ccd0255920ab52","checks": [@@ -713,8 +713,8 @@"engineeringProfile": null,"nodeCount": 12,"edgeCount": 12,- "artifactBytes": 620941,- "artifactSha256": "2be7f08e8b3c8a1cd50bef6152db0dfac98ef6e70d3f1fb27438a3e10bd39d84",+ "artifactBytes": 622092,+ "artifactSha256": "9d1e02bd3c1120c1d569a0f053b1646188e53ae821a9e79f2ecaab3653320aac","sourceBytes": 5543,"sourceSha256": "bbfedc2f1b73bf50932490f7f56d45d5f853e970d2fab26660a04947a783969c","checks": [@@ -811,8 +811,8 @@"engineeringProfile": null,"nodeCount": 10,"edgeCount": 6,- "artifactBytes": 610318,- "artifactSha256": "1179a53de66ab1ed58639dcdd25f574a6c102087f810adcce40f3ca158858575",+ "artifactBytes": 611790,+ "artifactSha256": "6aea53f4a18df5dd795634f3e6f615645f022d82f5e5611c05ecefe349b534e9","sourceBytes": 4527,"sourceSha256": "2e756b3d1ebc2f6c3f62f46c0fbb5584ed7bd6213627259ab43153b18c831cdf","checks": [@@ -909,8 +909,8 @@"engineeringProfile": null,"nodeCount": 11,"edgeCount": 6,- "artifactBytes": 611308,- "artifactSha256": "d3cecbf6ecf3bd2d347297de6312a22a8858d1cd5ce71cca5000de6c665bb56f",+ "artifactBytes": 612780,+ "artifactSha256": "40f86167ba5f91026abf156a387a3f1cbf09a2fb05d40051b9e28f8d8b9e793a","sourceBytes": 4394,"sourceSha256": "aa614f0c9a82f210e301e382f362dfbd7f290bda4d5501de3c99a6cd81b4c0a4","checks": [@@ -1007,8 +1007,8 @@"engineeringProfile": null,"nodeCount": 10,"edgeCount": 9,- "artifactBytes": 610940,- "artifactSha256": "35d9c14c7b9589c3f9f6ede9b8d7d6f276bc861dee126080c7460bca187239d7",+ "artifactBytes": 611902,+ "artifactSha256": "377a5fcf6350bf594d888a7b27641fc6e91121e4e2e98b1a8aabe98b97510f87","sourceBytes": 3863,"sourceSha256": "01567b5e49cad5139baa071533a028d22f0e80fedfb49095e0d9330aee7f87db","checks": [diff --git a/docs/issue-52-visual-evidence/README.md b/docs/issue-52-visual-evidence/README.mdnew file mode 100644index 00000000..00a6d554--- /dev/null+++ b/docs/issue-52-visual-evidence/README.md@@ -0,0 +1,36 @@+# Issue #52 visual acceptance++Browser review status: **passed** on 2026-08-02 with Google Chrome headless at+1280px width. The source fixtures are the two reproductions from Issue #52.+“Before” was rendered from `origin/main@a097c2d63eceeff9603a911a9075f0694d381f83`;+“after” was rendered from this worktree.++++| Reproduction | Dark | Light | Result |+|---|---|---|---|+| Dataflow default-only | [before](before-dataflow-dark.png) / [after](after-dataflow-dark.png) | [before](before-dataflow-light.png) / [after](after-dataflow-light.png) | After shows only `data flow`; PII, async, emphasis, and data-store claims are absent. |+| Lifecycle start → active → success | [before](before-lifecycle-dark.png) / [after](after-lifecycle-dark.png) | [before](before-lifecycle-light.png) / [after](after-lifecycle-light.png) | After shows `start`, `active state`, and `terminal success`; waiting and failure are absent. |++The machine-readable [browser results](browser-results.json) also confirm zero+runtime exceptions/`console.error` calls, in-viewBox bounds, exact interactive+roles and accessible names, custom-label propagation, visual-only forced unused+kinds, long mixed-label non-overlap, and complete hidden-mode removal. The+`npm run test:webm` browser gate additionally exercises roving keyboard+navigation, counts and selection, canonical SVG cleanup, print/embed behavior,+guided views, and the Classic/Signal Flow/Blueprint/Editorial × dark/light+matrix. Its Dataflow fixture proves that a real database node exposes one+`data store` button with count `1`, while the adjacent flow-variant entry stays+visual-only; Enter opens Semantic Lens on stable kind `database` and canonical+export strips the bridge decoration.++Checks performed in both themes:++- legend labels and swatches are visible, aligned, and inside the SVG;+- no label overlap, clipping, or unexpected empty legend region;+- node, state, transition, stage, and flow geometry is unchanged;+- no browser-visible rendering failure in either theme.++The PNGs are deterministic evidence artifacts; the generated HTML was not+checked in because it is already covered by the public renderer tests and would+duplicate the full viewer runtime eight times.diff --git a/docs/issue-52-visual-evidence/after-dataflow-dark.png b/docs/issue-52-visual-evidence/after-dataflow-dark.pngnew file mode 100644index 00000000..078a5bdfBinary files /dev/null and b/docs/issue-52-visual-evidence/after-dataflow-dark.png differdiff --git a/docs/issue-52-visual-evidence/after-dataflow-light.png b/docs/issue-52-visual-evidence/after-dataflow-light.pngnew file mode 100644index 00000000..fcd22ac7Binary files /dev/null and b/docs/issue-52-visual-evidence/after-dataflow-light.png differdiff --git a/docs/issue-52-visual-evidence/after-lifecycle-dark.png b/docs/issue-52-visual-evidence/after-lifecycle-dark.pngnew file mode 100644index 00000000..7f713c09Binary files /dev/null and b/docs/issue-52-visual-evidence/after-lifecycle-dark.png differdiff --git a/docs/issue-52-visual-evidence/after-lifecycle-light.png b/docs/issue-52-visual-evidence/after-lifecycle-light.pngnew file mode 100644index 00000000..6abe8f1dBinary files /dev/null and b/docs/issue-52-visual-evidence/after-lifecycle-light.png differdiff --git a/docs/issue-52-visual-evidence/before-dataflow-dark.png b/docs/issue-52-visual-evidence/before-dataflow-dark.pngnew file mode 100644index 00000000..6a888245Binary files /dev/null and b/docs/issue-52-visual-evidence/before-dataflow-dark.png differdiff --git a/docs/issue-52-visual-evidence/before-dataflow-light.png b/docs/issue-52-visual-evidence/before-dataflow-light.pngnew file mode 100644index 00000000..9037ac94Binary files /dev/null and b/docs/issue-52-visual-evidence/before-dataflow-light.png differdiff --git a/docs/issue-52-visual-evidence/before-lifecycle-dark.png b/docs/issue-52-visual-evidence/before-lifecycle-dark.pngnew file mode 100644index 00000000..c47ca77bBinary files /dev/null and b/docs/issue-52-visual-evidence/before-lifecycle-dark.png differdiff --git a/docs/issue-52-visual-evidence/before-lifecycle-light.png b/docs/issue-52-visual-evidence/before-lifecycle-light.pngnew file mode 100644index 00000000..c202d713Binary files /dev/null and b/docs/issue-52-visual-evidence/before-lifecycle-light.png differdiff --git a/docs/issue-52-visual-evidence/browser-results.json b/docs/issue-52-visual-evidence/browser-results.jsonnew file mode 100644index 00000000..3c7b8903--- /dev/null+++ b/docs/issue-52-visual-evidence/browser-results.json@@ -0,0 +1,156 @@+{+ "ok": true,+ "chrome": "Google Chrome headless",+ "viewportThemes": [+ "dark",+ "light"+ ],+ "results": {+ "dataflow-dark": {+ "theme": "dark",+ "kinds": [+ "default"+ ],+ "bridge": false,+ "legendTitle": true,+ "roles": [+ null+ ],+ "aria": [+ null+ ],+ "inside": true,+ "nonOverlapping": true+ },+ "lifecycle-dark": {+ "theme": "dark",+ "kinds": [+ "start",+ "active",+ "success"+ ],+ "bridge": true,+ "legendTitle": true,+ "roles": [+ "button",+ "button",+ "button"+ ],+ "aria": [+ "Inspect start, 1 node",+ "Inspect active state, 1 node",+ "Inspect terminal success, 1 node"+ ],+ "inside": true,+ "nonOverlapping": true+ },+ "dataflow-light": {+ "theme": "light",+ "kinds": [+ "default"+ ],+ "bridge": false,+ "legendTitle": true,+ "roles": [+ null+ ],+ "aria": [+ null+ ],+ "inside": true,+ "nonOverlapping": true+ },+ "lifecycle-light": {+ "theme": "light",+ "kinds": [+ "start",+ "active",+ "success"+ ],+ "bridge": true,+ "legendTitle": true,+ "roles": [+ "button",+ "button",+ "button"+ ],+ "aria": [+ "Inspect start, 1 node",+ "Inspect active state, 1 node",+ "Inspect terminal success, 1 node"+ ],+ "inside": true,+ "nonOverlapping": true+ },+ "custom": {+ "theme": "dark",+ "kinds": [+ "frontend",+ "database",+ "external"+ ],+ "bridge": true,+ "legendTitle": true,+ "roles": [+ "button",+ "button",+ null+ ],+ "aria": [+ "Inspect Reader <UI> & ops, 1 node",+ "Inspect Database, 1 node",+ null+ ],+ "inside": true,+ "nonOverlapping": true+ },+ "hidden": {+ "theme": "dark",+ "kinds": [],+ "bridge": false,+ "legendTitle": false,+ "roles": [],+ "aria": [],+ "inside": true,+ "nonOverlapping": true+ },+ "longLabels": {+ "theme": "dark",+ "kinds": [+ "start",+ "active",+ "waiting",+ "decision",+ "success",+ "failure",+ "neutral",+ "external"+ ],+ "bridge": true,+ "legendTitle": true,+ "roles": [+ "button",+ "button",+ null,+ null,+ null,+ null,+ null,+ null+ ],+ "aria": [+ "Inspect 开始 / Start of the complete lifecycle, 1 node",+ "Inspect 正在执行 active processing, 1 node",+ null,+ null,+ null,+ null,+ null,+ null+ ],+ "inside": true,+ "nonOverlapping": true+ }+ },+ "runtimeErrors": []+}diff --git a/docs/issue-52-visual-evidence/contact-sheet.png b/docs/issue-52-visual-evidence/contact-sheet.pngnew file mode 100644index 00000000..cd3263dcBinary files /dev/null and b/docs/issue-52-visual-evidence/contact-sheet.png differdiff --git a/docs/issue-52-visual-evidence/dataflow-repro.json b/docs/issue-52-visual-evidence/dataflow-repro.jsonnew file mode 100644index 00000000..028e514e--- /dev/null+++ b/docs/issue-52-visual-evidence/dataflow-repro.json@@ -0,0 +1,13 @@+{+ "schema_version": 1,+ "diagram_type": "dataflow",+ "meta": { "title": "Default Flow Only" },+ "stages": [{ "label": "Input" }, { "label": "Output" }],+ "nodes": [+ { "id": "input", "type": "backend", "label": "Input", "stage": 0, "row": 0 },+ { "id": "output", "type": "backend", "label": "Output", "stage": 1, "row": 0 }+ ],+ "flows": [+ { "from": "input", "to": "output", "label": "request", "route": "straight" }+ ]+}diff --git a/docs/issue-52-visual-evidence/lifecycle-repro.json b/docs/issue-52-visual-evidence/lifecycle-repro.jsonnew file mode 100644index 00000000..482a0a58--- /dev/null+++ b/docs/issue-52-visual-evidence/lifecycle-repro.json@@ -0,0 +1,15 @@+{+ "schema_version": 1,+ "diagram_type": "lifecycle",+ "meta": { "title": "No Waiting or Failure", "viewBox": [720, 566] },+ "lanes": [{ "id": "main", "label": "Lifecycle" }],+ "states": [+ { "id": "started", "type": "start", "label": "Started", "lane": "main", "col": 0 },+ { "id": "running", "type": "active", "label": "Running", "lane": "main", "col": 1 },+ { "id": "completed", "type": "success", "label": "Completed", "lane": "main", "col": 2 }+ ],+ "transitions": [+ { "from": "started", "to": "running" },+ { "from": "running", "to": "completed" }+ ]+}diff --git a/examples/dataflow-product-analytics.html b/examples/dataflow-product-analytics.htmlindex b585c2fd..d86ebf25 100644--- a/examples/dataflow-product-analytics.html+++ b/examples/dataflow-product-analytics.html@@ -4784,15 +4784,29 @@</g><!-- Legend -->- <text x="214" y="704" class="t-primary" font-size="10" font-weight="600">Legend</text>- <path d="M 214 724 L 248 724" class="a-emphasis" stroke-width="1.8" marker-end="url(#arrowhead-emphasis)"/>- <text x="257" y="727" class="t-muted" font-size="8">primary data</text>- <path d="M 340 724 L 374 724" class="a-security" stroke-width="1.4" marker-end="url(#arrowhead-security)"/>- <text x="383" y="727" class="t-muted" font-size="8">policy / PII</text>- <path d="M 480 724 L 514 724" class="a-dashed" stroke-width="1.4" marker-end="url(#arrowhead-dashed)"/>- <text x="523" y="727" class="t-muted" font-size="8">async batch</text>- <rect x="625" y="716" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>- <text x="646" y="724" class="t-muted" font-size="8">data store</text>+ <g data-legend data-legend-bridge>+ <text x="40" y="704" class="t-primary" font-size="10" font-weight="600">Legend</text>+ <g data-legend-semantic-kind="emphasis" data-legend-x="40" data-legend-baseline="724" data-legend-width="103">+ <path d="M 40 721 L 74 721" class="a-emphasis" stroke-width="1.8" marker-end="url(#arrowhead-emphasis)"/>+ <text x="83" y="724" class="t-muted" font-size="8">primary data</text>+ </g>+ <g data-legend-semantic-kind="security" data-legend-x="165" data-legend-baseline="724" data-legend-width="103">+ <path d="M 165 721 L 199 721" class="a-security" stroke-width="1.4" marker-end="url(#arrowhead-security)"/>+ <text x="208" y="724" class="t-muted" font-size="8">policy / PII</text>+ </g>+ <g data-legend-semantic-kind="dashed" data-legend-x="290" data-legend-baseline="724" data-legend-width="98">+ <path d="M 290 721 L 324 721" class="a-dashed" stroke-width="1.4" marker-end="url(#arrowhead-dashed)"/>+ <text x="333" y="724" class="t-muted" font-size="8">async batch</text>+ </g>+ <g data-legend-semantic-kind="database" data-legend-kind="database" data-legend-label="data store" data-legend-x="410" data-legend-baseline="724" data-legend-width="92">+ <rect x="410" y="716" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>+ <text x="431" y="724" class="t-muted" font-size="8">data store</text>+ </g>+ <g data-legend-semantic-kind="default" data-legend-x="524" data-legend-baseline="724" data-legend-width="88">+ <path d="M 524 721 L 558 721" class="a-default" stroke-width="1.4" marker-end="url(#arrowhead)"/>+ <text x="567" y="724" class="t-muted" font-size="8">data flow</text>+ </g>+ </g></svg><p class="intent-trace-status no-print" id="intent-trace-status" role="status" aria-live="polite" aria-atomic="true"></p><div class="share-chapter-cue no-print" id="share-chapter-cue" hidden role="status" aria-live="polite">@@ -5497,6 +5511,7 @@});Array.prototype.forEach.call(clone.querySelectorAll('[data-legend-kind]'), function (el) {el.removeAttribute('data-legend-kind');+ el.removeAttribute('data-legend-label');el.removeAttribute('data-legend-count');el.removeAttribute('data-legend-zero');el.removeAttribute('data-legend-selected');@@ -12455,7 +12470,8 @@}entry.setAttribute('role', 'button');entry.setAttribute('tabindex', legendEntries.length ? '-1' : '0');- entry.setAttribute('aria-label', 'Inspect ' + fact.label + ', ' + count + ' node' + (count === 1 ? '' : 's'));+ var visibleLabel = entry.getAttribute('data-legend-label') || fact.label;+ entry.setAttribute('aria-label', 'Inspect ' + visibleLabel + ', ' + count + ' node' + (count === 1 ? '' : 's'));entry.setAttribute('aria-pressed', 'false');entry.setAttribute('aria-haspopup', 'dialog');entry.setAttribute('aria-controls', 'semantic-lens');diff --git a/examples/lifecycle-agent-run.html b/examples/lifecycle-agent-run.htmlindex 7a7580bc..5bb5d2ec 100644--- a/examples/lifecycle-agent-run.html+++ b/examples/lifecycle-agent-run.html@@ -4729,24 +4729,32 @@<!-- Legend -->- <g data-legend-bridge>- <text x="220" y="542" class="t-primary" font-size="10" font-weight="600">Legend</text>- <g data-legend-kind="active">- <rect x="220" y="554" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>- <text x="240" y="562" class="t-muted" font-size="7">active state</text>- </g>- <g data-legend-kind="waiting">- <rect x="325" y="554" width="14" height="9" rx="2" class="c-cloud" stroke-width="1"/>- <text x="345" y="562" class="t-muted" font-size="7">waiting</text>- </g>- <g data-legend-kind="success">- <rect x="415" y="554" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>- <text x="435" y="562" class="t-muted" font-size="7">terminal success</text>- </g>- <g data-legend-kind="failure">- <rect x="560" y="554" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>- <text x="580" y="562" class="t-muted" font-size="7">failure / exit</text>- </g>+ <g data-legend data-legend-bridge>+ <text x="40" y="604" class="t-primary" font-size="10" font-weight="600">Legend</text>+ <g data-legend-semantic-kind="start" data-legend-kind="start" data-legend-label="start" data-legend-x="40" data-legend-baseline="624" data-legend-width="67">+ <rect x="40" y="616" width="14" height="9" rx="2" class="c-frontend" stroke-width="1"/>+ <text x="61" y="624" class="t-muted" font-size="8">start</text>+ </g>+ <g data-legend-semantic-kind="active" data-legend-kind="active" data-legend-label="active state" data-legend-x="129" data-legend-baseline="624" data-legend-width="102">+ <rect x="129" y="616" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>+ <text x="150" y="624" class="t-muted" font-size="8">active state</text>+ </g>+ <g data-legend-semantic-kind="waiting" data-legend-kind="waiting" data-legend-label="waiting" data-legend-x="253" data-legend-baseline="624" data-legend-width="77">+ <rect x="253" y="616" width="14" height="9" rx="2" class="c-cloud" stroke-width="1"/>+ <text x="274" y="624" class="t-muted" font-size="8">waiting</text>+ </g>+ <g data-legend-semantic-kind="decision" data-legend-kind="decision" data-legend-label="decision" data-legend-x="352" data-legend-baseline="624" data-legend-width="82">+ <rect x="352" y="616" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>+ <text x="373" y="624" class="t-muted" font-size="8">decision</text>+ </g>+ <g data-legend-semantic-kind="success" data-legend-kind="success" data-legend-label="terminal success" data-legend-x="456" data-legend-baseline="624" data-legend-width="122">+ <rect x="456" y="616" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>+ <text x="477" y="624" class="t-muted" font-size="8">terminal success</text>+ </g>+ <g data-legend-semantic-kind="failure" data-legend-kind="failure" data-legend-label="failure / exit" data-legend-x="600" data-legend-baseline="624" data-legend-width="112">+ <rect x="600" y="616" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>+ <text x="621" y="624" class="t-muted" font-size="8">failure / exit</text>+ </g></g></svg><p class="intent-trace-status no-print" id="intent-trace-status" role="status" aria-live="polite" aria-atomic="true"></p>@@ -5452,6 +5460,7 @@});Array.prototype.forEach.call(clone.querySelectorAll('[data-legend-kind]'), function (el) {el.removeAttribute('data-legend-kind');+ el.removeAttribute('data-legend-label');el.removeAttribute('data-legend-count');el.removeAttribute('data-legend-zero');el.removeAttribute('data-legend-selected');@@ -12410,7 +12419,8 @@}entry.setAttribute('role', 'button');entry.setAttribute('tabindex', legendEntries.length ? '-1' : '0');- entry.setAttribute('aria-label', 'Inspect ' + fact.label + ', ' + count + ' node' + (count === 1 ? '' : 's'));+ var visibleLabel = entry.getAttribute('data-legend-label') || fact.label;+ entry.setAttribute('aria-label', 'Inspect ' + visibleLabel + ', ' + count + ' node' + (count === 1 ? '' : 's'));entry.setAttribute('aria-pressed', 'false');entry.setAttribute('aria-haspopup', 'dialog');entry.setAttribute('aria-controls', 'semantic-lens');diff --git a/examples/sequence-cache-miss-request.html b/examples/sequence-cache-miss-request.htmlindex d68ad688..4ba124e4 100644--- a/examples/sequence-cache-miss-request.html+++ b/examples/sequence-cache-miss-request.html@@ -4799,15 +4799,29 @@</g><!-- Legend -->- <text x="150" y="686" class="t-primary" font-size="10" font-weight="600">Legend</text>- <path d="M 150 706 L 184 706" class="a-emphasis" stroke-width="1.8" marker-end="url(#arrowhead-emphasis)"/>- <text x="193" y="709" class="t-muted" font-size="8">request</text>- <path d="M 270 706 L 304 706" class="a-default" stroke-width="1.4" stroke-dasharray="3,5" marker-end="url(#arrowhead)"/>- <text x="313" y="709" class="t-muted" font-size="8">return</text>- <path d="M 385 706 L 419 706" class="a-security" stroke-width="1.4" marker-end="url(#arrowhead-security)"/>- <text x="428" y="709" class="t-muted" font-size="8">security</text>- <path d="M 530 706 L 564 706" class="a-dashed" stroke-width="1.4" marker-end="url(#arrowhead-dashed)"/>- <text x="573" y="709" class="t-muted" font-size="8">async trace</text>+ <g data-legend>+ <text x="40" y="686" class="t-primary" font-size="10" font-weight="600">Legend</text>+ <g data-legend-semantic-kind="emphasis" data-legend-x="40" data-legend-baseline="706" data-legend-width="78">+ <path d="M 40 703 L 74 703" class="a-emphasis" stroke-width="1.8" marker-end="url(#arrowhead-emphasis)"/>+ <text x="83" y="706" class="t-muted" font-size="8">request</text>+ </g>+ <g data-legend-semantic-kind="return" data-legend-x="140" data-legend-baseline="706" data-legend-width="73">+ <path d="M 140 703 L 174 703" class="a-default" stroke-width="1.4" stroke-dasharray="3,5" marker-end="url(#arrowhead)"/>+ <text x="183" y="706" class="t-muted" font-size="8">return</text>+ </g>+ <g data-legend-semantic-kind="security" data-legend-x="235" data-legend-baseline="706" data-legend-width="83">+ <path d="M 235 703 L 269 703" class="a-security" stroke-width="1.4" marker-end="url(#arrowhead-security)"/>+ <text x="278" y="706" class="t-muted" font-size="8">security</text>+ </g>+ <g data-legend-semantic-kind="dashed" data-legend-x="340" data-legend-baseline="706" data-legend-width="98">+ <path d="M 340 703 L 374 703" class="a-dashed" stroke-width="1.4" marker-end="url(#arrowhead-dashed)"/>+ <text x="383" y="706" class="t-muted" font-size="8">async trace</text>+ </g>+ <g data-legend-semantic-kind="default" data-legend-x="460" data-legend-baseline="706" data-legend-width="118">+ <path d="M 460 703 L 494 703" class="a-default" stroke-width="1.4" marker-end="url(#arrowhead)"/>+ <text x="503" y="706" class="t-muted" font-size="8">default message</text>+ </g>+ </g></svg><p class="intent-trace-status no-print" id="intent-trace-status" role="status" aria-live="polite" aria-atomic="true"></p><div class="share-chapter-cue no-print" id="share-chapter-cue" hidden role="status" aria-live="polite">@@ -5512,6 +5526,7 @@});Array.prototype.forEach.call(clone.querySelectorAll('[data-legend-kind]'), function (el) {el.removeAttribute('data-legend-kind');+ el.removeAttribute('data-legend-label');el.removeAttribute('data-legend-count');el.removeAttribute('data-legend-zero');el.removeAttribute('data-legend-selected');@@ -12470,7 +12485,8 @@}entry.setAttribute('role', 'button');entry.setAttribute('tabindex', legendEntries.length ? '-1' : '0');- entry.setAttribute('aria-label', 'Inspect ' + fact.label + ', ' + count + ' node' + (count === 1 ? '' : 's'));+ var visibleLabel = entry.getAttribute('data-legend-label') || fact.label;+ entry.setAttribute('aria-label', 'Inspect ' + visibleLabel + ', ' + count + ' node' + (count === 1 ? '' : 's'));entry.setAttribute('aria-pressed', 'false');entry.setAttribute('aria-haspopup', 'dialog');entry.setAttribute('aria-controls', 'semantic-lens');diff --git a/examples/web-app-rendered.html b/examples/web-app-rendered.htmlindex 6118f90a..b655a35e 100644--- a/examples/web-app-rendered.html+++ b/examples/web-app-rendered.html@@ -4737,31 +4737,31 @@<!-- Legend -->- <g data-legend-bridge>- <text x="40" y="559" class="t-primary" font-size="9" font-weight="600">Legend</text>- <g data-legend-kind="external">- <rect x="40" y="564" width="14" height="9" rx="2" class="c-external" stroke-width="1"/>- <text x="60" y="572" class="t-muted" font-size="8">External</text>+ <g data-legend data-legend-bridge>+ <text x="40" y="552" class="t-primary" font-size="10" font-weight="600">Legend</text>+ <g data-legend-semantic-kind="backend" data-legend-kind="backend" data-legend-label="Backend" data-legend-x="40" data-legend-baseline="572" data-legend-width="77">+ <rect x="40" y="564" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>+ <text x="61" y="572" class="t-muted" font-size="8">Backend</text></g>- <g data-legend-kind="security">- <rect x="144" y="564" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>- <text x="164" y="572" class="t-muted" font-size="8">Security</text>+ <g data-legend-semantic-kind="database" data-legend-kind="database" data-legend-label="Database" data-legend-x="139" data-legend-baseline="572" data-legend-width="82">+ <rect x="139" y="564" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>+ <text x="160" y="572" class="t-muted" font-size="8">Database</text></g>- <g data-legend-kind="cloud">- <rect x="248" y="564" width="14" height="9" rx="2" class="c-cloud" stroke-width="1"/>- <text x="268" y="572" class="t-muted" font-size="8">Cloud</text>+ <g data-legend-semantic-kind="cloud" data-legend-kind="cloud" data-legend-label="Cloud" data-legend-x="243" data-legend-baseline="572" data-legend-width="67">+ <rect x="243" y="564" width="14" height="9" rx="2" class="c-cloud" stroke-width="1"/>+ <text x="264" y="572" class="t-muted" font-size="8">Cloud</text></g>- <g data-legend-kind="backend">- <rect x="337" y="564" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>- <text x="357" y="572" class="t-muted" font-size="8">Backend</text>+ <g data-legend-semantic-kind="security" data-legend-kind="security" data-legend-label="Security" data-legend-x="332" data-legend-baseline="572" data-legend-width="82">+ <rect x="332" y="564" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>+ <text x="353" y="572" class="t-muted" font-size="8">Security</text></g>- <g data-legend-kind="database">- <rect x="436" y="564" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>- <text x="456" y="572" class="t-muted" font-size="8">Database</text>+ <g data-legend-semantic-kind="messagebus" data-legend-kind="messagebus" data-legend-label="Message bus" data-legend-x="436" data-legend-baseline="572" data-legend-width="97">+ <rect x="436" y="564" width="14" height="9" rx="2" class="c-messagebus" stroke-width="1"/>+ <text x="457" y="572" class="t-muted" font-size="8">Message bus</text></g>- <g data-legend-kind="messagebus">- <rect x="540" y="564" width="14" height="9" rx="2" class="c-messagebus" stroke-width="1"/>- <text x="560" y="572" class="t-muted" font-size="8">Message bus</text>+ <g data-legend-semantic-kind="external" data-legend-kind="external" data-legend-label="External" data-legend-x="555" data-legend-baseline="572" data-legend-width="82">+ <rect x="555" y="564" width="14" height="9" rx="2" class="c-external" stroke-width="1"/>+ <text x="576" y="572" class="t-muted" font-size="8">External</text></g></g></svg>@@ -5466,6 +5466,7 @@});Array.prototype.forEach.call(clone.querySelectorAll('[data-legend-kind]'), function (el) {el.removeAttribute('data-legend-kind');+ el.removeAttribute('data-legend-label');el.removeAttribute('data-legend-count');el.removeAttribute('data-legend-zero');el.removeAttribute('data-legend-selected');@@ -12424,7 +12425,8 @@}entry.setAttribute('role', 'button');entry.setAttribute('tabindex', legendEntries.length ? '-1' : '0');- entry.setAttribute('aria-label', 'Inspect ' + fact.label + ', ' + count + ' node' + (count === 1 ? '' : 's'));+ var visibleLabel = entry.getAttribute('data-legend-label') || fact.label;+ entry.setAttribute('aria-label', 'Inspect ' + visibleLabel + ', ' + count + ' node' + (count === 1 ? '' : 's'));entry.setAttribute('aria-pressed', 'false');entry.setAttribute('aria-haspopup', 'dialog');entry.setAttribute('aria-controls', 'semantic-lens');diff --git a/examples/web-app.html b/examples/web-app.htmlindex 6118f90a..89c8b2fb 100644--- a/examples/web-app.html+++ b/examples/web-app.html@@ -5466,6 +5466,7 @@});Array.prototype.forEach.call(clone.querySelectorAll('[data-legend-kind]'), function (el) {el.removeAttribute('data-legend-kind');+ el.removeAttribute('data-legend-label');el.removeAttribute('data-legend-count');el.removeAttribute('data-legend-zero');el.removeAttribute('data-legend-selected');@@ -12424,7 +12425,8 @@}entry.setAttribute('role', 'button');entry.setAttribute('tabindex', legendEntries.length ? '-1' : '0');- entry.setAttribute('aria-label', 'Inspect ' + fact.label + ', ' + count + ' node' + (count === 1 ? '' : 's'));+ var visibleLabel = entry.getAttribute('data-legend-label') || fact.label;+ entry.setAttribute('aria-label', 'Inspect ' + visibleLabel + ', ' + count + ' node' + (count === 1 ? '' : 's'));entry.setAttribute('aria-pressed', 'false');entry.setAttribute('aria-haspopup', 'dialog');entry.setAttribute('aria-controls', 'semantic-lens');diff --git a/examples/workflow-agent-tool-call-rendered.html b/examples/workflow-agent-tool-call-rendered.htmlindex 35c7c1a1..1d8e87b2 100644--- a/examples/workflow-agent-tool-call-rendered.html+++ b/examples/workflow-agent-tool-call-rendered.html@@ -4800,28 +4800,36 @@</g><!-- Legend -->- <g data-legend-bridge>- <text x="175" y="800" class="t-primary" font-size="10" font-weight="600">Legend</text>- <g data-legend-kind="frontend">- <rect x="175" y="812" width="14" height="9" rx="2" class="c-frontend" stroke-width="1"/>- <text x="195" y="820" class="t-muted" font-size="7">User UI</text>- </g>- <g data-legend-kind="backend">- <rect x="260" y="812" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>- <text x="280" y="820" class="t-muted" font-size="7">Agent logic</text>- </g>- <g data-legend-kind="security">- <rect x="370" y="812" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>- <text x="390" y="820" class="t-muted" font-size="7">Policy</text>- </g>- <g data-legend-kind="messagebus">- <rect x="455" y="812" width="14" height="9" rx="2" class="c-messagebus" stroke-width="1"/>- <text x="475" y="820" class="t-muted" font-size="7">Tool action</text>- </g>- <g data-legend-kind="database">- <rect x="565" y="812" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>- <text x="585" y="820" class="t-muted" font-size="7">Context / trace</text>- </g>+ <g data-legend data-legend-bridge>+ <text x="20" y="800" class="t-primary" font-size="10" font-weight="600">Legend</text>+ <g data-legend-semantic-kind="frontend" data-legend-kind="frontend" data-legend-label="User UI" data-legend-x="20" data-legend-baseline="820" data-legend-width="73">+ <rect x="20" y="812" width="14" height="9" rx="2" class="c-frontend" stroke-width="1"/>+ <text x="41" y="820" class="t-muted" font-size="7">User UI</text>+ </g>+ <g data-legend-semantic-kind="backend" data-legend-kind="backend" data-legend-label="Agent logic" data-legend-x="100" data-legend-baseline="820" data-legend-width="90">+ <rect x="100" y="812" width="14" height="9" rx="2" class="c-backend" stroke-width="1"/>+ <text x="121" y="820" class="t-muted" font-size="7">Agent logic</text>+ </g>+ <g data-legend-semantic-kind="security" data-legend-kind="security" data-legend-label="Policy" data-legend-x="197" data-legend-baseline="820" data-legend-width="69">+ <rect x="197" y="812" width="14" height="9" rx="2" class="c-security" stroke-width="1"/>+ <text x="218" y="820" class="t-muted" font-size="7">Policy</text>+ </g>+ <g data-legend-semantic-kind="messagebus" data-legend-kind="messagebus" data-legend-label="Tool action" data-legend-x="273" data-legend-baseline="820" data-legend-width="90">+ <rect x="273" y="812" width="14" height="9" rx="2" class="c-messagebus" stroke-width="1"/>+ <text x="294" y="820" class="t-muted" font-size="7">Tool action</text>+ </g>+ <g data-legend-semantic-kind="database" data-legend-kind="database" data-legend-label="Context / trace" data-legend-x="370" data-legend-baseline="820" data-legend-width="108">+ <rect x="370" y="812" width="14" height="9" rx="2" class="c-database" stroke-width="1"/>+ <text x="391" y="820" class="t-muted" font-size="7">Context / trace</text>+ </g>+ <g data-legend-semantic-kind="cloud" data-legend-kind="cloud" data-legend-label="Cloud service" data-legend-x="485" data-legend-baseline="820" data-legend-width="99">+ <rect x="485" y="812" width="14" height="9" rx="2" class="c-cloud" stroke-width="1"/>+ <text x="506" y="820" class="t-muted" font-size="7">Cloud service</text>+ </g>+ <g data-legend-semantic-kind="external" data-legend-kind="external" data-legend-label="External system" data-legend-x="591" data-legend-baseline="820" data-legend-width="108">+ <rect x="591" y="812" width="14" height="9" rx="2" class="c-external" stroke-width="1"/>+ <text x="612" y="820" class="t-muted" font-size="7">External system</text>+ </g></g></svg><p class="intent-trace-status no-print" id="intent-trace-status" role="status" aria-live="polite" aria-atomic="true"></p>@@ -5530,6 +5538,7 @@});Array.prototype.forEach.call(clone.querySelectorAll('[data-legend-kind]'), function (el) {el.removeAttribute('data-legend-kind');+ el.removeAttribute('data-legend-label');el.removeAttribute('data-legend-count');el.removeAttribute('data-legend-zero');el.removeAttribute('data-legend-selected');@@ -12488,7 +12497,8 @@}entry.setAttribute('role', 'button');entry.setAttribute('tabindex', legendEntries.length ? '-1' : '0');- entry.setAttribute('aria-label', 'Inspect ' + fact.label + ', ' + count + ' node' + (count === 1 ? '' : 's'));+ var visibleLabel = entry.getAttribute('data-legend-label') || fact.label;+ entry.setAttribute('aria-label', 'Inspect ' + visibleLabel + ', ' + count + ' node' + (count === 1 ? '' : 's'));entry.setAttribute('aria-pressed', 'false');entry.setAttribute('aria-haspopup', 'dialog');entry.setAttribute('aria-controls', 'semantic-lens');