Fix form input text positions (Fix #1338 #1347)

This commit is contained in:
Niklas von Hertzen 2017-12-31 19:38:31 +08:00
parent cc9d1f89dc
commit 79e1c857e6

View File

@ -133,7 +133,7 @@ const inlineFormElement = (
if (value.length > 0 && body) { if (value.length > 0 && body) {
const wrapper = node.ownerDocument.createElement('html2canvaswrapper'); const wrapper = node.ownerDocument.createElement('html2canvaswrapper');
copyCSSStyles(node.ownerDocument.defaultView.getComputedStyle(node, null), wrapper); copyCSSStyles(node.ownerDocument.defaultView.getComputedStyle(node, null), wrapper);
wrapper.style.position = 'fixed'; wrapper.style.position = 'absolute';
wrapper.style.left = `${container.bounds.left}px`; wrapper.style.left = `${container.bounds.left}px`;
wrapper.style.top = `${container.bounds.top}px`; wrapper.style.top = `${container.bounds.top}px`;
if (!allowLinebreak) { if (!allowLinebreak) {