UX: Render wizard previews for high-DPI displays (#7371)

* UX: Render wizard previews for high-DPI displays

Sets up a canvas element of twice the required dimensions, scales all coordinates by 2x, then shrinks the display in css.

* Use window.devicePixelRatio to determine scale factor
This commit is contained in:
David Taylor
2019-04-15 07:16:05 +01:00
committed by Sam
parent e50494bcde
commit fd0de64e0d
2 changed files with 10 additions and 3 deletions

View File

@@ -1,4 +1,4 @@
<div class='preview-area'>
<canvas width={{width}} height={{height}}>
<canvas width={{elementWidth}} height={{elementHeight}} style={{concat "width:" width "; height:" height ";"}}>
</canvas>
</div>