Javascript/Ionic3溢出:在Firefox中隐藏禁用滚动

8 javascript css firefox jquery

我有一个问题,我无法删除Firefox Quantum的Scrollbars.哦,它的工作原理就像这个css的魅力:

 div::-webkit-scrollbar {
  border:none;
  width:0;
  background: rgba(0,0,0,0);
  display: none;
  overflow-x: hidden;
  overflow-y: hidden;
}

div::-webkit-scrollbar-track {
  border:none;
  width:0;
  background: rgba(0,0,0,0);
  display: none;
  overflow-x: hidden;
  overflow-y: hidden;
}

div::-webkit-scrollbar-thumb {
  border:none;
  width:0;
  background: rgba(0,0,0,0);
  display: none;
  overflow-x: hidden;
  overflow-y: hidden;
}
Run Code Online (Sandbox Code Playgroud)

我还尝试用jQuery删除它,并将它直接添加到body标签中 style="overflow: hidden;"

什么都不行.我似乎无法摆脱他们.我该如何删除它们?

编辑:

与添加overflow: hidden;.scroll-content{}它去掉了滚动条,但我不能在Firefox不再滚动.如何启用overflow with overflow:hidden;

rup*_*pii 2

你可以做这样的事情。

<style>
    #container{
        height: 500px;
        width: 200px;
        background-color: #ccc;
        overflow: hidden;
    }
    #container-inner{
        width: calc(100% + 17px);
        height: 100%;
        overflow: scroll;
        overflow-x: hidden;
    }
    .content{
        width: 100%;
        height: 300px;
    }
    .one{
        background-color: red;
    }
    .two{
        background-color: green;
    }
    .three{
        background-color: yellow;
    }
</style>
<div>
    <div id="container">
        <div id="container-inner">
            <div class="content one">
            </div>
            <div class="content two">
            </div>
            <div class="content three">
            </div>
        </div>
    </div>
</div>
Run Code Online (Sandbox Code Playgroud)

我想创建一个小提琴,但https://jsfiddle.net/现在已关闭。