hacking-tutorial icon indicating copy to clipboard operation
hacking-tutorial copied to clipboard

[Bug] UI/Frontend Responsiveness Issue on Small Viewports

Open ZarrarPeshimam opened this issue 1 year ago • 11 comments

Describion The website's layout is not adequately responsive on small mobile viewports. The navigation sidebar (containing menu items like "Ethical Hacking," "Python for Ethical Hacking," etc.) occupies a disproportionate amount of the screen width, causing the main content area ("Tutorial," "Available Courses") to be severely compressed and almost unreadable.

To Reproduce Steps to reproduce the behavior:

  1. Go to https://hacking-tutorial.vercel.app
  2. Open Developer Tools (F12 or Ctrl+Shift+I / Cmd+Option+I).
  3. Switch to Device Emulation Mode (Toggle device toolbar).
  4. Select a small mobile device preset, such as 'iPhone SE' or set a custom width under 400px.
  5. See error: The main content is squeezed into a very narrow column next to the sidebar.

Expected behavior On small mobile viewports, the layout should prioritize the main content. The expected behavior is for the navigation sidebar to either:

  1. Collapse into a hamburger menu that opens on demand.
  2. Move above or below the main content area, allowing the main content to use the full screen width.

Screenshots

Image

Additional context The issue stems from a lack of, or incorrect, media queries that define a mobile-specific layout. The current layout appears to be a fixed-width desktop/tablet layout scaled down, resulting in poor user experience on smaller screens.


@amandewatnitrr, please consider assigning this issue to me as part of hacktober.

ZarrarPeshimam avatar Oct 12 '25 14:10 ZarrarPeshimam

@ZarrarPeshimam assigned to you. For any query keep in communication with @HarzhMehta

amandewatnitrr avatar Oct 12 '25 18:10 amandewatnitrr

Hey @ZarrarPeshimam , could you just wait till tomorrow afternoon ? I'm working on a new sidebar and home page where the content is directly mapped from md files into the website. So the sidebar and its content wl change (currently it's written manually).... maybe you could make a nice UI and I can integrate the same into my code once you're done. Let me know if anything is req Thanks!

HarzhMehta avatar Oct 12 '25 18:10 HarzhMehta

@amandewatnitrr can you assign this task to me?

Dhruvmax avatar Oct 13 '25 12:10 Dhruvmax

@HarzhMehta, Thanks for the clarification! I'll hold off on the responsiveness fix for now and look forward to your structural update tomorrow.

I can focus on creating a cleaner, modern, and more user-friendly frontend look-and-feel for the time being that you can then integrate into your new component structure (new sidebar, content mapping, etc.).

I would like to clarify first what exactly you want me to do, as per the instructions I would be going as follows, CSS/Styling: I can work on the actual CSS/Tailwind/styled-components for the new components (Sidebar, Home Page, Lesson Page), implementing a new visual theme.

Let me know which way you'd like to proceed!

ZarrarPeshimam avatar Oct 14 '25 03:10 ZarrarPeshimam

Hey @ZarrarPeshimam please coordinate with @Dhruvmax regarding this, i'll push prev UI with fixed folder str in sometime after which you can work on its UI. Please keep an eye on #72 #52 #60 #63 . @amandewatnitrr I'll push the readme logic with the old folder str in 2-3 hrs, after that the above 4-5 issues could work on fixing the UI.

HarzhMehta avatar Oct 14 '25 04:10 HarzhMehta

@ZarrarPeshimam can you tell me the work i need to do

Dhruvmax avatar Oct 14 '25 06:10 Dhruvmax

I fixed the mobile layout so the lesson content has enough room on small screens, with the sidebar available when needed. I also adjusted the navbar menu so its options are visible when opened. Verified the frontend build and lint checks, and tested the menu at 375px width.

WhiteHacker000 avatar Oct 07 '26 10:10 WhiteHacker000

Hi @WhiteHacker000

Thanks for looking into the issue and contributing to the repo, will review the MR and let you know. Keep checking the PR for any review comments.

amandewatnitrr avatar Oct 07 '26 10:10 amandewatnitrr

I want to ask you is there any other issue also related to 'https://github.com/amandewatnitrr/hacking-tutorial/issues/50', if there i would we seeing you to provide the little more description for the issue

WhiteHacker000 avatar Oct 16 '26 10:10 WhiteHacker000

error: The main content is squeezed into a very narrow column next to the sidebar. is resolved The New Behaviour is: On small mobile viewports, the layout should prioritize the main content, collapse into a hamburger menu that opens on demand.

WhiteHacker000 avatar Oct 16 '26 10:10 WhiteHacker000

I updated LessonTemplate.css to let navigation titles wrap, constrain buttons to their container, and stack the buttons vertically on screens up to 600px wide. This keeps both buttons visible and tappable, including below 427px.

WhiteHacker000 avatar Oct 16 '26 11:10 WhiteHacker000