You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Blank default icons (or blurry ones) instead of the correct icons are annoying in Firefox. Especially if those webpage are some of the main ones you use with this extension. So I've looked into a code and I have an idea how to fix this problem with favicons provided as base64 images.
In newtab.html we add options_favicon_json as one of the advanced options:
in newtab.js we are appending favicon_json option in var config dict:
number_recent: 10,icon_provider: 1,favicon_json: "{}"// <--- Right here};
in newtab.js we are modifying function getIcon(node) function to search for icons in dictionary first. If there is no defined domain, then extension is searching icon in selected provider:
and after this, users can assign icon as base64 image based on domain:
The only missing part is favicon_json validation to avoid the error in JSON.parse step.
Also, I think my code could be better optimized because for the first time in my life I looked at JavaScript code and it was just a quick test.
I hope this suggestion was helpful and I could add a verification step for JSON.parse step if you would like to implement it.
Btw, I love your extension and have been using it for many years ❤️
The text was updated successfully, but these errors were encountered:
I love the extension Isaiah Billingsley has made as well and I've been waiting this feature for a long time but i don't have the knowledge to help like you did...
Blank default icons (or blurry ones) instead of the correct icons are annoying in Firefox. Especially if those webpage are some of the main ones you use with this extension. So I've looked into a code and I have an idea how to fix this problem with favicons provided as base64 images.
newtab.html
we addoptions_favicon_json
as one of the advanced options:newtab.js
we are appendingfavicon_json
option invar config
dict:newtab.js
we are modifyingfunction getIcon(node)
function to search for icons in dictionary first. If there is no defined domain, then extension is searching icon in selected provider:and after this, users can assign icon as base64 image based on domain:
The only missing part is
favicon_json
validation to avoid the error inJSON.parse
step.Also, I think my code could be better optimized because for the first time in my life I looked at JavaScript code and it was just a quick test.
I hope this suggestion was helpful and I could add a verification step for
JSON.parse
step if you would like to implement it.Btw, I love your extension and have been using it for many years ❤️
The text was updated successfully, but these errors were encountered: