mirror of
https://github.com/cryptpad/cryptpad.git
synced 2026-09-14 11:05:41 +05:00
#2024 can print whole form as participant
This commit is contained in:
parent
dc30486d8f
commit
bb94d87ec4
@ -1553,3 +1553,15 @@
|
||||
.charts_main();
|
||||
}
|
||||
|
||||
@media print {
|
||||
html,
|
||||
body {
|
||||
height: auto !important;
|
||||
overflow: visible !important;
|
||||
}
|
||||
|
||||
.cp-form-creator-container {
|
||||
max-height: none !important;
|
||||
overflow-y: visible !important
|
||||
}
|
||||
}
|
||||
@ -131,24 +131,8 @@ define([
|
||||
var nativePrint = window.print.bind(window);
|
||||
|
||||
var printFullContent = function () {
|
||||
var target = document.querySelector('.cp-form-creator-container');
|
||||
if (!target) { nativePrint(); return; }
|
||||
|
||||
var prevHeight = target.style.height;
|
||||
var prevOverflow = target.style.overflow;
|
||||
var prevOverflowY = target.style.overflowY;
|
||||
var prevMaxHeight = target.style.maxHeight;
|
||||
|
||||
target.style.setProperty('height', 'auto', 'important');
|
||||
target.style.setProperty('max-height', 'none', 'important');
|
||||
target.style.setProperty('overflow', 'visible', 'important');
|
||||
target.style.setProperty('overflow-y', 'visible', 'important');
|
||||
|
||||
var restore = function () {
|
||||
target.style.height = prevHeight;
|
||||
target.style.overflow = prevOverflow;
|
||||
target.style.overflowY = prevOverflowY;
|
||||
target.style.maxHeight = prevMaxHeight;
|
||||
window.onafterprint = null;
|
||||
};
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user