@meta2d/core 1.1.15 → 1.1.17
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/package.json +1 -1
- package/src/canvas/canvas.js +16 -1
- package/src/canvas/canvas.js.map +1 -1
- package/src/core.js +10 -1
- package/src/core.js.map +1 -1
- package/src/diagrams/video.js +3 -1
- package/src/diagrams/video.js.map +1 -1
- package/src/options.d.ts +2 -0
- package/src/options.js +2 -0
- package/src/options.js.map +1 -1
- package/src/pen/render.js +19 -1
- package/src/pen/render.js.map +1 -1
package/src/core.js
CHANGED
|
@@ -4505,7 +4505,16 @@ export class Meta2d {
|
|
|
4505
4505
|
if (this.store.options.unFill) {
|
|
4506
4506
|
return; //不自适应
|
|
4507
4507
|
}
|
|
4508
|
-
|
|
4508
|
+
let rect = {
|
|
4509
|
+
x: this.store.data.origin.x,
|
|
4510
|
+
y: this.store.data.origin.y,
|
|
4511
|
+
width: this.store.data.width * this.store.data.scale,
|
|
4512
|
+
height: this.store.data.height * this.store.data.scale,
|
|
4513
|
+
};
|
|
4514
|
+
if (isNaN(rect.width) || isNaN(rect.height)) {
|
|
4515
|
+
rect = this.getRect();
|
|
4516
|
+
}
|
|
4517
|
+
// const rect = this.getRect();
|
|
4509
4518
|
const wGap = this.canvas.width - rect.width;
|
|
4510
4519
|
const hGap = this.canvas.height - rect.height;
|
|
4511
4520
|
//宽度拉伸
|