Skip to content

Commit

Permalink
fix dpr bug
Browse files Browse the repository at this point in the history
  • Loading branch information
Ovilia committed Mar 8, 2018
1 parent 3a427bb commit e8b6067
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion dist/index-min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ var height = 0;
var lipstickData = null;

function init() {
width = window.innerWidth * bgDpi;
height = window.innerHeight * bgDpi;
width = Math.floor(window.innerWidth * bgDpi);
height = Math.floor(window.innerHeight * bgDpi);

var bgDom = document.getElementById('bg');
bgDom.setAttribute('width', width);
Expand Down

0 comments on commit e8b6067

Please sign in to comment.