Environment Information
- Package version(s): v9 and v0
Please provide a reproduction of the bug in a codepen:
https://codesandbox.io/s/elastic-banach-78uu1p?file=/example.tsx
Actual behavior:
The current offset modifier used in usePopper will always invert the offset of the cross axis for all placements.
|
const offsetModifier = React.useMemo( |
|
() => |
|
offset |
|
? { |
|
name: 'offset', |
|
options: { offset: isRtl ? applyRtlToOffset(offset) : offset }, |
|
} |
|
: null, |
|
[offset, isRtl], |
|
); |
This means that even if the cross axis is vertical, the offset is inverted in RTL.
Expected behavior:
If the cross axis is vertical, then offset should be unchanged.
Priorities and help requested:
Are you willing to submit a PR to fix? Yes
Requested priority: Normal
Products/sites affected: (if applicable)
Environment Information
Please provide a reproduction of the bug in a codepen:
https://codesandbox.io/s/elastic-banach-78uu1p?file=/example.tsx
Actual behavior:
The current offset modifier used in
usePopperwill always invert the offset of the cross axis for all placements.fluentui/packages/react-positioning/src/usePopper.ts
Lines 81 to 90 in f8cf163
This means that even if the cross axis is vertical, the offset is inverted in RTL.
Expected behavior:
If the cross axis is vertical, then offset should be unchanged.
Priorities and help requested:
Are you willing to submit a PR to fix? Yes
Requested priority: Normal
Products/sites affected: (if applicable)