Skip to content

A reactive notebook for Python — run reproducible experiments, query with SQL, execute as a script, deploy as an app, and version with git. Stored as pure Python. All in a modern, AI-native editor.

fix(frontend): remove print page margin and inset content for themed PDF export (#9971)

Zhi Lic2971bc21e79
diff --git a/frontend/src/css/app/print.css b/frontend/src/css/app/print.css
index 8c9b1f64d9..669bb1efb2 100644
--- a/frontend/src/css/app/print.css
+++ b/frontend/src/css/app/print.css
@@ -16,6 +16,10 @@ body.printing #App {
height: fit-content !important;
overflow-y: visible !important;
overflow-x: hidden !important;
+
+ /* With @page margin:0 the themed background reaches the paper edge;
+ this padding insets printed content from all four edges. */
+ padding: 2rem !important;
}
h1,
@@ -69,4 +73,8 @@ body.printing #App {
padding-right: 0 !important;
max-height: none !important;
}
+
+ @page {
+ margin: 0;
+ }
}