mirror of
https://github.com/home-assistant/frontend.git
synced 2025-08-02 05:57:54 +00:00
Edit Options: Overflow Menu Fix (#5433)
* Adds no wrap and removes top and bottom padding * Small updates for clean up
This commit is contained in:
parent
82d6909957
commit
006d989943
@ -36,7 +36,7 @@ export class HuiCardOptions extends LitElement {
|
|||||||
<ha-card>
|
<ha-card>
|
||||||
<div class="options">
|
<div class="options">
|
||||||
<div class="primary-actions">
|
<div class="primary-actions">
|
||||||
<mwc-button @click="${this._editCard}"
|
<mwc-button @click=${this._editCard}
|
||||||
>${this.hass!.localize(
|
>${this.hass!.localize(
|
||||||
"ui.panel.lovelace.editor.edit_card.edit"
|
"ui.panel.lovelace.editor.edit_card.edit"
|
||||||
)}</mwc-button
|
)}</mwc-button
|
||||||
@ -47,17 +47,17 @@ export class HuiCardOptions extends LitElement {
|
|||||||
title="Move card down"
|
title="Move card down"
|
||||||
class="move-arrow"
|
class="move-arrow"
|
||||||
icon="hass:arrow-down"
|
icon="hass:arrow-down"
|
||||||
@click="${this._cardDown}"
|
@click=${this._cardDown}
|
||||||
?disabled="${this.lovelace!.config.views[this.path![0]].cards!
|
?disabled=${this.lovelace!.config.views[this.path![0]].cards!
|
||||||
.length ===
|
.length ===
|
||||||
this.path![1] + 1}"
|
this.path![1] + 1}
|
||||||
></paper-icon-button>
|
></paper-icon-button>
|
||||||
<paper-icon-button
|
<paper-icon-button
|
||||||
title="Move card up"
|
title="Move card up"
|
||||||
class="move-arrow"
|
class="move-arrow"
|
||||||
icon="hass:arrow-up"
|
icon="hass:arrow-up"
|
||||||
@click="${this._cardUp}"
|
@click=${this._cardUp}
|
||||||
?disabled="${this.path![1] === 0}"
|
?disabled=${this.path![1] === 0}
|
||||||
></paper-icon-button>
|
></paper-icon-button>
|
||||||
<paper-menu-button
|
<paper-menu-button
|
||||||
horizontal-align="right"
|
horizontal-align="right"
|
||||||
@ -73,7 +73,7 @@ export class HuiCardOptions extends LitElement {
|
|||||||
)}
|
)}
|
||||||
></paper-icon-button>
|
></paper-icon-button>
|
||||||
<paper-listbox slot="dropdown-content">
|
<paper-listbox slot="dropdown-content">
|
||||||
<paper-item @tap="${this._moveCard}">
|
<paper-item @tap=${this._moveCard}>
|
||||||
${this.hass!.localize(
|
${this.hass!.localize(
|
||||||
"ui.panel.lovelace.editor.edit_card.move"
|
"ui.panel.lovelace.editor.edit_card.move"
|
||||||
)}</paper-item
|
)}</paper-item
|
||||||
@ -83,7 +83,7 @@ export class HuiCardOptions extends LitElement {
|
|||||||
"ui.panel.lovelace.editor.edit_card.duplicate"
|
"ui.panel.lovelace.editor.edit_card.duplicate"
|
||||||
)}</paper-item
|
)}</paper-item
|
||||||
>
|
>
|
||||||
<paper-item .class="delete-item" @tap="${this._deleteCard}">
|
<paper-item class="delete-item" @tap=${this._deleteCard}>
|
||||||
${this.hass!.localize(
|
${this.hass!.localize(
|
||||||
"ui.panel.lovelace.editor.edit_card.delete"
|
"ui.panel.lovelace.editor.edit_card.delete"
|
||||||
)}</paper-item
|
)}</paper-item
|
||||||
@ -141,6 +141,10 @@ export class HuiCardOptions extends LitElement {
|
|||||||
padding: 0;
|
padding: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
paper-listbox {
|
||||||
|
padding: 0;
|
||||||
|
}
|
||||||
|
|
||||||
paper-item.header {
|
paper-item.header {
|
||||||
color: var(--primary-text-color);
|
color: var(--primary-text-color);
|
||||||
text-transform: uppercase;
|
text-transform: uppercase;
|
||||||
@ -150,6 +154,7 @@ export class HuiCardOptions extends LitElement {
|
|||||||
|
|
||||||
paper-item {
|
paper-item {
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
|
white-space: nowrap;
|
||||||
}
|
}
|
||||||
|
|
||||||
paper-item.delete-item {
|
paper-item.delete-item {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user