mirror of
https://github.com/joBr99/nspanel-lovelace-ui.git
synced 2026-02-16 01:46:59 +01:00
Compare commits
6 Commits
9947664ae8
...
Armilar-pa
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
54422eccaa | ||
|
|
02004f4b6d | ||
|
|
58278c5388 | ||
|
|
ff7d2020f7 | ||
|
|
160420fe82 | ||
|
|
56703ec458 |
2
.github/workflows/builder.yaml
vendored
2
.github/workflows/builder.yaml
vendored
@@ -100,7 +100,7 @@ jobs:
|
||||
|
||||
- name: Build ${{ matrix.addon }} add-on
|
||||
if: steps.check.outputs.build_arch == 'true'
|
||||
uses: home-assistant/builder@2023.12.0
|
||||
uses: home-assistant/builder@2024.01.0
|
||||
with:
|
||||
args: |
|
||||
${{ env.BUILD_ARGS }} \
|
||||
|
||||
@@ -971,27 +971,37 @@
|
||||
</value>
|
||||
</block>
|
||||
</value>
|
||||
<value name="VALUE">
|
||||
<shadow type="logic_boolean" id="I4PsJQb;6k+70^g*Xt/}">
|
||||
<field name="BOOL">TRUE</field>
|
||||
</shadow>
|
||||
<block type="convert_tostring" id="g{jZOA*6Clhc5`9::h.S">
|
||||
<value name="VALUE">
|
||||
<block type="math_random_int" id="SXG?j1]Jza!2fg[(cl!i">
|
||||
<value name="FROM">
|
||||
<shadow type="math_number" id="#/-;$~`{=}8wYY$kbvA9">
|
||||
<field name="NUM">1</field>
|
||||
</shadow>
|
||||
</value>
|
||||
<value name="TO">
|
||||
<shadow type="math_number" id="0x8~a;asHsiJ2Its%!VJ">
|
||||
<field name="NUM">100</field>
|
||||
</shadow>
|
||||
</value>
|
||||
</block>
|
||||
</value>
|
||||
</block>
|
||||
</value>
|
||||
<value name="VALUE">
|
||||
<shadow type="logic_boolean" id="I4PsJQb;6k+70^g*Xt/}">
|
||||
<field name="BOOL">TRUE</field>
|
||||
</shadow>
|
||||
<block type="text_join" id="XdhGC7#MxGw|KhC1x#MY">
|
||||
<mutation items="2"></mutation>
|
||||
<value name="ADD0">
|
||||
<block type="text" id="[(_1;{xE-xfzeB4]$uk;">
|
||||
<field name="TEXT">ID</field>
|
||||
</block>
|
||||
</value>
|
||||
<value name="ADD1">
|
||||
<block type="convert_tostring" id="g{jZOA*6Clhc5`9::h.S">
|
||||
<value name="VALUE">
|
||||
<block type="math_random_int" id="SXG?j1]Jza!2fg[(cl!i">
|
||||
<value name="FROM">
|
||||
<shadow type="math_number" id="#/-;$~`{=}8wYY$kbvA9">
|
||||
<field name="NUM">1</field>
|
||||
</shadow>
|
||||
</value>
|
||||
<value name="TO">
|
||||
<shadow type="math_number" id="0x8~a;asHsiJ2Its%!VJ">
|
||||
<field name="NUM">100</field>
|
||||
</shadow>
|
||||
</value>
|
||||
</block>
|
||||
</value>
|
||||
</block>
|
||||
</value>
|
||||
</block>
|
||||
</value>
|
||||
<value name="DELAY_MS">
|
||||
<shadow type="math_number" id="+6#n%fO}e4h%;FhKPV0c">
|
||||
<field name="NUM">0</field>
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*-----------------------------------------------------------------------
|
||||
TypeScript v4.3.3.33 zur Steuerung des SONOFF NSPanel mit dem ioBroker by @Armilar / @TT-Tom / @ticaki / @Britzelpuf / @Sternmiere / @ravenS0ne
|
||||
TypeScript v4.3.3.34 zur Steuerung des SONOFF NSPanel mit dem ioBroker by @Armilar / @TT-Tom / @ticaki / @Britzelpuf / @Sternmiere / @ravenS0ne
|
||||
- abgestimmt auf TFT 53 / v4.3.3 / BerryDriver 9 / Tasmota 13.3.0
|
||||
@joBr99 Projekt: https://github.com/joBr99/nspanel-lovelace-ui/tree/main/ioBroker
|
||||
NsPanelTs.ts (dieses TypeScript in ioBroker) Stable: https://github.com/joBr99/nspanel-lovelace-ui/blob/main/ioBroker/NsPanelTs.ts
|
||||
@@ -31,20 +31,8 @@ https://github.com/joBr99/nspanel-lovelace-ui/wiki/iobroker---Basisinstallation#
|
||||
|
||||
ReleaseNotes:
|
||||
Bugfixes und Erweiterungen:
|
||||
|
||||
- 17.09.2023 - v4.3.1 Upgrade TFT 53 / 4.3.1
|
||||
- 17.09.2023 - v4.3.1.1 Add Parameter fontSize (0-4) to cardGrid (with useValue)
|
||||
- 23.09.2023 - v4.3.1.2 Upgrade BerryDriver v9
|
||||
- 23.09.2023 - v4.3.1.3 Fix - Change ServivceMenu from Fake-SSId to real Tasmota-SSIdParam
|
||||
- 03.10.2023 - v4.3.1.4 Removing the examples from the NSPanelTs.ts --> https://github.com/joBr99/nspanel-lovelace-ui/wiki/NSPanel-Page-%E2%80%90-Typen_How-2_Beispiele
|
||||
- 03.10.2023 - v4.3.1.4 Delete NsPanelTs_without_Examples.ts
|
||||
- 12.10.2023 - v4.3.1.5 Fix Datapoint for Role timetable -> Attention use new script from TT-Tom https://github.com/tt-tom17/MyScripts/blob/main/Sonoff_NSPanel/Fahrplan_to_NSPanel.ts
|
||||
- 19.10.2023 - v4.3.1.6 Add more Alias Device-Types to Navigation / Minor Fixes
|
||||
- 22.10.2023 - v4.3.1.7 Fix CreateEntity (navigate) role 'light' and 'socket' and 'temperature'
|
||||
- 30.10.2023 - v4.3.2 Upgrade TFT 53 / 4.3.2
|
||||
- 30.10.2023 - v4.3.2.1 Fix formatDate/Date.parse with moment.js (Bugs in JS-Methodes)
|
||||
- 07.11.2023 - v4.3.2.2 Fix Selection of screensaver layout (alternative / advanced)
|
||||
- 08.11.2023 - v4.3.2.3 Fix Issues #1013 by laluz742 -> Parameter count mismatch: screensaver color
|
||||
See ChangeLog all Release Notes: https://github.com/joBr99/nspanel-lovelace-ui/wiki/Release-Notes
|
||||
|
||||
- 08.11.2023 - v4.3.3 Upgrade TFT 53 / 4.3.3
|
||||
- 11.11.2023 - v4.3.3.1 Fix for Issues #1020 HandleHardwareButton buttonConfig.mode -> 'toggle' and 'set'
|
||||
- 12.11.2023 - v4.3.3.2 Add autoCreateALias to cardUnlock
|
||||
@@ -103,7 +91,9 @@ ReleaseNotes:
|
||||
- 05.01.2024 - v4.3.3.32 Add Body for BoseSoundtouch-Player
|
||||
- 05.01.2024 - v4.3.3.33 Add BoseSoundtouch Functions
|
||||
- 05.01.2024 - v4.3.3.33 Screensaver Fix max Number of indicatorScreensaverEntity
|
||||
|
||||
- 07.01.2024 - v4.3.3.33 Fix BoseSoundtouch Proto
|
||||
- 08.01.2024 - v4.3.3.34 Fix: Disabled Icon Status while bug in updating data points in ioBroker (reason unknown)
|
||||
|
||||
Todo:
|
||||
- XX.XX.XXXX - v5.0.0 Change the bottomScreensaverEntity (rolling) if more than 6 entries are defined
|
||||
|
||||
@@ -966,7 +956,7 @@ export const config: Config = {
|
||||
// _________________________________ DE: Ab hier keine Konfiguration mehr _____________________________________
|
||||
// _________________________________ EN: No more configuration from here _____________________________________
|
||||
|
||||
const scriptVersion: string = 'v4.3.3.33';
|
||||
const scriptVersion: string = 'v4.3.3.34';
|
||||
const tft_version: string = 'v4.3.3';
|
||||
const desired_display_firmware_version = 53;
|
||||
const berry_driver_version = 9;
|
||||
@@ -3770,13 +3760,18 @@ function CreateEntity(pageItem: PageItem, placeId: number, useColors: boolean =
|
||||
if (Debug) log('min_Level: ' + min_Level, 'info');
|
||||
if (Debug) log('max_Level: ' + max_Level, 'info');
|
||||
|
||||
let icon_up_status = 'enable';
|
||||
let icon_down_status = 'enable';
|
||||
|
||||
let tempVal: number = getState(pageItem.id + '.ACTUAL').val
|
||||
let icon_up_status = tempVal === min_Level ? 'disable' : 'enable';
|
||||
|
||||
//Disabled Status while bug in updating origin adapter data points of lift values
|
||||
//let icon_up_status = tempVal === min_Level ? 'disable' : 'enable';
|
||||
let icon_stop_status = 'enable';
|
||||
if (tempVal === min_Level || tempVal === max_Level || checkBlindActive === false) {
|
||||
icon_stop_status = 'disable';
|
||||
//icon_stop_status = 'disable';
|
||||
}
|
||||
let icon_down_status = tempVal === max_Level ? 'disable' : 'enable';
|
||||
//let icon_down_status = tempVal === max_Level ? 'disable' : 'enable';
|
||||
let value = icon_up + '|' + icon_stop + '|' + icon_down + '|' + icon_up_status + '|' + icon_stop_status + '|' + icon_down_status
|
||||
|
||||
if (Debug) log('CreateEntity Icon role blind ~' + type + '~' + placeId + '~' + iconId + '~' + iconColor + '~' + name + '~' + value, 'info');
|
||||
@@ -6872,7 +6867,11 @@ function HandleButtonEvent(words: any): void {
|
||||
case "bosesoundtouch":
|
||||
if (Debug) log('bosesoundtouch - playlist ' + pageItemPL.adapterPlayerInstance + ' - ' + words[4]);
|
||||
if (Debug) log(adapterInstancePL + 'key');
|
||||
setState(adapterInstancePL + 'key', 'PRESET_' + (parseInt(words[4]) + 1));
|
||||
if (words[4] < 6) {
|
||||
setState(adapterInstancePL + 'key', 'PRESET_' + (parseInt(words[4]) + 1));
|
||||
} else if (words[4] == 6) {
|
||||
setState(adapterInstancePL + 'key', 'AUX_INPUT');
|
||||
}
|
||||
break;
|
||||
default:
|
||||
log('Hello Mr. Developer u miss in mode-playlist something!', 'warn');
|
||||
@@ -7026,12 +7025,12 @@ function HandleButtonEvent(words: any): void {
|
||||
case 'mode-insel':
|
||||
setIfExists(id + '.VALUE', parseInt(words[4]));
|
||||
break;
|
||||
case 'media-OnOff':
|
||||
let pageItemTem = findPageItem(id);
|
||||
if (!isPageMediaItem(pageItemTem)) break;
|
||||
let adaInstanceSpli = pageItemTem.adapterPlayerInstance.split('.');
|
||||
if (adaInstanceSpli[0] == 'squeezeboxrpc') {
|
||||
let adapterPlayerInstancePowerSelector: string = [pageItemTem.adapterPlayerInstance, 'Players', pageItemTem.mediaDevice, 'Power'].join('.');
|
||||
case 'media-OnOff': {
|
||||
let pageItemTemp = findPageItem(id);
|
||||
if (!isPageMediaItem(pageItemTemp)) break;
|
||||
let adapterInstance = pageItemTemp.adapterPlayerInstance.split('.');
|
||||
if (adapterInstance[0] == 'squeezeboxrpc') {
|
||||
let adapterPlayerInstancePowerSelector: string = [pageItemTemp.adapterPlayerInstance, 'Players', pageItemTemp.mediaDevice, 'Power'].join('.');
|
||||
let stateVal = getState(adapterPlayerInstancePowerSelector).val;
|
||||
if (stateVal === 0) {
|
||||
setState(adapterPlayerInstancePowerSelector, 1);
|
||||
@@ -7042,11 +7041,14 @@ function HandleButtonEvent(words: any): void {
|
||||
setIfExists(id + '.STOP', true);
|
||||
setIfExists(id + '.STATE', 0);
|
||||
}
|
||||
} else if (adapterInstance[0] == 'bosesoundtouch') {
|
||||
setState(pageItemTemp.adapterPlayerInstance + 'key', 'POWER');
|
||||
} else {
|
||||
setIfExists(id + '.STOP', true);
|
||||
}
|
||||
GeneratePage(activePage!);
|
||||
break;
|
||||
}
|
||||
case 'timer-start':
|
||||
if (words[4] != undefined) {
|
||||
let timer_panel = words[4].split(':');
|
||||
@@ -7799,12 +7801,17 @@ function GenerateDetailPage(type: NSPanel.PopupType, optional: NSPanel.mediaOpti
|
||||
let icon_stop = Icons.GetIcon('stop');
|
||||
let icon_down = Icons.GetIcon('arrow-down');
|
||||
let tempVal: number = getState(pageItem.id + '.ACTUAL').val
|
||||
let icon_up_status = tempVal === min_Level ? 'disable' : 'enable';
|
||||
|
||||
//Disabled Status while bug in updating origin adapter data points of lift values
|
||||
let icon_up_status = 'enable';
|
||||
//let icon_up_status = tempVal === min_Level ? 'disable' : 'enable';
|
||||
let icon_stop_status = 'enable';
|
||||
if (tempVal === min_Level || tempVal === max_Level || checkBlindActive === false) {
|
||||
icon_stop_status = 'disable';
|
||||
//icon_stop_status = 'disable';
|
||||
}
|
||||
let icon_down_status = tempVal === max_Level ? 'disable' : 'enable';
|
||||
let icon_down_status = 'enable';
|
||||
//let icon_down_status = tempVal === max_Level ? 'disable' : 'enable';
|
||||
|
||||
let textTilt = '';
|
||||
let iconTiltLeft = '';
|
||||
let iconTiltStop = '';
|
||||
@@ -7833,7 +7840,7 @@ function GenerateDetailPage(type: NSPanel.PopupType, optional: NSPanel.mediaOpti
|
||||
|
||||
out_msgs.push({
|
||||
payload: 'entityUpdateDetail' + '~' //entityUpdateDetail
|
||||
+ tempId + '~' //entity_id
|
||||
+ tempId + '~' //entity_id
|
||||
+ val + '~' //Shutterposition
|
||||
+ textSecondRow + '~' //pos_status 2.line
|
||||
+ findLocale('blinds', 'Position') + '~' //pos_translation
|
||||
@@ -8122,6 +8129,7 @@ function GenerateDetailPage(type: NSPanel.PopupType, optional: NSPanel.mediaOpti
|
||||
tempPlayList[i - 1] = formatInSelText(vPreset.replace('_',' '));
|
||||
if (Debug) log(formatInSelText(vPreset.replace('_',' ')))
|
||||
}
|
||||
tempPlayList[6] = 'AUX INPUT';
|
||||
optionalString = pageItem.playList != undefined ? tempPlayList.join('?') : ''
|
||||
} else if (vAdapter == 'sonos') {
|
||||
if (Debug) log(pageItem.adapterPlayerInstance + 'root.' + pageItem.mediaDevice + '.playlist_set', 'info');
|
||||
@@ -8586,6 +8594,7 @@ function HandleScreensaverUpdate(): void {
|
||||
|
||||
//Alternativ Layout bekommt zusätzlichen Status
|
||||
if (config.bottomScreensaverEntity[4] && getState(NSPanel_Path + 'Config.Screensaver.alternativeScreensaverLayout').val) {
|
||||
log('alternativ');
|
||||
let val = getState(config.bottomScreensaverEntity[4].ScreensaverEntity).val;
|
||||
if (parseFloat(val+"") == val) {
|
||||
val = parseFloat(val);
|
||||
|
||||
Reference in New Issue
Block a user