Browse Source

Merge pull request #22 in PG/plugin-bi-screen-adaptive from ~FAY/plugin-bi-screen-adaptive:release/10.0 to release/10.0

* commit '3a9ba966983648f3650747469213b384b5e06eef':
  BI-56250 fix:缩小的情况有滚动条
release/10.0
fay 5 years ago
parent
commit
6f5050f22f
  1. 8
      src/main/resources/com/finebi/plugin/web/plugin.screen_adaptive.js
  2. 8
      src/main/resources/com/finebi/plugin/web/scripts/entry.js

8
src/main/resources/com/finebi/plugin/web/plugin.screen_adaptive.js

@ -64,6 +64,11 @@
document.body.style.overflowY = "auto";
html.style.backgroundColor = "#ffffff";
if (scale < 1) {
document.body.style.width = bounds.width + "px";
document.body.style.height = bounds.height + "px";
}
window.scale = window.devicePixelRatio * scale;
}
@ -82,6 +87,9 @@
document.body.style.overflowY = "hidden";
html.style.backgroundColor = "#ffffff";
document.body.style.width = "100%";
document.body.style.height = "100%";
scale = 1;
window.scale = window.devicePixelRatio / scale;
}

8
src/main/resources/com/finebi/plugin/web/scripts/entry.js

@ -64,6 +64,11 @@
document.body.style.overflowY = "auto";
html.style.backgroundColor = "#ffffff";
if (scale < 1) {
document.body.style.width = bounds.width + "px";
document.body.style.height = bounds.height + "px";
}
window.scale = window.devicePixelRatio * scale;
}
@ -82,6 +87,9 @@
document.body.style.overflowY = "hidden";
html.style.backgroundColor = "#ffffff";
document.body.style.width = "100%";
document.body.style.height = "100%";
scale = 1;
window.scale = window.devicePixelRatio / scale;
}

Loading…
Cancel
Save