feat(signage): menus play whole rounds, seconds fields with − / +, widget limit setting, widgets as big as their content (owner review 6)
- A menu board with pages plays whole rounds (menuMs rounds its seconds up); the editor says how long it really plays under "Seconds on screen", the card and the playlist total use it. - Seconds on screen / per page: shared NumberInput (− / +, may be emptied: an error under the field and Save blocked until filled; 1 s at least, server ge=1). - Performance (Signage -> Message & settings): widgets per slide (signage.max_widgets, 10 recommended, up to 50), checked by the server (signage.too_many_widgets) and the editor. - Text, clock, date, QR, weather, logo placed by hand: the box is exactly the content (its height x text size sets the size, the width follows; handles scale keeping the shape; text size grows the box); a slide's widget may run off the slide while 5 % stays on it. - Slider: the value as close to the slider as the frame's padding; floor and table-colour sliders use the shared Slider. Timeline cards' ring no longer clipped; larger playlist buttons. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -101,6 +101,11 @@ test('a menu slide stays for all its pages; the page on screen', () => {
|
||||
const slide = { kind: 'menu', duration_s: 10, content: { page_seconds: 8 } }
|
||||
assert.equal(menuMs(slide, 1), 10_000)
|
||||
assert.equal(menuMs(slide, 3), 24_000)
|
||||
// owner review 6: whole rounds only (10 s, 2 pages of 3 s → 2 rounds of 6 s = 12 s; 7 s of 2 × 3 s → 12 s; 12 s → 12 s)
|
||||
assert.equal(menuMs({ kind: 'menu', duration_s: 10, content: { page_seconds: 3 } }, 2), 12_000)
|
||||
assert.equal(menuMs({ kind: 'menu', duration_s: 7, content: { page_seconds: 3 } }, 2), 12_000)
|
||||
assert.equal(menuMs({ kind: 'menu', duration_s: 12, content: { page_seconds: 3 } }, 2), 12_000)
|
||||
assert.equal(menuMs({ kind: 'menu', duration_s: 2, content: { page_seconds: 5 } }, 3), 15_000)
|
||||
assert.equal(pageAt(3, 8, 0), 0)
|
||||
assert.equal(pageAt(3, 8, 8_100), 1)
|
||||
assert.equal(pageAt(3, 8, 16_500), 2)
|
||||
|
||||
Reference in New Issue
Block a user