@leafer/selector 1.0.0-rc.25 → 1.0.0-rc.27

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 +3 -3
  2. package/src/Picker.ts +5 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@leafer/selector",
3
- "version": "1.0.0-rc.25",
3
+ "version": "1.0.0-rc.27",
4
4
  "description": "@leafer/selector",
5
5
  "author": "Chao (Leafer) Wan",
6
6
  "license": "MIT",
@@ -22,9 +22,9 @@
22
22
  "leaferjs"
23
23
  ],
24
24
  "dependencies": {
25
- "@leafer/core": "1.0.0-rc.25"
25
+ "@leafer/core": "1.0.0-rc.27"
26
26
  },
27
27
  "devDependencies": {
28
- "@leafer/interface": "1.0.0-rc.25"
28
+ "@leafer/interface": "1.0.0-rc.27"
29
29
  }
30
30
  }
package/src/Picker.ts CHANGED
@@ -136,7 +136,11 @@ export class Picker {
136
136
 
137
137
  protected hitChild(child: ILeaf, point: IRadiusPointData, proxy?: ILeaf): void {
138
138
  if (this.exclude && this.exclude.has(child)) return
139
- if (child.__hitWorld(point)) this.findList.add(proxy || child)
139
+ if (child.__hitWorld(point)) {
140
+ const { parent } = child
141
+ if (parent && parent.__hasMask && !child.__.mask && !parent.children.some(item => item.__.mask && item.__hitWorld(point))) return
142
+ this.findList.add(proxy || child)
143
+ }
140
144
  }
141
145
 
142
146
  protected clear(): void {