Skip to content

Fix Navbar Link Scrolling Visibility Issue#16

Open
sapeksh123 wants to merge 1 commit intoOsalumense:mainfrom
sapeksh123:fix/NavbarLinks-scrolling-Issue
Open

Fix Navbar Link Scrolling Visibility Issue#16
sapeksh123 wants to merge 1 commit intoOsalumense:mainfrom
sapeksh123:fix/NavbarLinks-scrolling-Issue

Conversation

@sapeksh123
Copy link

Screenshot 2025-07-12 144811 Screenshot 2025-07-12 144800

This commit fixes an issue where clicking on navbar links (such as #about, #services) would scroll to the corresponding section, but the top part of the content would be hidden behind the fixed/sticky navbar.
This was caused by the anchor scrolling behavior not accounting for the navbar's height.

Fixes Implemented:

  • Added additional top padding (or margin) to target sections to offset the navbar height.

  • Optionally added scroll-margin-top in CSS (Tailwind: scroll-mt-*) to ensure correct alignment.

  • Tested across different screen sizes (mobile, tablet, desktop) for responsive consistency.

@netlify
Copy link

netlify bot commented Jul 12, 2025

Deploy Preview for mld-prototype ready!

Name Link
🔨 Latest commit 32240f0
🔍 Latest deploy log https://app.netlify.com/projects/mld-prototype/deploys/687228900624130008988fd2
😎 Deploy Preview https://deploy-preview-16--mld-prototype.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

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.

1 participant