Fetch the repository succeeded.
PostCSS plugin that wraps hover selectors in a media media that's only valid on devices that support true hover events. The goal of this plugin is to prevent mobile browsers (mostly iOS) from getting their hover states "stuck" since hover.
Original idea: https://www.quirksmode.org/blog/archives/2012/11/what_the_hells.html
More explicit support for this feature: https://drafts.csswg.org/mediaqueries/#hover
Tested:
.foo {
bar:hover {
display: block;
}
}
.foo {
@media (hover: hover), (-moz-touch-enabled: 0), (-ms-high-contrast: none), (-ms-high-contrast: active) {
bar:hover {
display: block;
}
}
}
npm install postcss-require-hover
postcss([require("postcss-require-hover")]);
See PostCSS docs for examples for your environment.
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。