Add widget item type with editable sound and spatial controls

This commit is contained in:
Jage9
2026-02-21 22:20:15 -05:00
parent 97caaef001
commit bb36a007e2
16 changed files with 309 additions and 27 deletions

View File

@@ -91,13 +91,23 @@ export class CanvasRenderer {
? '#f97316'
: item.type === 'clock'
? '#86efac'
: '#60a5fa';
: item.type === 'widget'
? '#22d3ee'
: '#60a5fa';
this.ctx.fillRect(drawX, drawY, this.squarePixelSize, this.squarePixelSize);
this.ctx.fillStyle = '#111827';
this.ctx.font = 'bold 12px Courier New';
this.ctx.textAlign = 'center';
this.ctx.fillText(
item.type === 'radio_station' ? 'R' : item.type === 'wheel' ? 'W' : item.type === 'clock' ? 'C' : 'D',
item.type === 'radio_station'
? 'R'
: item.type === 'wheel'
? 'W'
: item.type === 'clock'
? 'C'
: item.type === 'widget'
? 'B'
: 'D',
drawX + this.squarePixelSize / 2,
drawY + 13,
);