diff --git a/src/panels/lovelace/editor/view-editor/hui-view-editor.ts b/src/panels/lovelace/editor/view-editor/hui-view-editor.ts index e25345e36f..74b017bea6 100644 --- a/src/panels/lovelace/editor/view-editor/hui-view-editor.ts +++ b/src/panels/lovelace/editor/view-editor/hui-view-editor.ts @@ -33,7 +33,7 @@ export class HuiViewEditor extends LitElement { private _suggestedPath = false; private _schema = memoizeOne( - (localize: LocalizeFunc, subview: boolean, showAdvanced: boolean) => + (localize: LocalizeFunc) => [ { name: "title", selector: { text: {} } }, { @@ -69,14 +69,6 @@ export class HuiViewEditor extends LitElement { boolean: {}, }, }, - ...(subview && showAdvanced - ? [ - { - name: "back_path", - selector: { navigation: {} }, - }, - ] - : []), ] as const ); @@ -98,11 +90,7 @@ export class HuiViewEditor extends LitElement { return html``; } - const schema = this._schema( - this.hass.localize, - this._config.subview ?? false, - this.hass.userData?.showAdvanced ?? false - ); + const schema = this._schema(this.hass.localize); const data = { theme: "Backend-selected", @@ -128,9 +116,6 @@ export class HuiViewEditor extends LitElement { if (config.type === "masonry") { delete config.type; } - if (!config.subview) { - delete config.back_path; - } if ( this.isNew && @@ -155,10 +140,6 @@ export class HuiViewEditor extends LitElement { return this.hass.localize("ui.panel.lovelace.editor.edit_view.type"); case "subview": return this.hass.localize("ui.panel.lovelace.editor.edit_view.subview"); - case "back_path": - return this.hass.localize( - "ui.panel.lovelace.editor.edit_view.back_path" - ); default: return this.hass!.localize( `ui.panel.lovelace.editor.card.generic.${schema.name}` @@ -174,10 +155,6 @@ export class HuiViewEditor extends LitElement { return this.hass.localize( "ui.panel.lovelace.editor.edit_view.subview_helper" ); - case "back_path": - return this.hass.localize( - "ui.panel.lovelace.editor.edit_view.back_path_helper" - ); default: return undefined; } diff --git a/src/translations/en.json b/src/translations/en.json index 186604a1b6..b4426b719e 100755 --- a/src/translations/en.json +++ b/src/translations/en.json @@ -3805,8 +3805,6 @@ }, "subview": "Subview", "subview_helper": "Subviews don't appear in tabs and have a back button.", - "back_path": "Back path (optional)", - "back_path_helper": "Only for subviews. If empty, clicking on back button will go to the previous page.", "edit_ui": "Edit in visual editor", "edit_yaml": "Edit in YAML" },