Skip to content

Fix nested chiren links in a tags#91

Open
Maimunar wants to merge 1 commit into
mainfrom
bug/nested-svg
Open

Fix nested chiren links in a tags#91
Maimunar wants to merge 1 commit into
mainfrom
bug/nested-svg

Conversation

@Maimunar

@Maimunar Maimunar commented Jul 3, 2026

Copy link
Copy Markdown

Summary

Closes #90

Fixes auto-events not firing when a link (<a>) wraps nested elements such as an inline SVG. The delegated click handler previously read event.target, which resolves to the innermost clicked element (e.g. the <svg>/<path>) rather than the anchor, so saAutomatedLink received an element without link properties (href, pathname, hostname) and no event was collected. The handler now passes this, the anchor the listener is bound to, matching the inline onclick path that already uses this.

Changes:

  • fix nested svg bug

Security implications

No security impact

Testing

Manual testing by the author. Claude review: no automated validation run; change is a one-line, isolated correctness fix in src/auto-events.js.

Checklist

  • Linked to an issue
  • Tested
  • Asked for a review

@Maimunar Maimunar requested a review from adriaandotcom July 3, 2026 12:21
@claude claude Bot added the change: needs review Changes affecting security, data protection, or system stability. label Jul 3, 2026
@github-actions

github-actions Bot commented Jul 3, 2026

Copy link
Copy Markdown
Claude review checkpoint

Reviewed commit 766efc011e8881ccc2283903a28b9a97fb02851e. This is used to keep later automated reviews focused on changes Claude has not checked yet.

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

Labels

change: needs review Changes affecting security, data protection, or system stability.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Fix nested chiren links in a tags

1 participant