mirror of
https://github.com/Foundry376/Mailspring.git
synced 2025-01-04 07:10:06 +08:00
fix(email-frame) Only use documentElement scrollHeight if it is taller than body
There are cases where the documentElement has a scrollHeight of 0, even if the body has a larger scrollHeight. Before, we were always using the documentElement if it was present. Now, we use the maximum scrollHeight.
This commit is contained in:
parent
7865da6b7d
commit
d996273b7b
1 changed files with 1 additions and 1 deletions
|
@ -114,7 +114,7 @@ export default class EmailFrame extends React.Component {
|
|||
}
|
||||
|
||||
if (doc && doc.documentElement) {
|
||||
height = doc.documentElement.scrollHeight;
|
||||
height = Math.max(height, doc.documentElement.scrollHeight);
|
||||
}
|
||||
|
||||
// scrollHeight does not include space required by scrollbar
|
||||
|
|
Loading…
Reference in a new issue