autotag and spamfilter context menu icons added
This commit is contained in:
parent
edf2de4c34
commit
f77d1dabe5
5 changed files with 10 additions and 1 deletions
|
|
@ -102,6 +102,8 @@ _The language status represents the percentage of translated strings in the late
|
||||||
- <a href="https://loading.io">loading.io</a> for the loading SVGs
|
- <a href="https://loading.io">loading.io</a> for the loading SVGs
|
||||||
- [Fluent Design System](https://www.iconfinder.com/fluent-designsystem) for the Custom Prompts table sorting icons
|
- [Fluent Design System](https://www.iconfinder.com/fluent-designsystem) for the Custom Prompts table sorting icons
|
||||||
- [JessiGue](https://www.flaticon.com/authors/jessigue) for the show/hide icon for api key fields
|
- [JessiGue](https://www.flaticon.com/authors/jessigue) for the show/hide icon for api key fields
|
||||||
|
- [Iconka.com](https://www.iconarchive.com/artist/iconka.html) for the autotag context menu icon
|
||||||
|
- [Icojam](https://www.iconarchive.com/artist/icojam.html) for the spam filter context menu icon
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
|
|
|
||||||
BIN
images/autotags.png
Normal file
BIN
images/autotags.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.9 KiB |
BIN
images/spamfilter.png
Normal file
BIN
images/spamfilter.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.7 KiB |
|
|
@ -25,6 +25,10 @@ export const getMenuContextDisplay = () => 'message_display_action_menu';
|
||||||
|
|
||||||
export const contextMenuID_AddTags = 'mzta-add-tags';
|
export const contextMenuID_AddTags = 'mzta-add-tags';
|
||||||
export const contextMenuID_Spamfilter = 'mzta-spamfilter';
|
export const contextMenuID_Spamfilter = 'mzta-spamfilter';
|
||||||
|
export const contextMenuIconsPath = {
|
||||||
|
[contextMenuID_AddTags]: 'moz-extension:images/autotags.png',
|
||||||
|
[contextMenuID_Spamfilter]: 'moz-extension:images/spamfilter.png',
|
||||||
|
};
|
||||||
|
|
||||||
export function getLanguageDisplayName(languageCode) {
|
export function getLanguageDisplayName(languageCode) {
|
||||||
const languageDisplay = new Intl.DisplayNames([languageCode], {type: 'language'});
|
const languageDisplay = new Intl.DisplayNames([languageCode], {type: 'language'});
|
||||||
|
|
|
||||||
|
|
@ -41,6 +41,7 @@ import {
|
||||||
extractJsonObject,
|
extractJsonObject,
|
||||||
contextMenuID_AddTags,
|
contextMenuID_AddTags,
|
||||||
contextMenuID_Spamfilter,
|
contextMenuID_Spamfilter,
|
||||||
|
contextMenuIconsPath,
|
||||||
sanitizeChatGPTModelData,
|
sanitizeChatGPTModelData,
|
||||||
sanitizeChatGPTWebCustomData,
|
sanitizeChatGPTWebCustomData,
|
||||||
stripHtmlKeepLines,
|
stripHtmlKeepLines,
|
||||||
|
|
@ -946,9 +947,11 @@ function addContextMenu(menu_id) {
|
||||||
browser.menus.create({
|
browser.menus.create({
|
||||||
id: menu_id,
|
id: menu_id,
|
||||||
title: browser.i18n.getMessage("context_menu_" + menu_id),
|
title: browser.i18n.getMessage("context_menu_" + menu_id),
|
||||||
contexts: ["message_list"]
|
contexts: ["message_list"],
|
||||||
|
icons: contextMenuIconsPath[menu_id],
|
||||||
});
|
});
|
||||||
taLog.log("Context menu added: " + menu_id);
|
taLog.log("Context menu added: " + menu_id);
|
||||||
|
console.log(">>>>>>> contextMenuIconsPath[menu_id]: " + contextMenuIconsPath[menu_id]);
|
||||||
}
|
}
|
||||||
|
|
||||||
function removeContextMenu(menu_id) {
|
function removeContextMenu(menu_id) {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue