Skip to content

Commit f54b283

Browse files
committed
Fix dark theme on public link shares
Signed-off-by: szaimen <szaimen@e.mail.de>
1 parent 09b38bc commit f54b283

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

apps/files/js/filelist.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1662,6 +1662,10 @@
16621662
tr.append(td);
16631663

16641664
var isDarkTheme = OCA.Accessibility && OCA.Accessibility.theme === 'dark'
1665+
// Needed for public pages:
1666+
if (!OCA.Accessibility && window.matchMedia && window.matchMedia('(prefers-color-scheme: dark)').matches) {
1667+
var isDarkTheme = true;
1668+
}
16651669

16661670
try {
16671671
var maxContrastHex = window.getComputedStyle(document.documentElement)

0 commit comments

Comments
 (0)