我创建了一个FormPanel
,其中TabPanel
包含多个标签。选项卡的背景颜色是默认的白色,但我希望它们都具有Panel
中通常存在的主题(默认蓝色)颜色。
我尝试过添加
bodyStyle:'background-color:transparent!important'
到表单,tabpanel和标签,它可以在IE9和Chrome中运行,但在FireFox中却不行?
如何在FireFox中丢弃transparent
作为伪色值?
的的JavaScript :
var form = new Ext.form.FormPanel({
border: false,
bodyStyle: 'background-color: transparent !important',
layout: 'fit',
items: [
{
xtype: 'tabpanel',
activeTab: 0,
bodyStyle: 'background-color: transparent !important',
deferredRender: false,
defaults: {
bodyStyle: 'padding: 4px; background-color: transparent !important',
layout: 'form',
autoScroll: true
},
items: [
{
title: 'Tab 1',
items: [
...
]
}, {
title: 'Tab 2',
items: [
...
]
}]
}]
});
答案 0 :(得分:3)
为什么不使用background:none
?
bodyStyle: 'background: none'
查看演示:http://jsfiddle.net/chaoszcat/ug7Qg/。
顺便说一下,看起来FormPanel
没有蓝色背景。其背景默认为白色。