Fix IPv6 link-local range check (fe80::/10) and li>button layout conflict#80
Merged
Fix IPv6 link-local range check (fe80::/10) and li>button layout conflict#80
Conversation
Co-authored-by: ormidales <46538211+ormidales@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Migrate changes from branch 1.0.4 to main
Fix IPv6 link-local range check (fe80::/10) and li>button layout conflict
Mar 5, 2026
ormidales
approved these changes
Mar 5, 2026
Contributor
There was a problem hiding this comment.
Pull request overview
This PR fixes two user-facing issues in the browser extension: (1) correctly classifying IPv6 link-local hosts as non-routable so Accept-Language spoofing is not applied, and (2) preventing list-item “remove” buttons in the popup from inheriting full-width sizing that collapses the domain label.
Changes:
- Update IPv6 link-local detection to cover the full
fe80::/10range (fe80–febf) via first-hextet parsing. - Override global
button { width: 100% }styling forli > buttonto avoid flex layout starvation of the domain<span>.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| background.js | Fixes IPv6 link-local range check so non-routable hosts are correctly excluded from header spoofing. |
| popup.css | Ensures in-list buttons size to content (not 100% width), preserving domain text visibility in the popup list. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
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.
Two bugs from the PR review: IPv6 link-local detection only covered
fe80::/16instead of the full/10block, andli > buttoninheritedwidth: 100%from the global button rule, collapsing the domain span into ellipsis.background.js— correct link-local rangestartsWith("fe80:")only matchesfe80::/16; the actual link-local block isfe80::/10(fe80–febf). Replaced with a hextet integer comparison:Addresses were in
fe81–febfbeing incorrectly treated as routable and having Accept-Language spoofing applied.popup.css— isolate remove button sizingli > button { flex-shrink: 0 }combined with the globalbutton { width: 100% }caused the remove button to hold 100% flex-basis and refuse to shrink, starving the domain<span>. Addedwidth: auto; margin: 0to break the inheritance for in-list buttons only.💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.