[feat](trx-frontend-http): add interleave time for overlapping TimeSpan entries

When multiple time-span entries are active simultaneously, the scheduler
now cycles through them by slot: slot = floor(utc_min / interleave_min) % count.
The interleave_min field is optional (null disables, first match wins).

UI: "Interleave time (min)" number input in the TimeSpan section with a
hint explaining the behaviour.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Signed-off-by: Stan Grams <sjg@haxx.space>
This commit is contained in:
2026-03-10 23:25:12 +01:00
parent c9d204ad1c
commit 4f9f93c9c1
3 changed files with 55 additions and 14 deletions
@@ -195,6 +195,13 @@
renderBookmarkSelect("scheduler-gl-night", null);
}
// Interleave input
const ilEl = document.getElementById("scheduler-ts-interleave");
if (ilEl) {
const il = currentConfig && currentConfig.interleave_min;
ilEl.value = il ? il : "";
}
// TimeSpan entries
renderTimespanEntries();
@@ -374,6 +381,8 @@
} else if (mode === "time_span") {
config.entries =
currentConfig && currentConfig.entries ? currentConfig.entries : [];
const ilVal = parseInt(document.getElementById("scheduler-ts-interleave").value, 10);
config.interleave_min = isNaN(ilVal) || ilVal <= 0 ? null : ilVal;
}
const btn = document.getElementById("scheduler-save-btn");