Hello bar应用程序让我的导航手机崩溃。

时间:2017-07-17 20:38:13

标签: javascript jquery css shopify

我在Shopify的主题中遇到问题,我安装了一个名为“Hello Bar”的应用程序来显示我所有页面上的优惠。由于某种原因,该应用程序与我的主题不兼容,我与该应用程序的开发人员交谈,他们告诉我在我的主题中将其添加到我的CSS文件中:

@media screen and (min-width: 1025px){

     .page-wrapper{

        position: static;

   }

}

这解决了桌面上的问题,但在移动版本上我的导航菜单崩溃了,我无法关闭它。我添加了这个来解决这个问题:

@media screen and (max-width: 1024px){
   .nav-mobile{
       display: none;
   }

但是当我点击菜单按钮时,菜单是空白的。 请有人帮助我,有没有可以解决这个问题的技巧?

2 个答案:

答案 0 :(得分:0)

设置display: none;会隐藏您应用它的元素。这就是菜单空白的原因。

答案 1 :(得分:0)

我添加了这个脚本并且无效

<div class="app searchbar object">
  <div class="app searchbar split"></div>
  <search-item class="app searchbar item" item="0">A</search-item>
  <div class="app searchbar split"></div>
  <search-item class="app searchbar item" item="1">Very</search-item>
  <div class="app searchbar split"></div>
  <search-item class="app searchbar item" item="2">Special</search-item>
  <div class="app searchbar split"></div>
  <search-item class="app searchbar item" item="3">Path</search-item>
  <div class="app searchbar split"></div>
  <search-item class="app searchbar item" item="4">That</search-item>
  <div class="app searchbar split"></div>
  <search-item class="app searchbar item" item="5">Contains</search-item>
  <div class="app searchbar split"></div>
  <search-item class="app searchbar item" item="6">Hidden</search-item>
  <div class="app searchbar split"></div>
  <search-item class="app searchbar item" item="7">Files</search-item>
  <div class="app searchbar split"></div>
  <search-item class="app searchbar item" item="8">That</search-item>
  <div class="app searchbar split"></div>
  <search-item class="app searchbar item" item="9">Can</search-item>
  <div class="app searchbar split"></div>
  <search-item class="app searchbar item" item="10">Ruin</search-item>
  <div class="app searchbar split"></div>
  <search-item class="app searchbar item" item="11">Your</search-item>
  <div class="app searchbar split"></div>
  <search-item class="app searchbar item" item="12">Life</search-item>
  <div class="app searchbar split"></div>
  <search-item class="app searchbar item" item="13">So</search-item>
  <div class="app searchbar split"></div>
  <search-item class="app searchbar item" item="14">Much</search-item>
</div>