Skip to content

Commit

Permalink
Merge pull request #1443 from warmfire540/main
Browse files Browse the repository at this point in the history
fix tap_action in speedtest custom card
  • Loading branch information
basbruss authored Jul 3, 2024
2 parents e47e972 + 7091c57 commit a3cf8d0
Showing 1 changed file with 7 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,9 @@ custom_card_irmajavi_speedtest:
show_name: true
show_icon: true
label: >-
[[[ return variables.ulm_custom_card_irmajavi_speedtest_router_model
]]]
[[[ return variables.ulm_custom_card_irmajavi_speedtest_router_model ]]]
name: >-
[[[ return variables.ulm_custom_card_irmajavi_speedtest_router_name
]]]
[[[ return variables.ulm_custom_card_irmajavi_speedtest_router_name ]]]
icon: "mdi:wifi"
styles:
icon:
Expand Down Expand Up @@ -146,15 +144,13 @@ custom_card_irmajavi_speedtest:
item1:
card:
type: "custom:button-card"
tap_action:
action: "more-info"
color: "var(--google-blue)"
show_label: true
show_icon: false
name: "[[[ return variables.ulm_custom_card_irmajavi_speedtest_download ]]]"
entity: >-
[[[ return
variables.ulm_custom_card_irmajavi_speedtest_download_speed_entity;
variables.ulm_custom_card_irmajavi_speedtest_download_speed_entity;
]]]
label: |
[[[
Expand Down Expand Up @@ -209,10 +205,10 @@ custom_card_irmajavi_speedtest:
[[[
var state1 = "";
if (states[variables.ulm_custom_card_irmajavi_speedtest_upload_speed_entity].state){
var state1 = states[variables.ulm_custom_card_irmajavi_speedtest_upload_speed_entity].state;
if (states[variables.ulm_custom_card_irmajavi_speedtest_upload_speed_entity].attributes.unit_of_measurement){
state1 += states[variables.ulm_custom_card_irmajavi_speedtest_upload_speed_entity].attributes.unit_of_measurement;
}
var state1 = states[variables.ulm_custom_card_irmajavi_speedtest_upload_speed_entity].state;
if (states[variables.ulm_custom_card_irmajavi_speedtest_upload_speed_entity].attributes.unit_of_measurement){
state1 += states[variables.ulm_custom_card_irmajavi_speedtest_upload_speed_entity].attributes.unit_of_measurement;
}
}
return state1;
]]]
Expand Down

0 comments on commit a3cf8d0

Please sign in to comment.