From d064ba930d268ecf98c372d03451f908ecd95924 Mon Sep 17 00:00:00 2001 From: Til Schmitter Date: Sat, 20 Jun 2026 20:43:41 +0200 Subject: [PATCH] fix reading accent color in settings --- copyparty/web/browser.js | 3 +++ copyparty/web/util.js | 2 -- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/copyparty/web/browser.js b/copyparty/web/browser.js index c29aea67..e9086e7f 100644 --- a/copyparty/web/browser.js +++ b/copyparty/web/browser.js @@ -1501,6 +1501,9 @@ ebi('accent').oninput = ebi('accent_picker').oninput = function () { setColor(validcolor); }, 100); } +if(accent && accent.length > 3){ + ebi('accent').value = ebi('accent_picker').value = accent; +} // corner radius ebi('radius').oninput = function () { diff --git a/copyparty/web/util.js b/copyparty/web/util.js index ee6fa110..f4b661ab 100644 --- a/copyparty/web/util.js +++ b/copyparty/web/util.js @@ -2372,8 +2372,6 @@ var thing = QS('meta[name=theme-color]'); if(accent && accent.length > 3){ console.log('read accent color from settings: ' + accent); document.documentElement.style.setProperty('--a', parseColor(accent)); - if(ebi('accent')) - ebi('accent').value = ebi('accent_picker').value = accent; } function bchrome() {