Add chamber light control to printer card

- Add light toggle button next to camera button at bottom of card
  - Custom ChamberLight SVG icon with on/off states (yellow fill + rays when on)
  - Backend endpoint: POST /printers/{id}/chamber-light?on=true|false
  - Optimistic UI update for instant feedback
  - Works on all Bambu Lab printers (X1, P1, A1, H2D)
  - H2D dual chamber lights controlled together

Closes #67
This commit is contained in:
maziggy
2026-01-11 08:47:13 +01:00
parent fa7296389b
commit 6f6df1e339
8 changed files with 502 additions and 380 deletions
+6
View File
@@ -1333,6 +1333,12 @@ export const api = {
method: 'POST',
}),
// Chamber Light Control
setChamberLight: (printerId: number, on: boolean) =>
request<{ success: boolean; message: string }>(`/printers/${printerId}/chamber-light?on=${on}`, {
method: 'POST',
}),
// Skip Objects
getPrintableObjects: (printerId: number) =>
request<{