@camstack/addon-provider-homematic 1.2.197 → 1.2.198
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/dist/.bundle-modules.json +10 -4
- package/dist/_stub.js +2132 -1567
- package/dist/{_virtual_mf-localSharedImportMap___mfe_internal__addon_provider_homematic_page-C4Fww_oV.mjs → _virtual_mf-localSharedImportMap___mfe_internal__addon_provider_homematic_page-Dn1q938b.mjs} +4 -4
- package/dist/_virtual_mf___mfe_internal__addon_provider_homematic_page__loadShare___mf_0_camstack_mf_1_ui_mf_2_library__loadShare__.js-JVtI9IQh.mjs +26 -0
- package/dist/addon-provider-homematic.css +1 -1
- package/dist/addon.js +1899 -1506
- package/dist/addon.mjs +1900 -1507
- package/dist/{hostInit-DTPxs8RG.mjs → hostInit-Bn44sNXl.mjs} +3 -3
- package/dist/index.mjs +1 -1
- package/dist/remoteEntry.js +1 -1
- package/dist/{virtual_mf-REMOTE_ENTRY_ID___mfe_internal__addon_provider_homematic_page__remoteEntry_js-DSDGvcoJ.mjs → virtual_mf-REMOTE_ENTRY_ID___mfe_internal__addon_provider_homematic_page__remoteEntry_js-Lmec5QIi.mjs} +1 -1
- package/dist/widgets/_stub.js +208 -57
- package/dist/widgets/{_virtual_mf-localSharedImportMap___mfe_internal__addon_provider_homematic_widgets-p7WFaZQH.mjs → _virtual_mf-localSharedImportMap___mfe_internal__addon_provider_homematic_widgets-CRu7ZKE2.mjs} +2 -2
- package/dist/widgets/_virtual_mf___mfe_internal__addon_provider_homematic_widgets__loadShare___mf_0_camstack_mf_1_ui_mf_2_library__loadShare__.js-BEMWyRfG.mjs +26 -0
- package/dist/widgets/{hostInit-CtVv-2Cj.mjs → hostInit-oD-DrYN6.mjs} +2 -2
- package/dist/widgets/remoteEntry.js +1 -1
- package/package.json +3 -3
- package/dist/_virtual_mf___mfe_internal__addon_provider_homematic_page__loadShare___mf_0_camstack_mf_1_ui_mf_2_library__loadShare__.js-D0unHZPY.mjs +0 -26
- package/dist/widgets/_virtual_mf___mfe_internal__addon_provider_homematic_widgets__loadShare___mf_0_camstack_mf_1_ui_mf_2_library__loadShare__.js-C7ks8wIZ.mjs +0 -26
|
@@ -45,7 +45,7 @@ async function r() {
|
|
|
45
45
|
}
|
|
46
46
|
},
|
|
47
47
|
"@camstack/types": {
|
|
48
|
-
version: "1.2.
|
|
48
|
+
version: "1.2.564",
|
|
49
49
|
scope: "default",
|
|
50
50
|
shareConfig: {
|
|
51
51
|
singleton: !0,
|
|
@@ -81,11 +81,11 @@ async function r() {
|
|
|
81
81
|
}
|
|
82
82
|
},
|
|
83
83
|
"@camstack/ui-library": {
|
|
84
|
-
version: "1.2.
|
|
84
|
+
version: "1.2.441",
|
|
85
85
|
scope: "default",
|
|
86
86
|
shareConfig: {
|
|
87
87
|
singleton: !0,
|
|
88
|
-
requiredVersion: ">=1.2.
|
|
88
|
+
requiredVersion: ">=1.2.441",
|
|
89
89
|
import: !1
|
|
90
90
|
}
|
|
91
91
|
},
|
package/dist/index.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { HomematicProviderAddon, a as
|
|
1
|
+
import { HomematicProviderAddon, a as toHomematicOptions, c as mapHmChannel, i as homematicGatewayDeviceSchema, l as mapHmDeviceChannels, n as connectionFromSettings, o as deriveHmEntitySpecs, r as homematicConfigSchema, s as inferHmDeviceType, t as buildConnectionFormSchema } from "./addon.mjs";
|
|
2
2
|
export { HomematicProviderAddon, buildConnectionFormSchema, connectionFromSettings, deriveHmEntitySpecs, homematicConfigSchema, homematicGatewayDeviceSchema, inferHmDeviceType, mapHmChannel, mapHmDeviceChannels, toHomematicOptions };
|
package/dist/remoteEntry.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as e, t } from "./virtual_mf-REMOTE_ENTRY_ID___mfe_internal__addon_provider_homematic_page__remoteEntry_js-
|
|
1
|
+
import { n as e, t } from "./virtual_mf-REMOTE_ENTRY_ID___mfe_internal__addon_provider_homematic_page__remoteEntry_js-Lmec5QIi.mjs";
|
|
2
2
|
export { t as get, e as init };
|
|
@@ -2753,7 +2753,7 @@ async function rr(e) {
|
|
|
2753
2753
|
}
|
|
2754
2754
|
}
|
|
2755
2755
|
async function ir() {
|
|
2756
|
-
return tr ||= rr(() => import("./_virtual_mf-localSharedImportMap___mfe_internal__addon_provider_homematic_page-
|
|
2756
|
+
return tr ||= rr(() => import("./_virtual_mf-localSharedImportMap___mfe_internal__addon_provider_homematic_page-Dn1q938b.mjs")).catch((e) => {
|
|
2757
2757
|
throw tr = void 0, e;
|
|
2758
2758
|
}), tr;
|
|
2759
2759
|
}
|
package/dist/widgets/_stub.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as e, c as t, d as n, f as r, i, l as a, n as o, o as s, p as c, r as l, s as u, t as d, u as f } from "./_virtual_mf___mfe_internal__addon_provider_homematic_widgets__loadShare___mf_0_camstack_mf_1_ui_mf_2_library__loadShare__.js-
|
|
1
|
+
import { a as e, c as t, d as n, f as r, i, l as a, n as o, o as s, p as c, r as l, s as u, t as d, u as f } from "./_virtual_mf___mfe_internal__addon_provider_homematic_widgets__loadShare___mf_0_camstack_mf_1_ui_mf_2_library__loadShare__.js-BEMWyRfG.mjs";
|
|
2
2
|
import { a as p, i as m, n as h, o as ee, r as g, s as _, t as v } from "./_virtual_mf___mfe_internal__addon_provider_homematic_widgets__loadShare__react__loadShare__.js-Cz6ebdBh.mjs";
|
|
3
3
|
import { n as y, t as b } from "./_virtual_mf___mfe_internal__addon_provider_homematic_widgets__loadShare__react_mf_1_jsx_mf_2_runtime__loadShare__.js-B8RWlLTT.mjs";
|
|
4
4
|
//#region ../../node_modules/zod/v4/core/core.js
|
|
@@ -3571,6 +3571,37 @@ Y({
|
|
|
3571
3571
|
senders: J(qo),
|
|
3572
3572
|
receivers: J(qo),
|
|
3573
3573
|
failures: J(Yo)
|
|
3574
|
+
});
|
|
3575
|
+
var Xo = Y({
|
|
3576
|
+
address: W(),
|
|
3577
|
+
channelName: W().nullable(),
|
|
3578
|
+
deviceName: W().nullable(),
|
|
3579
|
+
deviceId: K().int().nullable()
|
|
3580
|
+
}), Zo = Y({
|
|
3581
|
+
id: W(),
|
|
3582
|
+
name: W(),
|
|
3583
|
+
active: q(),
|
|
3584
|
+
internal: q(),
|
|
3585
|
+
lastRunMs: K().nullable(),
|
|
3586
|
+
createdByCamstack: q(),
|
|
3587
|
+
channels: J(Xo)
|
|
3588
|
+
}), Qo = Y({
|
|
3589
|
+
address: W(),
|
|
3590
|
+
name: W().nullable(),
|
|
3591
|
+
deviceAddress: W(),
|
|
3592
|
+
deviceName: W().nullable(),
|
|
3593
|
+
deviceType: W()
|
|
3594
|
+
});
|
|
3595
|
+
Y({
|
|
3596
|
+
programs: J(Zo),
|
|
3597
|
+
keys: J(Qo)
|
|
3598
|
+
}), Z.extend({
|
|
3599
|
+
programId: W().min(1),
|
|
3600
|
+
confirmed: Q
|
|
3601
|
+
}).extend({ active: q() }), Z.extend({
|
|
3602
|
+
deviceAddress: W().min(1),
|
|
3603
|
+
channelAddresses: J(W().min(1)).min(1),
|
|
3604
|
+
confirmed: Q
|
|
3574
3605
|
}), Z.extend({
|
|
3575
3606
|
sender: W().min(1),
|
|
3576
3607
|
receiver: W().min(1),
|
|
@@ -3579,13 +3610,13 @@ Y({
|
|
|
3579
3610
|
short: Go,
|
|
3580
3611
|
long: Go
|
|
3581
3612
|
});
|
|
3582
|
-
var
|
|
3613
|
+
var $o = Y({
|
|
3583
3614
|
address: W(),
|
|
3584
3615
|
name: W()
|
|
3585
3616
|
});
|
|
3586
3617
|
Y({
|
|
3587
|
-
device:
|
|
3588
|
-
channels: J(
|
|
3618
|
+
device: $o,
|
|
3619
|
+
channels: J($o)
|
|
3589
3620
|
}), Z.extend({
|
|
3590
3621
|
address: W().min(1),
|
|
3591
3622
|
name: W(),
|
|
@@ -3620,31 +3651,31 @@ Y({
|
|
|
3620
3651
|
added: J(W()),
|
|
3621
3652
|
removed: J(W())
|
|
3622
3653
|
});
|
|
3623
|
-
var
|
|
3654
|
+
var es = Uo.extend({ readable: q() }), ts = Y({
|
|
3624
3655
|
address: W(),
|
|
3625
3656
|
index: K(),
|
|
3626
3657
|
type: W().nullable(),
|
|
3627
3658
|
name: W().nullable(),
|
|
3628
|
-
values: J(
|
|
3629
|
-
}),
|
|
3659
|
+
values: J(es)
|
|
3660
|
+
}), ns = Y({
|
|
3630
3661
|
rssiDevice: K().nullable(),
|
|
3631
3662
|
rssiPeer: K().nullable(),
|
|
3632
3663
|
unreach: q().nullable(),
|
|
3633
3664
|
lowBattery: q().nullable(),
|
|
3634
3665
|
dutyCycle: za([q(), K()]).nullable(),
|
|
3635
3666
|
configPending: q().nullable()
|
|
3636
|
-
}),
|
|
3667
|
+
}), rs = Y({
|
|
3637
3668
|
installed: W().nullable(),
|
|
3638
3669
|
available: W().nullable(),
|
|
3639
3670
|
updatable: q().nullable(),
|
|
3640
3671
|
state: W().nullable()
|
|
3641
|
-
}),
|
|
3672
|
+
}), is = Y({
|
|
3642
3673
|
address: W(),
|
|
3643
3674
|
name: W().nullable(),
|
|
3644
3675
|
type: W(),
|
|
3645
|
-
firmware:
|
|
3646
|
-
diagnostics:
|
|
3647
|
-
channels: J(
|
|
3676
|
+
firmware: rs,
|
|
3677
|
+
diagnostics: ns,
|
|
3678
|
+
channels: J(ts)
|
|
3648
3679
|
});
|
|
3649
3680
|
Z.extend({
|
|
3650
3681
|
channel: W().min(1),
|
|
@@ -3655,7 +3686,7 @@ Z.extend({
|
|
|
3655
3686
|
});
|
|
3656
3687
|
//#endregion
|
|
3657
3688
|
//#region src/i18n/index.ts
|
|
3658
|
-
var { useT: $, Trans:
|
|
3689
|
+
var { useT: $, Trans: as, translate: os } = c("provider-homematic", {
|
|
3659
3690
|
en: {
|
|
3660
3691
|
common: { loading: "Loading…" },
|
|
3661
3692
|
write: { failedTitle: "The CCU refused the change" },
|
|
@@ -3674,7 +3705,8 @@ var { useT: $, Trans: ns, translate: rs } = c("provider-homematic", {
|
|
|
3674
3705
|
tabHeating: "Heating",
|
|
3675
3706
|
tabPairing: "Pairing",
|
|
3676
3707
|
tabLinks: "Direct links",
|
|
3677
|
-
tabSettings: "Settings"
|
|
3708
|
+
tabSettings: "Settings",
|
|
3709
|
+
tabPrograms: "Programs"
|
|
3678
3710
|
},
|
|
3679
3711
|
overview: {
|
|
3680
3712
|
loadFailed: "Could not read the CCU",
|
|
@@ -3960,6 +3992,65 @@ var { useT: $, Trans: ns, translate: rs } = c("provider-homematic", {
|
|
|
3960
3992
|
pressMessage: "Send {{parameter}} on {{channel}}? Whatever this key is linked to will run.",
|
|
3961
3993
|
writeConfirm: "Send to the CCU",
|
|
3962
3994
|
none: "No values"
|
|
3995
|
+
},
|
|
3996
|
+
programs: {
|
|
3997
|
+
title: "Programs",
|
|
3998
|
+
hint: "A program runs on the CCU. CamStack only creates a key-event program: short and long press, no action.",
|
|
3999
|
+
searchPlaceholder: "Search programs",
|
|
4000
|
+
searchLabel: "Search programs",
|
|
4001
|
+
facetsLabel: "Filter programs",
|
|
4002
|
+
clearFilters: "Clear filters",
|
|
4003
|
+
colName: "Name",
|
|
4004
|
+
colActive: "Active",
|
|
4005
|
+
colLastRun: "Last run",
|
|
4006
|
+
colConditions: "Conditions",
|
|
4007
|
+
colOrigin: "Origin",
|
|
4008
|
+
active: "Active",
|
|
4009
|
+
inactive: "Inactive",
|
|
4010
|
+
camstack: "CamStack",
|
|
4011
|
+
other: "CCU",
|
|
4012
|
+
none: "No programs",
|
|
4013
|
+
noMatch: "No programs match",
|
|
4014
|
+
run: "Run",
|
|
4015
|
+
runTitle: "Run program",
|
|
4016
|
+
runMessage: "Run \"{{name}}\" on the CCU now?",
|
|
4017
|
+
runConfirm: "Run program",
|
|
4018
|
+
enable: "Enable",
|
|
4019
|
+
disable: "Disable",
|
|
4020
|
+
enableTitle: "Enable program",
|
|
4021
|
+
disableTitle: "Disable program",
|
|
4022
|
+
enableMessage: "Enable \"{{name}}\" on the CCU?",
|
|
4023
|
+
disableMessage: "Disable \"{{name}}\" on the CCU? It stops running until you enable it again.",
|
|
4024
|
+
enableConfirm: "Enable program",
|
|
4025
|
+
disableConfirm: "Disable program",
|
|
4026
|
+
delete: "Delete",
|
|
4027
|
+
deleteTitle: "Delete program",
|
|
4028
|
+
deleteMessage: "Delete \"{{name}}\" on the CCU? This cannot be undone.",
|
|
4029
|
+
deleteConfirm: "Delete program",
|
|
4030
|
+
edit: "Edit keys",
|
|
4031
|
+
newProgram: "New key program",
|
|
4032
|
+
saving: "Saving…",
|
|
4033
|
+
saved: "Saved",
|
|
4034
|
+
loadFailed: "Programs could not be loaded",
|
|
4035
|
+
formTitleNew: "New key program",
|
|
4036
|
+
formTitleEdit: "Edit key program",
|
|
4037
|
+
formHint: "Short and long press on each selected key. The program has no action.",
|
|
4038
|
+
fieldDevice: "Button device",
|
|
4039
|
+
fieldKeys: "Keys",
|
|
4040
|
+
fieldKeysHint: "The program listens to these keys only.",
|
|
4041
|
+
pickDevice: "Choose a device",
|
|
4042
|
+
save: "Save",
|
|
4043
|
+
createTitle: "Create key program",
|
|
4044
|
+
createMessage: "Create a key-event program for \"{{name}}\" on the CCU?",
|
|
4045
|
+
createConfirm: "Create program",
|
|
4046
|
+
updateTitle: "Update key program",
|
|
4047
|
+
updateMessage: "Update the keys of \"{{name}}\" on the CCU?",
|
|
4048
|
+
updateConfirm: "Update program",
|
|
4049
|
+
noKeys: "This CCU has no HmIP keys",
|
|
4050
|
+
justNow: "just now",
|
|
4051
|
+
minutesAgo: "{{count}} min ago",
|
|
4052
|
+
hoursAgo: "{{count}} h ago",
|
|
4053
|
+
daysAgo: "{{count}} d ago"
|
|
3963
4054
|
}
|
|
3964
4055
|
},
|
|
3965
4056
|
it: {
|
|
@@ -3980,7 +4071,8 @@ var { useT: $, Trans: ns, translate: rs } = c("provider-homematic", {
|
|
|
3980
4071
|
tabHeating: "Riscaldamento",
|
|
3981
4072
|
tabPairing: "Associazione",
|
|
3982
4073
|
tabLinks: "Collegamenti diretti",
|
|
3983
|
-
tabSettings: "Impostazioni"
|
|
4074
|
+
tabSettings: "Impostazioni",
|
|
4075
|
+
tabPrograms: "Programmi"
|
|
3984
4076
|
},
|
|
3985
4077
|
overview: {
|
|
3986
4078
|
loadFailed: "Impossibile leggere la CCU",
|
|
@@ -4266,12 +4358,71 @@ var { useT: $, Trans: ns, translate: rs } = c("provider-homematic", {
|
|
|
4266
4358
|
pressMessage: "Inviare {{parameter}} su {{channel}}? Verrà eseguito ciò a cui il tasto è collegato.",
|
|
4267
4359
|
writeConfirm: "Invia alla CCU",
|
|
4268
4360
|
none: "Nessun valore"
|
|
4361
|
+
},
|
|
4362
|
+
programs: {
|
|
4363
|
+
title: "Programmi",
|
|
4364
|
+
hint: "Un programma gira sulla CCU. CamStack crea solo un programma di tasti: pressione breve e lunga, senza azione.",
|
|
4365
|
+
searchPlaceholder: "Cerca programmi",
|
|
4366
|
+
searchLabel: "Cerca programmi",
|
|
4367
|
+
facetsLabel: "Filtra programmi",
|
|
4368
|
+
clearFilters: "Azzera filtri",
|
|
4369
|
+
colName: "Nome",
|
|
4370
|
+
colActive: "Attivo",
|
|
4371
|
+
colLastRun: "Ultima esecuzione",
|
|
4372
|
+
colConditions: "Condizioni",
|
|
4373
|
+
colOrigin: "Origine",
|
|
4374
|
+
active: "Attivo",
|
|
4375
|
+
inactive: "Inattivo",
|
|
4376
|
+
camstack: "CamStack",
|
|
4377
|
+
other: "CCU",
|
|
4378
|
+
none: "Nessun programma",
|
|
4379
|
+
noMatch: "Nessun programma corrisponde",
|
|
4380
|
+
run: "Esegui",
|
|
4381
|
+
runTitle: "Esegui programma",
|
|
4382
|
+
runMessage: "Eseguire \"{{name}}\" sulla CCU adesso?",
|
|
4383
|
+
runConfirm: "Esegui programma",
|
|
4384
|
+
enable: "Attiva",
|
|
4385
|
+
disable: "Disattiva",
|
|
4386
|
+
enableTitle: "Attiva programma",
|
|
4387
|
+
disableTitle: "Disattiva programma",
|
|
4388
|
+
enableMessage: "Attivare \"{{name}}\" sulla CCU?",
|
|
4389
|
+
disableMessage: "Disattivare \"{{name}}\" sulla CCU? Non parte finché non lo riattivi.",
|
|
4390
|
+
enableConfirm: "Attiva programma",
|
|
4391
|
+
disableConfirm: "Disattiva programma",
|
|
4392
|
+
delete: "Elimina",
|
|
4393
|
+
deleteTitle: "Elimina programma",
|
|
4394
|
+
deleteMessage: "Eliminare \"{{name}}\" sulla CCU? Operazione non annullabile.",
|
|
4395
|
+
deleteConfirm: "Elimina programma",
|
|
4396
|
+
edit: "Modifica tasti",
|
|
4397
|
+
newProgram: "Nuovo programma tasti",
|
|
4398
|
+
saving: "Salvataggio…",
|
|
4399
|
+
saved: "Salvato",
|
|
4400
|
+
loadFailed: "Impossibile caricare i programmi",
|
|
4401
|
+
formTitleNew: "Nuovo programma tasti",
|
|
4402
|
+
formTitleEdit: "Modifica programma tasti",
|
|
4403
|
+
formHint: "Pressione breve e lunga su ogni tasto scelto. Il programma non ha azioni.",
|
|
4404
|
+
fieldDevice: "Dispositivo tasti",
|
|
4405
|
+
fieldKeys: "Tasti",
|
|
4406
|
+
fieldKeysHint: "Il programma ascolta solo questi tasti.",
|
|
4407
|
+
pickDevice: "Scegli un dispositivo",
|
|
4408
|
+
save: "Salva",
|
|
4409
|
+
createTitle: "Crea programma tasti",
|
|
4410
|
+
createMessage: "Creare un programma di tasti per \"{{name}}\" sulla CCU?",
|
|
4411
|
+
createConfirm: "Crea programma",
|
|
4412
|
+
updateTitle: "Aggiorna programma tasti",
|
|
4413
|
+
updateMessage: "Aggiornare i tasti di \"{{name}}\" sulla CCU?",
|
|
4414
|
+
updateConfirm: "Aggiorna programma",
|
|
4415
|
+
noKeys: "Questa CCU non ha tasti HmIP",
|
|
4416
|
+
justNow: "adesso",
|
|
4417
|
+
minutesAgo: "{{count}} min fa",
|
|
4418
|
+
hoursAgo: "{{count}} h fa",
|
|
4419
|
+
daysAgo: "{{count}} g fa"
|
|
4269
4420
|
}
|
|
4270
4421
|
}
|
|
4271
4422
|
});
|
|
4272
4423
|
//#endregion
|
|
4273
4424
|
//#region src/ui/ParamField.tsx
|
|
4274
|
-
function
|
|
4425
|
+
function ss(e, t) {
|
|
4275
4426
|
if (typeof t == "boolean") return t;
|
|
4276
4427
|
if (e.type === "INTEGER" || e.type === "FLOAT") {
|
|
4277
4428
|
if (t.trim() === "") return;
|
|
@@ -4280,7 +4431,7 @@ function is(e, t) {
|
|
|
4280
4431
|
}
|
|
4281
4432
|
return t;
|
|
4282
4433
|
}
|
|
4283
|
-
function
|
|
4434
|
+
function cs(e) {
|
|
4284
4435
|
let { param: r, edit: i, onEdit: a } = e, { t: o } = $(), s = r.unit === null ? r.parameter : `${r.parameter} (${r.unit})`, c = r.min !== null && r.max !== null ? o("config.range", {
|
|
4285
4436
|
min: r.min,
|
|
4286
4437
|
max: r.max
|
|
@@ -4330,10 +4481,10 @@ function as(e) {
|
|
|
4330
4481
|
}
|
|
4331
4482
|
//#endregion
|
|
4332
4483
|
//#region src/ui/ccu-client.ts
|
|
4333
|
-
var
|
|
4334
|
-
async function
|
|
4484
|
+
var ls = "provider-homematic";
|
|
4485
|
+
async function us(e, t, n, r) {
|
|
4335
4486
|
let i = await e.addons.custom.mutate({
|
|
4336
|
-
addonId:
|
|
4487
|
+
addonId: ls,
|
|
4337
4488
|
action: t,
|
|
4338
4489
|
input: n
|
|
4339
4490
|
});
|
|
@@ -4341,7 +4492,7 @@ async function ss(e, t, n, r) {
|
|
|
4341
4492
|
}
|
|
4342
4493
|
//#endregion
|
|
4343
4494
|
//#region src/ui/use-ccu-data.ts
|
|
4344
|
-
function
|
|
4495
|
+
function ds(e, t, n, r, i = {}) {
|
|
4345
4496
|
let [a, o] = _(void 0), [s, c] = _(null), [l, u] = _(n !== null), [d, f] = _(0), p = ee(0), h = JSON.stringify(n), v = i.pollMs;
|
|
4346
4497
|
return m(() => {
|
|
4347
4498
|
if (n === null) {
|
|
@@ -4349,7 +4500,7 @@ function cs(e, t, n, r, i = {}) {
|
|
|
4349
4500
|
return;
|
|
4350
4501
|
}
|
|
4351
4502
|
let i = ++p.current, a, s = (l) => {
|
|
4352
|
-
l && u(!0),
|
|
4503
|
+
l && u(!0), us(e, t, n, r).then((e) => {
|
|
4353
4504
|
p.current === i && (o(e), c(null), u(!1), v !== void 0 && (a = setTimeout(() => s(!1), v)));
|
|
4354
4505
|
}, (e) => {
|
|
4355
4506
|
p.current === i && (c(e instanceof Error ? e.message : String(e)), u(!1), v !== void 0 && (a = setTimeout(() => s(!1), v)));
|
|
@@ -4374,7 +4525,7 @@ function cs(e, t, n, r, i = {}) {
|
|
|
4374
4525
|
}
|
|
4375
4526
|
//#endregion
|
|
4376
4527
|
//#region src/ui/use-ccu-write.ts
|
|
4377
|
-
function
|
|
4528
|
+
function fs(e) {
|
|
4378
4529
|
let t = l(), n = o(), { t: r } = $();
|
|
4379
4530
|
return g(async (i) => {
|
|
4380
4531
|
if (!await t({
|
|
@@ -4384,7 +4535,7 @@ function ls(e) {
|
|
|
4384
4535
|
variant: i.variant ?? "default"
|
|
4385
4536
|
})) return null;
|
|
4386
4537
|
try {
|
|
4387
|
-
return await
|
|
4538
|
+
return await us(e, i.action, {
|
|
4388
4539
|
...i.input,
|
|
4389
4540
|
confirmed: !0
|
|
4390
4541
|
}, i.schema);
|
|
@@ -4404,8 +4555,8 @@ function ls(e) {
|
|
|
4404
4555
|
}
|
|
4405
4556
|
//#endregion
|
|
4406
4557
|
//#region src/ui/ChannelConfigDialog.tsx
|
|
4407
|
-
function
|
|
4408
|
-
let { trpc: t, integrationId: i, device: o, onClose: c } = e, { t: l } = $(), d =
|
|
4558
|
+
function ps(e) {
|
|
4559
|
+
let { trpc: t, integrationId: i, device: o, onClose: c } = e, { t: l } = $(), d = fs(t), f = ds(t, "getCcuDeviceConfig", p(() => ({
|
|
4409
4560
|
integrationId: i,
|
|
4410
4561
|
address: o.address
|
|
4411
4562
|
}), [i, o.address]), Wo), [m, h] = _(null), [ee, g] = _({}), [v, x] = _(!1), S = f.data?.channels ?? [], C = S.find((e) => e.channel === m) ?? S[0], te = p(() => {
|
|
@@ -4413,7 +4564,7 @@ function us(e) {
|
|
|
4413
4564
|
for (let t of C?.params ?? []) {
|
|
4414
4565
|
let n = ee[`${C?.channel}/${t.parameter}`];
|
|
4415
4566
|
if (n === void 0) continue;
|
|
4416
|
-
let r =
|
|
4567
|
+
let r = ss(t, n);
|
|
4417
4568
|
r !== void 0 && r !== t.value && (e[t.parameter] = r);
|
|
4418
4569
|
}
|
|
4419
4570
|
return e;
|
|
@@ -4482,7 +4633,7 @@ function us(e) {
|
|
|
4482
4633
|
className: "text-xs text-danger",
|
|
4483
4634
|
children: l("config.valuesUnreadable", { error: C.error })
|
|
4484
4635
|
}),
|
|
4485
|
-
C.params.map((e) => /* @__PURE__ */ b(
|
|
4636
|
+
C.params.map((e) => /* @__PURE__ */ b(cs, {
|
|
4486
4637
|
param: e,
|
|
4487
4638
|
edit: ee[`${C.channel}/${e.parameter}`],
|
|
4488
4639
|
onEdit: (t) => g((n) => ({
|
|
@@ -4500,28 +4651,28 @@ function us(e) {
|
|
|
4500
4651
|
}
|
|
4501
4652
|
//#endregion
|
|
4502
4653
|
//#region src/ui/value-format.ts
|
|
4503
|
-
function
|
|
4654
|
+
function ms(e) {
|
|
4504
4655
|
return e.type !== "ENUM" || e.valueList === null || typeof e.value != "number" ? e : {
|
|
4505
4656
|
...e,
|
|
4506
4657
|
value: e.valueList[e.value] ?? null
|
|
4507
4658
|
};
|
|
4508
4659
|
}
|
|
4509
|
-
function
|
|
4660
|
+
function hs(e, t) {
|
|
4510
4661
|
if (e.type === "ENUM" && e.valueList !== null && typeof t == "string") {
|
|
4511
4662
|
let n = e.valueList.indexOf(t);
|
|
4512
4663
|
return n < 0 ? void 0 : n;
|
|
4513
4664
|
}
|
|
4514
|
-
return
|
|
4665
|
+
return ss(e, t);
|
|
4515
4666
|
}
|
|
4516
|
-
function
|
|
4667
|
+
function gs(e) {
|
|
4517
4668
|
if (!e.readable || e.value === null || typeof e.value == "boolean") return null;
|
|
4518
|
-
let t =
|
|
4669
|
+
let t = ms(e).value;
|
|
4519
4670
|
return t === null ? null : e.unit === null || e.unit === "" ? String(t) : `${String(t)} ${e.unit}`;
|
|
4520
4671
|
}
|
|
4521
4672
|
//#endregion
|
|
4522
4673
|
//#region src/ui/SetValueDialog.tsx
|
|
4523
|
-
function
|
|
4524
|
-
let { param: t, channelLabel: n, onClose: i, onSet: o } = e, { t: s } = $(), [c, l] = _(void 0), [u, d] = _(!1), f = c === void 0 ? void 0 :
|
|
4674
|
+
function _s(e) {
|
|
4675
|
+
let { param: t, channelLabel: n, onClose: i, onSet: o } = e, { t: s } = $(), [c, l] = _(void 0), [u, d] = _(!1), f = c === void 0 ? void 0 : hs(t, c), p = async () => {
|
|
4525
4676
|
if (f !== void 0) {
|
|
4526
4677
|
d(!0);
|
|
4527
4678
|
try {
|
|
@@ -4546,8 +4697,8 @@ function ms(e) {
|
|
|
4546
4697
|
disabled: f === void 0 || u,
|
|
4547
4698
|
children: s("panel.set")
|
|
4548
4699
|
}),
|
|
4549
|
-
children: /* @__PURE__ */ b(
|
|
4550
|
-
param:
|
|
4700
|
+
children: /* @__PURE__ */ b(cs, {
|
|
4701
|
+
param: ms(t),
|
|
4551
4702
|
edit: c,
|
|
4552
4703
|
onEdit: l
|
|
4553
4704
|
})
|
|
@@ -4555,10 +4706,10 @@ function ms(e) {
|
|
|
4555
4706
|
}
|
|
4556
4707
|
//#endregion
|
|
4557
4708
|
//#region src/ui/DevicePanel.tsx
|
|
4558
|
-
function
|
|
4709
|
+
function vs(e) {
|
|
4559
4710
|
return e.name ?? `${e.type ?? e.address} · ${e.index}`;
|
|
4560
4711
|
}
|
|
4561
|
-
function
|
|
4712
|
+
function ys(e) {
|
|
4562
4713
|
let { diagnostics: t, firmware: n } = e.state, { t: r } = $(), i = (e) => e === null ? "—" : String(e);
|
|
4563
4714
|
return /* @__PURE__ */ y("div", {
|
|
4564
4715
|
className: "flex flex-wrap items-center gap-2",
|
|
@@ -4593,12 +4744,12 @@ function gs(e) {
|
|
|
4593
4744
|
]
|
|
4594
4745
|
});
|
|
4595
4746
|
}
|
|
4596
|
-
function
|
|
4597
|
-
let { trpc: t, integrationId: n, address: a, deviceId: o } = e, { t: c } = $(), l =
|
|
4747
|
+
function bs(e) {
|
|
4748
|
+
let { trpc: t, integrationId: n, address: a, deviceId: o } = e, { t: c } = $(), l = ds(t, "getCcuDeviceState", p(() => ({
|
|
4598
4749
|
integrationId: n,
|
|
4599
4750
|
address: a
|
|
4600
|
-
}), [n, a]),
|
|
4601
|
-
let i = t.type === "ACTION", a =
|
|
4751
|
+
}), [n, a]), is), u = fs(t), [d, m] = _({ kind: "closed" }), h = async (e, t, r) => {
|
|
4752
|
+
let i = t.type === "ACTION", a = ms({
|
|
4602
4753
|
...t,
|
|
4603
4754
|
value: r
|
|
4604
4755
|
}).value;
|
|
@@ -4615,10 +4766,10 @@ function _s(e) {
|
|
|
4615
4766
|
title: c("panel.writeTitle"),
|
|
4616
4767
|
message: i ? c("panel.pressMessage", {
|
|
4617
4768
|
parameter: t.parameter,
|
|
4618
|
-
channel:
|
|
4769
|
+
channel: vs(e)
|
|
4619
4770
|
}) : c("panel.writeMessage", {
|
|
4620
4771
|
parameter: t.parameter,
|
|
4621
|
-
channel:
|
|
4772
|
+
channel: vs(e),
|
|
4622
4773
|
value: String(a)
|
|
4623
4774
|
}),
|
|
4624
4775
|
confirmLabel: c("panel.writeConfirm"),
|
|
@@ -4659,7 +4810,7 @@ function _s(e) {
|
|
|
4659
4810
|
children: e.value ? c("panel.yes") : c("panel.no")
|
|
4660
4811
|
}) : /* @__PURE__ */ b("span", {
|
|
4661
4812
|
className: "text-sm text-foreground",
|
|
4662
|
-
children:
|
|
4813
|
+
children: gs(e) ?? "—"
|
|
4663
4814
|
}), v = (e) => [
|
|
4664
4815
|
{
|
|
4665
4816
|
key: "parameter",
|
|
@@ -4722,13 +4873,13 @@ function _s(e) {
|
|
|
4722
4873
|
})]
|
|
4723
4874
|
})]
|
|
4724
4875
|
}),
|
|
4725
|
-
/* @__PURE__ */ b(
|
|
4876
|
+
/* @__PURE__ */ b(ys, { state: x }),
|
|
4726
4877
|
x.channels.filter((e) => e.values.length > 0).map((e) => /* @__PURE__ */ y("div", {
|
|
4727
4878
|
className: "flex flex-col gap-1",
|
|
4728
4879
|
children: [/* @__PURE__ */ y("span", {
|
|
4729
4880
|
className: "text-xs font-medium text-foreground-muted",
|
|
4730
4881
|
children: [
|
|
4731
|
-
e.index === 0 ? c("panel.maintenance") :
|
|
4882
|
+
e.index === 0 ? c("panel.maintenance") : vs(e),
|
|
4732
4883
|
" ·",
|
|
4733
4884
|
" ",
|
|
4734
4885
|
e.address
|
|
@@ -4741,7 +4892,7 @@ function _s(e) {
|
|
|
4741
4892
|
emptyMessage: c("panel.none")
|
|
4742
4893
|
})]
|
|
4743
4894
|
}, e.address)),
|
|
4744
|
-
d.kind === "configure" && /* @__PURE__ */ b(
|
|
4895
|
+
d.kind === "configure" && /* @__PURE__ */ b(ps, {
|
|
4745
4896
|
trpc: t,
|
|
4746
4897
|
integrationId: n,
|
|
4747
4898
|
device: {
|
|
@@ -4750,9 +4901,9 @@ function _s(e) {
|
|
|
4750
4901
|
},
|
|
4751
4902
|
onClose: () => m({ kind: "closed" })
|
|
4752
4903
|
}),
|
|
4753
|
-
d.kind === "set" && /* @__PURE__ */ b(
|
|
4904
|
+
d.kind === "set" && /* @__PURE__ */ b(_s, {
|
|
4754
4905
|
param: d.param,
|
|
4755
|
-
channelLabel:
|
|
4906
|
+
channelLabel: vs(d.channel),
|
|
4756
4907
|
onClose: () => m({ kind: "closed" }),
|
|
4757
4908
|
onSet: async (e) => {
|
|
4758
4909
|
await h(d.channel, d.param, e) && m({ kind: "closed" });
|
|
@@ -4763,13 +4914,13 @@ function _s(e) {
|
|
|
4763
4914
|
}
|
|
4764
4915
|
//#endregion
|
|
4765
4916
|
//#region src/widgets/DevicePanelWidget.tsx
|
|
4766
|
-
var
|
|
4917
|
+
var xs = Y({
|
|
4767
4918
|
integrationId: W().min(1),
|
|
4768
4919
|
address: W().min(1)
|
|
4769
4920
|
});
|
|
4770
|
-
function
|
|
4771
|
-
let n = e(), { t: r } = $(), i =
|
|
4772
|
-
return i.success ? /* @__PURE__ */ b(
|
|
4921
|
+
function Ss(t) {
|
|
4922
|
+
let n = e(), { t: r } = $(), i = xs.safeParse(t.config ?? {});
|
|
4923
|
+
return i.success ? /* @__PURE__ */ b(bs, {
|
|
4773
4924
|
trpc: n,
|
|
4774
4925
|
integrationId: i.data.integrationId,
|
|
4775
4926
|
address: i.data.address,
|
|
@@ -4781,6 +4932,6 @@ function ys(t) {
|
|
|
4781
4932
|
}
|
|
4782
4933
|
//#endregion
|
|
4783
4934
|
//#region src/widgets/index.tsx
|
|
4784
|
-
var
|
|
4935
|
+
var Cs = { "device-panel": Ss };
|
|
4785
4936
|
//#endregion
|
|
4786
|
-
export {
|
|
4937
|
+
export { Cs as default };
|
|
@@ -18,7 +18,7 @@ var e = {
|
|
|
18
18
|
},
|
|
19
19
|
"@camstack/types": {
|
|
20
20
|
name: "@camstack/types",
|
|
21
|
-
version: "1.2.
|
|
21
|
+
version: "1.2.564",
|
|
22
22
|
scope: ["default"],
|
|
23
23
|
loaded: !1,
|
|
24
24
|
from: "addon_provider_homematic_widgets",
|
|
@@ -33,7 +33,7 @@ var e = {
|
|
|
33
33
|
},
|
|
34
34
|
"@camstack/ui-library": {
|
|
35
35
|
name: "@camstack/ui-library",
|
|
36
|
-
version: "1.2.
|
|
36
|
+
version: "1.2.441",
|
|
37
37
|
scope: ["default"],
|
|
38
38
|
loaded: !1,
|
|
39
39
|
from: "addon_provider_homematic_widgets",
|