我开发了一个Chrome扩展程序,其格式为位于用户窗口顶部的水平条。这件事情,“像”是:Chrome扩展程序无法占用整个窗口宽度
但它是如何看起来就像当我把它添加到Chrome浏览器作为一个扩展(见右上角的图标):
这里有什么问题?
这里的清单:
{
"manifest_version": 2,
"name": "CLAWS",
"description": "testing",
"version": "1.0",
"permissions": [
"tabs",
"https://google.com.br/"
],
"browser_action": {
"default_icon": "icone_app.png",
"default_popup": "HTML.html"
}
}
编辑:HTML代码:
<!DOCTYPE html>
<html>
<head>
<link href='CSS.css' rel='stylesheet' type='text/css'>
</head>
<body>
<div id="barra"></div>
</body>
</html>
和CSS.css:
#barra{
background-color:red;
width:100%;
height:80px;
}
请发表HTML.html。它创建了自己的窗口,窗口大小与主窗口分开。特别是没有什么特别的宽度,所以我的猜测是默认为最小宽度。 – Teepeemm
对不起,你有什么意思“有一个特定的宽度”?这是关于扩展窗口?代码现在在帖子中。 –