diff --git a/src/data/lovelace/config/action.ts b/src/data/lovelace/config/action.ts index 800a54dc3f28..6aa0a8ee8831 100644 --- a/src/data/lovelace/config/action.ts +++ b/src/data/lovelace/config/action.ts @@ -28,7 +28,7 @@ export interface UrlActionConfig extends BaseActionConfig { export interface MoreInfoActionConfig extends BaseActionConfig { action: "more-info"; - entity_id?: string; + entity?: string; } export interface AssistActionConfig extends BaseActionConfig { diff --git a/src/panels/lovelace/common/handle-action.ts b/src/panels/lovelace/common/handle-action.ts index 00ab032fdd8d..e7337ab51c97 100644 --- a/src/panels/lovelace/common/handle-action.ts +++ b/src/panels/lovelace/common/handle-action.ts @@ -95,7 +95,7 @@ export const handleAction = async ( switch (actionConfig.action) { case "more-info": { const entityId = - actionConfig.entity_id || + actionConfig.entity || config.entity || config.camera_image || config.image_entity; diff --git a/src/panels/lovelace/editor/structs/action-struct.ts b/src/panels/lovelace/editor/structs/action-struct.ts index 7744a99070dc..b6b7c75a27d4 100644 --- a/src/panels/lovelace/editor/structs/action-struct.ts +++ b/src/panels/lovelace/editor/structs/action-struct.ts @@ -63,7 +63,7 @@ const actionConfigStructAssist = type({ const actionConfigStructMoreInfo = type({ action: literal("more-info"), - entity_id: optional(string()), + entity: optional(string()), }); export const actionConfigStructType = object({