我试图改变kendo-splitter-pane的背景颜色。但是,即使我向其添加样式标记,它似乎也不适用于其内部元素。
那么为kendo-splitter-pane定制颜色的适当方法是什么?
你需要在background-color
元素上应用kendo-splitter-pane
,如下所示:
@Component({
selector: 'my-app',
template: `
<kendo-splitter style="height: 200px;">
<kendo-splitter-pane class="pane1">
<h3>Left pane</h3>
</kendo-splitter-pane>
<kendo-splitter-pane>
<h3>Center pane</h3>
</kendo-splitter-pane>
<kendo-splitter-pane [resizable]="false">
<h3>Right pane</h3>
</kendo-splitter-pane>
</kendo-splitter>
`,
styles: [ `
h3 {
font-size: 1.2em;
padding: 10px;
}
.pane1 {
background-color: red;
}
` ]
})
class AppComponent {}