Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

:hover 丢失 #293

Closed
s97712 opened this issue May 9, 2024 · 2 comments
Closed

:hover 丢失 #293

s97712 opened this issue May 9, 2024 · 2 comments
Assignees
Labels
question Further information is requested

Comments

@s97712
Copy link

s97712 commented May 9, 2024

描述这个Bug
设置完 injectAdditionalCssVarScope 选项之后,所有的:hover 伪类都丢失了。

      chain.merge({
          plugin: {
            install: {
              plugin: UnifiedWebpackPluginV5,
              args: [{
                appType: 'taro',
                injectAdditionalCssVarScope: true,
              }],
            }
          }
        })

运行环境

  • OS: ALL
  • Nodejs: 20x
  • Framework: Taro
@s97712 s97712 added the bug Something isn't working label May 9, 2024
@sonofmagic
Copy link
Owner

你这是在小程序平台吗?小程序本身就是没有 :hover 的,要用标签的 hover-class 替代
https://developers.weixin.qq.com/miniprogram/dev/component/view.html

@sonofmagic
Copy link
Owner

当然,你想要在小程序端,保留 :hover 的话,你可以给插件传入一个 cssRemoveHoverPseudoClass: false 配置项
但是,,小程序端 css 里面写 :hover 是没有用的哈。

@sonofmagic sonofmagic added question Further information is requested and removed bug Something isn't working labels May 16, 2024
@s97712 s97712 closed this as completed May 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants