fix(sc-45073): don't render active connection filter as a self-link#3443
Open
dcschreiber wants to merge 4 commits into
Open
fix(sc-45073): don't render active connection filter as a self-link#3443dcschreiber wants to merge 4 commits into
dcschreiber wants to merge 4 commits into
Conversation
The connections-panel header shows a strip of recent filters (TextFilter chips). The active chip's href is the current page (/<ref>?with=<book>), so right-clicking the secondary text's title and choosing "Open Link in New Tab" just duplicated the current two-panel view instead of doing anything useful. Render the active recent filter as a plain (non-link) element so right-click shows the normal page menu. The other chips stay links — opening a different connection in a new tab is legitimate.
📊 Code Quality Score: 1/100
Was this score accurate? 👍 Yes · 👎 No Scored by GitVelocity · How are scores calculated? |
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adjusts the connections panel UI so the active “recent” text filter title is no longer rendered as an anchor, preventing the browser’s “Open Link in New Tab” behavior from duplicating the current two-panel view.
Changes:
- Add logic to render the active recent
TextFilteras non-clickable content instead of an<a>tag. - Refactor the
TextFilterrender output to reuse a sharedinnerelement for both linked and non-linked cases.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+140
to
+142
| return renderAsTitle ? | ||
| <span className="textFilterTitle">{inner}</span> : | ||
| <a href={url} onClick={this.handleClick}>{inner}</a>; |
Contributor
Author
There was a problem hiding this comment.
Good catch — switched the wrapper to a < div > so it's valid HTML.
saengel
requested changes
Jun 25, 2026
saengel
left a comment
Contributor
There was a problem hiding this comment.
See the feedback from Copilot, otherwise looks good.
…ary-text-title-link
A <span> cannot legally contain the block-level <div> in `inner`; browsers reparent it, which can shift layout. Address Copilot/saengel review feedback by using a <div> wrapper. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
stevekaplan123
approved these changes
Jul 8, 2026
saengel
approved these changes
Jul 8, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes sc-45073. Right-clicking the secondary text's title in the connections panel and choosing "Open Link in New Tab" duplicated the current two-panel page.
The title was being rendered as an 'a' tag.
The title (
TextFilter) had anhrefset as the current page (/<ref>?with=<book>), so the new tab just reopened it.Fix: render the title as a non-link (it doesn't function as a link), so right-click shows the normal page menu.