Skip to content

fix(axonometric): read complete label text including SVG tspans - #331

Open
rudycelekli wants to merge 1 commit into
cathrynlavery:mainfrom
rudycelekli:fix/axonometric-label-text-20261006
Open

rudycelekli wants to merge 1 commit into
cathrynlavery:mainfrom
rudycelekli:fix/axonometric-label-text-20261006

Conversation

@rudycelekli

Copy link
Copy Markdown

What does this PR do?

Read descendant text inside SVG text labels when matching exploded-view and axonometric-plan labels to declared parts. Accumulation is limited to label text ancestors, preserving direct element text without duplicating it on groups or the document.

AI assistance was used for implementation and validation; I reviewed the change and native evidence.

Visual proof

Not applicable: no diagram, example, or template changes. Pinned Chromium renders the styled/nested-tspan variants pixel-identically to the shipped examples. Both public verifiers rejected those labels before the correction; geometry and invalid-label controls remain enforced.

Validation gates

  • python3 scripts/test-lint-a11y.py
  • python3 scripts/lint-skin.py --all --baseline
  • python3 scripts/verify-sequence-oauth.py
  • python3 scripts/verify-drawio-import.py
  • python3 scripts/verify-mermaid-import.py
  • git diff --exit-code green after python3 scripts/build-icons.py (generated icons unchanged)
  • Docs updated in the same PR where behavior changed

The initial complete 77-command suite passed 76 commands; render gate 17 reported clipping on unchanged animated assets. The independently reproduced JavaScript playback/capture race is tracked in #312. One actual locked, unchanged-head native rerun of gate 17 passed (209 rendered files, zero findings). Thus all 77 required commands have passed across the original and retry receipts; the initial failure is preserved and no threshold, source, or test exception was used. at signed head 0cc43997f157043e54ed705c6caf6d4b90754636. Native proof uses pinned Playwright 1.62.0 and bundled Chromium 151.0.7922.34 with external network blocked. Hosted CI is pending.

Checklist

  • No new entries added to scripts/lint-skin-baseline.txt
  • Generated and source files are consistent (extractor ↔ verifier ↔ reference ↔ command)
  • Accessible SVG contract satisfied for new/changed examples (none changed)
  • Rendered screenshots are attached for every new/changed diagram variant, or visual proof is marked not applicable
  • Code of Conduct respected

Related issues

Closes #297.

Fixes cathrynlavery#297. AI assistance was used for investigation, implementation, and tests.

Signed-off-by: Rudy Celekli <rudy@gradiahq.com>
@greptile-apps

greptile-apps Bot commented Oct 6, 2026 •

Copy link
Copy Markdown

RetriggerConfidence Score: 5/5

[Medium risk] Fixes label text parsing to handle SVG inline styling.

The PR appears safe to merge.

What we checked:

  • Labels count text twice: ancestors() starts at the parent, excluding the current element. The added loop writes only to <text> ancestors, not groups or the document.

Summary

The shared SVG reader now includes descendant text when reading labels. Both geometry verifiers can match labels containing inline <tspan> elements to their declared names.

  • Adds styled and nested-span tests for exploded views and axonometric plans.
  • Updates the README and both references to describe complete-label matching.
  • No actionable issues found. Review used code inspection; no tests were run.

Reviews (1) · Last reviewed commit: "fix(axonometric): preserve descendant la..."

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Exploded and plan verifiers lose labels wrapped in valid SVG tspans

1 participant