Skip to content

Commit

Permalink
disable tilt if text appears over popup
Browse files Browse the repository at this point in the history
  • Loading branch information
matt8707 committed Jun 29, 2023
1 parent 7df57ea commit 34011e1
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions button_card_templates/tilt.yaml
Expand Up @@ -4,10 +4,15 @@ tilt:
variables:
tilt_enable: >
[[[
// enable only on this
if (window.navigator.userAgent.match(/Macintosh; Intel Mac OS X/i)) {
// disable on macos app, text appears over popup
if (window.navigator.userAgent.includes("Home Assistant")) {
return false
}
// enable on macos browsers
else if (window.navigator.userAgent.match(/Macintosh; Intel Mac OS X/i)) {
return true;
}
// default - phones, tablets etc
return false;
]]]
tilt_options: >
Expand Down

0 comments on commit 34011e1

Please sign in to comment.