mirror of
https://github.com/naturalcrit/homebrewery.git
synced 2025-12-26 16:02:38 +00:00
hide toolbar during printing
This commit is contained in:
@@ -23,6 +23,7 @@ const printCurrentBrew = ()=>{
|
||||
//Force DOM reflow; Print dialog causes a repaint, and @media print CSS somehow makes out-of-view pages disappear
|
||||
const node = window.frames['BrewRenderer'].contentDocument.getElementsByClassName('brewRenderer').item(0);
|
||||
node.style.display='none';
|
||||
node.getElementsByClassName('toolBar').item(0).style.display='none';
|
||||
node.offsetHeight; // accessing this is enough to trigger a reflow
|
||||
node.style.display='';
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user