The @mention a generated page will not show the correct Favicon
Categories
(Core :: Machine Learning: Frontend, defect, P3)
Tracking
()
People
(Reporter: rdoghi, Assigned: giulia)
References
(Blocks 1 open bug)
Details
(Whiteboard: [aiaug])
Attachments
(1 file, 1 external file)
|
339.56 KB,
video/mp4
|
Details |
Found in
- Nightly 160.0a1 (2026-10-22)
Affected versions
- Nightly 160.0a1 (2026-10-22)
Affected platforms
- All
Preconditions
Enable Smart Window.
Steps to reproduce
- Reach any website and create a page for it.
- Open a new tab And @mention the generated tab.
Expected result
- The Favicon for that page should be displayed in the Context chip.
Actual result
- The @mention page does not show the correct Favicon.
Regression range
N/A
Updated•1 month ago
|
Comment 1•1 month ago
|
||
| frontend-triage | ||
The inline @ mention path never uses the tab's real icon. It rebuilds the icon from the URL as page-icon:<url>, and for a generated page (about:smartpage?page=…) that lookup always gets the default globe.
-
A generated page's favicon is a static
chrome:SVG in aitab.html. FaviconLoader.sys.mjs only lets Places storedata:icons (before pageshow) for trusted schemes. So the tab getssmart-page-16.svgviagBrowser.setIcon, but Places has nothing stored for theabout:smartpageURL. -
The suggestion row gets the right icon: it comes from
tab.imagein SmartbarMentionsPanelSearch.sys.mjs. Adding the tab through the context "+" button keeps that icon (iconSrc: icon). Typing@instead callsplugin.mentions.insert()in SmartbarInputUtils.mjs, which dropsicon. -
Every later step then rebuilds the icon from the URL:
- the editor chip's
nodeView(SmartbarInputUtils.mjs) usespage-icon:${node.attrs.id} #calculateCurrentMentionsand the tab-group expansion in ai-window.mjs (and line 2237) useUrlbarShared.getIconForUrl()#getIconSrcin ai-chat-message.mjs buildspage-icon:${href}for the sent message
For
about:smartpageall of these resolve to the default favicon. - the editor chip's
Suggested fix: add a URL-based resolver next to isSmartPageURL in TrustedInternalURLs.mjs. It would return chrome://browser/content/aiwindow/assets/smart-page-16.svg for smart-page URLs and getIconForUrl() for everything else. Note that it takes a parsed URL, as in ai-window.mjs around line 1595. Use it at the three places above. A URL-based resolver is needed because the stored mention markdown only carries href, type and color. An icon attr on the mention node would be lost when a conversation is restored or re-rendered. Keep it out of UrlbarShared.getIconForUrl: that has around 17 urlbar callers. Precedent: #resolveTabIconSrc in SmartbarInput.mjs already lets chrome: icons through for the current-tab chip. Both aiWindow.html and aiChatContent.html allow img-src chrome:. Other about: pages with a chrome: favicon (e.g. about:preferences) very likely have the same problem in live chips. Carrying the chrome: tab.image through mentions.insert would cover those too, but that is a separate change.
Test: no existing test checks a tab-mention chip's icon. Add a case to browser_aiwindow_smartbar_inline_mentions.js. It can open about:smartpage?page=<name> with browser.smartwindow.aitab.enabled set, as browser_aitab_page.js does, then @mention it and check the chip's iconSrc.
Suggested severity: S4. The defect is cosmetic: the mention still works and only its chip shows a generic icon instead of the smart-page icon.
If you'd like to provide feedback on this comment, please use the 👍 or 👎 reaction.
If you want to categorize your feedback you can add one of the following tags: ai-triage-{wrong-file, wrong-cause, hallucination, out-of-scope, not-a-bug, wrong-fix, shallow-fix, wrong-severity}.
Needinfo hackbot@mozilla.tld to have a patch generated for this bug, include any questions or directions as needed in your comment.
Comment 2•1 month ago
|
||
The severity field is not set for this bug.
:jlevinsohn, could you have a look please?
For more information, please visit BugBot documentation.
| Assignee | ||
Updated•1 month ago
|
| Assignee | ||
Comment 3•1 month ago
|
||
Updated•1 month ago
|
Comment 5•28 days ago
|
||
| bugherder | ||
Comment 6•28 days ago
|
||
Since nightly and release are affected, beta will likely be affected too.
For more information, please visit BugBot documentation.
Comment 7•28 days ago
|
||
The patch landed in nightly and beta is affected.
:giulia, please make an uplift decision for beta:
- For beta, nominate the patch for beta uplift approval if the fix should be included in this release, or set
status-firefox161towontfixif the fix can wait for the next release.
Uplift requests can be submitted from Lando: D339241.
See Requesting an Uplift for documentation on how to request an uplift.
For more information, please visit BugBot documentation.
| Reporter | ||
Comment 8•28 days ago
|
||
Verified as fixed in our latest Nightly 162.0a1 (2026-11-06)
Updated•28 days ago
|
| Reporter | ||
Comment 9•28 days ago
|
||
Updating the main status flag.
Description
•