@switchbot/homebridge-switchbot 5.0.0-beta.111 → 5.0.0-beta.113
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/MIGRATION.md +10 -0
- package/README.md +43 -0
- package/TODO.md +263 -0
- package/config.schema.json +27 -10
- package/dist/device-types.d.ts.map +1 -1
- package/dist/device-types.js +93 -63
- package/dist/device-types.js.map +1 -1
- package/dist/deviceFactory.d.ts.map +1 -1
- package/dist/deviceFactory.js +55 -33
- package/dist/deviceFactory.js.map +1 -1
- package/dist/devices/genericDevice.d.ts +12 -1
- package/dist/devices/genericDevice.d.ts.map +1 -1
- package/dist/devices/genericDevice.js +121 -1
- package/dist/devices/genericDevice.js.map +1 -1
- package/dist/errors.d.ts +5 -0
- package/dist/errors.d.ts.map +1 -0
- package/dist/errors.js +51 -0
- package/dist/errors.js.map +1 -0
- package/dist/homebridge-ui/endpoints/devices.d.ts.map +1 -1
- package/dist/homebridge-ui/endpoints/devices.js +80 -1
- package/dist/homebridge-ui/endpoints/devices.js.map +1 -1
- package/dist/homebridge-ui/endpoints/discovery.d.ts.map +1 -1
- package/dist/homebridge-ui/endpoints/discovery.js +73 -41
- package/dist/homebridge-ui/endpoints/discovery.js.map +1 -1
- package/dist/homebridge-ui/public/css/styles.css +209 -16
- package/dist/homebridge-ui/public/index.html +87 -56
- package/dist/homebridge-ui/public/js/api.d.ts +24 -1
- package/dist/homebridge-ui/public/js/api.d.ts.map +1 -1
- package/dist/homebridge-ui/public/js/api.js +33 -2
- package/dist/homebridge-ui/public/js/api.js.map +1 -1
- package/dist/homebridge-ui/public/js/api.ts +52 -3
- package/dist/homebridge-ui/public/js/app.js +1604 -143
- package/dist/homebridge-ui/public/js/app.js.map +3 -3
- package/dist/homebridge-ui/public/js/app.ts +2 -1
- package/dist/homebridge-ui/public/js/devices.d.ts.map +1 -1
- package/dist/homebridge-ui/public/js/devices.js +2 -0
- package/dist/homebridge-ui/public/js/devices.js.map +1 -1
- package/dist/homebridge-ui/public/js/devices.ts +13 -1
- package/dist/homebridge-ui/public/js/discovery.d.ts +1 -0
- package/dist/homebridge-ui/public/js/discovery.d.ts.map +1 -1
- package/dist/homebridge-ui/public/js/discovery.js +1244 -124
- package/dist/homebridge-ui/public/js/discovery.js.map +1 -1
- package/dist/homebridge-ui/public/js/discovery.ts +1344 -142
- package/dist/homebridge-ui/public/js/modals.d.ts.map +1 -1
- package/dist/homebridge-ui/public/js/modals.js +42 -0
- package/dist/homebridge-ui/public/js/modals.js.map +1 -1
- package/dist/homebridge-ui/public/js/modals.ts +50 -1
- package/dist/homebridge-ui/public/js/render.d.ts +3 -0
- package/dist/homebridge-ui/public/js/render.d.ts.map +1 -1
- package/dist/homebridge-ui/public/js/render.js +389 -36
- package/dist/homebridge-ui/public/js/render.js.map +1 -1
- package/dist/homebridge-ui/public/js/render.ts +421 -38
- package/dist/platform.d.ts +1 -0
- package/dist/platform.d.ts.map +1 -1
- package/dist/platform.js +3 -4
- package/dist/platform.js.map +1 -1
- package/dist/switchbotClient.d.ts.map +1 -1
- package/dist/switchbotClient.js +51 -5
- package/dist/switchbotClient.js.map +1 -1
- package/docs/assets/highlight.css +9 -2
- package/docs/index.html +28 -2
- package/docs/variables/default.html +1 -1
- package/package.json +9 -8
- package/src/device-types.ts +95 -64
- package/src/deviceFactory.ts +55 -33
- package/src/devices/genericDevice.ts +113 -1
- package/src/errors.ts +43 -0
- package/src/homebridge-ui/endpoints/devices.ts +82 -1
- package/src/homebridge-ui/endpoints/discovery.ts +78 -44
- package/src/homebridge-ui/public/css/styles.css +209 -16
- package/src/homebridge-ui/public/index.html +87 -56
- package/src/homebridge-ui/public/js/api.ts +52 -3
- package/src/homebridge-ui/public/js/app.ts +2 -1
- package/src/homebridge-ui/public/js/devices.ts +13 -1
- package/src/homebridge-ui/public/js/discovery.ts +1344 -142
- package/src/homebridge-ui/public/js/modals.ts +50 -1
- package/src/homebridge-ui/public/js/render.ts +421 -38
- package/src/platform.ts +3 -4
- package/src/switchbotClient.ts +44 -9
- package/test/e2e/run-e2e.spec.ts +12 -10
- package/test/helpers/matter-harness.ts +2 -2
- package/test/matter-integration.spec.ts +21 -0
- package/todo/COMPLETED.md +313 -0
- package/todo/TODO.md +80 -66
- package/switchbot-homebridge-switchbot-5.0.0.tgz +0 -0
package/todo/TODO.md
CHANGED
|
@@ -1,104 +1,118 @@
|
|
|
1
|
-
# SwitchBot Plugin TODO List
|
|
1
|
+
# SwitchBot Plugin TODO List (2026)
|
|
2
2
|
|
|
3
|
-
## Active Tasks
|
|
4
3
|
|
|
5
|
-
|
|
4
|
+
#### 8. Batch Import
|
|
6
5
|
|
|
7
|
-
-
|
|
6
|
+
- [x] Add checkboxes to select multiple devices
|
|
7
|
+
- [x] Add "Add Selected to Config" button
|
|
8
|
+
- [x] Implement bulk configuration with smart defaults
|
|
9
|
+
|
|
10
|
+
- [x] Show firmware update available indicators
|
|
11
|
+
- [x] Show offline/unreachable warnings
|
|
12
|
+
- [x] Add "Needs Attention" section at top
|
|
13
|
+
- [ ] Implement battery level trending (if historical data available)
|
|
14
|
+
|
|
15
|
+
#### 10. Export/Import Discovery
|
|
16
|
+
|
|
17
|
+
- [ ] Add "Export Results" button (JSON format)
|
|
18
|
+
- [ ] Add "Import Results" for comparison or troubleshooting
|
|
19
|
+
- [ ] Share with support for debugging
|
|
20
|
+
- [ ] Compare current vs previous discovery (show differences)
|
|
21
|
+
- [ ] Generate discovery report (formatted summary)
|
|
8
22
|
|
|
9
23
|
---
|
|
10
24
|
|
|
11
|
-
##
|
|
25
|
+
## Bug Fixes & Technical Debt
|
|
12
26
|
|
|
13
|
-
###
|
|
27
|
+
### Testing & Quality Assurance
|
|
14
28
|
|
|
15
|
-
|
|
29
|
+
- [ ] **Test discovery with real hardware**
|
|
30
|
+
- [ ] Test BLE discovery with nearby devices
|
|
31
|
+
- [ ] Test OpenAPI discovery with cloud-registered devices
|
|
32
|
+
- [ ] Test with mixed BLE+API devices
|
|
33
|
+
- [ ] Test connection type badge display
|
|
34
|
+
- [ ] Verify deduplication works correctly
|
|
16
35
|
|
|
17
|
-
- [ ]
|
|
18
|
-
- [ ]
|
|
19
|
-
- [ ]
|
|
20
|
-
- [ ]
|
|
21
|
-
- [ ]
|
|
36
|
+
- [ ] **Add error handling improvements**
|
|
37
|
+
- [ ] Better error messages for users
|
|
38
|
+
- [ ] Retry logic with exponential backoff
|
|
39
|
+
- [ ] Graceful degradation when BLE unavailable
|
|
40
|
+
- [ ] Network timeout handling
|
|
22
41
|
|
|
23
|
-
|
|
42
|
+
---
|
|
24
43
|
|
|
25
|
-
|
|
44
|
+
## Documentation
|
|
26
45
|
|
|
27
|
-
- [ ]
|
|
28
|
-
- [ ]
|
|
29
|
-
- [ ] Add
|
|
30
|
-
- [ ]
|
|
31
|
-
- [ ]
|
|
46
|
+
- [ ] **Update README with discovery features**
|
|
47
|
+
- [ ] Document BLE vs OpenAPI discovery
|
|
48
|
+
- [ ] Add screenshots of new UI features
|
|
49
|
+
- [ ] Explain connection type badges
|
|
50
|
+
- [ ] Add troubleshooting guide for discovery issues
|
|
32
51
|
|
|
33
|
-
|
|
52
|
+
- [ ] **Create developer documentation**
|
|
53
|
+
- [ ] Document new modular structure
|
|
54
|
+
- [ ] API documentation for endpoints
|
|
55
|
+
- [ ] Contributing guidelines for UI changes
|
|
34
56
|
|
|
35
|
-
|
|
36
|
-
- [ ] Add badge: "☁️ Recommended: API" for hub-dependent devices
|
|
37
|
-
- [ ] Show tooltip explaining why recommendation is made
|
|
38
|
-
- [ ] Consider device type (some work better with BLE vs API)
|
|
57
|
+
---
|
|
39
58
|
|
|
40
|
-
|
|
59
|
+
## Priority Summary
|
|
41
60
|
|
|
42
|
-
|
|
43
|
-
- [ ] Add option to disable BLE scanning if no Bluetooth adapter
|
|
44
|
-
- [ ] Add option to adjust BLE timeout
|
|
45
|
-
- [ ] Remember user preferences in localStorage
|
|
46
|
-
- [ ] Show system Bluetooth availability status
|
|
61
|
+
### Must Do (Next Release)
|
|
47
62
|
|
|
48
|
-
|
|
63
|
+
1. Better Loading States
|
|
49
64
|
|
|
50
|
-
|
|
51
|
-
- [ ] Show "Last scanned: X minutes ago" with timestamp
|
|
52
|
-
- [ ] Add "Refresh" button to re-scan
|
|
53
|
-
- [ ] Show cached results immediately on page load
|
|
54
|
-
- [ ] Auto-refresh option with configurable interval
|
|
65
|
+
### Should Do (Soon)
|
|
55
66
|
|
|
56
|
-
|
|
67
|
+
1. Connection Recommendations
|
|
68
|
+
2. Device Grouping
|
|
69
|
+
3. Test discovery with real hardware
|
|
70
|
+
4. Update README with new features
|
|
57
71
|
|
|
58
|
-
|
|
59
|
-
- [ ] Show extended information:
|
|
60
|
-
- [ ] Battery level (if available)
|
|
61
|
-
- [ ] Firmware version
|
|
62
|
-
- [ ] Cloud service enabled/disabled status
|
|
63
|
-
- [ ] Last seen timestamp
|
|
64
|
-
- [ ] Full MAC address
|
|
65
|
-
- [ ] Device capabilities/features
|
|
66
|
-
- [ ] Add "Copy ID" and "Copy MAC" buttons
|
|
72
|
+
### Nice to Have (Future)
|
|
67
73
|
|
|
68
|
-
|
|
74
|
+
1. Configurable BLE Scan
|
|
75
|
+
2. Discovery History/Cache
|
|
76
|
+
3. Connection Testing
|
|
77
|
+
4. Batch Import
|
|
78
|
+
5. Device Health Dashboard
|
|
69
79
|
|
|
70
|
-
|
|
80
|
+
---
|
|
81
|
+
|
|
82
|
+
## Notes
|
|
83
|
+
|
|
84
|
+
- See [COMPLETED.md](COMPLETED.md) for all completed features
|
|
85
|
+
- UI mockups available in [mockups/](mockups/) directory
|
|
86
|
+
- Consider user feedback on most-wanted features
|
|
87
|
+
- Test all changes with real SwitchBot devices
|
|
88
|
+
- Maintain backwards compatibility with existing configs
|
|
89
|
+
- Keep UI responsive and fast (< 500ms interactions)
|
|
90
|
+
- Follow Homebridge UI/UX conventions
|
|
91
|
+
# Integration: node-switchbot Beta Updates (March 2026)
|
|
92
|
+
|
|
93
|
+
## Tasks to Integrate Latest node-switchbot Features
|
|
94
|
+
|
|
95
|
+
|
|
96
|
+
## Next Features
|
|
97
|
+
|
|
98
|
+
### Advanced Features (Priority: Low)
|
|
71
99
|
|
|
72
|
-
- [ ] Show devices as they're discovered (streaming results)
|
|
73
|
-
- [ ] Add animated "pulsing" indicator for active BLE scan
|
|
74
|
-
- [ ] Update RSSI values in real-time during scan
|
|
75
|
-
- [ ] Show "X devices found..." counter during scan
|
|
76
100
|
|
|
77
|
-
#### 8. Connection Testing
|
|
78
101
|
|
|
79
|
-
- [ ] Add "Test Connection" button per device
|
|
80
|
-
- [ ] Attempt to connect and read basic device status
|
|
81
|
-
- [ ] Show success/failure indicator with details
|
|
82
|
-
- [ ] Display connection latency
|
|
83
|
-
- [ ] Show which connection method succeeded (BLE/API)
|
|
84
102
|
|
|
85
|
-
####
|
|
103
|
+
#### 8. Batch Import
|
|
86
104
|
|
|
87
105
|
- [ ] Add checkboxes to select multiple devices
|
|
88
106
|
- [ ] Add "Add Selected to Config" button
|
|
89
107
|
- [ ] Implement bulk configuration with smart defaults
|
|
90
|
-
- [ ] Show progress for batch operations
|
|
91
|
-
- [ ] Allow batch enable/disable of devices
|
|
92
108
|
|
|
93
|
-
#### 10. Device Health Dashboard
|
|
94
109
|
|
|
95
|
-
- [
|
|
96
|
-
- [
|
|
97
|
-
- [ ] Show offline/unreachable warnings
|
|
110
|
+
- [x] Show firmware update available indicators
|
|
111
|
+
- [x] Show offline/unreachable warnings
|
|
98
112
|
- [ ] Add "Needs Attention" section at top
|
|
99
113
|
- [ ] Implement battery level trending (if historical data available)
|
|
100
114
|
|
|
101
|
-
####
|
|
115
|
+
#### 10. Export/Import Discovery
|
|
102
116
|
|
|
103
117
|
- [ ] Add "Export Results" button (JSON format)
|
|
104
118
|
- [ ] Add "Import Results" for comparison or troubleshooting
|
|
Binary file
|