Skip to content

[menu-button] Right aligned menu with wide item infinitely resizes #631

Open
@bradbarrow

Description

@bradbarrow

🐛 Bug report

Current Behavior

When a Menu-Button is right aligned to a viewport and one of it's items is wide enough that the MenuList needs to occupy the full width of the screen and the item will still wrap - the MenuList/Popover grows towards the left edge of the viewport but when it collides it starts from 0 width again and animates in an infinite loop.

reach-menu-bug

Note I am not using Reach UIs styles

When I do try and use Reach UIs styles, I experience this behaviour instead.

Expected behavior

I'd expect the MenuList/Popover to occupy the full available width of the screen and for the items inside it to wrap within themselves the same way they do when the button is left aligned.

Reproducible example

Sandbox

Sandbox with Reach UI styles

Additional context

Seems related perhaps to this: #189
At times I was able to reproduce the above issue in my same non-reach-ui-styles Sandbox above when resizing the viewport.

Your environment

image

Metadata

Metadata

Assignees

No one assigned

    Labels

    Help WantedExtra attention is neededType: BugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions