Skip to content

Commit 9aa66c8

Browse files
authored
fix: wrong layer z-axis position in Picker (DAP-4755) (#19)
1 parent f6d376a commit 9aa66c8

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

libs/engine/src/app/components/picker-highlighter.tsx

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,12 @@ import { Highlighter } from './highlighter'
66
const DEFAULT_INACTIVE_BORDER_COLOR = '#384BFF4D' // light blue
77
const DEFAULT_CHILDREN_BORDER_STYLE = 'dashed'
88

9-
const getElementDepth = (el: Element | ShadowRoot | null | undefined) => {
9+
const getElementDepth = (el: Element | Node | ShadowRoot | null | undefined) => {
1010
let depth = 0
11-
1211
while (el) {
1312
depth++
14-
el = el instanceof ShadowRoot ? el.host : el.parentElement
13+
el = el instanceof ShadowRoot ? el.host : el.parentNode
1514
}
16-
1715
return depth
1816
}
1917

0 commit comments

Comments
 (0)