From 4759b0c08e1e5667ad01cdb3299eb69889883e5e Mon Sep 17 00:00:00 2001 From: TeaTinyTool Date: Sat, 13 Jun 2026 17:52:26 +0200 Subject: [PATCH 1/2] Improve dark mode support for editor and preview Make the ACE editor and file preview follow the current TinyFileManager theme. Dark mode now uses a matching ACE theme and a separate Highlight.js style for previews, while light mode keeps the existing behavior. Plain text previews without Highlight.js also receive dark mode styling. --- tinyfilemanager.php | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/tinyfilemanager.php b/tinyfilemanager.php index 9dfa94cf9..7e459441a 100644 --- a/tinyfilemanager.php +++ b/tinyfilemanager.php @@ -49,6 +49,7 @@ // highlight.js style // for dark theme use 'ir-black' $highlightjs_style = 'vs'; +$highlightjs_style_dark = 'vs2015'; // Enable ace.js (https://ace.c9.io/) on view's page $edit_files = true; @@ -176,6 +177,7 @@ 'css-dropzone' => '', 'css-font-awesome' => '', 'css-highlightjs' => '', + 'css-highlightjs-dark' => '', 'js-ace' => '', 'js-bootstrap' => '', 'js-dropzone' => '', @@ -4028,7 +4030,7 @@ function fm_show_header() - +