No DSPs by default: new installs start empty and say so
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
9c6d2d6e35
commit
763a8781f4
5 files changed
+22
-6
No files matched your search
+14
-2
@@ -2409,6 +2409,17 @@ function viewSettings() {
|
||||
// ------------------------------------------------------------------ render
|
||||
|
||||
const H_SCROLL = ".mixer, .bands, .geq, .routing";
|
||||
// first start: nothing added yet
|
||||
function noDspView() {
|
||||
return h("div", { class: "empty nodsp" }, svgIcon('<rect x="3" y="7" width="18" height="10" rx="2"/><path d="M7 12h.01M11 12h6"/>'),
|
||||
h("b", {}, t("No DSP added yet")),
|
||||
h("p", {}, t("Add your DSP over the network or USB. To look around first, switch on demo mode in the settings.")),
|
||||
h("button", { class: "on", "data-view-ok": "", onclick: () => {
|
||||
S.settings = true; S.addDev = true; render();
|
||||
document.getElementById("set-devices")?.scrollIntoView({ block: "start" });
|
||||
} }, t("Add a DSP")));
|
||||
}
|
||||
|
||||
function render() {
|
||||
if (S.busy) { S.dirty = true; return; }
|
||||
if ($("#app").hidden) return;
|
||||
@@ -2429,10 +2440,11 @@ function render() {
|
||||
const d = dev();
|
||||
const field = !S.settings && S.view === "soundfield"; // the room plan works without a connected DSP
|
||||
const dash = !S.settings && S.view === "dash"; // shows all DSPs, works without any
|
||||
document.body.dataset.view = field ? "soundfield" : dash ? "dash" : S.settings || !d ? "settings" : S.view;
|
||||
document.body.dataset.view = field ? "soundfield" : dash ? "dash" : S.settings ? "settings" : S.view;
|
||||
if (field) content = viewSoundField();
|
||||
else if (dash) content = viewDash();
|
||||
else if (S.settings || !d) content = viewSettings();
|
||||
else if (S.settings) content = viewSettings();
|
||||
else if (!d) content = noDspView();
|
||||
else if (d.status !== "online" || !d.state)
|
||||
content = h("div", { class: "empty" }, h("div", { class: "spinner" + (["loading", "connecting"].includes(d.status) ? "" : " off") }),
|
||||
d.status === "loading" ? t("Loading the configuration from the DSP…")
|
||||
|
||||
@@ -388,6 +388,7 @@ function dashModule(m) {
|
||||
|
||||
function viewDash() {
|
||||
if (viewOnly()) dashEdit = false;
|
||||
if (!dashDevs().length) return noDspView();
|
||||
const mods = dashMods();
|
||||
return [
|
||||
h("div", { class: "dhead" }, h("h2", {}, "Dashboard"),
|
||||
|
||||
@@ -581,6 +581,8 @@ const DE = {
|
||||
"Read-only": "Nur ansehen",
|
||||
"Edit mode – changes go to the DSP": "Bearbeiten – Änderungen gehen an den DSP",
|
||||
"Read-only – switch to edit at the top": "Nur ansehen – oben auf Bearbeiten umschalten",
|
||||
"No DSP added yet": "Noch kein DSP angelegt",
|
||||
"Add your DSP over the network or USB. To look around first, switch on demo mode in the settings.": "Lege deinen DSP über Netzwerk oder USB an. Zum Ausprobieren gibt es in den Einstellungen den Demo-Modus.",
|
||||
};
|
||||
|
||||
const DE_PATTERNS = [
|
||||
|
||||
@@ -884,3 +884,7 @@ canvas.dcurve { display: block; width: 100%; flex: 1 1 0; min-height: 70px; back
|
||||
.guard.on .guardtrack { background: var(--accent); }
|
||||
.guard.on .guardtrack i { left: 14px; }
|
||||
body.locked #main input[type=range] { pointer-events: none; }
|
||||
.nodsp { gap: 10px; }
|
||||
.nodsp svg { width: 44px; height: 44px; fill: none; stroke: var(--dim); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
|
||||
.nodsp b { color: var(--text); font-size: 18px; }
|
||||
.nodsp p { max-width: 420px; margin: 0 0 6px; line-height: 1.45; }
|
||||
Reference in new issue
Block a user