我制作了一个 DIV
和 visibility: hidden
并附加了一个 ::before
这个 DIV 的伪元素 visibility : 可见
。这在 Firefox、Chrome 和 Safari 中按预期工作,但在 Internet Explorer 10 中不呈现伪元素。
请解释我是否做错了,或者这是否是 Internet Explorer 的问题。是否有任何解决方法(我们只能访问 CSS,而不能访问源 HTML)?
最佳答案
过滤器不适用于 IE 中的伪元素。
读:
msdn
Other specified styling properties apply to the appearance of the inserted content, not to the element's content.
IE很烂,处理它。
我认为唯一的方法是将“隐藏文本”颜色更改为您的背景颜色,您知道其余的......
关于html - IE10 : 'visibility:visible' on before pseudo-element of 'visibility:hidden' element,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/17530947/