javascript - 光标 :move 时 firefox 表单不工作

标签 javascript jquery html css

我有一个像

这样的 HTML 表单

    #stoppage_section .stoppage{
        cursor: move; /* fallback if grab cursor is unsupported */
        cursor: grab;
        cursor: -moz-grab;
        cursor: -webkit-grab;
    }
    <div id="stoppage_section">
      <div class="stoppage">
         <input class="form-control" ....>
      </div>
      <div class="stoppage">
         <input class="form-control" ....>
      </div>
    </div>

当用户在这个 stoppage_section 区域移动时,我想显示像 move 图标这样的光标。但是当鼠标进入输入字段时,它会正常工作。

此代码在 Chrome 中运行良好。 但在 firefox 输入字段中不再可写

我想要什么

当鼠标(光标)位于 div 时,它将显示 move 图标,当鼠标(光标)位于输入字段时,它将正常工作

Mozilla Firefox Version 48.0.2. Latest version not possible to use for me as Firebug looks like native style which is disgusting

最佳答案

像这样?

    .stoppage {
        background-color: #dddddd; /* that you can see the div */
    }

    .stoppage:hover {
        cursor: move; /* fallback if grab cursor is unsupported */
        cursor: grab;
        cursor: -moz-grab;
        cursor: -webkit-grab;
    }
    <div id="stoppage_section">
      <div class="stoppage">
         <input class="form-control" ....>
      </div>
      <div class="stoppage">
         <input class="form-control" ....>
      </div>
    </div>

关于javascript - 光标 :move 时 firefox 表单不工作,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/41827407/

相关文章:

javascript - 谷歌 OAuth gapi.auth.authorize X-Frame-Options : SAMEORIGIN

jquery - 关于 jQuery 和点击功能的问题

javascript - 使用javascript的图像缩小功能

javascript - 在 div 中调用 javascript 函数

javascript - 加载后如何使用 JavaScript 调整 Google map 的大小?

javascript - 在不使用额外助手的情况下限制 Handlebars #each 中的结果

javascript - Vue 过滤器函数总是返回 5 个以上的元素

jquery - 如何将url加载到div标签中

html - 为什么 LESS css 在本地主机上不起作用

php - 尝试使用 laravel 删除值时出错