conversionxl / aybolit

Lightweight web components library built with LitElement.
https://conversionxl.github.io/aybolit/
MIT License
7 stars 8 forks source link

feat(cxl-ui): [cxl-marketing-nav] vertically align navigation menu items #253

Closed anoblet closed 1 year ago

anoblet commented 1 year ago

252

https://app.clickup.com/t/861m930qc

github-actions[bot] commented 1 year ago

size-limit report 📦

Path Size
packages/cxl-ui/pkg/dist-web/cxl-ui.js 30.88 KB (+0.32% 🔺)
packages/cxl-ui/pkg/dist-web/cxl-ui-jwplayer.js 11.87 KB (0%)
packages/cxl-ui/pkg/dist-web/cxl-ui-playbooks.js 23.46 KB (0%)
packages/cxl-ui/pkg/dist-web/vendor.js 125.65 KB (+2.53% 🔺)
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 193.02 KB (+1.68% 🔺)
anoblet commented 1 year ago

Sure

Before: https://www.loom.com/share/b9bd5830f15242df959349ac1abdba65 After: https://www.loom.com/share/86cd26c849ee4e2ba9bee91ddf2e8e7a

lkraav commented 1 year ago

Sure

Before: https://www.loom.com/share/b9bd5830f15242df959349ac1abdba65 After: https://www.loom.com/share/86cd26c849ee4e2ba9bee91ddf2e8e7a

What if the next box is smaller than the opener, and opener menu item is at the bottom?

anoblet commented 1 year ago

That's a good point... what if we set a minimum height on the most recent menu equal to that of the parent menu?

anoblet commented 1 year ago

I just tested, and it seems context-menu seems to account for at least the hover/click side of things.

image

lkraav commented 1 year ago

I just tested, and it seems context-menu seems to account for at least the hover/click side of things.

Yeah but looks super awkward.

Can this be pre-calculated per context menu, so only larger items could be repositioned?

anoblet commented 1 year ago

This has been updated to only reposition submenus who's height is taller than that of the top level menu.

lkraav commented 1 year ago

This has been updated to only reposition submenus who's height is taller than that of the top level menu.

UX felt quite pleasant.

Can you add more children to "Parent length > Child length" menu item? 1 is not a good example, because it looks natural by default. What about 2-3-4 children there?

anoblet commented 1 year ago

Updated to add additional menu items.

lkraav commented 1 year ago

/rebase

paulkirspuu commented 1 year ago

Lets ship, and iterate on top if necessary.

cc @pawelkmpt @lkraav

lkraav commented 1 year ago

Lets ship, and iterate on top if necessary.

I'm preparing 1.5.0 with more updates, ETA tomorrow.

paulkirspuu commented 1 year ago

Tomorrow sounds good.

paulkirspuu commented 1 year ago

Did we get 1.5.0 together and ready to deploy live? Or lets do 1.4.x deployment meanwhile?

lkraav commented 1 year ago

Did we get 1.5.0 together and ready to deploy live? Or lets do 1.4.x deployment meanwhile?

https://github.com/conversionxl/aybolit/commit/7afba394a98803abcea035f5286f1003b227f064

Requires theme updates tomorrow.