mirror of
https://github.com/home-assistant/frontend.git
synced 2025-07-24 17:56:46 +00:00
Add dashboard title to strategy editor (#26015)
This commit is contained in:
parent
93837f01f7
commit
96bbfe8a93
@ -144,6 +144,9 @@ class DialogDashboardStrategyEditor extends LitElement {
|
|||||||
.path=${mdiClose}
|
.path=${mdiClose}
|
||||||
></ha-icon-button>
|
></ha-icon-button>
|
||||||
<span slot="title" .title=${title}>${title}</span>
|
<span slot="title" .title=${title}>${title}</span>
|
||||||
|
${this._params.title
|
||||||
|
? html`<span slot="subtitle">${this._params.title}</span>`
|
||||||
|
: nothing}
|
||||||
<ha-button-menu
|
<ha-button-menu
|
||||||
corner="BOTTOM_END"
|
corner="BOTTOM_END"
|
||||||
menu-corner="END"
|
menu-corner="END"
|
||||||
|
@ -3,6 +3,7 @@ import type { LovelaceDashboardStrategyConfig } from "../../../../../data/lovela
|
|||||||
|
|
||||||
export interface DashboardStrategyEditorDialogParams {
|
export interface DashboardStrategyEditorDialogParams {
|
||||||
config: LovelaceDashboardStrategyConfig;
|
config: LovelaceDashboardStrategyConfig;
|
||||||
|
title?: string;
|
||||||
saveConfig: (config: LovelaceDashboardStrategyConfig) => void;
|
saveConfig: (config: LovelaceDashboardStrategyConfig) => void;
|
||||||
takeControl: () => void;
|
takeControl: () => void;
|
||||||
deleteDashboard: () => Promise<boolean>;
|
deleteDashboard: () => Promise<boolean>;
|
||||||
|
@ -782,6 +782,7 @@ class HUIRoot extends LitElement {
|
|||||||
|
|
||||||
showDashboardStrategyEditorDialog(this, {
|
showDashboardStrategyEditorDialog(this, {
|
||||||
config: this.lovelace!.rawConfig,
|
config: this.lovelace!.rawConfig,
|
||||||
|
title: this.panel ? getPanelTitle(this.hass, this.panel) : undefined,
|
||||||
saveConfig: this.lovelace!.saveConfig,
|
saveConfig: this.lovelace!.saveConfig,
|
||||||
takeControl: () => {
|
takeControl: () => {
|
||||||
showSaveDialog(this, {
|
showSaveDialog(this, {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user