AITab - find in-mozilla hosting for font artifacts using gcs
Categories
(Core :: Machine Learning: Frontend, task, P1)
Tracking
()
People
(Reporter: mlucks, Assigned: rrando)
References
(Blocks 1 open bug)
Details
(Whiteboard: [aiaug])
As we have been playing around with using a custom font for AITab, there have been security and caching concerns brought up using a google font. We are exploring the possibility of hosting font artifacts via google cloud storage instead of pulling the font in remotely via google fonts.
Please do not forget uncomment or clean up the TODO and font assignment t in aitab-base.css
Note: mochitest treats any off-localhost connection as fatal, so loading fonts.googleapis.com aborts every test that opens about:aitab. Resolving both hosts to localhost avoids that, and the font simply doesn't load under test, which nothing depends on.
Make sure to add in browser/components/aiwindow/ui/test/browser/browser.toml, inside prefs:
"network.dns.localDomains=fonts.googleapis.com,fonts.gstatic.com"
Updated•2 months ago
|
Please also circle back to the storybook implementation in preview-head.html lines 14-20, there is a TODO comment if you search the bug id
Note: mochitest treats any off-localhost connection as fatal, so loading fonts.googleapis.com aborts every test that opens about:aitab. Resolving both hosts to localhost avoids that, and the font simply doesn't load under test, which nothing depends on.
Make sure to add in browser/components/aiwindow/ui/test/browser/browser.toml, inside prefs:
"network.dns.localDomains=fonts.googleapis.com,fonts.gstatic.com"
Comment 3•2 months ago
|
||
in creating a remote settings attachment such as for a font or image, a record is created along with the attachment content made available on the cdn, so we should be able to use the latter without calling any remote settings attachment apis (which would fetch the record then resolves the indirection to cdn)
https://searchfox.org/firefox-main/search?q=settings-attachments.cdn
we would need to update the font-src csp to allow https://firefox-settings-attachments.cdn.mozilla.net
Comment 4•1 month ago
|
||
Implementation happening on bug 2078662
Description
•