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

Pharos Menu styling issue when the last menu item is an mfe being mounted #864

Open
ymouzakis opened this issue Jan 30, 2025 · 1 comment

Comments

@ymouzakis
Copy link
Contributor

Expected behavior
Second to last menu item is lacking border.

Actual behavior
Each menu item has a border except for the last one.

Steps to reproduce the issue

  1. Create a pharos menu with three items, two vanilla menu items, one citation menu item (from mfe-citation)
  2. Note that the second to last menu item is lacking border.

Screenshots or code
Image

Image

Pharos version
Indicate which version of Pharos you are using.

Your environment

  • OS: [e.g. macOS]
  • Browser: [e.g. Chrome, Firefox, Safari]
  • Version: [e.g. 88]

Additional information
I think a way to fix this to have some type of observer in the menu which is watching to see how the menu changes over time, and re-rendering.

@daneah
Copy link
Member

daneah commented Jan 30, 2025

@ymouzakis thanks for reporting; I agree this is probably because the slotted content is changed after the component is initially created. One approach may be to call this.requestUpdate() on the slotchange event in the DropdownMenu's code.

@ymouzakis ymouzakis changed the title Pharos Menu styling issue when the last menu item is a mfe being mounted Pharos Menu styling issue when the last menu item is an mfe being mounted Jan 30, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants