这里的是我做过什么:
创建一个新的应用程序使用下面的命令
sencha -sdk <path to ext 6.0.2> generate app -ext MyApp MyTestApp
cd MyTestApp
sencha generate theme --extend theme-classic my-classic-theme2
在packages/local/my-classic-theme2/sass/src
的内部创建了文件夹panel
,并在该文件夹内创建了一个文件Panel.scss
。
编辑该文件并粘贴您的代码是:
@include extjs-panel-ui(
$ui: 'highlight-framed',
$ui-header-background-color: red,
$ui-border-color: red,
$ui-header-border-color: red,
$ui-body-border-color: red,
$ui-border-width: 5px,
$ui-border-radius: 5px,
$ui-header-color: white
);
编辑的classic/src/view/main/Main.js
文件,并替换的项目与此块:
items: [{
title: 'Home',
iconCls: 'fa-home',
// The following grid shares a store with the classic version's grid as well!
items: [{
xtype: 'mainlist'
}]
}, {
title: 'Users',
iconCls: 'fa-user',
items : [{
xtype: 'panel',
frame: true,
ui: 'highlight',
title: 'Testing my highlight panel',
items: [{
xtype: 'textfield',
fieldLabel: 'Foo',
value: 'Bar'
}]
}]
}]
最后编辑app.json
并确保我"theme"
是指向my-classic-theme2
然sencha app watch
并去了http://localhost:1841
我的用户选项卡以红色标题显示面板。
肯定做了些什么......面板标题变小了,但一切仍然是默认的蓝色。即使我说红色。有原因吗? (我把上面的mixin) – solarissf