本文介绍了Chrome扩展程序图标清单的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
如何在此页面中更改Chrome扩展程序图标?
How to change Chrome Extension icon in this page?
这是我的清单代码:
{
"manifest_version": 2,
"name": "Demo",
"description": "This is demo.",
"version": "1.0",
"browser_action": {
"default_icon": "icon128.png",
"icons": {
"16": "icon16.png",
"48": "icon48.png",
"128": "icon128.png"
},
"default_popup": "popup.html"
},
"permissions": [
"activeTab",
"storage"
]
}
工具栏上的图标已更改,但chrome://extension
页面上未更改.
The icon on toolbar is changed, but not on the chrome://extension
page.
推荐答案
在manifest.json
中设置"icons"
键.
browser_action.icons
键是工具栏中显示的键(可能仅使用16、24和32尺寸的图像,请参见浏览器操作).
Set "icons"
key in manifest.json
.
The browser_action.icons
key is what gets displayed in the toolbar (and will probably only use 16, 24, and 32 sized images, see browserAction).
chrome://extensions
中显示的一个是顶级icons
键.在清单文档中,查找第6个条目,以便清单具有顶层条目,例如:
The one displayed in chrome://extensions
is a top level icons
key. In the manifest documentation, look for the 6th entry, so that your manifest has an top-level entry, like:
{
"icons": {
"16": "icon16.png",
"48": "icon48.png",
"128": "icon128.png"
}
}
这篇关于Chrome扩展程序图标清单的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!