Skip to content

Commit

Permalink
fix: Properties x and y of BoundingRect is undefined in old browser (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
MoyuScript committed Jan 22, 2022
1 parent 67c5e8d commit e587a82
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/css/layout/bounds.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ export class Bounds {
const domRect = Array.from(domRectList).find((rect) => rect.width !== 0);
return domRect
? new Bounds(
domRect.x + context.windowBounds.left,
domRect.y + context.windowBounds.top,
domRect.left + context.windowBounds.left,
domRect.top + context.windowBounds.top,
domRect.width,
domRect.height
)
Expand Down

0 comments on commit e587a82

Please sign in to comment.