Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Popover doesn't respect placement prop #1411

Open
1 task
akos0horvath opened this issue Jan 9, 2024 · 3 comments
Open
1 task

Popover doesn't respect placement prop #1411

akos0horvath opened this issue Jan 9, 2024 · 3 comments
Assignees

Comments

@akos0horvath
Copy link

akos0horvath commented Jan 9, 2024

Background Information

Package Version(s):
ui-popover v8.51.0

Browser:
Chrome (All Versions)
Safari (All Versions)

OS:
MacOS 14.1.2

Device:
Macbook Pro

Component:
Popover

Describe the Bug

Popover doesn't respect placement property. See Steps To Reproduce.

Steps To Reproduce

1. Go to my minimal reproducible example: https://codesandbox.io/p/sandbox/busy-murdock-q3rwyy?file=%2Findex.js
2. Click on 'Sign In' to open the Popover
3. Reduce window size, and around the width of the Popover, the placement changes from 'bottom start' to 'bottom center'
4. On such small Popover this doesn't seem like a big issue, but the same exact behaviour is present with bigger Popover content; around the width of the content, the placement changes.

Expected Behavior

Placement prop is respected

Screenshots

Screen.Recording.2024-01-09.at.16.01.06.mov

Additional Information

Current Workaround(s):
Doesn't seem like it

Products Affected:

Are you willing to submit a PR to fix?

  • Yes, I'm willing to submit a PR

Requested Priority:
Normal

@HerrTopi
Copy link
Contributor

I think the behaviour is intended: the popover tries to fit to the space best it can. We'll take a look if we can improve on this in any meaningful and non breaking way and get back to you

@akos0horvath
Copy link
Author

akos0horvath commented Jan 18, 2024

Hmm, is this an intended behaviour?

Screenshot 2024-01-18 at 12 24 59

If I don't add the placement="bottom start" property, it displays normally, but if I add it, the above weirdness happens.

@HerrTopi
Copy link
Contributor

Well, no :D This really isn't the intended way. Thanks for the good examples, we'll look into it and keep you posted

@HerrTopi HerrTopi self-assigned this Feb 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants