Skip to content

[Popper] Use floating-ui #1531

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

Merged
merged 25 commits into from
Jul 19, 2022
Merged

[Popper] Use floating-ui #1531

merged 25 commits into from
Jul 19, 2022

Conversation

benoitgrelard
Copy link
Contributor

@benoitgrelard benoitgrelard commented Jul 15, 2022

Follow up PR: #1540


Supersedes #1516

Fixes #370
Fixes #557
Fixes #740
Fixes #781
Fixes #800
Fixes #1445
Fixes #1464

Others potentially linked to investigate:
#791 — explore this
#945 — may be doable now with use of mainAxis shift, but not sure it's worth it, probably needs a diff pattern
#1087 — linked to #791


Warning
Docs updates:

  • 🔥 Arrow offset prop is gone
  • 🔥 Content collisionTolerance prop is renamed to collisionPadding and accept number | Padding
  • Content arrowPadding prop is new
  • Content sticky prop is new
  • Content hideWhenDetached prop is new
  • No need for Portal part around submenu contents (in DropdownMenu and ContextMenu)
  • Update demos accordingly

  • Also once PR is merged, go on main and delete references to core/popper in version files (only 1 I think)

@benoitgrelard benoitgrelard added PR: Breaking Change This PR contains a breaking change PR: Documentation Needed This PR warrants a documentation update labels Jul 18, 2022
@benoitgrelard benoitgrelard marked this pull request as ready for review July 18, 2022 15:42
@benoitgrelard benoitgrelard requested a review from andy-hook as a code owner July 18, 2022 15:42
@benoitgrelard benoitgrelard merged commit 87bf377 into main Jul 19, 2022
@benoitgrelard benoitgrelard deleted the floating-ui branch July 19, 2022 17:52
luisorbaiceta pushed a commit to luisorbaiceta/primitives that referenced this pull request Jul 21, 2022
* [Popper] Use `floating-ui`

* Re-integrate collision props

* Align stories

* Align for chromatic

* More chromatic bits

* Update DropdownMenu.stories.tsx

* Restore Popper stories

* Cater for PopperContent in Portal positioning issues

* Hide arrow automatically

* Add Popper chromatic story

* Update Popper.stories.tsx

* Delete old `core/popper` package

* Delete usage of Arrow `offset` prop

* Update 07c2bf00.yml

* Default to `fixed` strategy

* Expose `arrowPadding` prop

* No need for Portal on sub in ContextMenu and DropdownMenu

* Fix typeahead scoping in submenus

* Add comments

* PR feedback

* Expose more configuration

* Fix story for chromatic

* Add padding to chromatic stories

* Add delay to chromatic stories

* Fix chromatic
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment