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

Group headers are not correctly aligned when using anchor_align: :end in Primer::Alpha::ActionMenu #2950

Closed
HDinger opened this issue Jul 17, 2024 · 0 comments · Fixed by #2951
Labels

Comments

@HDinger
Copy link
Contributor

HDinger commented Jul 17, 2024

Steps to reproduce

  • Create a Primer::Alpha::ActionMenu with anchor_align: :end and groups
  • e.g:
<div style="display: grid; place-content: center;">
<%= render(Primer::Alpha::ActionMenu.new(anchor_align: :end)) do |component| %>
  <% component.with_show_button { "Menu" } %>
    <% component.with_group do |group|
      group.with_heading(title: "Vegetarian options")
      group.with_item(label: "Grilled portbello mushroom")
      group.with_item(label: "Polenta")
    end %>
<% end %>
</div>

Actual behavior

  • The menu opens correctly positioned
  • The items are correclty aligned on the left side
  • The group header is aligned at the right side
Bildschirmfoto 2024-07-17 um 13 10 15

Expected behaviour

  • The group header should also be left aligned, no matter how the menu is positioned.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
1 participant