Skip to content

Commit

Permalink
fix: issue with compute-position-on-mount
Browse files Browse the repository at this point in the history
  • Loading branch information
segunadebayo committed Oct 6, 2021
1 parent 7d54710 commit d557a08
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/eight-waves-agree.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@chakra-ui/popover": patch
---

Fix issue where `computePositionOnMount` didn't work without explict value
2 changes: 1 addition & 1 deletion packages/popover/src/use-popover.ts
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ export function usePopover(props: UsePopoverProps = {}) {
forceUpdate,
} = usePopper({
...popperProps,
enabled: isOpen || computePositionOnMount,
enabled: isOpen || !!computePositionOnMount,
})

useFocusOnPointerDown({
Expand Down

0 comments on commit d557a08

Please sign in to comment.