@leafer-draw/miniapp 2.1.8 → 2.1.9

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.
@@ -6984,7 +6984,7 @@ class LeafLevelList {
6984
6984
  }
6985
6985
  }
6986
6986
 
6987
- const version = "2.1.8";
6987
+ const version = "2.1.9";
6988
6988
 
6989
6989
  class LeaferCanvas extends LeaferCanvasBase {
6990
6990
  get allowBackgroundColor() {
@@ -7300,7 +7300,10 @@ class Watcher {
7300
7300
  if (this.running) this.target.emit(RenderEvent.REQUEST);
7301
7301
  }
7302
7302
  __onAttrChange(event) {
7303
- if (this.config.usePartLayout) this.__updatedList.add(event.target);
7303
+ this.add(event.target);
7304
+ }
7305
+ add(leaf) {
7306
+ if (this.config.usePartLayout) this.__updatedList.add(leaf);
7304
7307
  this.update();
7305
7308
  }
7306
7309
  __onChildEvent(event) {
@@ -8139,11 +8142,7 @@ class PolygonData extends UIData {
8139
8142
  }
8140
8143
  }
8141
8144
 
8142
- class StarData extends UIData {
8143
- get __boxStroke() {
8144
- return !this.__pathInputed;
8145
- }
8146
- }
8145
+ class StarData extends UIData {}
8147
8146
 
8148
8147
  class PathData extends UIData {
8149
8148
  get __pathInputed() {
@@ -10436,13 +10435,9 @@ function createPattern(paint, ui, canvas, renderOptions) {
10436
10435
  if (fixScale) scaleX *= fixScale, scaleY *= fixScale;
10437
10436
  width *= scaleX;
10438
10437
  height *= scaleY;
10439
- if (gap) {
10438
+ if (gap && !brush) {
10440
10439
  xGap = gap.x * scaleX / abs$1(data.scaleX || 1);
10441
10440
  yGap = gap.y * scaleY / abs$1(data.scaleY || 1);
10442
- if (brush) {
10443
- const brushScale = PaintImage.getBrushScale(paint, ui);
10444
- xGap /= brushScale, yGap /= brushScale;
10445
- }
10446
10441
  }
10447
10442
  if (transform || scaleX !== 1 || scaleY !== 1) {
10448
10443
  scaleX *= getFloorScale(width + (xGap || 0));