2016-04-14 57 views
0

我想删除范围内输入(HTML5视频控制)的内线。有什么办法吗?删除输入[范围]内线

Have a Look!

+0

你这个样子的实际标记是什么样的?此外,您使用的是什么浏览器(因为并非所有浏览器都呈现'

回答

0

如果这是一个简单的HTML元素<video>然后你会相当有限,以你如何处理它造型。这些元素的外观会从浏览器到浏览器不同,所看到如下:

火狐

enter image description here

谷歌浏览器

enter image description here

的Internet Explorer

enter image description here

边缘

enter image description here

这些样式是非常困难的,有时甚至是不可能覆盖(尤其是在任何一种一致的方式的),因为它们依赖于样式是浏览器特定如下所示:

audio::-webkit-media-controls-timeline, video::-webkit-media-controls-timeline { 
    -webkit-appearance: media-slider; 
    display: flex; 
    height: 8px; 
    background-color: transparent; 
    min-width: 25px; 
    color: inherit; 
    flex: 1 1 auto; 
    margin: 0px 15px 0px 0px; 
    padding: 0px; 
    border: initial; 
} 

或专门针对t他的范围段:

input[type="range" i] { 
    color: rgb(196, 196, 196); 
} 

你可以尝试使用的风格,会明确地覆盖它,但你的成功可能会有所不同:

input[type="range" i] { 
    /* Attempt to hide this */ 
    color: transparent!important; 
} 

如果您正在寻找类似的东西,你会可能会更好使用基于Javascript的像JPlayerMediaElement.js