From 3ba572ee3712e8ca1f27089e2040fe6578af7afd Mon Sep 17 00:00:00 2001 From: karwosts <32912880+karwosts@users.noreply.github.com> Date: Mon, 5 Aug 2024 08:07:03 -0700 Subject: [PATCH] Fix pointer cursor issues (#21587) * Fix pointer cursor issues * one more --- src/panels/lovelace/cards/hui-gauge-card.ts | 14 +++++--------- src/panels/lovelace/cards/hui-glance-card.ts | 10 ++-------- src/panels/lovelace/common/has-action.ts | 10 ++++++++++ .../lovelace/components/hui-generic-entity-row.ts | 12 +++++++----- .../lovelace/entity-rows/hui-number-entity-row.ts | 1 - .../lovelace/entity-rows/hui-scene-entity-row.ts | 3 --- .../lovelace/entity-rows/hui-simple-entity-row.ts | 3 --- .../lovelace/entity-rows/hui-update-entity-row.ts | 3 --- .../lovelace/entity-rows/hui-weather-entity-row.ts | 12 +++++++----- 9 files changed, 31 insertions(+), 37 deletions(-) diff --git a/src/panels/lovelace/cards/hui-gauge-card.ts b/src/panels/lovelace/cards/hui-gauge-card.ts index d4e0c2aacc..4370516653 100644 --- a/src/panels/lovelace/cards/hui-gauge-card.ts +++ b/src/panels/lovelace/cards/hui-gauge-card.ts @@ -23,7 +23,7 @@ import type { HomeAssistant } from "../../../types"; import { actionHandler } from "../common/directives/action-handler-directive"; import { findEntities } from "../common/find-entities"; import { handleAction } from "../common/handle-action"; -import { hasAction } from "../common/has-action"; +import { hasAction, hasAnyAction } from "../common/has-action"; import { hasConfigOrEntityChanged } from "../common/has-changed"; import { createEntityNotFoundWarning } from "../components/hui-warning"; import type { LovelaceCard, LovelaceCardEditor } from "../types"; @@ -128,24 +128,20 @@ class HuiGaugeCard extends LitElement implements LovelaceCard { const name = this._config.name ?? computeStateName(stateObj); - const hasAnyAction = - !this._config.tap_action || - hasAction(this._config.tap_action) || - hasAction(this._config.hold_action) || - hasAction(this._config.double_tap_action); - // Use `stateObj.state` as value to keep formatting (e.g trailing zeros) // for consistent value display across gauge, entity, entity-row, etc. return html` ${!this.hideName ? html`
${weatherStateIcon || html`