微信公开课
微信公开课小程序热门讨论关于「下拉框的问题,求大佬指教」的小程序开发问题
补充:下拉框的问题,求大佬指教
展开:首先声明我不会写下拉框,这是在网上找的demo如图红色框框标出来的地方,鼠标根本就点不到,一点就会到输入框里面下面是wxss和wxmlwxss:select_box{background:fff;width:71%;margin:10rpx;position:relative;float:right;}select{boxsizing:borderbox;width:100%;height:70rpx;border:1pxsolidefefef;borderradius:8rpx;display:flex;alignitems:center;padding:020rpx;}select_text{fontsize:30rpx;flex:1;}select_img{width:30rpx;height:20rpx;display:block;transition:transform03s;}select_img_rotate{transform:rotate(180deg);}option_box{position:absolute;top:70rpx;width:100%;border:1pxsolidefefef;boxsizing:borderbox;height:0;overflowy:auto;bordertop:0;background:fff;transition:height03s;}option{display:block;lineheight:40rpx;fontsize:30rpx;borderbottom:1pxsolidefefef;padding:10rpx;}wxml:<viewclass=select_box<viewclass=selectcatchtap=selectTap<textclass=select_text{{selectData[index]}}<text<imageclass=select_img{{show&&select_img_rotate}}src=imagesdownpng<image<view<viewclass=option_boxstyle=height:{{show?(selectDatalength5?300:selectDatalength*60):0}}rpx;<textclass=optionstyle={{index==selectDatalength1&&border:0;}}wx:for={{selectData}}wx:key=thisdataindex={{index}}catchtap=optionTap{{item}}<text<view<view即速小程序:textarea是原生组件,无法被覆盖原生组件:https:developersweixinqqcomminiprogramdevcomponentnativecomponenthtml:下拉框的样式我根据情况改了一下,但是这个选取不了的问题就一直不知道是哪里的问题,不知道该怎么解决
更多有关「下拉框的问题,求大佬指教」的讨论可以前往微信公开课小程序参与互动哦!了解更多