Skip to content

Commit

Permalink
[@mantine/core] Popover: Fix issue when dropdown could be scrolled pa…
Browse files Browse the repository at this point in the history
…ss its target (#2694)
  • Loading branch information
Ryiski committed Oct 18, 2022
1 parent 1158833 commit 6aa574a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/mantine-core/src/Popover/use-popover.ts
Expand Up @@ -8,6 +8,7 @@ import {
size,
Middleware,
inline,
limitShift,
} from '@floating-ui/react-dom-interactions';
import { FloatingPosition, useFloatingAutoUpdate } from '../Floating';
import { PopoverWidth, PopoverMiddlewares } from './Popover.types';
Expand All @@ -31,7 +32,7 @@ function getPopoverMiddlewares(options: UsePopoverOptions) {
const middlewares: Middleware[] = [offset(options.offset)];

if (options.middlewares.shift) {
middlewares.push(shift());
middlewares.push(shift({ limiter: limitShift() }));
}

if (options.middlewares.flip) {
Expand Down

0 comments on commit 6aa574a

Please sign in to comment.