微信小程序页面文字不显示
发布于 6 年前 作者 xujie 8379 次浏览 来自 问答

页面渲染了数据,但是文字不显示,而且没有加上任何隐藏或者透明度的属性。但是就是不显示

5 回复

我也遇到相同的问题了,,,难过

我也遇到同样情况,你这个问题解决了吗?

<view class='test' style="left:{{item.left0}}%;" wx:for="{{alltext}}" wx:for-item="item" wx:key="xxx" wx:for-index="id">
       <view class='time'></view>
       <view style='width:100%;height:92%;margin:0 auto; box-sizing: border-box;position: relative;height:92%'>
         <view class='pm' style='font-size:18px;line-height:18px;padding:0 48px'>{{id+1}}/{{allnum}}</view>
         <view class='title pm'>{{item.title}}</view>
         <view class='allsel' wx:if="{{item.type==1}}" style='width:100%'>
           <!-- 正确值   -->
           <view class='sel pr {{item.allhui&&item.sel_type=="radio"?"huise":""}} {{!queding?"huise":""}} {{item.allhui&&item.sel_type=="checkbox"?"opacity1":""}}  {{sitem.isSelect? "black":""}} {{sitem.zhengqiuorcuowu?"green":""}}' wx:for="{{item.cont}}" data-sel='{{sitem.judge}}' wx:for-index="idx" wx:for-item="sitem"
             bindtap='clicksel' data-type="{{item.type}}" data-id="{{idx}}" data-selclass="{{item.sel_type}}" data-title="{{id}}">
             <view style='margin-right:20rpx;'>{{english[idx]}}</view>
             <view>{{sitem.judge}}</view>
             <image class='juage {{sitem.showduicuo?"selpic":""}}' style='width:30rpx;height:30rpx;margin-right:10rpx;' src='{{sitem.status=="true"?"https://video-chanel.widiazine.cn/xcx/gou.svg":"https://video-chanel.widiazine.cn/xcx/cha.svg"}}'></image>
           </view>
         </view>
         <view class='allselpic' wx:if="{{item.type==0}}">
           <view class='selp {{sitem.zhengqueborder?"zhengqueborder":""}} {{sitem.borderStyle?"selborder":""}}' wx:for="{{item.cont}}" data-sel='{{sitem.judge}}' wx:for-index="idx" data-type="{{item.type}}" wx:for-item="sitem" bindtap='clicksel' data-id="{{idx}}"
             data-selclass="{{item.sel_type}}" data-title="{{id}}">
             <image style='width:100%;' mode="widthFix" src='{{sitem.judge}}'></image>
             <view class='selE'>
               <view class='selenglish {{!sitem.chuoduiorenglish?"gou":""}}'>
                 {{english[idx]}}
               </view>
               <view>
                 <image class=' {{sitem.chuoduiorenglish?"gou":""}}' style='width:30rpx;height:30rpx;margin-right:10rpx;' src='{{sitem.status=="true"?"https://video-chanel.widiazine.cn/xcx/gou.svg":"https://video-chanel.widiazine.cn/xcx/cha.svg"}}'></image>
               </view>
             </view>
             <view class='tupianfucen {{!sitem.fucenstatus?"gou":""}}'>
             </view>
           </view>
         </view>
 
         <view class='allselpics' wx:if="{{item.type==2}}">
           <view class='selps {{sitem.zhengqueborder?"zhengqueborder":""}} {{sitem.borderStyle?"selborder":""}}' wx:for="{{item.cont}}" wx:for-index="idx" data-sel='{{sitem.judge}}' data-type="{{item.type}}" wx:for-item="sitem" bindtap='clicksel' data-id="{{idx}}"
             data-selclass="{{item.sel_type}}" data-title="{{id}}">
             <image style='width:100%;' mode="widthFix" src='{{sitem.judge}}'></image>
             <view class='selE'>
               <view class='selenglish {{!sitem.chuoduiorenglish?"gou":""}}'>
                 {{english[idx]}}
               </view>
               <view>
                 <image class=' {{sitem.chuoduiorenglish?"gou":""}}' style='width:30rpx;height:30rpx;margin-right:10rpx;' src='{{sitem.status=="true"?"https://video-chanel.widiazine.cn/xcx/gou.svg":"https://video-chanel.widiazine.cn/xcx/cha.svg"}}'></image>
               </view>
             </view>
             <view class='tupianfucen {{!sitem.fucenstatus?"gou":""}}'>
             </view>
           </view>
         </view>
 
         <view class='nextBtn'>
                     <view class='buttom pr' data-id='{{id}}' bindtap='nextTest'>下一题</view>
         <view class='buttom {{item.sel_type=="radio"?"confirm":""}} {{!queding?"confirm":""}}' data-type="{{item.type}}" data-id='{{id}}' bindtap='confirm'>确定</view>
         </view>
 
       </view>
 
 
     </view>
.test{
    position: absolute;
  width: 750rpx;
  height: 100%;
  box-sizing: border-box;
  overflow: hidden;
  /* z-index: 999; */
      
}
.title{
  color: #000000;
  margin: 64rpx 0 30px 0;
  /* font-weight: 600; */
  letter-spacing: 5rpx;
  font-size:40rpx;
  line-height: 28px;
  padding:0 48px
}
.allsel{
  /* padding-bottom: 86px; */
  height:80%;
overflow-y:auto;
padding: 0 48px;
box-sizing: border-box;
padding-bottom:30%;
 
 
}
.sel{
  font-size: 28rpx;
  line-height: 20px;
  color:#666666;
  display: flex;
  flex-direction: row;
  margin-bottom: 60rpx;
  position: relative;
   
}

2点钟都不睡啊。。做个代码片段可以不

回到顶部