core: make user settings use vertical tabs

This commit is contained in:
Jens Langhammer
2021-03-03 09:28:12 +01:00
parent 3cb0575a1e
commit 28cd08bbba
3 changed files with 11 additions and 3 deletions

View File

@ -12,10 +12,17 @@ export class Tabs extends LitElement {
@property()
currentPage?: string;
@property({type: Boolean})
vertical = false;
static get styles(): CSSResult[] {
return [GlobalsStyle, TabsStyle, css`
::slotted(*) {
height: 100%;
flex-grow: 2;
}
:host([vertical]) {
display: flex;
}
`];
}
@ -39,7 +46,7 @@ export class Tabs extends LitElement {
}
this.currentPage = pages[0].attributes.getNamedItem("slot")?.value;
}
return html`<div class="pf-c-tabs">
return html`<div class="pf-c-tabs ${this.vertical ? "pf-m-vertical pf-m-box" : ""}">
<ul class="pf-c-tabs__list">
${pages.map((page) => this.renderTab(page))}
</ul>