Моя панель навигации Bootstrap с фиксированным верхом не отображает все выпадающие элементы при просмотре в небольшом окне или на мобильном устройстве - PullRequest
1 голос
/ 24 мая 2019

Я пытаюсь создать панель навигации с фиксированным верхом, с несколькими выпадающими элементами, но когда я просматриваю ее в небольшом окне или на мобильном устройстве, вы не видите нижние выпадающие элементы или прокручиваете, чтобы получить к ним доступ.

Я попытался установить body,html{height:100%;} и html{min-height:100%}, как предложено в другом посте для аналогичной проблемы, но это не сработало.

HTML

<!doctype html>
<html>
<head>
  <meta charset="utf-8">
  <title>Example</title>
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
<script src="https://code.jquery.com/jquery-3.3.1.slim.min.js" integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.7/umd/popper.min.js" integrity="sha384-UO2eT0CpHqdSJQ6hJty5KVphtPhzWj9WO1clHTMGa3JDZwrnQq4sF86dIHNDz0W1" crossorigin="anonymous"></script>
  <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css" integrity="sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2MZw1T" crossorigin="anonymous">
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/js/bootstrap.min.js" integrity="sha384-JjSmVgyd0p3pXB1rRibZUAYoIIy6OrQ6VrjIEaFf/nJGzIxFDsf4x0xIM+B07jRM" crossorigin="anonymous"></script>

</head>

  <body>

  <nav class="navbar navbar-expand-sm navbar-dark bg-dark fixed-top">
  <a class="navbar-brand " href="#">Example</a>
  <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarNavDropdown" aria-controls="navbarNavDropdown" aria-expanded="false" aria-label="Toggle navigation">
    <span class="navbar-toggler-icon"></span>
  </button>
      <div class="collapse navbar-collapse justify-content-center" id="navbarNavDropdown">
          <ul class="navbar-nav">
            <li class="nav-item active mx-2">
              <a class="nav-link" href="index.html">Home <span class="sr-only">(current)</span></a>
            </li>
            <li class="nav-item dropdown mx-2">
              <a class="nav-link dropdown-toggle" href="#" id="DropDown1" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">Link 1</a>
              <div class="dropdown-menu" aria-labelledby="DropDown1">
                <a class="dropdown-item" href="#">Dropdown1</a>
                <a class="dropdown-item" href="#">Dropdown2</a>
                <a class="dropdown-item" href="#">Dropdown3</a>
                <a class="dropdown-item" href="#">Dropdown4</a>
              </div>
            </li>
            <li class="nav-item dropdown mx-2">
              <a class="nav-link dropdown-toggle" href="#" id="DropDown2" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">Link2</a>
              <div class="dropdown-menu" aria-labelledby="DropDown2">
                <a class="dropdown-item " href="#">Dropdown1 <span class="sr-only">(current)</span></a>
                <a class="dropdown-item" href="#">Dropdown2</a>
                <a class="dropdown-item" href="#">Dropdown3</a>
                <a class="dropdown-item" href="#">Dropdown4</a>
                <a class="dropdown-item" href="#">Dropdown5</a>
                <a class="dropdown-item" href="#">Dropdown6</a>
                <a class="dropdown-item" href="#">Dropdown7</a>
                <a class="dropdown-item" href="#">Dropdown8</a>
              </div>
            </li>
            <li class="nav-item mx-2">
              <a class="nav-link" href="#">Link3</a>
            </li>
            <li class="nav-item mx-2">
              <a class="nav-link" href="#">Link4</a>
            </li>
            <li class="nav-item mx-2">
              <a class="nav-link" href="#">Link5</a>
            </li>
            <li class="nav-item mx-2">
              <a class="nav-link" href="#">Link6</a>
            </li>
          </ul>
        </div>
  </nav>
    <header>
    </header>
    <main>
      <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer faucibus quam eros, quis elementum metus suscipit quis. Etiam ultrices pharetra diam, sed tempus mauris tincidunt sit amet. Vivamus vestibulum sollicitudin bibendum. Nam egestas, lectus vitae semper blandit, elit sapien venenatis diam, quis vehicula sem neque vel tellus. Suspendisse nec venenatis metus, ac blandit lacus. Etiam eu velit convallis, auctor turpis eget, faucibus orci. Vestibulum ac justo porta, congue lectus fringilla, sagittis metus. Sed orci velit, placerat eu interdum eget, volutpat in urna. Fusce quis tellus non lorem imperdiet blandit. Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas.</p>

<p>Aliquam aliquam commodo nulla, nec porta augue efficitur a. Etiam maximus, ligula vitae feugiat malesuada, magna est ultricies nunc, sit amet efficitur metus metus vel lectus. Nunc eleifend orci nec orci faucibus congue. In sodales pretium tempor. Pellentesque sed risus risus. Aenean vulputate euismod eleifend. Donec vitae tincidunt felis, quis euismod neque. Nam at urna convallis, tincidunt arcu quis, commodo urna. Quisque ultrices interdum erat vel suscipit. Morbi sed ex dignissim, posuere elit ac, sodales est.</p>

<p>Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Suspendisse potenti. Nunc dictum ac purus at accumsan. Ut consequat efficitur nisi. Nam tempor, justo at tempus pretium, nunc dolor iaculis magna, eget mattis sapien metus nec neque. Quisque consequat dolor lacus. Fusce vestibulum accumsan arcu eget varius. Suspendisse rutrum elit felis, at bibendum neque sagittis non. Aliquam ut nibh eget mi eleifend congue quis eleifend turpis. Etiam placerat scelerisque enim, ut dictum magna tempor sed. Ut tempus, ante sed vehicula porttitor, justo lectus malesuada est, sed suscipit nisl metus ac lorem. Duis hendrerit sodales risus id laoreet. Aenean quis felis eu diam lobortis gravida. Aenean sem mi, sodales vel dictum eget, malesuada quis lacus.</p>

<p>Phasellus quis augue magna. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Suspendisse a sagittis ante. Nunc rutrum lacus imperdiet, varius ipsum ut, tempus dui. Donec vel ligula lacus. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Proin semper augue ut nisi rutrum, vitae eleifend nisl gravida. Etiam cursus turpis pulvinar, finibus tortor pretium, fringilla libero. Vivamus tempus feugiat orci eget facilisis. Etiam efficitur dapibus porta. Vivamus venenatis leo mauris. Donec eleifend mi a enim sagittis sollicitudin.</p>

<p>Cras sed mollis neque. Nam nibh purus, commodo quis sem in, porta egestas erat. Praesent eleifend venenatis sem, in pulvinar est dignissim in. Mauris nulla augue, laoreet vel tortor at, accumsan pharetra urna. Sed a volutpat metus. Praesent cursus turpis id augue venenatis, nec dapibus tortor molestie. Maecenas tincidunt, velit at tincidunt pretium, purus urna tempor sapien, vitae efficitur nisi sem eu erat. Praesent in ullamcorper turpis. Nullam bibendum mi vel nibh egestas pellentesque.</p>
    </main>
    <footer>
    </footer>
  </body>
</html>

CSS

body { 
    padding-top: 65px; 
}

Я включил пример кода, который я использую, по ссылке ниже.

https://codepen.io/EDMSM/pen/VOXRJo

1 Ответ

0 голосов
/ 25 мая 2019
 .fixed-top {
   max-height: 100vh;
   overflow-y: auto;
   margin-right: -17px;
   padding-right: 17px;
 }

Следует исправить вашу проблему.(Возможно, вы захотите заключить его в sm медиазапрос, но это не обязательно, так как он ничего не сломает на планшете или на рабочем столе).

Хитрость 17px заключается в компенсации полосы прокруткиширина в Chrome и избежать двойной полосы прокрутки.

«чистой» альтернативой 17px «хаку» (из-за отсутствия лучшего термина) является применение выбранного вами класса к <body> при открытии меню иудалить его при закрытии.Этот класс должен препятствовать тому, чтобы <body> имел полосу прокрутки, пока меню открыто.

Например, чтобы обойти ту же самую проблему (но для модальных) Bootstrap использует класс .modal-open, который применяет overflow:hidden; position:fixed к <body>.

Смотрите, как он работает только с CSS:

nav.fixed-top {
   max-height: 100vh;
   overflow-y: auto;
   margin-right: -17px;
   padding-right: 17px;
 }
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<script src="https://code.jquery.com/jquery-3.3.1.slim.min.js" integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.7/umd/popper.min.js" integrity="sha384-UO2eT0CpHqdSJQ6hJty5KVphtPhzWj9WO1clHTMGa3JDZwrnQq4sF86dIHNDz0W1" crossorigin="anonymous"></script>
  <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css" integrity="sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2MZw1T" crossorigin="anonymous">
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/js/bootstrap.min.js" integrity="sha384-JjSmVgyd0p3pXB1rRibZUAYoIIy6OrQ6VrjIEaFf/nJGzIxFDsf4x0xIM+B07jRM" crossorigin="anonymous"></script>

  <nav class="navbar navbar-expand-sm navbar-dark bg-dark fixed-top">
  <a class="navbar-brand " href="#">Example</a>
  <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarNavDropdown" aria-controls="navbarNavDropdown" aria-expanded="false" aria-label="Toggle navigation">
    <span class="navbar-toggler-icon"></span>
  </button>
      <div class="collapse navbar-collapse justify-content-center" id="navbarNavDropdown">
          <ul class="navbar-nav">
            <li class="nav-item active mx-2">
              <a class="nav-link" href="index.html">Home <span class="sr-only">(current)</span></a>
            </li>
            <li class="nav-item dropdown mx-2">
              <a class="nav-link dropdown-toggle" href="#" id="DropDown1" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">Link 1</a>
              <div class="dropdown-menu" aria-labelledby="DropDown1">
                <a class="dropdown-item" href="#">Dropdown1</a>
                <a class="dropdown-item" href="#">Dropdown2</a>
                <a class="dropdown-item" href="#">Dropdown3</a>
                <a class="dropdown-item" href="#">Dropdown4</a>
              </div>
            </li>
            <li class="nav-item dropdown mx-2">
              <a class="nav-link dropdown-toggle" href="#" id="DropDown2" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">Link2</a>
              <div class="dropdown-menu" aria-labelledby="DropDown2">
                <a class="dropdown-item " href="#">Dropdown1 <span class="sr-only">(current)</span></a>
                <a class="dropdown-item" href="#">Dropdown2</a>
                <a class="dropdown-item" href="#">Dropdown3</a>
                <a class="dropdown-item" href="#">Dropdown4</a>
                <a class="dropdown-item" href="#">Dropdown5</a>
                <a class="dropdown-item" href="#">Dropdown6</a>
                <a class="dropdown-item" href="#">Dropdown7</a>
                <a class="dropdown-item" href="#">Dropdown8</a>
              </div>
            </li>
            <li class="nav-item mx-2">
              <a class="nav-link" href="#">Link3</a>
            </li>
            <li class="nav-item mx-2">
              <a class="nav-link" href="#">Link4</a>
            </li>
            <li class="nav-item mx-2">
              <a class="nav-link" href="#">Link5</a>
            </li>
            <li class="nav-item mx-2">
              <a class="nav-link" href="#">Link6</a>
            </li>
          </ul>
        </div>
  </nav>
    <header>
    </header>
    <main>
      <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer faucibus quam eros, quis elementum metus suscipit quis. Etiam ultrices pharetra diam, sed tempus mauris tincidunt sit amet. Vivamus vestibulum sollicitudin bibendum. Nam egestas, lectus vitae semper blandit, elit sapien venenatis diam, quis vehicula sem neque vel tellus. Suspendisse nec venenatis metus, ac blandit lacus. Etiam eu velit convallis, auctor turpis eget, faucibus orci. Vestibulum ac justo porta, congue lectus fringilla, sagittis metus. Sed orci velit, placerat eu interdum eget, volutpat in urna. Fusce quis tellus non lorem imperdiet blandit. Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas.</p>

<p>Aliquam aliquam commodo nulla, nec porta augue efficitur a. Etiam maximus, ligula vitae feugiat malesuada, magna est ultricies nunc, sit amet efficitur metus metus vel lectus. Nunc eleifend orci nec orci faucibus congue. In sodales pretium tempor. Pellentesque sed risus risus. Aenean vulputate euismod eleifend. Donec vitae tincidunt felis, quis euismod neque. Nam at urna convallis, tincidunt arcu quis, commodo urna. Quisque ultrices interdum erat vel suscipit. Morbi sed ex dignissim, posuere elit ac, sodales est.</p>

<p>Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Suspendisse potenti. Nunc dictum ac purus at accumsan. Ut consequat efficitur nisi. Nam tempor, justo at tempus pretium, nunc dolor iaculis magna, eget mattis sapien metus nec neque. Quisque consequat dolor lacus. Fusce vestibulum accumsan arcu eget varius. Suspendisse rutrum elit felis, at bibendum neque sagittis non. Aliquam ut nibh eget mi eleifend congue quis eleifend turpis. Etiam placerat scelerisque enim, ut dictum magna tempor sed. Ut tempus, ante sed vehicula porttitor, justo lectus malesuada est, sed suscipit nisl metus ac lorem. Duis hendrerit sodales risus id laoreet. Aenean quis felis eu diam lobortis gravida. Aenean sem mi, sodales vel dictum eget, malesuada quis lacus.</p>

<p>Phasellus quis augue magna. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Suspendisse a sagittis ante. Nunc rutrum lacus imperdiet, varius ipsum ut, tempus dui. Donec vel ligula lacus. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Proin semper augue ut nisi rutrum, vitae eleifend nisl gravida. Etiam cursus turpis pulvinar, finibus tortor pretium, fringilla libero. Vivamus tempus feugiat orci eget facilisis. Etiam efficitur dapibus porta. Vivamus venenatis leo mauris. Donec eleifend mi a enim sagittis sollicitudin.</p>

<p>Cras sed mollis neque. Nam nibh purus, commodo quis sem in, porta egestas erat. Praesent eleifend venenatis sem, in pulvinar est dignissim in. Mauris nulla augue, laoreet vel tortor at, accumsan pharetra urna. Sed a volutpat metus. Praesent cursus turpis id augue venenatis, nec dapibus tortor molestie. Maecenas tincidunt, velit at tincidunt pretium, purus urna tempor sapien, vitae efficitur nisi sem eu erat. Praesent in ullamcorper turpis. Nullam bibendum mi vel nibh egestas pellentesque.</p>
    </main>
    <footer>
    </footer>

Посмотрите, как он работает с JS и CSS (без взлома 17px):

$('.navbar-toggler').on('click tap', function(){
  const expanded = $(this).attr('aria-expanded') === 'false';
  $('body').toggleClass('modal-open', expanded);
});
nav.fixed-top {
   max-height: 100vh;
   overflow-y: auto;
 }
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<script src="https://code.jquery.com/jquery-3.3.1.slim.min.js" integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.7/umd/popper.min.js" integrity="sha384-UO2eT0CpHqdSJQ6hJty5KVphtPhzWj9WO1clHTMGa3JDZwrnQq4sF86dIHNDz0W1" crossorigin="anonymous"></script>
  <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css" integrity="sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2MZw1T" crossorigin="anonymous">
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/js/bootstrap.min.js" integrity="sha384-JjSmVgyd0p3pXB1rRibZUAYoIIy6OrQ6VrjIEaFf/nJGzIxFDsf4x0xIM+B07jRM" crossorigin="anonymous"></script>

  <nav class="navbar navbar-expand-sm navbar-dark bg-dark fixed-top">
  <a class="navbar-brand " href="#">Example</a>
  <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarNavDropdown" aria-controls="navbarNavDropdown" aria-expanded="false" aria-label="Toggle navigation">
    <span class="navbar-toggler-icon"></span>
  </button>
      <div class="collapse navbar-collapse justify-content-center" id="navbarNavDropdown">
          <ul class="navbar-nav">
            <li class="nav-item active mx-2">
              <a class="nav-link" href="index.html">Home <span class="sr-only">(current)</span></a>
            </li>
            <li class="nav-item dropdown mx-2">
              <a class="nav-link dropdown-toggle" href="#" id="DropDown1" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">Link 1</a>
              <div class="dropdown-menu" aria-labelledby="DropDown1">
                <a class="dropdown-item" href="#">Dropdown1</a>
                <a class="dropdown-item" href="#">Dropdown2</a>
                <a class="dropdown-item" href="#">Dropdown3</a>
                <a class="dropdown-item" href="#">Dropdown4</a>
              </div>
            </li>
            <li class="nav-item dropdown mx-2">
              <a class="nav-link dropdown-toggle" href="#" id="DropDown2" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">Link2</a>
              <div class="dropdown-menu" aria-labelledby="DropDown2">
                <a class="dropdown-item " href="#">Dropdown1 <span class="sr-only">(current)</span></a>
                <a class="dropdown-item" href="#">Dropdown2</a>
                <a class="dropdown-item" href="#">Dropdown3</a>
                <a class="dropdown-item" href="#">Dropdown4</a>
                <a class="dropdown-item" href="#">Dropdown5</a>
                <a class="dropdown-item" href="#">Dropdown6</a>
                <a class="dropdown-item" href="#">Dropdown7</a>
                <a class="dropdown-item" href="#">Dropdown8</a>
              </div>
            </li>
            <li class="nav-item mx-2">
              <a class="nav-link" href="#">Link3</a>
            </li>
            <li class="nav-item mx-2">
              <a class="nav-link" href="#">Link4</a>
            </li>
            <li class="nav-item mx-2">
              <a class="nav-link" href="#">Link5</a>
            </li>
            <li class="nav-item mx-2">
              <a class="nav-link" href="#">Link6</a>
            </li>
          </ul>
        </div>
  </nav>
    <header>
    </header>
    <main>
      <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer faucibus quam eros, quis elementum metus suscipit quis. Etiam ultrices pharetra diam, sed tempus mauris tincidunt sit amet. Vivamus vestibulum sollicitudin bibendum. Nam egestas, lectus vitae semper blandit, elit sapien venenatis diam, quis vehicula sem neque vel tellus. Suspendisse nec venenatis metus, ac blandit lacus. Etiam eu velit convallis, auctor turpis eget, faucibus orci. Vestibulum ac justo porta, congue lectus fringilla, sagittis metus. Sed orci velit, placerat eu interdum eget, volutpat in urna. Fusce quis tellus non lorem imperdiet blandit. Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas.</p>

<p>Aliquam aliquam commodo nulla, nec porta augue efficitur a. Etiam maximus, ligula vitae feugiat malesuada, magna est ultricies nunc, sit amet efficitur metus metus vel lectus. Nunc eleifend orci nec orci faucibus congue. In sodales pretium tempor. Pellentesque sed risus risus. Aenean vulputate euismod eleifend. Donec vitae tincidunt felis, quis euismod neque. Nam at urna convallis, tincidunt arcu quis, commodo urna. Quisque ultrices interdum erat vel suscipit. Morbi sed ex dignissim, posuere elit ac, sodales est.</p>

<p>Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Suspendisse potenti. Nunc dictum ac purus at accumsan. Ut consequat efficitur nisi. Nam tempor, justo at tempus pretium, nunc dolor iaculis magna, eget mattis sapien metus nec neque. Quisque consequat dolor lacus. Fusce vestibulum accumsan arcu eget varius. Suspendisse rutrum elit felis, at bibendum neque sagittis non. Aliquam ut nibh eget mi eleifend congue quis eleifend turpis. Etiam placerat scelerisque enim, ut dictum magna tempor sed. Ut tempus, ante sed vehicula porttitor, justo lectus malesuada est, sed suscipit nisl metus ac lorem. Duis hendrerit sodales risus id laoreet. Aenean quis felis eu diam lobortis gravida. Aenean sem mi, sodales vel dictum eget, malesuada quis lacus.</p>

<p>Phasellus quis augue magna. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Suspendisse a sagittis ante. Nunc rutrum lacus imperdiet, varius ipsum ut, tempus dui. Donec vel ligula lacus. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Proin semper augue ut nisi rutrum, vitae eleifend nisl gravida. Etiam cursus turpis pulvinar, finibus tortor pretium, fringilla libero. Vivamus tempus feugiat orci eget facilisis. Etiam efficitur dapibus porta. Vivamus venenatis leo mauris. Donec eleifend mi a enim sagittis sollicitudin.</p>

<p>Cras sed mollis neque. Nam nibh purus, commodo quis sem in, porta egestas erat. Praesent eleifend venenatis sem, in pulvinar est dignissim in. Mauris nulla augue, laoreet vel tortor at, accumsan pharetra urna. Sed a volutpat metus. Praesent cursus turpis id augue venenatis, nec dapibus tortor molestie. Maecenas tincidunt, velit at tincidunt pretium, purus urna tempor sapien, vitae efficitur nisi sem eu erat. Praesent in ullamcorper turpis. Nullam bibendum mi vel nibh egestas pellentesque.</p>
    </main>
    <footer>
    </footer>

Примечание: В этом конкретном случае я рекомендую решение CSS по нескольким причинам, но главным образом потому, чтоJS one создает небольшой скачок ширины меню при открытии / закрытии в определенных комбинациях браузера и ОС, что довольно трудно исправить, не затрагивая другие комбинации.

Добро пожаловать на сайт PullRequest, где вы можете задавать вопросы и получать ответы от других членов сообщества.
...