From cd335419ffa5d42cf02d4ad66aa8d7bcc25e1ec7 Mon Sep 17 00:00:00 2001
From: David <33458145+davidmcpowell@users.noreply.github.com>
Date: Mon, 10 Nov 2025 10:42:19 +0000
Subject: [PATCH] Merge pull request #29603 from overleaf/dp-detached-pdf-light
Fix missing light theme for detached pdf
GitOrigin-RevId: 61af7e34c44f6d2842ca9d5c1b5d7458a2a1a6c8
---
.../components/pdf-preview-detached-root.tsx | 14 +++++++++++---
1 file changed, 11 insertions(+), 3 deletions(-)
diff --git a/services/web/frontend/js/features/pdf-preview/components/pdf-preview-detached-root.tsx b/services/web/frontend/js/features/pdf-preview/components/pdf-preview-detached-root.tsx
index 09c81c5820..2f9e661773 100644
--- a/services/web/frontend/js/features/pdf-preview/components/pdf-preview-detached-root.tsx
+++ b/services/web/frontend/js/features/pdf-preview/components/pdf-preview-detached-root.tsx
@@ -3,6 +3,7 @@ import PdfPreview from './pdf-preview'
import useWaitForI18n from '../../../shared/hooks/use-wait-for-i18n'
import { ReactContextRoot } from '@/features/ide-react/context/react-context-root'
import { useIsNewEditorEnabled } from '@/features/ide-redesign/utils/new-editor-utils'
+import useThemedPage from '@/shared/hooks/use-themed-page'
function PdfPreviewDetachedRoot() {
const { isReady } = useWaitForI18n()
@@ -13,13 +14,20 @@ function PdfPreviewDetachedRoot() {
return (
-
-
-
+
)
}
+function PdfPreviewDetachedRootContent() {
+ useThemedPage() // set the page theme based on user settings
+
+ return (
+
+
+
+ )
+}
function EditorRedesignWrapper({ children }: { children: React.ReactNode }) {
const newEditorEnabled = useIsNewEditorEnabled()
if (!newEditorEnabled) {