@leafer-ui/mask 1.9.6 → 1.9.8

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.
Files changed (2) hide show
  1. package/package.json +5 -5
  2. package/src/index.ts +3 -2
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@leafer-ui/mask",
3
- "version": "1.9.6",
3
+ "version": "1.9.8",
4
4
  "description": "@leafer-ui/mask",
5
5
  "author": "Chao (Leafer) Wan",
6
6
  "license": "MIT",
@@ -22,11 +22,11 @@
22
22
  "leaferjs"
23
23
  ],
24
24
  "dependencies": {
25
- "@leafer/core": "1.9.6",
26
- "@leafer-ui/draw": "1.9.6"
25
+ "@leafer/core": "1.9.8",
26
+ "@leafer-ui/draw": "1.9.8"
27
27
  },
28
28
  "devDependencies": {
29
- "@leafer/interface": "1.9.6",
30
- "@leafer-ui/interface": "1.9.6"
29
+ "@leafer/interface": "1.9.8",
30
+ "@leafer-ui/interface": "1.9.8"
31
31
  }
32
32
  }
package/src/index.ts CHANGED
@@ -24,6 +24,9 @@ Group.prototype.__renderMask = function (canvas: ILeaferCanvas, options: IRender
24
24
  }
25
25
 
26
26
  // mask start
27
+
28
+ if (mask === 'clipping' || mask === 'clipping-path') excludeRenderBounds(child, options) || child.__render(canvas, options) // 剪贴蒙版,需要渲染自身到原画布中,如果应用遮罩会造成透明度减半。clipping-path 支持渲染外描边。
29
+
27
30
  maskOpacity = child.__.opacity
28
31
  usedGrayscaleAlpha = false
29
32
 
@@ -50,8 +53,6 @@ Group.prototype.__renderMask = function (canvas: ILeaferCanvas, options: IRender
50
53
 
51
54
  }
52
55
 
53
- if (mask === 'clipping' || mask === 'clipping-path') excludeRenderBounds(child, options) || child.__render(canvas, options) // 剪贴蒙版,需要渲染自身到原画布中,如果应用遮罩会造成透明度减半
54
-
55
56
  continue
56
57
  }
57
58