SUMMARY:
Fixed "SVG diagram not found in contentDocument" error by adding
fallback to use documentElement when getElementById doesn't find SVG.
ISSUE:
When SVG is loaded via <object> tag, sometimes getElementById() doesn't
find the SVG element even though it exists in contentDocument.
FIX:
Added fallback logic:
1. Try svgDoc.getElementById('interactive-arch-diagram')
2. If not found, try svgDoc.documentElement (the root SVG element)
3. Verify element is actually an SVG before proceeding
This ensures the interactive diagram works regardless of how the browser
parses the SVG document structure.
🤖 Generated with Claude Code (https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
|
||
|---|---|---|
| .. | ||
| code-copy-button.js | ||
| coming-soon-overlay.js | ||
| currency-selector.js | ||
| document-cards.js | ||
| document-viewer.js | ||
| footer.js | ||
| interactive-diagram.js | ||
| language-selector.js | ||
| navbar.js | ||
| toc.js | ||