{"record":{"id":"d1967b1b8996ba8b","repo":"affaan-m/ECC","slug":"mermaid-render-skipped","errorCode":null,"errorMessage":"Mermaid render skipped:","messagePattern":"Mermaid render skipped:","errorType":"console","errorClass":null,"httpStatus":null,"severity":"error","filePath":"scripts/lib/plan-canvas/ui.js","lineNumber":47,"sourceCode":"function mermaidLoaderScript(url) {\n  return `<script type=\"module\">\n  try {\n    const mermaid = (await import(${JSON.stringify(url)})).default;\n    mermaid.initialize({\n      startOnLoad: false,\n      securityLevel: 'strict',\n      theme: 'dark',\n      fontFamily: \"-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif\",\n      themeVariables: {\n        primaryColor: '#13161e', primaryBorderColor: '#6885e8', primaryTextColor: '#dfe2e9',\n        lineColor: '#80859a', secondaryColor: '#191d2a', tertiaryColor: '#101218',\n        background: '#080a0e', mainBkg: '#13161e', clusterBkg: '#0d0f14'\n      }\n    });\n    await mermaid.run({ querySelector: '.mermaid' });\n  } catch (err) {\n    document.querySelectorAll('.mermaid').forEach(el => el.classList.add('mermaid-unrendered'));\n    console.warn('Mermaid render skipped:', err && err.message);\n  }\n</script>`;\n}\n\n// Design tokens shared by the chrome and the markdown artifact template.\nconst TOKENS_CSS = `\n  :root{\n    --bg:#080a0e; --bg2:#0d0f14; --bg3:#13161e; --bg4:#191d2a;\n    --surface:#101218; --surface-hover:#171a24; --border:#1d2130; --border-light:#272c3e;\n    --text:#dfe2e9; --text2:#80859a; --text3:#4c5168;\n    --accent:#6885e8; --accent-glow:rgba(104,133,232,0.15); --accent-dim:#3d5ab8;\n    --green:#4acb8a; --green-glow:rgba(74,203,138,0.15);\n    --orange:#eca85a; --orange-glow:rgba(236,168,90,0.15);\n    --pink:#e26a9e; --pink-glow:rgba(226,106,158,0.15);\n    --red:#e86060; --red-glow:rgba(232,96,96,0.15);\n    --teal:#4acbbe; --teal-glow:rgba(74,203,190,0.15);\n    --radius:8px; --radius-sm:5px;\n    --font:-apple-system,BlinkMacSystemFont,'SF Pro Display','Inter','Segoe UI',Roboto,sans-serif;","sourceCodeStart":29,"sourceCodeEnd":65,"githubUrl":"https://github.com/affaan-m/ECC/blob/06c5e118c4d3e6c3b7f9445f973a2194c82de193/scripts/lib/plan-canvas/ui.js#L29-L65","documentation":"In the plan-canvas UI's injected Mermaid loader script, diagram rendering was deliberately skipped — the dynamic import of the Mermaid module or the render call failed (offline, blocked CDN, bad syntax). The page still renders; only the Mermaid diagram is omitted.","triggerScenarios":"Thrown at scripts/lib/plan-canvas/ui.js:47 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Check the Mermaid diagram syntax in the plan for parse errors.","Ensure the Mermaid renderer dependency loaded; check console for the underlying exception."],"exampleFix":null,"handlingStrategy":"fallback","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"06c5e118c4d3e6c3b7f9445f973a2194c82de193","analyzedAt":"2026-08-18T11:27:13.915Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}