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 navigation tap issue #15154 #15173

Merged
merged 1 commit into from
Sep 19, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
85 changes: 59 additions & 26 deletions media/css/m24/components/navigation-refresh.scss
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,16 @@
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at https://mozilla.org/MPL/2.0/.

@keyframes nav-slide-in {
from {
transform: translateX(100%);
}

to {
transform: translateX(0);
}
}

.moz24-navigation-refresh {
display: flex;
width: 100%;
Expand Down Expand Up @@ -32,22 +42,30 @@
.c-navigation-items {
// mobile specfic styles
@media (max-width: $screen-md) {
display: flex;
position: fixed;
z-index: 100;
top: 0;
right: 0;
width: 100%;
height: calc(100vh - 48px); // 48px margin top
background-color: #fff;
transition: 0.45s;
transform: translateX(100%);
margin-top: 48px;
padding-top: 0;
overflow: hidden auto;
display: none;

&.mzp-is-open {
transform: translateX(0);
display: flex;
position: fixed;
z-index: 100;
top: 0;
right: 0;
width: 100%;
height: calc(100vh - 48px); // 48px margin top
background-color: #fff;
transition: 0.45s;
margin-top: 48px;
padding-top: 0;
overflow: hidden auto;
animation: nav-slide-in 0.45s ease;

.c-menu-category-list:has(.c-menu-category.mzp-is-selected) {
margin-bottom: 0;

.c-menu-category:not(.mzp-is-selected) {
display: none;
}
}
}
}
}
Expand Down Expand Up @@ -246,15 +264,7 @@
}

.c-menu-panel {
transform: translateX(0);
}
}
}

.c-menu-panel {
// mobile specfic styles
@media (max-width: $screen-md) {
display: block;
display: block;
position: fixed;
z-index: 100;
top: 0;
Expand All @@ -263,9 +273,21 @@
height: auto;
background-color: #fff;
overflow: hidden auto;
transition: 0.45s;
margin-top: 50px;
transform: translateX(100%);
margin-top: 98px;
animation: nav-slide-in 0.45s ease;

@media (min-width: $screen-md) {
margin-top: 64px;
animation: none;
}
}
}
}

.c-menu-panel {
// mobile specfic styles
@media (max-width: $screen-md) {
display: none;
}

@media (min-width: $screen-md) {
Expand Down Expand Up @@ -489,6 +511,17 @@
}

// page content
// page content here is not part of Protocol, it is specifc to Bedrock; should be documented in future
body:has(.c-navigation-items.mzp-is-open) {
#outer-wrapper {
wen-2018 marked this conversation as resolved.
Show resolved Hide resolved
display: none;

@media (min-width: $screen-md) {
display: block;
}
}
}

#outer-wrapper {
margin-top: 48px;

Expand Down