From 626abfa811a2bfccbe4713e339c35a39c1c99009 Mon Sep 17 00:00:00 2001 From: Doug Nelson Date: Fri, 24 May 2024 19:49:05 -0500 Subject: [PATCH] onn. pro Support v3.4.4 What's New: - Added support for onn. Streaming Device 4K pro - App launcher for Cheers - Danmu Player (closes #382) - App launcher for Radioplayer (UK) (closes #412) - App launcher for TrillerTV (closes #414) Fixes / Changes: - Updated launcher for BINGE (AU) app update (closes #413) Can't see these changes after updating? Visit this link: https://github.com/PRProd/HA-Firemote/wiki/Force-a-Refresh --- README.md | 6 +- dist/HA-Firemote.js | 297 +++++++++++++++++++++++++++++++------- dist/launcher-buttons.js | 128 ++++++++++++++-- dist/supported-devices.js | 5 + 4 files changed, 366 insertions(+), 70 deletions(-) diff --git a/README.md b/README.md index 6c8ef55..18ac1df 100644 --- a/README.md +++ b/README.md @@ -173,9 +173,9 @@ Options: | device_family | string | yes | amazon-fire
apple-tv
chromecast
nvidia-shield
onn
roku
xiaomi
[none](https://github.com/PRProd/HA-Firemote/wiki/entity:-none) | Manufacturer Family | |android_tv_remote_entity| string | no | any valid entity created in the [Android TV Remote Integration](https://www.home-assistant.io/integrations/androidtv_remote/) | entity_id
Ignored in Apple TV and Roku configurations | apple_tv_remote_entity | string | yes* | any valid remote entity created in the [Apple TV Integration](https://www.home-assistant.io/integrations/apple_tv) | entity_id
* Required ONLY in Apple TV configurations -| device_type | string | yes | [appletv-4k-gen3](https://support.apple.com/kb/SP886)
[appletv-4k-gen2](https://support.apple.com/kb/SP845)
[appletv-4k-gen1](https://support.apple.com/kb/SP769)
[appletv-gen4](https://support.apple.com/kb/SP724)
[appletv-gen3](https://support.apple.com/kb/SP648)
[appletv-gen2](https://support.apple.com/kb/SP598)
[appletv-gen1](https://support.apple.com/kb/SP19)
chromecast-4k
[fire_tv_toshiba_v35](https://github.com/PRProd/HA-Firemote/wiki/Smart-TV---Toshiba-V35-Series-LED-FHD-HD---Fire-TV-(2021))
[fire_tv_4_series](https://github.com/PRProd/HA-Firemote/wiki/Smart-TV---Fire-TV-4-Series-(2021))
fire_tv_jvc-4k-2021
[fire_tv_cube_third_gen](https://github.com/PRProd/HA-Firemote/wiki/Fire-TV-Cube---3rd-Gen-(2022))
[fire_tv_cube_second_gen](https://github.com/PRProd/HA-Firemote/wiki/Fire-TV-Cube---2nd-Gen-(2019))
[fire_tv_cube_first_gen](https://github.com/PRProd/HA-Firemote/wiki/Fire-TV-Cube---1st-Gen-(2018))
[fire_tv_stick_4k_max_second_gen](https://github.com/PRProd/HA-Firemote/wiki/Fire-TV-Stick-4K-Max-2nd-Gen-(2023))
[fire_tv_stick_4k_second_gen](https://github.com/PRProd/HA-Firemote/wiki/Fire-TV-Stick-4K-2nd-Gen-(2023))
[fire_tv_stick_4k_max](https://github.com/PRProd/HA-Firemote/wiki/Fire-TV-Stick-4K-Max---1st-Gen-(2021))
[fire_tv_3rd_gen](https://github.com/PRProd/HA-Firemote/wiki/Fire-TV-Stick---3rd-Gen-(2020))
[fire_tv_stick_lite](https://github.com/PRProd/HA-Firemote/wiki/Fire-TV-Stick-Lite---1st-Gen-(2020))
[fire_stick_4k](https://github.com/PRProd/HA-Firemote/wiki/Fire-TV-Stick-4K---1st-Gen-(2018))
[fire_stick_second_gen](https://github.com/PRProd/HA-Firemote/wiki/Fire-TV-Stick---2nd-Gen-(2016---2019))
[fire_stick_first_gen](https://github.com/PRProd/HA-Firemote/wiki/Fire-TV-Stick-1st-Gen-(2014))
[fire_tv_second_gen_2015](https://github.com/PRProd/HA-Firemote/wiki/Fire-TV-%E2%80%90-2nd-Gen-(2015))
[onn-4k-streaming-box](https://github.com/PRProd/HA-Firemote/wiki/onn.-Google-TV-4K-Streaming-Box-(2023))
onn-full-hd-streaming-stick
roku-streambar-pro
roku-streambar
roku-ultra-lt-2023
roku-ultra-lt
roku-ultra-2020
roku-streaming-stick-4k
roku-express-4k-plus
roku-express-4k
roku-express
roku-premiere
roku-generic-hisense
roku-generic-tcl
roku-generic-westinghouse
shield-tv-2017
shield-tv-pro-2017
shield-tv-2019
shield-tv-pro-2019
mi-box-s
xiaomi-tv-stick-4k
[other](https://github.com/PRProd/HA-Firemote/wiki/entity:-none)| The type of device you are controlling
[Which devices are supported?](https://github.com/PRProd/HA-Firemote/wiki/Existing-Amazon-Devices---Support-Chart)
[Which device do I own?](https://developer.amazon.com/docs/fire-tv/device-specifications.html) | +| device_type | string | yes | [appletv-4k-gen3](https://support.apple.com/kb/SP886)
[appletv-4k-gen2](https://support.apple.com/kb/SP845)
[appletv-4k-gen1](https://support.apple.com/kb/SP769)
[appletv-gen4](https://support.apple.com/kb/SP724)
[appletv-gen3](https://support.apple.com/kb/SP648)
[appletv-gen2](https://support.apple.com/kb/SP598)
[appletv-gen1](https://support.apple.com/kb/SP19)
chromecast-4k
[fire_tv_toshiba_v35](https://github.com/PRProd/HA-Firemote/wiki/Smart-TV---Toshiba-V35-Series-LED-FHD-HD---Fire-TV-(2021))
[fire_tv_4_series](https://github.com/PRProd/HA-Firemote/wiki/Smart-TV---Fire-TV-4-Series-(2021))
fire_tv_jvc-4k-2021
[fire_tv_cube_third_gen](https://github.com/PRProd/HA-Firemote/wiki/Fire-TV-Cube---3rd-Gen-(2022))
[fire_tv_cube_second_gen](https://github.com/PRProd/HA-Firemote/wiki/Fire-TV-Cube---2nd-Gen-(2019))
[fire_tv_cube_first_gen](https://github.com/PRProd/HA-Firemote/wiki/Fire-TV-Cube---1st-Gen-(2018))
[fire_tv_stick_4k_max_second_gen](https://github.com/PRProd/HA-Firemote/wiki/Fire-TV-Stick-4K-Max-2nd-Gen-(2023))
[fire_tv_stick_4k_second_gen](https://github.com/PRProd/HA-Firemote/wiki/Fire-TV-Stick-4K-2nd-Gen-(2023))
[fire_tv_stick_4k_max](https://github.com/PRProd/HA-Firemote/wiki/Fire-TV-Stick-4K-Max---1st-Gen-(2021))
[fire_tv_3rd_gen](https://github.com/PRProd/HA-Firemote/wiki/Fire-TV-Stick---3rd-Gen-(2020))
[fire_tv_stick_lite](https://github.com/PRProd/HA-Firemote/wiki/Fire-TV-Stick-Lite---1st-Gen-(2020))
[fire_stick_4k](https://github.com/PRProd/HA-Firemote/wiki/Fire-TV-Stick-4K---1st-Gen-(2018))
[fire_stick_second_gen](https://github.com/PRProd/HA-Firemote/wiki/Fire-TV-Stick---2nd-Gen-(2016---2019))
[fire_stick_first_gen](https://github.com/PRProd/HA-Firemote/wiki/Fire-TV-Stick-1st-Gen-(2014))
[fire_tv_second_gen_2015](https://github.com/PRProd/HA-Firemote/wiki/Fire-TV-%E2%80%90-2nd-Gen-(2015))
onn-streaming-device-4k-pro
[onn-4k-streaming-box](https://github.com/PRProd/HA-Firemote/wiki/onn.-Google-TV-4K-Streaming-Box-(2023))
onn-full-hd-streaming-stick
roku-streambar-pro
roku-streambar
roku-ultra-lt-2023
roku-ultra-lt
roku-ultra-2020
roku-streaming-stick-4k
roku-express-4k-plus
roku-express-4k
roku-express
roku-premiere
roku-generic-hisense
roku-generic-tcl
roku-generic-westinghouse
shield-tv-2017
shield-tv-pro-2017
shield-tv-2019
shield-tv-pro-2019
mi-box-s
xiaomi-tv-stick-4k
[other](https://github.com/PRProd/HA-Firemote/wiki/entity:-none)| The type of device you are controlling
[Which devices are supported?](https://github.com/PRProd/HA-Firemote/wiki/Existing-Amazon-Devices---Support-Chart)
[Which device do I own?](https://developer.amazon.com/docs/fire-tv/device-specifications.html) | | compatibility_mode | string | no | default
strong
event0
event1
event2
event3
event4
event5
event6
event7
event8
event9
event10
event11
event12
event13 | Adjust this value only if your buttons are completely unresponsive

Ignored in Apple TV configurations

[FAQ Available for additional help](https://github.com/PRProd/HA-Firemote#faq) | -|defaultRemoteStyle_override | string | no | AF1
AF2
AF3
AF4
AF5
AF6
AFJTV
AR1
AR2
AR3
CC1
NS1
NS2
ON1
RVRP
RVR
RSR
RHR
RTR
RWR
XM1
XM2
AL1
AL2 | Optionally select a style of remote different from the one that shipped with your device | +|defaultRemoteStyle_override | string | no | AF1
AF2
AF3
AF4
AF5
AF6
AFJTV
AR1
AR2
AR3
CC1
NS1
NS2
ON1
ON2
RVRP
RVR
RSR
RHR
RTR
RWR
XM1
XM2
AL1
AL2 | Optionally select a style of remote different from the one that shipped with your device | | app_launch_1
app_launch_2
app_launch_3
app_launch_4
app_launch_5
etc... | string | no | [ See App Launch Button Customization section for options](#app-launch-button-customization) | Quick launch apps customization | |hdmi_1
hdmi_2
hdmi_3
hdmi_4| string | no | Personalized name for this HDMI input | The name entered here will appear on the button (truncated to 8 characters to fit)| | scale | integer| no | Any positive number | Change the size of this card by percentage. The default size is 100 | @@ -302,6 +302,7 @@ Valid button names are as follows: - keyboard-button - left-button - live-button + - magic-star-button - mute-button - num1-button - num2-button @@ -405,3 +406,4 @@ Click on the [Issues](https://github.com/PRProd/HA-Firemote/issues) button at th - Take a look at the current [discussions board](https://github.com/PRProd/HA-Firemote/discussions) to see if anything is tagged with "Help Wanted". - Buy Me A Coffee - Since it is personally expensive for me to purchase, evaluate, and develop integrations for all of your requests, I've set up an [Amazon Wish List (US)](https://www.amazon.com/hz/wishlist/ls/2UDS10RPJ6F5K?ref_=wl_share) and an [Amazon Wish List (DE)](https://www.amazon.de/hz/wishlist/ls/HFABU3R70GWE?ref_=wl_share) for any of you who are feeling incredibly generous and want to send me something that I don't already own. + diff --git a/dist/HA-Firemote.js b/dist/HA-Firemote.js index b380114..265859f 100644 --- a/dist/HA-Firemote.js +++ b/dist/HA-Firemote.js @@ -1,9 +1,9 @@ -const HAFiremoteVersion = 'v3.4.3'; +const HAFiremoteVersion = 'v3.4.4'; import {LitElement, html, css, unsafeHTML, unsafeCSS} from './lit/lit-all.min.js'; -import {launcherData, launcherCSS} from "./launcher-buttons.js?version=v3.4.3"; -import {rosettaStone} from './language-translations.js?version=v3.4.3'; -import {devices} from './supported-devices.js?version=v3.4.3'; +import {launcherData, launcherCSS} from "./launcher-buttons.js?version=v3.4.4"; +import {rosettaStone} from './language-translations.js?version=v3.4.4'; +import {devices} from './supported-devices.js?version=v3.4.4'; console.groupCollapsed("%c 🔥 FIREMOTE-CARD 🔥 %c "+HAFiremoteVersion+" installed ", "color: orange; font-weight: bold; background: black", "color: green; font-weight: bold;"), console.log("Readme:", "https://github.com/PRProd/HA-Firemote"), @@ -28,8 +28,8 @@ var appmap = new Map(Object.entries(launcherData)); const translationmap = new Map(Object.entries(rosettaStone)); // Set the max number of app launcher buttons for each remote style -const appButtonMax = { "AF4": 6, "AF5": 6, "AF6": 6, "AFJTV": 6, "AR1": 10, "AR2": 8, "AR3": 8, "CC1": 6, "NS2": 6, - "ON1": 8, "RVRP": 8, "RHR": 10, "RTR": 6, "RWR": 10, "RVR": 10, "RSR": 10, +const appButtonMax = { "AF4": 6, "AF5": 6, "AF6": 6, "AFJTV": 6, "AR1": 10, "AR2": 8, "AR3": 8, "CC1": 6, "NS2": 6, + "ON1": 8, "ON2": 8, "RVRP": 8, "RHR": 10, "RTR": 6, "RWR": 10, "RVR": 10, "RSR": 10, "XM1": 10, "XM2": 10, "AL1": appmap.size, "AL2": appmap.size,}; @@ -1895,7 +1895,7 @@ class FiremoteCard extends LitElement { } /* onn. styles */ - .remote-body.ON1 { + .remote-body.ON1, .remote-body.ON2 { align-content: start; grid-row-gap: calc(var(--sz)* 1rem); background: #ebebea; @@ -1906,61 +1906,95 @@ class FiremoteCard extends LitElement { box-shadow: 0 calc(var(--sz) * 0.214rem) calc(var(--sz) * 0.214rem) rgb(0 0 0 / 10%); } - .ON1 .remote-button { + .remote-body.ON2 { + background: #252525; + border-color: #2f2f2f; + } + + .ON1 .remote-button, .ON2 .remote-button { background: #fff; color: rgb(106, 106, 106); border: solid rgb(186 186 186) calc(var(--sz)* 0.0714rem); box-shadow: rgb(0 0 0 / 15%) 0px calc(var(--sz)* 0.063rem) calc(var(--sz)* 0.188rem); } - .ON1 .remote-button:active { + .ON2 .remote-button { + background: #2f2f2f; + border: solid rgb(15 15 15) calc(var(--sz)* 0.0714rem); + } + + .ON1 .remote-button:active, .ON2 .remote-button:active { box-shadow: inset rgb(0 0 0 / 42%) 0px calc(var(--sz)* 0.1rem) calc(var(--sz)* 0.188rem); filter: brightness(0.94); border: solid rgb(232 232 232) calc(var(--sz)* 0.0714rem); } + .ON2 .remote-button:active { + border: solid rgb(10 10 10) calc(var(--sz)* 0.0714rem); + } + .remote-body.ON1 .remote-button.litbutton { background: #ffffe7; } - .remote-body.ON1 .remote-button.litbutton > ha-icon { + .remote-body.ON1 #power-button.litbutton > ha-icon, + .remote-body.ON2 .remote-button.litbutton > ha-icon { color: #017374 !important; } - .remote-body.ON1 .remote-button:active > ha-icon { + .remote-body.ON2 #power-button.litbutton > ha-icon { + color: #ebef66 !important; + } + + .remote-body.ON1 .remote-button:active > ha-icon, + .remote-body.ON2 .remote-button:active > ha-icon { transform: scale(calc(var(--sz)* 0.90)); } - .remote-body.ON1 .remote-button.dark { + .remote-body.ON1 .remote-button.dark, + .remote-body.ON2 .remote-button.dark { background: linear-gradient(180deg, rgba(69,69,69,1) 26%, rgba(55,55,55,1) 50%, rgba(45,45,45,1) 75%); } + .remote-body.ON2 .remote-button.light { + background: linear-gradient(0deg, #c8c8c8 0%, rgba(255, 255, 255, 1) 100%); + } + .remote-body.ON1 .remote-button > ha-icon { color: rgb(106 106 106); } + .remote-body.ON2 .remote-button > ha-icon { + color: rgb(245 245 245); + } + .remote-body.ON1 .remote-button.dark > ha-icon { color: #ebebea; } - .remote-body.ON1 .remote-button.dark.litbutton { - background: #004040; + .remote-body.ON2 .remote-button.light > ha-icon { + color: #464646; } - .remote-body.ON1 .remote-button.dark.litbutton > ha-icon { - color: #ffffab !important; + .remote-body.ON1 .remote-button.dark.litbutton, + background: #004040; + } + .remote-body.ON1 .remote-button.litbutton > ha-icon, + .remote-body.ON1 .remote-button.dark.litbutton > ha-icon, + .remote-body.ON2 .remote-button.dark.litbutton > ha-icon { + color: #ffffab; } - .ON1 .directionButtonContainer { + .ON1 .directionButtonContainer, .ON2 .directionButtonContainer { box-shadow: rgb(0 0 0 / 73%) calc(var(--sz)* 0.025rem) calc(var(--sz)* 0.025rem) calc(var(--sz)* 0.025rem); background: black; } - .ON1 .directionButtonContainer:has(#down-button:active) { + .ON1 .directionButtonContainer:has(#down-button:active), .ON2 .directionButtonContainer:has(#down-button:active) { box-shadow: none; } - .ON1 .dpadContainer { + .ON1 .dpadContainer, .ON2 .dpadContainer { align-items: center; justify-items: center; position: relative; @@ -1969,7 +2003,8 @@ class FiremoteCard extends LitElement { isolation: isolate; } - .ON1 .dpadbutton, .ON1 .dpadbutton:active { + .ON1 .dpadbutton, .ON1 .dpadbutton:active, + .ON2 .dpadbutton, .ON2 .dpadbutton:active { all: unset; cursor: pointer; width: calc(var(--sz)* 5.5714rem); @@ -1977,7 +2012,7 @@ class FiremoteCard extends LitElement { outline: solid #2e2e2e calc(var(--sz)* 0.0714rem); } - .ON1 .dpadbutton { + .ON1 .dpadbutton, .ON2 .dpadbutton { background: rgba(55, 55, 55, 1); appearance: none; -webkit-appearance: none; @@ -1985,7 +2020,12 @@ class FiremoteCard extends LitElement { -webkit-tap-highlight-color: transparent; } - .ON1 .dpadbutton:active { + .ON2 .dpadbutton { + background: rgb(216 216 216); + outline: solid rgb(200 200 200) calc(var(--sz)* 0.0714rem); + } + + .ON1 .dpadbutton:active, .ON2 .dpadbutton:active { background: rgba(45, 45, 45, 1); box-shadow: inset #161616 0 0 calc(var(--sz)* 0.35rem) 0px; transform: none; @@ -1995,7 +2035,13 @@ class FiremoteCard extends LitElement { appearance: none; } - .ON1 .centerbutton { + .ON2 .dpadbutton:active { + background: rgb(200 200 200); + box-shadow: none; + outline: solid #989898 calc(var(--sz)* 0.0714rem); + } + + .ON1 .centerbutton, .ON2 .centerbutton { background: linear-gradient(180deg, #c8c8c8 0%, rgba(255, 255, 255, 1) 100%); border: solid #2b2b2b calc(var(--sz)* 0.25rem); width: calc(var(--sz)* 5.13rem); @@ -2006,28 +2052,37 @@ class FiremoteCard extends LitElement { isolation: isolate; } - .ON1 .centerbutton:active { + .ON2 .centerbutton { + background: linear-gradient(0deg, rgb(48 48 48) 26%, rgb(39 39 39) 50%, rgb(33 33 33) 75%); + } + + .ON1 .centerbutton:active, .ON2 .centerbutton:active { transform: none; filter: brightness(0.92); border: solid #2b2b2b calc(var(--sz)* 0.29rem); } - .ON1 #power-button, .ON1 #input-button { + .ON2 .centerbutton:active { + filter: brightness(0.8); + } + + .ON1 #power-button, .ON1 #input-button, + .ON2 #power-button, .ON2 #magic-star-button { height: calc(var(--sz)* 2.5rem); width: calc(var(--sz)* 2.5rem); } - .ON1 #power-button { + .ON1 #power-button, .ON2 #power-button { justify-self: left; } - .ON1 .micNLight { + .ON1 .micNLight, .ON2 .micNLight { display: grid; align-content: space-between; padding: calc(var(--sz) * 0.25rem) 0; } - .ON1 .activityLight { + .ON1 .activityLight, .ON2 .activityLight { background: #adff87; box-shadow: lime 0 0 calc(var(--sz)* 0.6rem) calc(var(--sz)* 0.05rem); border-radius: 100%; @@ -2036,7 +2091,7 @@ class FiremoteCard extends LitElement { opacity: 0; } - .ON1 .micHole { + .ON1 .micHole, .ON2 .micHole { background: black; border-radius: 100%; height: calc(var(--sz)* 0.3rem); @@ -2045,27 +2100,28 @@ class FiremoteCard extends LitElement { justify-self: center; } - .ON1 #input-button { + .ON1 #input-button, .ON2 #magic-star-button { justify-self: right; } - .ON1 #profile-button, .ON1 #settings-button { + .ON1 #profile-button, .ON1 #settings-button, + .ON2 #profile-button, .ON2 #settings-button { align-self: end; } - .ON1 #keyboard-button { + .ON1 #keyboard-button, .ON2 #keyboard-button { height: calc(var(--sz)* 3.572rem); width: calc(var(--sz)* 3.572rem); margin-bottom: calc(var(--sz)* 1.1rem); } - .ON1 #home-button { + .ON1 #home-button, .ON2 #home-button { align-self: end; margin-top: calc(var(--sz)* 1.1rem); z-index: 10; /* Required for companion app to prevent accidental push of down button */ } - .ON1 .volumeChannelSection { + .ON1 .volumeChannelSection, .ON2 .volumeChannelSection { grid-column-start: 1; grid-column-end: 4; display: grid; @@ -2078,32 +2134,32 @@ class FiremoteCard extends LitElement { align-items: center; } - .ON1 #volume-up-button { + .ON1 #volume-up-button, .ON2 #volume-up-button { grid-area: vol-up; margin-bottom: 0; border-bottom: 0; font-size: calc(var(--sz)* 2rem); } - .ON1 #channel-up-button { + .ON1 #channel-up-button, .ON2 #channel-up-button { grid-area: ch-up; margin-bottom: 0; border-bottom: 0; } - .ON1 #mute-button { + .ON1 #mute-button, .ON2 #mute-button { grid-area: mute; height: calc(var(--sz)* 2.6rem); width: calc(var(--sz)* 2.6rem); } - .ON1 #volume-down-button { + .ON1 #volume-down-button, .ON2 #volume-down-button { grid-area: vol-down; border-top: 0; font-size: calc(var(--sz)* 2rem); } - .ON1 #channel-down-button { + .ON1 #channel-down-button, .ON2 #channel-down-button { grid-area: ch-down; border-top: 0; } @@ -2115,6 +2171,12 @@ class FiremoteCard extends LitElement { border-bottom: 0; } + .ON2 #volume-up-button:active, .ON2 #channel-up-button:active { + filter: none; + background: linear-gradient(0deg, rgb(46 46 46) 0%, rgb(38 38 38) 95%); + border-bottom: 0; + } + .ON1 #volume-down-button:active, .ON1 #channel-down-button:active { filter: none; background: linear-gradient(0deg, rgba(240, 240, 240, 1) 0%, rgba(255, 255, 255, 1) 95%); @@ -2123,7 +2185,14 @@ class FiremoteCard extends LitElement { border-top: 0; } - .ON1 .afappsgrid { + .ON2 #volume-down-button:active, .ON2 #channel-down-button:active { + filter: none; + background: linear-gradient(180deg, rgb(46 46 46) 0%, rgb(38 38 38) 95%); + box-shadow: none; + border-top: 0; + } + + .ON1 .afappsgrid, .ON2 .afappsgrid { align-content: start; margin: calc(var(--sz)* 0.75rem) 0 calc(var(--sz)* 3.75rem) 0; } @@ -2132,7 +2201,11 @@ class FiremoteCard extends LitElement { border-color: #ccc; } - .ON1 .srcButton.appActive { + .ON2 .srcButton { + border-color: #292929; + } + + .ON1 .srcButton.appActive, .ON2 .srcButton.appActive { box-shadow: rgb(0 0 0 / 13%) 0 calc(var(--sz)* 0.214rem) calc(var(--sz)* 0.1428rem) 0, white 0 0 calc(var(--sz)* 0.857rem) calc(var(--sz)* 0.429rem); border-color: #e6e6e6; animation-name: flash_border; @@ -2141,6 +2214,10 @@ class FiremoteCard extends LitElement { animation-iteration-count: infinite; } + .ON2 .srcButton.appActive { + box-shadow: rgb(255 255 255 / 0%) 0 calc(var(--sz)* 0.214rem) calc(var(--sz)* 0.1428rem) 0, rgb(255 255 255 / 31%) 0 0 calc(var(--sz)* 0.857rem) calc(var(--sz)* 0.429rem); + } + @keyframes flash_border { 0% { border-color: rgb(0 0 0 / 16%); @@ -2153,16 +2230,16 @@ class FiremoteCard extends LitElement { } } - .ON1 .srcButton:active { + .ON1 .srcButton:active, .ON2 .srcButton:active { box-shadow: inset rgb(0 0 0 / 25%) 0 calc(var(--sz)* 0.214rem) calc(var(--sz)* 0.1428rem) 0; } - .ON1 .deviceNameTop { + .ON1 .deviceNameTop, .ON2 .deviceNameTop { grid-column: 1 / 4; margin: calc(var(--sz)* -1rem) 0; } - .ON1 .deviceNameBottom { + .ON1 .deviceNameBottom, .ON2 .deviceNameBottom { position: absolute; bottom: calc(var(--sz)* 0.75rem); margin: 0; @@ -2181,6 +2258,10 @@ class FiremoteCard extends LitElement { max-width: calc(var(--sz)* 5rem); max-height: calc(var(--sz)* 2rem); } + + .ON2 .onnLogo svg { + fill: #949494; + } /* end onn. styles */ ${unsafeCSS(launcherCSS)} @@ -2198,11 +2279,12 @@ class FiremoteCard extends LitElement { background: #000; } - .ON1 .functionRebootButton { + .ON1 .functionRebootButton, .ON2 .functionRebootButton { background: #fff; } - .ON1 .functionSearchGoogleTVButton, .ON1 .functionCaptionsButton, .ON1 .functionpairingButton { + .ON1 .functionSearchGoogleTVButton, .ON1 .functionCaptionsButton, .ON1 .functionpairingButton, + .ON2 .functionSearchGoogleTVButton, .ON2 .functionCaptionsButton, .ON2 .functionpairingButton { background: #fff; color: #000; } @@ -2230,7 +2312,7 @@ class FiremoteCard extends LitElement { display: none; } - .ON1 .functionSystemUpdateButton { + .ON1 .functionSystemUpdateButton, .ON2 .functionSystemUpdateButton { background: #fff; color: #000; } @@ -2240,6 +2322,12 @@ class FiremoteCard extends LitElement { box-shadow: 0 0 calc(var(--sz) * 0.857rem) calc(var(--sz) * 0.142rem) rgb(255 255 255 / 20%) !important; } + .ON1 .functionFindRemoteButton, + .ON2 .functionFindRemoteButton { + color: yellow; + border: solid calc(var(--sz) * 0.1rem) #017374; + } + .shield-remote-body .functionFindRemoteButton, .shield-remote-body .functionMuteButton, .shield-remote-body .functionSystemUpdateButton, .shield-remote-body .functionMuteButton, .shield-remote-body .functionRebootButton, .shield-remote-body .functionSettingsButton, .shield-remote-body .functionCaptionsButton { color: rgb(153, 231, 0); @@ -2570,7 +2658,7 @@ class FiremoteCard extends LitElement { if(this._config.device_family == 'apple-tv') { AppLaunchButtonFilterCssValue = 'grayscale(0%) brightness(100%)'; } - else if (this._config.device_family == 'onn' || this._config.defaultRemoteStyle_override == 'ON1') { + else if (this._config.device_family == 'onn' || this._config.defaultRemoteStyle_override == 'ON1' || this._config.defaultRemoteStyle_override == 'ON2') { AppLaunchButtonFilterCssValue = 'grayscale(25%) brightness(80%)'; } var guiEditorDirection = this.hass.config.language == 'he' ? 'rtl' : 'ltr'; @@ -2755,7 +2843,7 @@ class FiremoteCard extends LitElement { appLaunchButtons.set("confBtn3", config.app_launch_3 || 'disney-plus'); appLaunchButtons.set("confBtn4", config.app_launch_4 || 'freeview-play'); } - else if(['ON1'].includes(displayedRemote)) { + else if(['ON1', 'ON2'].includes(displayedRemote)) { appLaunchButtons.set("confBtn1", config.app_launch_1 || 'youtube'); appLaunchButtons.set("confBtn2", config.app_launch_2 || 'netflix'); appLaunchButtons.set("confBtn3", config.app_launch_3 || 'disney-plus'); @@ -3745,6 +3833,94 @@ class FiremoteCard extends LitElement { } + // Render onn. remote style 2 + if ( getDeviceAttribute('defaultRemoteStyle') == 'ON2' ) { + return html` + + + ${cssVars} + +
+ + ${drawDeviceName(this, this._config, 'top')} + + +
+
+
+
+ + + + + + +
+
+ + + + +
+ +
+ + + + + +
+ +
+ + + + + +
+ + ${drawAppLaunchButtons(this, this._config, 3, appButtonMax["ON2"])} + + + + ${drawDeviceName(this, this._config, 'bottom')} + ${drawFiremoteVersionNumber(this, this._config)} + +
+ +
+ `; + } + + function renderRokuPowerRow(remote, style){ if(style=='RVR') { return html` @@ -4740,6 +4916,18 @@ class FiremoteCard extends LitElement { return; }; + // Magic Button / Star Button (Google TV / onn pro) + if(clicked.target.id == 'magic-star-button') { + if (deviceType == 'onn-streaming-device-4k-pro') { + this.hass.callService("androidtv", "adb_command", { entity_id: this._config.entity, command: 'adb shell input keyevent 313' }); + return; + } + else { + unsupportedButton(); + return; + } + }; + // Keyboard button if(clicked.target.id == 'keyboard-button') { var text = prompt("Enter text to send"); @@ -5055,7 +5243,7 @@ class FiremoteCard extends LitElement { this.hass.callService("remote", "send_command", { entity_id: this._config.roku_remote_entity, command: 'channel_up', num_repeats: 1, delay_secs: 0, hold_secs: 0}); return; } - if (['fire_tv_stick_4k_second_gen', 'fire_tv_stick_4k_max_second_gen', 'onn-4k-streaming-box', 'onn-full-hd-streaming-stick'].includes(deviceType)) { + if (['fire_tv_stick_4k_second_gen', 'fire_tv_stick_4k_max_second_gen', 'onn-streaming-device-4k-pro', 'onn-4k-streaming-box', 'onn-full-hd-streaming-stick'].includes(deviceType)) { this.hass.callService("androidtv", "adb_command", { entity_id: this._config.entity, command: 'adb shell input keyevent KEYCODE_CHANNEL_UP'}); } else { @@ -5098,7 +5286,7 @@ class FiremoteCard extends LitElement { else if (deviceType == 'mi-box-s') { this.hass.callService("androidtv", "adb_command", { entity_id: this._config.entity, command: 'adb shell am start -n com.google.android.tv/com.android.tv.MainActivity' }); } - else if (deviceType == 'onn-4k-streaming-box' || deviceType == 'onn-full-hd-streaming-stick') { + else if (deviceType == 'onn-4k-streaming-box' || deviceType == 'onn-full-hd-streaming-stick' || deviceType == 'onn-streaming-device-4k-pro') { this.hass.callService("androidtv", "adb_command", { entity_id: this._config.entity, command: 'adb shell input keyevent KEYCODE_GUIDE'}); } else { @@ -5113,7 +5301,7 @@ class FiremoteCard extends LitElement { this.hass.callService("remote", "send_command", { entity_id: this._config.roku_remote_entity, command: 'channel_down', num_repeats: 1, delay_secs: 0, hold_secs: 0}); return; } - if (['fire_tv_stick_4k_second_gen', 'fire_tv_stick_4k_max_second_gen', 'onn-4k-streaming-box', 'onn-full-hd-streaming-stick'].includes(deviceType)) { + if (['fire_tv_stick_4k_second_gen', 'fire_tv_stick_4k_max_second_gen', 'onn-streaming-device-4k-pro', 'onn-4k-streaming-box', 'onn-full-hd-streaming-stick'].includes(deviceType)) { this.hass.callService("androidtv", "adb_command", { entity_id: this._config.entity, command: 'adb shell input keyevent KEYCODE_CHANNEL_DOWN'}); } else { @@ -5144,7 +5332,7 @@ class FiremoteCard extends LitElement { // Settings Button if(clicked.target.id == 'settings-button') { - if(deviceType == 'onn-4k-streaming-box' || deviceType == 'onn-full-hd-streaming-stick') { + if(['onn-4k-streaming-box', 'onn-full-hd-streaming-stick', 'onn-streaming-device-4k-pro'].includes(deviceType)) { this.hass.callService("androidtv", "adb_command", { entity_id: this._config.entity, command: 'adb shell input keyevent 83' }); } else if(compatibility_mode == 'strong' || eventListenerBinPath == 'undefined' || deviceType == 'fire_tv_cube_third_gen') { @@ -6085,7 +6273,8 @@ class FiremoteCardEditor extends LitElement { - + + diff --git a/dist/launcher-buttons.js b/dist/launcher-buttons.js index d90a974..549ae86 100644 --- a/dist/launcher-buttons.js +++ b/dist/launcher-buttons.js @@ -491,9 +491,9 @@ const launcherData = { "className": "bingeAuButton", "deviceFamily": ["amazon-fire", "apple-tv", "chromecast", "nvidia-shield", "xiaomi"], "amazon-fire": { - "appName": "au.com.streamotion.ares.tv", - "androidName": "au.com.streamotion.ares.tv", - "adbLaunchCommand": "adb shell am start -n au.com.streamotion.ares.tv/au.com.streamotion.ares.tv.main.MainActivity", + "appName": "au.com.streamotion.ctv.binge", + "androidName": "au.com.streamotion.ctv.binge", + "adbLaunchCommand": "adb shell am start -n au.com.streamotion.ctv.binge/au.com.streamotion.ctv.MainActivity", }, "apple-tv": { "appName": "BINGE", @@ -501,17 +501,30 @@ const launcherData = { "chromecast": { "appName": "au.com.streamotion.ares.tv", "androidName": "au.com.streamotion.ares.tv", - "adbLaunchCommand": "adb shell am start -n au.com.streamotion.ares.tv/au.com.streamotion.ares.tv.main.MainActivity", + "adbLaunchCommand": "adb shell am start -n au.com.streamotion.ares.tv/au.com.streamotion.tv.SplashActivity", }, "nvidia-shield": { "appName": "au.com.streamotion.ares.tv", "androidName": "au.com.streamotion.ares.tv", - "adbLaunchCommand": "adb shell am start -n au.com.streamotion.ares.tv/au.com.streamotion.ares.tv.main.MainActivity", + "adbLaunchCommand": "adb shell am start -n au.com.streamotion.ares.tv/au.com.streamotion.tv.SplashActivity", }, "xiaomi": { "appName": "au.com.streamotion.ares.tv", "androidName": "au.com.streamotion.ares.tv", - "adbLaunchCommand": "adb shell am start -n au.com.streamotion.ares.tv/au.com.streamotion.ares.tv.main.MainActivity", + "adbLaunchCommand": "adb shell am start -n au.com.streamotion.ares.tv/au.com.streamotion.tv.SplashActivity", + }, + }, + + + "binge-au-alt": { + "button": '', + "friendlyName": 'Binge (AU) alt', + "className": "bingeAuButton", + "deviceFamily": ["amazon-fire"], + "amazon-fire": { + "appName": "au.com.streamotion.ares.tv", + "androidName": "au.com.streamotion.ares.tv", + "adbLaunchCommand": "adb shell am start -n au.com.streamotion.ares.tv/au.com.streamotion.tv.SplashActivity", }, }, @@ -683,10 +696,11 @@ const launcherData = { "cheers-danmu-player": { "button": '', "friendlyName": 'Cheers - Danmu Player', - "appName": "Cheers - Danmu Player", "className": "cheersDanmuPlayerButton", - "androidName": "com.", - "deviceFamily": [], + "deviceFamily": ["apple-tv"], + "apple-tv": { + "appName": "Cheers", + }, }, @@ -4079,6 +4093,40 @@ const launcherData = { }, + "radioplayer-uk": { + "button": '', + "button-round": '', + "friendlyName": "Radioplayer (UK)", + "className": "radioPlayerUKButton", + "deviceFamily": ["amazon-fire", "chromecast", "nvidia-shield", "onn", "xiaomi"], + "amazon-fire": { + "appName": "uk.co.radioplayer", + "androidName": "uk.co.radioplayer", + "adbLaunchCommand": "adb shell am start -n uk.co.radioplayer/.IntroActivity", + }, + "chromecast": { + "appName": "uk.co.radioplayer", + "androidName": "uk.co.radioplayer", + "adbLaunchCommand": "adb shell am start -n uk.co.radioplayer/.IntroActivity", + }, + "nvidia-shield": { + "appName": "uk.co.radioplayer", + "androidName": "uk.co.radioplayer", + "adbLaunchCommand": "adb shell am start -n uk.co.radioplayer/.IntroActivity", + }, + "onn": { + "appName": "uk.co.radioplayer", + "androidName": "uk.co.radioplayer", + "adbLaunchCommand": "adb shell am start -n uk.co.radioplayer/.IntroActivity", + }, + "xiaomi": { + "appName": "uk.co.radioplayer", + "androidName": "uk.co.radioplayer", + "adbLaunchCommand": "adb shell am start -n uk.co.radioplayer/.IntroActivity", + }, + }, + + "raiplay": { "button": '', "friendlyName": "RaiPlay (IT)", @@ -5688,6 +5736,47 @@ const launcherData = { }, + "triller-tv": { + "button": '', + "button-round": '', + "friendlyName": "TrillerTV", + "className": "trillerTVButton", + "deviceFamily": ["amazon-fire", "apple-tv", "chromecast", "nvidia-shield", "onn", "roku", "xiaomi"], + "amazon-fire": { + "appName": "com.flipps.fitetv", + "androidName": "com.flipps.fitetv", + "adbLaunchCommand": "adb shell am start -n com.flipps.fitetv/com.bianor.ams.androidtv.activity.TvMainActivity", + }, + "apple-tv": { + "appName": "TrillerTV", + }, + "chromecast": { + "appName": "com.flipps.fitetv", + "androidName": "com.flipps.fitetv", + "adbLaunchCommand": "adb shell am start -n com.flipps.fitetv/com.bianor.ams.androidtv.activity.TvMainActivity", + }, + "nvidia-shield": { + "appName": "com.flipps.fitetv", + "androidName": "com.flipps.fitetv", + "adbLaunchCommand": "adb shell am start -n com.flipps.fitetv/com.bianor.ams.androidtv.activity.TvMainActivity", + }, + "onn": { + "appName": "com.flipps.fitetv", + "androidName": "com.flipps.fitetv", + "adbLaunchCommand": "adb shell am start -n com.flipps.fitetv/com.bianor.ams.androidtv.activity.TvMainActivity", + }, + "roku": { + "appName": 'TrillerTV: Live Sports', + "app-id": 174995, + }, + "xiaomi": { + "appName": "com.flipps.fitetv", + "androidName": "com.flipps.fitetv", + "adbLaunchCommand": "adb shell am start -n com.flipps.fitetv/com.bianor.ams.androidtv.activity.TvMainActivity", + }, + }, + + "tubi": { "button": '', "friendlyName": "tubi", @@ -6604,12 +6693,15 @@ const launcherData = { "button": " Find Remote", "friendlyName": "Function: Find My Remote", "className": "functionFindRemoteButton", - "deviceFamily": ["nvidia-shield", "roku"], + "deviceFamily": ["nvidia-shield", "onn", "roku"], "nvidia-shield": { "appName": "com.nvidia.remotelocator", "androidName": "com.nvidia.remotelocator", "adbLaunchCommand": "adb shell am start -a android.intent.action.VIEW -d -n com.nvidia.remotelocator/.ShieldRemoteLocatorActivity", }, + "onn": { + "adbLaunchCommand": "adb shell input keyevent KEYCODE_BUTTON_11", + }, "roku": { "remoteCommand": '{"command": "find_remote", "num_repeats": 1, "hold_secs": 0}', }, @@ -7059,7 +7151,7 @@ const launcherCSS = ` .AF6 .disneyPlusButton { background: rgb(37, 37, 37); } - .ON1 .disneyPlusButton { + .ON1 .disneyPlusButton, .ON2 .disneyPlusButton { background: #fff; } .disneyPlusButton svg { @@ -7069,7 +7161,7 @@ const launcherCSS = ` .shield-remote-body .disneyPlusButton svg { width: calc(var(--sz) * 4.8rem); } - .ON1 .disneyPlusButton > svg > g > * { + .ON1 .disneyPlusButton > svg > g > *, .ON2 .disneyPlusButton > svg > g > * { fill: #0c2661 !important; } @@ -7589,10 +7681,10 @@ const launcherCSS = ` .paramountPlusButton { background: #0667fc; } - .ON1 .paramountPlusButton { + .ON1 .paramountPlusButton, .ON2 .paramountPlusButton { background: #fff; } - .ON1 .paramountPlusButton > svg > path { + .ON1 .paramountPlusButton > svg > path, .ON2 .paramountPlusButton > svg > path { fill: #0667fc !important; } @@ -7678,6 +7770,10 @@ const launcherCSS = ` background: #000; } + .radioPlayerUKButton { + background: #c03; + } + .raiPlayButton { background: #fff; } @@ -7972,6 +8068,10 @@ const launcherCSS = ` background: #000; } + .trillerTVButton { + background: linear-gradient(74deg, #334877 6%, #35497c00 40%),linear-gradient(351deg, #F30B0B4F 0%, #35497C00 35%),linear-gradient(111deg, #1a2846 9%, #0d1424 100%); + } + .tubiButton { background: radial-gradient(circle at 80% -20%, rgba(140,0,229,1) 0%, rgba(69,0,157,1) 100%); } diff --git a/dist/supported-devices.js b/dist/supported-devices.js index 50533dc..57e41b2 100644 --- a/dist/supported-devices.js +++ b/dist/supported-devices.js @@ -282,6 +282,11 @@ const devices = { "noCategory": { + "onn-streaming-device-4k-pro": { + "supported": true, + "friendlyName": "onn. Streaming Device 4K pro", + "defaultRemoteStyle" : "ON2", + }, "onn-4k-streaming-box": { "supported": true, "friendlyName": "onn. 4K Streaming Box",