From 10e22654ea21c15006338f497af0c86f53736ec4 Mon Sep 17 00:00:00 2001 From: Laurent Cozic Date: Wed, 4 Sep 2019 20:11:35 +0100 Subject: [PATCH] Desktop: Fixes #1815: Fixed cropped content issue when printing or exporting to PDF --- ReactNativeClient/lib/renderers/noteStyle.js | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/ReactNativeClient/lib/renderers/noteStyle.js b/ReactNativeClient/lib/renderers/noteStyle.js index ee7c72f376..515c348261 100644 --- a/ReactNativeClient/lib/renderers/noteStyle.js +++ b/ReactNativeClient/lib/renderers/noteStyle.js @@ -253,6 +253,14 @@ module.exports = function(style, options) { .code, .inline-code { border: 1px solid #CBCBCB; } + + #content { + /* The height of the content is set dynamically by JavaScript (in updateBodyHeight) to go + around various issues related to scrolling. However when printing we don't want this + fixed size as that would crop the content. So we set it to auto here. "important" is + needed to override the style set by JavaScript at the element-level. */ + height: auto !important; + } } `;