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

fix(cxl-ui): cxl-marketing-nav menu bar button alignment on desktop #442

Merged
merged 1 commit into from
Jan 15, 2025

Conversation

anoblet
Copy link
Collaborator

@anoblet anoblet commented Dec 16, 2024

Copy link

github-actions bot commented Dec 16, 2024

size-limit report 📦

Path Size
packages/cxl-ui/pkg/dist-web/cxl-ui.js 44.85 KB (0%)
packages/cxl-ui/pkg/dist-web/cxl-ui-jwplayer.js 15.04 KB (0%)
packages/cxl-ui/pkg/dist-web/cxl-ui-playbooks.js 29.23 KB (0%)
packages/cxl-ui/pkg/dist-web/vendor.js 157.96 KB (0%)
packages/cxl-ui/pkg/dist-web/cxl-ui-institute.js, packages/cxl-ui/pkg/dist-web/cxl-ui-jwplayer.js, packages/cxl-ui/pkg/dist-web/cxl-ui-playbooks.js, packages/cxl-ui/pkg/dist-web/cxl-ui.js, packages/cxl-ui/pkg/dist-web/manifest.js, packages/cxl-ui/pkg/dist-web/unresolved.js, packages/cxl-ui/pkg/dist-web/vendor.js 291.54 KB (0%)

Copy link

github-actions bot commented Dec 16, 2024

Visit the preview URL for this PR (updated for commit a95a081):

https://aybolit-449f1--pr442-anoblet-fix-menu-bar-8zlv71mc.web.app

(expires Wed, 22 Jan 2025 09:20:53 GMT)

🔥 via Firebase Hosting GitHub Action 🌎

Sign: ebc08d8a89b4eb54ebfb0bb50bd15f151f1243f5

Copy link

@pawelkmpt pawelkmpt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It doesn't look right on desktop.

Screenshot 2024-12-17 at 10 02 02
Screenshot 2024-12-17 at 10 10 44
Screenshot 2024-12-17 at 10 11 24

@anoblet
Copy link
Collaborator Author

anoblet commented Dec 17, 2024

I removed the faded red background for the close icon and changed the nav bar padding from --lumo-space-m to --cxl-wrap-padding. It's hard to get perfect alignment since the logo has whitespace in itself, though it looks better than before. The only issue I see is on desktop. It doesn't look possible to remove the padding or margin for the last menu item(https://stackoverflow.com/a/66664161/3935891) so the help link isn't aligned.

Mobile closed:
localhost_

Mobile opened:
localhost_ (1)

Desktop:
localhost_ (2)

@anoblet anoblet requested a review from pawelkmpt December 17, 2024 16:29
@anoblet anoblet force-pushed the anoblet/fix/menu-bar branch from e254a7e to 486116c Compare December 17, 2024 16:32
Copy link

@pawelkmpt pawelkmpt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@anoblet I deployed it live, looks good in most places but on the dashboard menu is wider than content. I see it uses 1c-w layout.

Please check more non-standard pages on institute so we know if this is just dashboard issue or wider problem.

If just dashboard, propose solution

Screenshot 2025-01-02 at 10 23 24

@lkraav
Copy link

lkraav commented Jan 2, 2025

It's hard to get perfect alignment since the logo has whitespace in itself, though it looks better than before.

Logo icon itself should absolutely have 0 / zero padding. Anything else is a bug.

@anoblet anoblet force-pushed the anoblet/fix/menu-bar branch from 486116c to 838bc37 Compare January 3, 2025 15:46
@anoblet
Copy link
Collaborator Author

anoblet commented Jan 3, 2025

It's difficult to test this locally since WP Starter has a different dashboard/layout, though the result should be this:

cxl com_institute_dashboard_ (6)

I set a max-width for the marketing nav equal to the max-width of the content.

Logo icon itself should absolutely have 0 / zero padding. Anything else is a bug.

There's no left padding on the icon, though the SVG itself has whitespace:

image

@anoblet anoblet requested a review from pawelkmpt January 3, 2025 15:53
Copy link

@pawelkmpt pawelkmpt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nav bottom border is not full width anymore. It's also visible on your screenshot @anoblet

Screenshot 2025-01-10 at 16 04 40

@anoblet anoblet force-pushed the anoblet/fix/menu-bar branch from 838bc37 to f02b0fa Compare January 14, 2025 14:29
@anoblet anoblet requested a review from pawelkmpt January 14, 2025 14:29
@anoblet
Copy link
Collaborator Author

anoblet commented Jan 14, 2025

Nav bottom border is not full width anymore. It's also visible on your screenshot @anoblet

This should be fixed. I moved the border to the marketing nav instead of the inner nav.

Copy link

@pawelkmpt pawelkmpt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's still broken. Now bottom border is not visible when the page loads. It appears when you start scrolling.

BEFORE
Screenshot 2025-01-14 at 17 35 07

AFTER
Screenshot 2025-01-14 at 17 34 20

@anoblet anoblet force-pushed the anoblet/fix/menu-bar branch from f02b0fa to d6d903d Compare January 14, 2025 17:44
@anoblet
Copy link
Collaborator Author

anoblet commented Jan 14, 2025

I missed the display: block; on cxl-marketing-nav. It should work now. My fault, I had this in dev tools, though I didn't add it to the commit.

localhost_ (3)

@anoblet anoblet requested a review from pawelkmpt January 14, 2025 17:47
@pawelkmpt pawelkmpt force-pushed the anoblet/fix/menu-bar branch from d6d903d to a95a081 Compare January 15, 2025 09:18
@pawelkmpt pawelkmpt merged commit 76af974 into master Jan 15, 2025
2 checks passed
@pawelkmpt pawelkmpt deleted the anoblet/fix/menu-bar branch January 15, 2025 09:19
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

Successfully merging this pull request may close these issues.

3 participants