Monorepo for Aesthetic.Computer aesthetic.computer
4
fork

Configure Feed

Select the types of activity you want to include in your feed.

fix: F8 hold always toggles — press with nothing held to clear

F8 ON: engage hold mode (snapshot + auto-latch new notes)
F8 OFF: stop all held notes and clear, even if empty

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

+7 -7
+7 -7
fedac/native/pieces/notepat.mjs
··· 592 592 } 593 593 return; 594 594 } 595 - // F8: Hold/latch — capture currently-playing notes and keep them sounding 595 + // F8: Hold/latch toggle 596 + // ON: snapshot current keys + auto-latch new keys while held 597 + // OFF: stop all held notes and clear 596 598 if (key === "f8") { 597 599 if (holdActive) { 598 - // Release hold: stop all held notes 600 + // Clear hold: stop all held notes 599 601 for (const k of heldKeys) stopSoundKey(k, sound, system, 0.08); 600 602 heldKeys.clear(); 601 603 holdActive = false; 602 604 sound?.synth?.({ type: "sine", tone: 330, duration: 0.06, volume: 0.12, attack: 0.002, decay: 0.05 }); 603 605 } else { 604 - // Engage hold: snapshot all currently-sounding keys 606 + // Engage hold: snapshot current keys (may be empty — new keys auto-latch) 605 607 heldKeys = new Set(Object.keys(sounds)); 606 - holdActive = heldKeys.size > 0; 607 - if (holdActive) { 608 - sound?.synth?.({ type: "sine", tone: 660, duration: 0.06, volume: 0.12, attack: 0.002, decay: 0.05 }); 609 - } 608 + holdActive = true; 609 + sound?.synth?.({ type: "sine", tone: 660, duration: 0.06, volume: 0.12, attack: 0.002, decay: 0.05 }); 610 610 } 611 611 return; 612 612 }