@camstack/addon-training 0.1.92 → 0.1.94

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.
Files changed (23) hide show
  1. package/CHANGELOG.md +10 -1
  2. package/README.md +18 -12
  3. package/dist/{MotionZonesSettings-Cli21_S4.mjs → MotionZonesSettings-BDIz0ADl.mjs} +2 -2
  4. package/dist/{PrivacyMaskSettings-BqMnLgR4.mjs → PrivacyMaskSettings-Cz_1itEY.mjs} +2 -2
  5. package/dist/{SceneMonitorEditor-TOlMkkSx.mjs → SceneMonitorEditor-DxdQN6e5.mjs} +119 -120
  6. package/dist/_stub.js +5295 -5310
  7. package/dist/{_virtual_mf-localSharedImportMap___mfe_internal__addon_training_page-Ki3rRnXi.mjs → _virtual_mf-localSharedImportMap___mfe_internal__addon_training_page-DcGxW0BQ.mjs} +4 -4
  8. package/dist/{_virtual_mf___mfe_internal__addon_training_page__loadShare___mf_0_camstack_mf_1_types__loadShare__.js-COkV6wxS.mjs → _virtual_mf___mfe_internal__addon_training_page__loadShare___mf_0_camstack_mf_1_types__loadShare__.js-B6wwfPOo.mjs} +1 -1
  9. package/dist/addon-training.css +1 -1
  10. package/dist/{dist-BYGiAfO5.js → dist-C_f7s2st.js} +38 -7
  11. package/dist/{dist-BLeIfxL-.mjs → dist-mC0XNhcx.mjs} +38 -7
  12. package/dist/{hostInit-SSLNnzqp.mjs → hostInit-DPLOK7Fx.mjs} +3 -3
  13. package/dist/index.js +1 -1
  14. package/dist/orchestrator/training.addon.js +1 -1
  15. package/dist/orchestrator/training.addon.mjs +1 -1
  16. package/dist/{player-overlays-CpnLw8Tf.mjs → player-overlays-ClwLHxNP.mjs} +1 -1
  17. package/dist/providers/modal/training-modal.addon.js +1 -1
  18. package/dist/providers/modal/training-modal.addon.mjs +1 -1
  19. package/dist/remoteEntry.js +1 -1
  20. package/dist/{responsive-wZ7jMF7F.mjs → responsive-Cx4quvGq.mjs} +1 -1
  21. package/dist/{scene-monitor-copy-Cqfs4Vng.mjs → scene-monitor-copy-DIJUg8Ro.mjs} +63 -46
  22. package/dist/{virtual_mf-REMOTE_ENTRY_ID___mfe_internal__addon_training_page__remoteEntry_js-CG3LeBz1.mjs → virtual_mf-REMOTE_ENTRY_ID___mfe_internal__addon_training_page__remoteEntry_js-Ch6HQCmx.mjs} +1 -1
  23. package/package.json +2 -2
@@ -17436,7 +17436,22 @@ var BrokerProviderInfoSchema = object({
17436
17436
  */
17437
17437
  interactiveConnectPath: string().min(1).optional(),
17438
17438
  /** Relative hub path to disconnect the linked account (same popup pattern). */
17439
- interactiveDisconnectPath: string().min(1).optional()
17439
+ interactiveDisconnectPath: string().min(1).optional(),
17440
+ /**
17441
+ * The kind signs in through a server-held interactive session instead of
17442
+ * (or before) typed credentials. `basePath` is a hub-relative route set
17443
+ * served by the owning addon (`/addon/<id>/...`) speaking the sign-in
17444
+ * contract: `POST {basePath}/start` (body: the form's settings) answers
17445
+ * `{ sessionId, loginUrl }`; `GET {basePath}/status?sessionId=` answers
17446
+ * `{ phase: 'starting' | 'awaiting-login' | 'captured' | 'error' |
17447
+ * 'cancelled', loginUrl, error }`; `POST {basePath}/commit`
17448
+ * (`{ sessionId, name, brokerId? }`) stores the credentials on a new or
17449
+ * existing broker and answers `{ brokerId }`; `POST {basePath}/cancel`
17450
+ * (`{ sessionId }`) drops the session. The dialog that edits a broker
17451
+ * offers it as the default path; the fields the session fills are
17452
+ * marked `filledBySignIn` in the kind's settings schema.
17453
+ */
17454
+ signIn: object({ basePath: string().min(1) }).optional()
17440
17455
  }))
17441
17456
  });
17442
17457
  var ListInputSchema = object({
@@ -44070,7 +44085,7 @@ var NetworkAccessStatusSchema = object({
44070
44085
  });
44071
44086
  /**
44072
44087
  * Optional, richer endpoint shape returned by providers that expose
44073
- * MORE than one ingress concurrently (Tailscale Ingress with mixed
44088
+ * MORE than one ingress concurrently (Tailscale Funnel with mixed
44074
44089
  * serve+funnel rules, future ngrok multi-tunnel, …). Each entry carries
44075
44090
  * the originating provider config (mode + sourcePort) so the
44076
44091
  * orchestrator UI can label rows distinctly. Providers that expose only
@@ -57183,7 +57198,7 @@ var BatteryStatusSchema = object({
57183
57198
  */
57184
57199
  binary: boolean().optional().meta({ label: "Binary indicator" })
57185
57200
  });
57186
- DeviceType.Camera, DeviceType.Sensor, DeviceType.Button, DeviceType.Switch, DeviceType.PetFeeder, DeviceType.Container, DeviceType.Thermostat;
57201
+ DeviceType.Camera, DeviceType.Sensor, DeviceType.Button, DeviceType.Switch, DeviceType.PetFeeder, DeviceType.Container, DeviceType.Thermostat, DeviceType.EventEmitter;
57187
57202
  method(object({
57188
57203
  deviceId: number(),
57189
57204
  /** Bound on the wait. Sensible range 3000–10000ms. */
@@ -61785,9 +61800,9 @@ object({
61785
61800
  /** Cumulative energy in kilowatt-hours since the meter was reset. */
61786
61801
  kwhTotal: number().optional().meta(readingMeta("energy", { label: "Energy" })),
61787
61802
  /** Voltage in volts. */
61788
- volts: number().optional().meta(readingMeta("voltage")),
61803
+ volts: number().optional().meta(readingMeta("voltage", { label: "Voltage" })),
61789
61804
  /** Current in amperes. */
61790
- amps: number().optional().meta(readingMeta("current")),
61805
+ amps: number().optional().meta(readingMeta("current", { label: "Current" })),
61791
61806
  /** Apparent power in volt-amperes. */
61792
61807
  va: number().optional().meta(readingMeta("apparent-power")),
61793
61808
  /** Power factor (0..1) if reported. */
@@ -61795,7 +61810,23 @@ object({
61795
61810
  /** Ms epoch when the slice was last updated. */
61796
61811
  lastFetchedAt: number()
61797
61812
  });
61798
- DeviceType.Sensor, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher;
61813
+ [
61814
+ DeviceType.Sensor,
61815
+ DeviceType.Switch,
61816
+ DeviceType.Light,
61817
+ DeviceType.Fan,
61818
+ DeviceType.Climate,
61819
+ DeviceType.Thermostat,
61820
+ DeviceType.Humidifier,
61821
+ DeviceType.WaterHeater,
61822
+ DeviceType.MediaPlayer,
61823
+ DeviceType.Washer,
61824
+ DeviceType.Dryer,
61825
+ DeviceType.Dishwasher,
61826
+ DeviceType.Vacuum,
61827
+ DeviceType.LawnMower,
61828
+ DeviceType.PetFeeder
61829
+ ].filter((type) => type !== DeviceType.Sensor);
61799
61830
  /**
61800
61831
  * Presence cap. Models HA `person.*` and `device_tracker.*` entities
61801
61832
  * on `DeviceType.Presence`. Read-only — no setters: presence is
@@ -66077,7 +66108,7 @@ var trainingCapability = {
66077
66108
  };
66078
66109
  DeviceFeature.FanSpeed, DeviceFeature.FanPreset, DeviceFeature.FanDirection, DeviceFeature.FanOscillating, DeviceFeature.CoverPositionable, DeviceFeature.CoverTilt, DeviceFeature.ValvePositionable, DeviceFeature.MediaPlayerVolume, DeviceFeature.ClimateFanMode;
66079
66110
  SOURCE_CAPS.filter((cap) => cap !== "switch" && cap !== "motion");
66080
- DeviceType.Camera, DeviceType.Sensor, DeviceType.Button, DeviceType.Switch, DeviceType.PetFeeder, DeviceType.Container, DeviceType.Thermostat, DeviceType.Camera, DeviceType.Hub, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer, DeviceType.Camera, DeviceType.Camera, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.MediaPlayer, DeviceType.WaterHeater, DeviceType.Humidifier, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.PetFeeder;
66111
+ DeviceType.Camera, DeviceType.Sensor, DeviceType.Button, DeviceType.Switch, DeviceType.PetFeeder, DeviceType.Container, DeviceType.Thermostat, DeviceType.EventEmitter, DeviceType.Camera, DeviceType.Hub, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer, DeviceType.Camera, DeviceType.Camera, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.MediaPlayer, DeviceType.WaterHeater, DeviceType.Humidifier, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.PetFeeder;
66081
66112
  String.raw`rose\(active(\d+), changed(\d+), (\d+(?:\.\d+)?)\)`;
66082
66113
  DeviceRole.BinarySensor, DeviceRole.MotionSensor;
66083
66114
  new Set(CAP_NAMES);
@@ -17403,7 +17403,22 @@ var BrokerProviderInfoSchema = object({
17403
17403
  */
17404
17404
  interactiveConnectPath: string().min(1).optional(),
17405
17405
  /** Relative hub path to disconnect the linked account (same popup pattern). */
17406
- interactiveDisconnectPath: string().min(1).optional()
17406
+ interactiveDisconnectPath: string().min(1).optional(),
17407
+ /**
17408
+ * The kind signs in through a server-held interactive session instead of
17409
+ * (or before) typed credentials. `basePath` is a hub-relative route set
17410
+ * served by the owning addon (`/addon/<id>/...`) speaking the sign-in
17411
+ * contract: `POST {basePath}/start` (body: the form's settings) answers
17412
+ * `{ sessionId, loginUrl }`; `GET {basePath}/status?sessionId=` answers
17413
+ * `{ phase: 'starting' | 'awaiting-login' | 'captured' | 'error' |
17414
+ * 'cancelled', loginUrl, error }`; `POST {basePath}/commit`
17415
+ * (`{ sessionId, name, brokerId? }`) stores the credentials on a new or
17416
+ * existing broker and answers `{ brokerId }`; `POST {basePath}/cancel`
17417
+ * (`{ sessionId }`) drops the session. The dialog that edits a broker
17418
+ * offers it as the default path; the fields the session fills are
17419
+ * marked `filledBySignIn` in the kind's settings schema.
17420
+ */
17421
+ signIn: object({ basePath: string().min(1) }).optional()
17407
17422
  }))
17408
17423
  });
17409
17424
  var ListInputSchema = object({
@@ -44037,7 +44052,7 @@ var NetworkAccessStatusSchema = object({
44037
44052
  });
44038
44053
  /**
44039
44054
  * Optional, richer endpoint shape returned by providers that expose
44040
- * MORE than one ingress concurrently (Tailscale Ingress with mixed
44055
+ * MORE than one ingress concurrently (Tailscale Funnel with mixed
44041
44056
  * serve+funnel rules, future ngrok multi-tunnel, …). Each entry carries
44042
44057
  * the originating provider config (mode + sourcePort) so the
44043
44058
  * orchestrator UI can label rows distinctly. Providers that expose only
@@ -57150,7 +57165,7 @@ var BatteryStatusSchema = object({
57150
57165
  */
57151
57166
  binary: boolean().optional().meta({ label: "Binary indicator" })
57152
57167
  });
57153
- DeviceType.Camera, DeviceType.Sensor, DeviceType.Button, DeviceType.Switch, DeviceType.PetFeeder, DeviceType.Container, DeviceType.Thermostat;
57168
+ DeviceType.Camera, DeviceType.Sensor, DeviceType.Button, DeviceType.Switch, DeviceType.PetFeeder, DeviceType.Container, DeviceType.Thermostat, DeviceType.EventEmitter;
57154
57169
  method(object({
57155
57170
  deviceId: number(),
57156
57171
  /** Bound on the wait. Sensible range 3000–10000ms. */
@@ -61752,9 +61767,9 @@ object({
61752
61767
  /** Cumulative energy in kilowatt-hours since the meter was reset. */
61753
61768
  kwhTotal: number().optional().meta(readingMeta("energy", { label: "Energy" })),
61754
61769
  /** Voltage in volts. */
61755
- volts: number().optional().meta(readingMeta("voltage")),
61770
+ volts: number().optional().meta(readingMeta("voltage", { label: "Voltage" })),
61756
61771
  /** Current in amperes. */
61757
- amps: number().optional().meta(readingMeta("current")),
61772
+ amps: number().optional().meta(readingMeta("current", { label: "Current" })),
61758
61773
  /** Apparent power in volt-amperes. */
61759
61774
  va: number().optional().meta(readingMeta("apparent-power")),
61760
61775
  /** Power factor (0..1) if reported. */
@@ -61762,7 +61777,23 @@ object({
61762
61777
  /** Ms epoch when the slice was last updated. */
61763
61778
  lastFetchedAt: number()
61764
61779
  });
61765
- DeviceType.Sensor, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher;
61780
+ [
61781
+ DeviceType.Sensor,
61782
+ DeviceType.Switch,
61783
+ DeviceType.Light,
61784
+ DeviceType.Fan,
61785
+ DeviceType.Climate,
61786
+ DeviceType.Thermostat,
61787
+ DeviceType.Humidifier,
61788
+ DeviceType.WaterHeater,
61789
+ DeviceType.MediaPlayer,
61790
+ DeviceType.Washer,
61791
+ DeviceType.Dryer,
61792
+ DeviceType.Dishwasher,
61793
+ DeviceType.Vacuum,
61794
+ DeviceType.LawnMower,
61795
+ DeviceType.PetFeeder
61796
+ ].filter((type) => type !== DeviceType.Sensor);
61766
61797
  /**
61767
61798
  * Presence cap. Models HA `person.*` and `device_tracker.*` entities
61768
61799
  * on `DeviceType.Presence`. Read-only — no setters: presence is
@@ -66044,7 +66075,7 @@ var trainingCapability = {
66044
66075
  };
66045
66076
  DeviceFeature.FanSpeed, DeviceFeature.FanPreset, DeviceFeature.FanDirection, DeviceFeature.FanOscillating, DeviceFeature.CoverPositionable, DeviceFeature.CoverTilt, DeviceFeature.ValvePositionable, DeviceFeature.MediaPlayerVolume, DeviceFeature.ClimateFanMode;
66046
66077
  SOURCE_CAPS.filter((cap) => cap !== "switch" && cap !== "motion");
66047
- DeviceType.Camera, DeviceType.Sensor, DeviceType.Button, DeviceType.Switch, DeviceType.PetFeeder, DeviceType.Container, DeviceType.Thermostat, DeviceType.Camera, DeviceType.Hub, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer, DeviceType.Camera, DeviceType.Camera, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.MediaPlayer, DeviceType.WaterHeater, DeviceType.Humidifier, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.PetFeeder;
66078
+ DeviceType.Camera, DeviceType.Sensor, DeviceType.Button, DeviceType.Switch, DeviceType.PetFeeder, DeviceType.Container, DeviceType.Thermostat, DeviceType.EventEmitter, DeviceType.Camera, DeviceType.Hub, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer, DeviceType.Camera, DeviceType.Camera, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.MediaPlayer, DeviceType.WaterHeater, DeviceType.Humidifier, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.PetFeeder;
66048
66079
  String.raw`rose\(active(\d+), changed(\d+), (\d+(?:\.\d+)?)\)`;
66049
66080
  DeviceRole.BinarySensor, DeviceRole.MotionSensor;
66050
66081
  new Set(CAP_NAMES);
@@ -36,7 +36,7 @@ async function r() {
36
36
  }
37
37
  },
38
38
  "@camstack/types": {
39
- version: "1.2.424",
39
+ version: "1.2.428",
40
40
  scope: "default",
41
41
  shareConfig: {
42
42
  singleton: !0,
@@ -45,7 +45,7 @@ async function r() {
45
45
  }
46
46
  },
47
47
  "@camstack/sdk": {
48
- version: "1.2.153",
48
+ version: "1.2.154",
49
49
  scope: "default",
50
50
  shareConfig: {
51
51
  singleton: !0,
@@ -81,7 +81,7 @@ async function r() {
81
81
  }
82
82
  },
83
83
  "@camstack/ui-library": {
84
- version: "1.2.335",
84
+ version: "1.2.337",
85
85
  scope: "default",
86
86
  shareConfig: {
87
87
  singleton: !0,
package/dist/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- require("./dist-BYGiAfO5.js");
2
+ require("./dist-C_f7s2st.js");
3
3
  const require_orchestrator_training_addon = require("./orchestrator/training.addon.js");
4
4
  const require_providers_modal_training_modal_addon = require("./providers/modal/training-modal.addon.js");
5
5
  //#region src/providers/fake/fake-provider.ts
@@ -1,5 +1,5 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_dist = require("../dist-BYGiAfO5.js");
2
+ const require_dist = require("../dist-C_f7s2st.js");
3
3
  let node_path = require("node:path");
4
4
  node_path = require_dist.__toESM(node_path);
5
5
  let node_crypto = require("node:crypto");
@@ -1,4 +1,4 @@
1
- import { a as addonPagesSourceCapability, i as TrainingResultSchema, l as BaseAddon, m as defineRecordKinds, n as TrainingJobSchema, o as parseTrainingEventLine, r as TrainingJobSpecSchema, s as trainingCapability, t as TRAINING_JOB_SCHEMA, u as RECORD_MAX_DATA_BYTES } from "../dist-BLeIfxL-.mjs";
1
+ import { a as addonPagesSourceCapability, i as TrainingResultSchema, l as BaseAddon, m as defineRecordKinds, n as TrainingJobSchema, o as parseTrainingEventLine, r as TrainingJobSpecSchema, s as trainingCapability, t as TRAINING_JOB_SCHEMA, u as RECORD_MAX_DATA_BYTES } from "../dist-mC0XNhcx.mjs";
2
2
  import path from "node:path";
3
3
  import { createHash } from "node:crypto";
4
4
  import { createReadStream } from "node:fs";
@@ -1,7 +1,7 @@
1
1
  import { d as e, u as t, w as n, y as r } from "./_virtual_mf___mfe_internal__addon_training_page__loadShare__react__loadShare__.js-CEvdvp1T.mjs";
2
2
  import { n as i, r as a, t as o } from "./_virtual_mf___mfe_internal__addon_training_page__loadShare__react_mf_1_jsx_mf_2_runtime__loadShare__.js-DnrbBvrw.mjs";
3
3
  import { n as s, t as c } from "./chevron-right-cA8Hucbi.mjs";
4
- import { g as l } from "./responsive-wZ7jMF7F.mjs";
4
+ import { g as l } from "./responsive-Cx4quvGq.mjs";
5
5
  //#region ../ui-library/src/composites/widget-panel.tsx
6
6
  n();
7
7
  function u({ title: e, icon: t, headerRight: n, collapsible: l = !1, defaultOpen: u = !0, open: d, onOpenChange: f, bodyClassName: p = "p-3", children: m }) {
@@ -1,5 +1,5 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_dist = require("../../dist-BYGiAfO5.js");
2
+ const require_dist = require("../../dist-C_f7s2st.js");
3
3
  let node_path = require("node:path");
4
4
  node_path = require_dist.__toESM(node_path, 1);
5
5
  let node_crypto = require("node:crypto");
@@ -1,4 +1,4 @@
1
- import { C as record, S as object, _ as isSecretClear, b as boolean, c as trainingProviderCapability, d as SECRET_CLEAR, f as arrayItemFieldPath, g as globalSecretScope, h as entryBody, l as BaseAddon, p as defineEntryKind, v as isSecretMarker, w as string, x as number, y as toSecretFieldView } from "../../dist-BLeIfxL-.mjs";
1
+ import { C as record, S as object, _ as isSecretClear, b as boolean, c as trainingProviderCapability, d as SECRET_CLEAR, f as arrayItemFieldPath, g as globalSecretScope, h as entryBody, l as BaseAddon, p as defineEntryKind, v as isSecretMarker, w as string, x as number, y as toSecretFieldView } from "../../dist-mC0XNhcx.mjs";
2
2
  import { createRequire } from "node:module";
3
3
  import path, { dirname, posix } from "node:path";
4
4
  import { createHash, createPrivateKey, createPublicKey, createSign, randomBytes, randomUUID } from "node:crypto";
@@ -1,2 +1,2 @@
1
- import { n as e, t } from "./virtual_mf-REMOTE_ENTRY_ID___mfe_internal__addon_training_page__remoteEntry_js-CG3LeBz1.mjs";
1
+ import { n as e, t } from "./virtual_mf-REMOTE_ENTRY_ID___mfe_internal__addon_training_page__remoteEntry_js-Ch6HQCmx.mjs";
2
2
  export { t as get, e as init };
@@ -1,6 +1,6 @@
1
1
  import { b as e, d as t, g as n, l as r, n as i, u as a, w as o, y as s } from "./_virtual_mf___mfe_internal__addon_training_page__loadShare__react__loadShare__.js-CEvdvp1T.mjs";
2
2
  import "./_virtual_mf___mfe_internal__addon_training_page__loadShare__react_mf_1_jsx_mf_2_runtime__loadShare__.js-DnrbBvrw.mjs";
3
- import { O as c } from "./_virtual_mf___mfe_internal__addon_training_page__loadShare___mf_0_camstack_mf_1_types__loadShare__.js-COkV6wxS.mjs";
3
+ import { O as c } from "./_virtual_mf___mfe_internal__addon_training_page__loadShare___mf_0_camstack_mf_1_types__loadShare__.js-B6wwfPOo.mjs";
4
4
  //#region ../ui-library/src/lib/shared-context.ts
5
5
  o();
6
6
  function l(e, t) {
@@ -1,52 +1,69 @@
1
- import { g as e, l as t, w as n, y as r } from "./_virtual_mf___mfe_internal__addon_training_page__loadShare__react__loadShare__.js-CEvdvp1T.mjs";
2
- import { n as i } from "./ui-text-CqJgUCKX.mjs";
1
+ import { g as e, l as t, u as n, w as r, y as i } from "./_virtual_mf___mfe_internal__addon_training_page__loadShare__react__loadShare__.js-CEvdvp1T.mjs";
2
+ import "./_virtual_mf___mfe_internal__addon_training_page__loadShare__react_mf_1_jsx_mf_2_runtime__loadShare__.js-DnrbBvrw.mjs";
3
+ import { n as a } from "./ui-text-CqJgUCKX.mjs";
4
+ import { g as o } from "./responsive-Cx4quvGq.mjs";
5
+ //#region ../ui-library/src/composites/confirm-dialog.tsx
6
+ r();
7
+ var s = o("camstack:confirm-dialog", null);
8
+ function c() {
9
+ let e = n(s);
10
+ if (!e) throw Error("useConfirm must be used within ConfirmDialogProvider");
11
+ return e;
12
+ }
13
+ function l() {
14
+ return c().confirm;
15
+ }
16
+ function u() {
17
+ return c().prompt;
18
+ }
19
+ //#endregion
3
20
  //#region ../ui-library/src/lib/hub-mount.ts
4
- n();
5
- var a = "camstack-mount", o = /^\/(?:[A-Za-z0-9_\-.]+\/)*$/, s = null;
6
- function c(e) {
21
+ var d = "camstack-mount", f = /^\/(?:[A-Za-z0-9_\-.]+\/)*$/, p = null;
22
+ function m(e) {
7
23
  if (e == null || e === "") return null;
8
24
  let t = e.endsWith("/") ? e : `${e}/`;
9
- return !o.test(t) || t.includes("/../") || t.includes("/./") ? null : t;
25
+ return !f.test(t) || t.includes("/../") || t.includes("/./") ? null : t;
10
26
  }
11
- function l() {
27
+ function h() {
12
28
  if (typeof document > "u") return "/";
13
- let e = c(document.querySelector(`meta[name="${a}"]`)?.getAttribute("content"));
29
+ let e = m(document.querySelector(`meta[name="${d}"]`)?.getAttribute("content"));
14
30
  if (e !== null) return e;
15
31
  if (document.querySelector("base[href]") !== null) try {
16
32
  let e = new URL(document.baseURI);
17
33
  if (e.origin === window.location.origin) {
18
- let t = c(e.pathname);
34
+ let t = m(e.pathname);
19
35
  if (t !== null) return t;
20
36
  }
21
37
  } catch {}
22
38
  return "/";
23
39
  }
24
- function u() {
25
- return s === null && (s = l()), s;
40
+ function g() {
41
+ return p === null && (p = h()), p;
26
42
  }
27
- function d() {
28
- return u().replace(/\/$/, "");
43
+ function _() {
44
+ return g().replace(/\/$/, "");
29
45
  }
30
- function f(e) {
46
+ function v(e) {
31
47
  return /^[a-z][a-z0-9+.-]*:/i.test(e) || e.startsWith("//");
32
48
  }
33
- function p(e) {
34
- if (f(e)) return e;
35
- let t = u(), n = e.replace(/^\/+/, "");
36
- return t !== "/" && (e === d() || e.startsWith(t)) ? e : `${t}${n}`;
49
+ function y(e) {
50
+ if (v(e)) return e;
51
+ let t = g(), n = e.replace(/^\/+/, "");
52
+ return t !== "/" && (e === _() || e.startsWith(t)) ? e : `${t}${n}`;
37
53
  }
38
54
  //#endregion
39
55
  //#region ../ui-library/src/hooks/use-device-snapshot.ts
40
- var m = "/addon/snapshot/media";
41
- function h(n, i = {}) {
42
- let { width: a, baseUrl: o } = i, [s, c] = r(0);
56
+ r();
57
+ var b = "/addon/snapshot/media";
58
+ function x(n, r = {}) {
59
+ let { width: a, baseUrl: o } = r, [s, c] = i(0);
43
60
  return {
44
61
  src: e(() => {
45
62
  if (n === null || n <= 0) return null;
46
- let e = o === void 0 ? d() : o.replace(/\/+$/, ""), t = new URLSearchParams();
63
+ let e = o === void 0 ? _() : o.replace(/\/+$/, ""), t = new URLSearchParams();
47
64
  a !== void 0 && Number.isInteger(a) && a > 0 && t.set("w", String(a)), s > 0 && (t.set("force", "1"), t.set("r", String(s)));
48
65
  let r = t.toString();
49
- return `${e}${m}/${String(n)}.jpg${r.length > 0 ? `?${r}` : ""}`;
66
+ return `${e}${b}/${String(n)}.jpg${r.length > 0 ? `?${r}` : ""}`;
50
67
  }, [
51
68
  n,
52
69
  a,
@@ -61,7 +78,7 @@ function h(n, i = {}) {
61
78
  }
62
79
  //#endregion
63
80
  //#region ../ui-library/src/composites/cap-settings/scene-monitor-copy.ts
64
- var g = ["day", "ir"], _ = {
81
+ var S = ["day", "ir"], C = {
65
82
  day: {
66
83
  labelKey: "uiLibrary.sceneMonitor.variant.day",
67
84
  labelFallback: "Daylight"
@@ -83,17 +100,17 @@ var g = ["day", "ir"], _ = {
83
100
  labelFallback: "Dusk"
84
101
  }
85
102
  };
86
- function v(e, t = i) {
87
- let n = _[e];
103
+ function w(e, t = a) {
104
+ let n = C[e];
88
105
  return n === void 0 ? e : t(n.labelKey, n.labelFallback);
89
106
  }
90
- function y(e, t = i) {
91
- let n = new Set(e.coveredConditions), r = g.map((e) => `${v(e, t)} ${n.has(e) ? "✓" : "✗"}`), a = [...n].filter((e) => !g.some((t) => t === e));
92
- for (let e of a) r.push(`${v(e, t)} ✓`);
93
- let o = g.filter((e) => !n.has(e));
107
+ function T(e, t = a) {
108
+ let n = new Set(e.coveredConditions), r = S.map((e) => `${w(e, t)} ${n.has(e) ? "✓" : "✗"}`), i = [...n].filter((e) => !S.some((t) => t === e));
109
+ for (let e of i) r.push(`${w(e, t)} ✓`);
110
+ let o = S.filter((e) => !n.has(e));
94
111
  if (o.length === 0) return r.join(" · ");
95
112
  if (n.size === 0) return t("uiLibrary.sceneMonitor.coverage.empty", "{{parts}} — nothing captured yet, so this scene is not watching.", { parts: r.join(" · ") });
96
- let [s = "", c] = o.map((e) => v(e, t).toLowerCase()), l = c === void 0 ? s : t("uiLibrary.sceneMonitor.coverage.namesJoin", "{{first}} and {{second}}", {
113
+ let [s = "", c] = o.map((e) => w(e, t).toLowerCase()), l = c === void 0 ? s : t("uiLibrary.sceneMonitor.coverage.namesJoin", "{{first}} and {{second}}", {
97
114
  first: s,
98
115
  second: c
99
116
  }), u = {
@@ -102,10 +119,10 @@ function y(e, t = i) {
102
119
  };
103
120
  return e.onUncoveredCondition === "judge-anyway" ? t("uiLibrary.sceneMonitor.coverage.judgeAnyway", "{{parts}} — {{names}} judged against the references you do have.", u) : t("uiLibrary.sceneMonitor.coverage.skip", "{{parts}} — optional; checks in {{names}} are skipped.", u);
104
121
  }
105
- function b(e, t = i) {
106
- return e.suspendedCondition === null ? null : t("uiLibrary.sceneMonitor.suspension", "Paused — nothing was captured in {{light}}, so checks are on hold until the light changes back. Capture {{light}} if you want it watched around the clock.", { light: v(e.suspendedCondition, t).toLowerCase() });
122
+ function E(e, t = a) {
123
+ return e.suspendedCondition === null ? null : t("uiLibrary.sceneMonitor.suspension", "Paused — nothing was captured in {{light}}, so checks are on hold until the light changes back. Capture {{light}} if you want it watched around the clock.", { light: w(e.suspendedCondition, t).toLowerCase() });
107
124
  }
108
- var x = {
125
+ var D = {
109
126
  "no-reference-for-condition": {
110
127
  key: "uiLibrary.sceneMonitor.unavailable.no_reference_for_condition",
111
128
  fallback: "can’t tell — nothing has been captured for this scene yet. Press “Capture daylight” to photograph what normal looks like."
@@ -127,19 +144,19 @@ var x = {
127
144
  fallback: "can’t tell — this camera did not return a frame."
128
145
  }
129
146
  };
130
- function S(e, t, n = i) {
147
+ function O(e, t, n = a) {
131
148
  if (e.states.length === 0) return n("uiLibrary.sceneMonitor.status.notArmed", "Not armed yet — capture the initial state to start watching.");
132
149
  if (e.verdict === "unknown") {
133
150
  if (e.unavailable === null) return n("uiLibrary.sceneMonitor.status.cantTellNow", "can’t tell right now.");
134
- let t = x[e.unavailable];
151
+ let t = D[e.unavailable];
135
152
  return n(t.key, t.fallback);
136
153
  }
137
- let r = e.verdict === "diverged" ? e.divergedAt : e.armedAt, a = r === null ? "" : ` ${n("uiLibrary.sceneMonitor.status.heldFor", "for {{duration}}", { duration: E(Math.max(0, t - r)) })}`;
138
- if (e.latched) return e.verdict === "diverged" ? n("uiLibrary.sceneMonitor.status.changedLatched", "CHANGED{{held}} — press Reset when you have dealt with it.", { held: a }) : n("uiLibrary.sceneMonitor.status.backToNormal", "Back to normal, but still flagged as changed{{held}}. Press Reset to clear it.", { held: a });
139
- let o = b(e, n);
140
- return o === null ? e.verdict === "diverged" ? n("uiLibrary.sceneMonitor.status.changed", "CHANGED{{held}}", { held: a }) : n("uiLibrary.sceneMonitor.status.normal", "Normal{{held}}", { held: a }) : o;
154
+ let r = e.verdict === "diverged" ? e.divergedAt : e.armedAt, i = r === null ? "" : ` ${n("uiLibrary.sceneMonitor.status.heldFor", "for {{duration}}", { duration: M(Math.max(0, t - r)) })}`;
155
+ if (e.latched) return e.verdict === "diverged" ? n("uiLibrary.sceneMonitor.status.changedLatched", "CHANGED{{held}} — press Reset when you have dealt with it.", { held: i }) : n("uiLibrary.sceneMonitor.status.backToNormal", "Back to normal, but still flagged as changed{{held}}. Press Reset to clear it.", { held: i });
156
+ let o = E(e, n);
157
+ return o === null ? e.verdict === "diverged" ? n("uiLibrary.sceneMonitor.status.changed", "CHANGED{{held}}", { held: i }) : n("uiLibrary.sceneMonitor.status.normal", "Normal{{held}}", { held: i }) : o;
141
158
  }
142
- function C(e, t = i) {
159
+ function k(e, t = a) {
143
160
  return e.states.length === 0 ? {
144
161
  text: t("uiLibrary.sceneMonitor.badge.notArmed", "Not armed"),
145
162
  tone: "unknown"
@@ -160,11 +177,11 @@ function C(e, t = i) {
160
177
  tone: "unknown"
161
178
  };
162
179
  }
163
- var w = .4;
164
- function T(e) {
165
- return e.width * e.height > w;
180
+ var A = .4;
181
+ function j(e) {
182
+ return e.width * e.height > A;
166
183
  }
167
- function E(e) {
184
+ function M(e) {
168
185
  let t = Math.floor(e / 1e3);
169
186
  if (t < 60) return `${t}s`;
170
187
  let n = Math.floor(t / 60);
@@ -173,4 +190,4 @@ function E(e) {
173
190
  return r < 48 ? `${r}h` : `${Math.floor(r / 24)}d`;
174
191
  }
175
192
  //#endregion
176
- export { S as a, p as c, T as i, C as n, v as o, y as r, h as s, g as t };
193
+ export { O as a, y as c, j as i, l, k as n, w as o, T as r, x as s, S as t, u };
@@ -2762,7 +2762,7 @@ async function or(e) {
2762
2762
  }
2763
2763
  }
2764
2764
  async function sr() {
2765
- return ir ||= or(() => import("./_virtual_mf-localSharedImportMap___mfe_internal__addon_training_page-Ki3rRnXi.mjs")).catch((e) => {
2765
+ return ir ||= or(() => import("./_virtual_mf-localSharedImportMap___mfe_internal__addon_training_page-DcGxW0BQ.mjs")).catch((e) => {
2766
2766
  throw ir = void 0, e;
2767
2767
  }), ir;
2768
2768
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camstack/addon-training",
3
- "version": "0.1.92",
3
+ "version": "0.1.94",
4
4
  "description": "Cloud training for CamStack: fine-tune the root detector on your own frames, on your own GPU-cloud account",
5
5
  "keywords": [
6
6
  "camstack",
@@ -68,7 +68,7 @@
68
68
  {
69
69
  "id": "training-modal",
70
70
  "category": "system",
71
- "name": "Modal (training cloud)",
71
+ "name": "Modal",
72
72
  "description": "Runs CamStack training jobs on your Modal account (modal.com, $30 of free credit a month on the Starter plan). Inert until you enter a Modal token",
73
73
  "version": "1.0.0",
74
74
  "entry": "./dist/providers/modal/training-modal.addon.js",