修复 bug
This commit is contained in:
@@ -158,6 +158,21 @@ export function freqLabel(freq: unknown) {
|
||||
return String(Math.round(hz));
|
||||
}
|
||||
|
||||
/** Dev: log decoded syncPeq JSON after EQ page fetches device PEQ state. */
|
||||
export function logEqSyncPeqDev(source: string, data: PeqState): void {
|
||||
if (!import.meta.env.DEV) return;
|
||||
console.log(`[EQ syncPeq] ${source}`, data);
|
||||
}
|
||||
|
||||
export async function fetchEqSyncPeq(
|
||||
api: { getPeqState: () => Promise<PeqState> },
|
||||
source: string,
|
||||
): Promise<PeqState> {
|
||||
const data = await api.getPeqState();
|
||||
logEqSyncPeqDev(source, data);
|
||||
return data;
|
||||
}
|
||||
|
||||
/* ── Build PEQ catalog sync key ── */
|
||||
export function buildPeqCatalogSyncKey(
|
||||
remote: Pick<PeqState, "peq" | "peqSelect"> | null | undefined,
|
||||
|
||||
Reference in New Issue
Block a user