Plugin lives in Plugin/ — invisible to User Script Plugin. dev_install.sh symlinks into /usr/local/emhttp/plugins/varaverk/ for development. Pages: Monitor (5s poll), Scheduler (orchs + Advanced children, toggle + cron), Config (raw editor, host-aware file access), Docs (markdown + live $VAR substitution). API endpoints: monitor.php (JSON), scheduler.php (writes schedule.json + cron.d), config.php (writes conf files with host permission check). Includes: config.php (parser, host detection, var map), scheduler.php (job tree, cron.d rebuild), monitor.php (docker, GPU, resources, fallback, transcode), docs.php (file tree, var substitution, Parsedown renderer).
10 lines
299 B
JavaScript
10 lines
299 B
JavaScript
// Varaverk — shared JS utilities
|
|
// Page-specific JS lives inline in each page partial.
|
|
|
|
// Flash a status element briefly then fade
|
|
function vvFlashStatus(el, msg, ok) {
|
|
el.textContent = msg;
|
|
el.style.color = ok ? '#4caf50' : '#f44336';
|
|
setTimeout(() => { el.textContent = ''; }, 3000);
|
|
}
|