Profile avatar layout and z-index issues in public profile view #204075
🏷️ Discussion TypeBug 💬 Feature/Topic AreaProfile BodyHello GitHub Team and Community, I found a UI layout and layering issue in GitHub public profile pages when viewing a profile while logged out or in Incognito mode. The issue does not appear when logged in. Steps to reproduce
Actual behaviorThe profile avatar is incorrectly positioned in the public view. Instead of staying inside its expected profile container, the avatar moves upward and extends outside of its container. The top part of the avatar overlaps the profile sub-navigation ( The navigation contains:
Additionally, when scrolling:
Expected behaviorThe profile avatar should remain inside its intended container and maintain the same position as the logged-in view. When the navigation becomes sticky, it should appear above the avatar or the avatar should be properly clipped/positioned so that it does not overlap the navigation. Technical observationThe issue appears to be related to differences in the public profile layout CSS and stacking behavior. Possible causes:
Observed behavior:
Environment
Profile example: ReporterThis issue was reported and investigated by Ahmad Jeddizahed ( Thank you for looking into this. |
Replies: 2 comments
|
💬 Your Product Feedback Has Been Submitted 🎉 Thank you for taking the time to share your insights with us! Your feedback is invaluable as we build a better GitHub experience for all our users. Here's what you can expect moving forward ⏩
Where to look to see what's shipping 👀
What you can do in the meantime 💻
As a member of the GitHub community, your participation is essential. While we can't promise that every suggestion will be implemented, we want to emphasize that your feedback is instrumental in guiding our decisions and priorities. Thank you once again for your contribution to making GitHub even better! We're grateful for your ongoing support and collaboration in shaping the future of our platform. ⭐ |
Possible fix / Technical observationI could not identify stable class names for these containers, so I am referring to them by their roles. I noticed two possible CSS-related causes:
In the logged-out/incognito view, the profile image container appears to be positioned higher than its expected section. Because of this, the image extends outside its intended container and overlaps the profile sub-navigation. Adding additional top spacing to the profile image container (for example, an equivalent of
During scrolling, the sub-navigation becomes sticky. The current stacking order appears to be:
Because the profile image container has a higher stacking level, the image remains above the sticky navigation and passes over it while scrolling. Adjusting the stacking order so that the sticky navigation is above the profile image container, or reducing the image container's stacking priority, would prevent this behavior. Expected result:
Animation.mp4 |
Possible fix / Technical observation
I could not identify stable class names for these containers, so I am referring to them by their roles.
I noticed two possible CSS-related causes:
In the logged-out/incognito view, the profile image container appears to be positioned higher than its expected section. Because of this, the image extends outside its intended container and overlaps the profile sub-navigation.
Adding additional top spacing to the profile image container (for example, an equivalent of
mt-8) appears to move the image back to its expected position and prevents the overlap with the navigation.During…