scrypted-detection-trainer 0.1.3 → 0.1.4

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/dist/plugin.zip CHANGED
Binary file
@@ -1620,6 +1620,7 @@ class DetectionTrainer extends sdk_1.ScryptedDeviceBase {
1620
1620
  .filter(d => d &&
1621
1621
  (d.type === sdk_1.ScryptedDeviceType.Camera || d.type === sdk_1.ScryptedDeviceType.Doorbell) &&
1622
1622
  d.interfaces?.includes(sdk_1.ScryptedInterface.ObjectDetector));
1623
+ const uiUrl = await sdk_1.default.endpointManager.getLocalEndpoint(undefined, { public: true }).catch(() => '/endpoint/scrypted-detection-trainer/public/');
1623
1624
  const settings = [
1624
1625
  {
1625
1626
  key: 'info',
@@ -1629,11 +1630,12 @@ class DetectionTrainer extends sdk_1.ScryptedDeviceBase {
1629
1630
  value: '',
1630
1631
  },
1631
1632
  {
1632
- key: 'ui_link',
1633
+ key: 'open_ui',
1633
1634
  title: 'Review UI',
1634
1635
  description: 'Open the detection review and labeling interface.',
1636
+ type: 'html',
1635
1637
  readonly: true,
1636
- value: await sdk_1.default.endpointManager.getLocalEndpoint('scrypted-detection-trainer', { public: true }).catch(() => '/endpoint/scrypted-detection-trainer/public/'),
1638
+ value: `<a href="${uiUrl}" target="_blank" style="display:inline-block;padding:8px 16px;background:#1a4d8a;color:#fff;border-radius:6px;text-decoration:none;font-size:13px;">Open Review UI ↗</a>`,
1637
1639
  },
1638
1640
  ];
1639
1641
  for (const cam of cameras) {