Routing: white level text, short animation when switching; lock option in the PIN card
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
2fbb5e7424
commit
3ce0334aea
2 files changed
+23
-8
No files matched your search
+9
-6
@@ -1532,10 +1532,13 @@ function viewRouting(d) {
|
||||
h("span", { class: "chev" }, open ? "▴" : "▾")));
|
||||
ins.forEach((_, i) => {
|
||||
const on = oc.matrix >> i & 1;
|
||||
grid.append(h("button", { class: "xp" + (on ? " on" : ""), style: `--cc:${inColor(d, i)}`,
|
||||
const fx = S.xpFx === `${d.id}|${o}|${i}`; // just switched: short animation, once
|
||||
if (fx) S.xpFx = null;
|
||||
grid.append(h("button", { class: "xp" + (on ? " on" : "") + (fx ? " fx" : ""), style: `--cc:${inColor(d, i)}`,
|
||||
"aria-label": `${chLabel("in", i)} → ${chLabel("out", o)}`, "aria-pressed": String(!!on),
|
||||
onclick: () => {
|
||||
const m = chans(dev(), "out")[o].matrix ^ (1 << i);
|
||||
S.xpFx = `${d.id}|${o}|${i}`;
|
||||
setParam("out", o, "matrix", m); render();
|
||||
} }, h("span", { class: "node" }), on ? h("small", { title: `${sign(gainDb(oc.mix[i]))} dB` }, gainDb(oc.mix[i]) === 0 ? "0" : sign(gainDb(oc.mix[i]))) : null));
|
||||
});
|
||||
@@ -2239,13 +2242,12 @@ function backupCard() {
|
||||
}
|
||||
|
||||
// Desktop app only: let phones/tablets on the LAN use this PC as server (they need the PIN)
|
||||
function lockOptionCard() {
|
||||
function lockOption() {
|
||||
const box = h("input", { type: "checkbox", checked: !!S.lockDash, onchange: async () => {
|
||||
try { S.lockDash = (await api("POST", "/api/lock-dash", { enabled: box.checked })).enabled; }
|
||||
catch (e) { box.checked = !!S.lockDash; toast(t("Error: ") + trMsg(e.message)); }
|
||||
} });
|
||||
return h("div", { class: "card" }, h("h3", {}, t("Lock")),
|
||||
h("label", { class: "chk" }, box, t("Only show dashboard while locked")),
|
||||
return h("div", { class: "lockopt" }, h("label", { class: "chk" }, box, t("Only show dashboard while locked")),
|
||||
h("p", { class: "info" }, t("With the lock on, this window then shows just your dashboard, until it is unlocked with the PIN.")));
|
||||
}
|
||||
|
||||
@@ -2297,7 +2299,8 @@ function pinCard() {
|
||||
S.isApp ? null : h("button", { onclick: logout }, svgIcon(ICON.logout), t(" Log out")))),
|
||||
h("p", { class: "info" }, S.isApp
|
||||
? t("This app needs no PIN. The default is 1234; changing it logs out all phones.")
|
||||
: t("The default PIN is 1234. After changing it only this device stays logged in.")));
|
||||
: t("The default PIN is 1234. After changing it only this device stays logged in.")),
|
||||
S.isApp ? lockOption() : null);
|
||||
}
|
||||
|
||||
// ------------------------------------------------------------------ custom logo (top left and browser icon)
|
||||
@@ -2414,7 +2417,7 @@ function viewSettings() {
|
||||
["devices", t("Devices"), t("Several DSPs can be connected at the same time – pick one at the top. A DSP accepts only one connection: close the Thomann editor first."),
|
||||
"wide", [...S.order.filter(id => !S.devices[id].demo).map(id => deviceForm(S.devices[id])), scanCard(), addDeviceCard()]],
|
||||
["access", S.isApp ? t("Remote access") : t("Security"), S.isApp ? t("Let phones and tablets in your network control this computer – they log in with the PIN.") : t("Who may use this web interface."),
|
||||
"wide", [S.isApp ? remoteCard() : null, S.isApp ? lockOptionCard() : null, pinCard()]],
|
||||
"wide", [S.isApp ? remoteCard() : null, pinCard()]],
|
||||
["backup", t("Backup"), t("Save and restore the settings of this app."), "wide", [backupCard()]],
|
||||
];
|
||||
const nav = h("nav", { class: "setnav", "aria-label": t("Settings") }, sections.map(([id, title]) =>
|
||||
|
||||
Reference in new issue
Block a user