A
A
Andrnofollow2020-08-31 10:23:57
css
Andrnofollow, 2020-08-31 10:23:57

How to adapt the horizontal menu to the mob in CSS?

Added drop-down menu items to the site https://nurdez.kz/ but on the mobile version, these menu items, when the list drops out, stretch to the end of the page. How to adapt these menu items for mobile phones so that the page does not stretch in CSS? I will be very grateful!

Answer the question

In order to leave comments, you need to log in

2 answer(s)
M
m1rvi, 2020-08-31
@m1rvi

It can be so.
5f4ca8c8313e3874213938.png
I would do it this way: I made
two menus (for PC and mobile phones) and used media. Initially, the menu for mobiles display none ,
but when the resolution approaches 720px, then the Menu for mobiles display block , and for desktop display none.

S
sashabeep, 2020-09-01
@sashabeep

Good question!
Usually, the menu hides when it reaches a certain screen size and turns from horizontal to vertical. Opens with a button.
Or, a separate mobile menu is created, and the main one is hidden. For example, such a menu can be made separately, and the main one can be hidden https://mmenujs.com/mmenu-light/
And the most interesting option is like the Gorbunov Bureau https://bureau.ru/bb/soviet/20170227/

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question