mirror of
https://github.com/discourse/discourse.git
synced 2024-12-04 05:53:43 +08:00
fd0de64e0d
* 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
5 lines
160 B
Handlebars
5 lines
160 B
Handlebars
<div class='preview-area'>
|
|
<canvas width={{elementWidth}} height={{elementHeight}} style={{concat "width:" width "; height:" height ";"}}>
|
|
</canvas>
|
|
</div>
|