Skip to content

Commit a7b6105

Browse files
committed
fix: mobile top-right menu UX
1 parent 5018909 commit a7b6105

File tree

2 files changed

+30
-1
lines changed

2 files changed

+30
-1
lines changed

decidim-core/app/helpers/decidim/menu_helper.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ def mobile_breadcrumb_root_menu
4747
@mobile_breadcrumb_root_menu ||= ::Decidim::BreadcrumbRootMenuPresenter.new(
4848
:mobile_menu,
4949
self,
50-
container_options: { class: "menu-bar__dropdown-menu" }
50+
container_options: { class: "menu-bar__main-dropdown__top-menu" }
5151
)
5252
end
5353

decidim-core/app/packs/stylesheets/decidim/_header.scss

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -404,6 +404,35 @@ header {
404404
}
405405
}
406406

407+
&__top {
408+
@apply w-full px-4;
409+
410+
&-menu {
411+
@apply w-full md:w-1/2 mt-0 grid md:grid-cols-2 gap-x-6 text-secondary;
412+
413+
> * {
414+
@apply py-3 md:py-3.5 border-b last:border-0 border-gray-3;
415+
416+
/* since the grid has 2 columns, remove the border for these last 2 columns */
417+
&:nth-last-child(-n + 2) {
418+
@apply md:border-0;
419+
}
420+
}
421+
422+
a {
423+
@apply flex items-center justify-start gap-1 font-semibold text-lg text-secondary;
424+
425+
span {
426+
@apply min-w-0 truncate;
427+
}
428+
429+
svg {
430+
@apply flex-none fill-current;
431+
}
432+
}
433+
}
434+
}
435+
407436
&__bottom {
408437
@apply hidden md:flex;
409438
}

0 commit comments

Comments
 (0)