IE10: 'visibility:visible' on before pseudo-element of 'visibility:hidden' element

笑着哭i 提交于 2020-01-02 01:37:08

问题


I have made a DIV with visibility: hidden and attached a ::before pseudo-element of this DIV with visibility: visible. This works as expected in Firefox, Chrome and Safari, but in Internet Explorer 10 the pseudo-element does not render.

Please explain if I'm accomplishing this wrong, or whether this is an issue with Internet Explorer. Are there any work arounds (we only have access to the CSS, not the source HTML)?

JSFiddle demonstrating issue.


回答1:


Filters don't work on pseudo elements in IE.
Read: msdn

Other specified styling properties apply to the appearance of the inserted content, not to the element's content.


IE sucks, deal with it.
I think the only way is to change the "hidden text" color to your background color, and you know the rest...



来源:https://stackoverflow.com/questions/17530947/ie10-visibilityvisible-on-before-pseudo-element-of-visibilityhidden-eleme

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!