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: prevent heading lines overlap with navbar in desktop mode #148

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
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
4 changes: 4 additions & 0 deletions scss/home.scss

Choose a reason for hiding this comment

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

Hello @Firdous708 ,
I faced the same issue and came here to add it, but found your solution, your solution works well on your device, but by increasing the width of screen, we will face the same issue again.
To prevent this issue from its root, we need to use position sticky instead of fixed, and top 0 is required also.

Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,10 @@ section#hero {
.buttons {
margin-left: -1.5rem;
}
// media query to prevent navbar from overlapping with the heading on desktop
@media screen and (min-width: 1024px) {
margin-top: 40px;
}
}
}

Expand Down