Implementing effects. Closes #2 (#19)

Co-authored-by: osiu97 <osiu97@gmail.com>
Reviewed-on: #19
This commit was merged in pull request #19.
This commit is contained in:
2026-07-08 21:47:34 +02:00
parent 1a94ca3947
commit 9aa9d0f69f
9 changed files with 338 additions and 83 deletions
+11 -1
View File
@@ -1,6 +1,16 @@
import SequenceRunner from './sequence-runner.js';
import UI from './ui.js';
function getGlobalMode() {
const m1 = document.getElementById('mode-select');
if (m1) return m1.value;
const m2 = document.getElementById('seq-mode-select');
if (m2) return m2.value;
const m3 = document.getElementById('text-mode-select');
if (m3) return m3.value;
return 'direct';
}
export function buildQuickSequencesHTML() {
return `
<div class="card" id="quick-sequences-card" style="margin-bottom: 16px;">
@@ -49,7 +59,7 @@ export async function initQuickSequences(bgName, getSpots, getSteps, onStepCompl
if (seq) {
stopBtn.style.display = 'block';
const { steps1, steps2 } = getSteps();
await SequenceRunner.run(seq, getSpots(), steps1, steps2, onStepComplete);
await SequenceRunner.run(seq, getSpots(), steps1, steps2, getGlobalMode(), onStepComplete);
stopBtn.style.display = 'none';
}
});