button设置active后长按效果不恢复,不设置少了点击反馈?真机测试没问题。

小程序 文章 2020-09-01 16:41 645 0 全屏看文

AI助手支持GPT4.0

button设置active后长按效果不恢复,不设置少了点击反馈?真机测试没问题。After the button is set to active, the effect of long pressing will not be restored. If the button is not set, click feedback is missing? The real machine test is no problem.

button设置active后长按效果不恢复,不设置少了点击反馈?真机测试没问题。

回答:

仙ღ₅₂₀¹³¹⁴:

button的样式 建议设置 button的hover-class

尽管如此,世界依旧美丽:https://developers.weixin.qq.com/s/yFowC2mb72k1
尽管如此,世界依旧美丽:长按‘你好’按钮,黄色背景不会消失,再点一下才会消失
微喵网络:

弄一个 [ 能复现问题的简单的 ] 代码片段

https://developers.weixin.qq.com/miniprogram/dev/devtools/minicode.html

尽管如此,世界依旧美丽:你好.btn:active{ 
  background-color: yellow; 

.btn{ 
  width: 150px; 
  height: 50px; 
  border: 1px solid rgb(220, 223, 230); 
  background-color: #409EFF; 
  color: white; 
}
尽管如此,世界依旧美丽:https://developers.weixin.qq.com/s/yFowC2mb72k1
尽管如此,世界依旧美丽:长按‘你好’按钮,黄色背景不会消失,再点一下才会消失
微喵网络:没复现,长按后能恢复
微喵网络:以真机为准,模拟器仅供参考
尽管如此,世界依旧美丽:我这边好像不能发视频吧
微喵网络:模拟器上不用纠结,真机没问题就行
尽管如此,世界依旧美丽:就是说开发工具只能参考,😂
微喵网络:对

-EOF-

AI助手支持GPT4.0