leafer-ui 1.5.0 → 1.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -4
- package/dist/web.cjs +2 -2
- package/dist/web.cjs.map +1 -1
- package/dist/web.esm.js +2 -2
- package/dist/web.esm.js.map +1 -1
- package/dist/web.esm.min.js +1 -1
- package/dist/web.esm.min.js.map +1 -1
- package/dist/web.js +6 -10
- package/dist/web.js.map +1 -1
- package/dist/web.min.cjs +1 -1
- package/dist/web.min.cjs.map +1 -1
- package/dist/web.min.js +1 -1
- package/dist/web.min.js.map +1 -1
- package/dist/web.module.js +6 -10
- package/dist/web.module.js.map +1 -1
- package/dist/web.module.min.js +1 -1
- package/dist/web.module.min.js.map +1 -1
- package/package.json +12 -12
package/dist/web.esm.js
CHANGED
|
@@ -125,7 +125,7 @@ class LeaferCanvas extends LeaferCanvasBase {
|
|
|
125
125
|
else {
|
|
126
126
|
window.addEventListener('resize', this.windowListener = () => {
|
|
127
127
|
const pixelRatio = Platform.devicePixelRatio;
|
|
128
|
-
if (this.pixelRatio !== pixelRatio) {
|
|
128
|
+
if (!this.config.pixelRatio && this.pixelRatio !== pixelRatio) {
|
|
129
129
|
const { width, height } = this;
|
|
130
130
|
this.emitResize({ width, height, pixelRatio });
|
|
131
131
|
}
|
|
@@ -142,7 +142,7 @@ class LeaferCanvas extends LeaferCanvasBase {
|
|
|
142
142
|
checkAutoBounds(parentSize) {
|
|
143
143
|
const view = this.view;
|
|
144
144
|
const { x, y, width, height } = this.autoBounds.getBoundsFrom(parentSize);
|
|
145
|
-
const size = { width, height, pixelRatio: Platform.devicePixelRatio };
|
|
145
|
+
const size = { width, height, pixelRatio: this.config.pixelRatio ? this.pixelRatio : Platform.devicePixelRatio };
|
|
146
146
|
if (!this.isSameSize(size)) {
|
|
147
147
|
const { style } = view;
|
|
148
148
|
style.marginLeft = x + 'px';
|