homebridge-bluos 1.1.5 → 1.1.6

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 CHANGED
@@ -1,5 +1,12 @@
1
1
  # Changelog
2
2
 
3
+ ## [1.1.6](https://github.com/tbaur/homebridge-bluos/compare/v1.1.5...v1.1.6) (2026-08-31)
4
+
5
+
6
+ ### Bug Fixes
7
+
8
+ * announce discovery with a toast while the spinner runs ([#35](https://github.com/tbaur/homebridge-bluos/issues/35)) ([99582c9](https://github.com/tbaur/homebridge-bluos/commit/99582c92d710f7e5c7aade520faf76a431a0a477))
9
+
3
10
  ## [1.1.5](https://github.com/tbaur/homebridge-bluos/compare/v1.1.4...v1.1.5) (2026-08-31)
4
11
 
5
12
 
@@ -10,39 +10,7 @@
10
10
  -->
11
11
  <style>
12
12
  .bluos-intro { margin-bottom: 1rem; }
13
- .bluos-toolbar {
14
- display: flex;
15
- gap: .5rem;
16
- align-items: flex-end;
17
- flex-wrap: wrap;
18
- position: sticky;
19
- top: 0;
20
- z-index: 5;
21
- margin: 0 0 1rem;
22
- padding: .55rem 0;
23
- /* Frosted so cards do not show through while this bar stays on screen. */
24
- background: rgba(128, 128, 128, .12);
25
- backdrop-filter: blur(10px);
26
- }
27
- .bluos-busy {
28
- display: inline-flex;
29
- align-items: center;
30
- align-self: center;
31
- gap: .4rem;
32
- font-size: .85rem;
33
- white-space: nowrap;
34
- }
35
- .bluos-busy[hidden] { display: none !important; }
36
- .bluos-busy::before {
37
- content: '';
38
- width: .85rem;
39
- height: .85rem;
40
- border: 2px solid currentColor;
41
- border-right-color: transparent;
42
- border-radius: 50%;
43
- animation: bluos-spin .7s linear infinite;
44
- }
45
- @keyframes bluos-spin { to { transform: rotate(360deg); } }
13
+ .bluos-toolbar { display: flex; gap: .5rem; align-items: flex-end; flex-wrap: wrap; margin-bottom: 1rem; }
46
14
  .bluos-toolbar .form-group { margin-bottom: 0; }
47
15
  .bluos-card { border: 1px solid rgba(128, 128, 128, .3); border-radius: .5rem; padding: .85rem 1rem; margin-bottom: .75rem; }
48
16
  .bluos-card.is-selected { border-color: #007bff; box-shadow: 0 0 0 1px rgba(0, 123, 255, .35); }
@@ -78,7 +46,6 @@
78
46
 
79
47
  <div class="bluos-toolbar">
80
48
  <button class="btn btn-primary" id="discover">Discover Players</button>
81
- <span id="discover-status" class="bluos-busy text-muted" hidden></span>
82
49
  <div class="form-group">
83
50
  <label for="timeout" class="mb-0" style="font-size: .8rem;">Listen for</label>
84
51
  <select class="form-control form-control-sm" id="timeout">
@@ -457,30 +457,12 @@
457
457
 
458
458
  // --- Actions ------------------------------------------------------------
459
459
 
460
- let requestInFlight = false
461
-
462
- /**
463
- * Show progress next to Discover, which is where the user just pressed.
464
- *
465
- * Homebridge's spinner is centred on the whole settings page. With a long
466
- * list of players that centre sits below the fold, so a user who pressed
467
- * Discover would see nothing happen for several seconds.
468
- */
469
- function setBusy(isBusy, message) {
470
- requestInFlight = isBusy
471
- byId('discover').disabled = isBusy
472
- byId('manual-probe').disabled = isBusy
473
- const status = byId('discover-status')
474
- status.hidden = !isBusy
475
- status.textContent = isBusy ? message : ''
476
- }
477
-
478
460
  async function discover() {
479
- if (requestInFlight) {
480
- return
481
- }
482
461
  const timeoutSec = Number(byId('timeout').value) || DEFAULT_TIMEOUT_SEC
483
- setBusy(true, 'Listening for players…')
462
+ homebridge.showSpinner()
463
+ // The overlay can sit in the middle of a long device list. The toast is
464
+ // drawn on the Config UI chrome, so it stays visible.
465
+ homebridge.toast.info('Listening for players…', 'Discovering')
484
466
  try {
485
467
  const response = await homebridge.request('/discover', { timeoutSec })
486
468
  const found = Array.isArray(response && response.players) ? response.players : []
@@ -505,14 +487,11 @@
505
487
  } catch (error) {
506
488
  homebridge.toast.error(describeError(error), 'Discovery failed')
507
489
  } finally {
508
- setBusy(false)
490
+ homebridge.hideSpinner()
509
491
  }
510
492
  }
511
493
 
512
494
  async function probe() {
513
- if (requestInFlight) {
514
- return
515
- }
516
495
  const host = byId('manual-host').value.trim()
517
496
  const portValue = byId('manual-port').value.trim()
518
497
  if (host.length === 0) {
@@ -523,7 +502,8 @@
523
502
  if (portValue.length > 0) {
524
503
  payload.port = Number(portValue)
525
504
  }
526
- setBusy(true, 'Probing…')
505
+ homebridge.showSpinner()
506
+ homebridge.toast.info(`Probing ${host}…`, 'Probing')
527
507
  try {
528
508
  const response = await homebridge.request('/probe', payload)
529
509
  const found = Array.isArray(response && response.players) ? response.players : []
@@ -539,7 +519,7 @@
539
519
  } catch (error) {
540
520
  homebridge.toast.error(describeError(error), 'Probe failed')
541
521
  } finally {
542
- setBusy(false)
522
+ homebridge.hideSpinner()
543
523
  }
544
524
  }
545
525
 
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "homebridge-bluos",
3
3
  "displayName": "Homebridge BluOS",
4
- "version": "1.1.5",
4
+ "version": "1.1.6",
5
5
  "description": "Homebridge plugin for BluOS players — per-zone volume, mute, volume-preset and battery accessories over the LAN Custom Integration API. Verified on NAD and Bluesound hardware",
6
6
  "main": "dist/index.js",
7
7
  "types": "dist/index.d.ts",