微信小程序——weui的使用
使用
在根目录中复制weui.wxss,app.wxss中引入
在weui.io中查看到自己想要的样式表后,到第二个网站复制代码,复制到自己的项目中即可
<!--pages/register/register2.wxml-->
<view class="container">
<view class="page__hd">
<view class="page__title">学生用户注册</view>
<view class='linkTo' bindtap='toMangerReg'> 我是经营者,上线我的店铺-></view>
</view>
<form>
<view class='list-title'>注册手机</view>
<view class="weui-cells weui-cells_after-title">
<view class="weui-cell weui-cell_select">
<view class="weui-cell__hd" style="width: 80px">
<picker bindchange="bindCountryCodeChange" value="{{countryCodeIndex}}" range="{{countryCodes}}">
<view class="weui-select">{{countryCodes[countryCodeIndex]}}</view>
</picker>
</view>
<view class="weui-cell__bd weui-cell__bd_in-select-before">
<input class="weui-input" placeholder="请输入手机号码" bindinput='mobileChange'/>
</view>
</view>
</view>
<view class='list-title'>实名制</view>
<view class="weui-cells weui-cells_after-title">
<view class="weui-cell weui-cell_select">
<view class="weui-cell__hd" style="">
<picker bindchange="bindSchoolChange" value="{{schoolIndex}}" range="{{schools}}">
<view class="weui-select">学校</view>
</picker>
</view>
<view class="weui-cell__bd weui-cell__bd_in-select-before">
<input class="weui-input"value="{{schools[schoolIndex]}}" bindinput='shcoolChange'/>
</view>
</view>
</view>
<view class="weui-cells weui-cells_after-title">
<view class="weui-cell weui-cell_input">
<view class="weui-cell__hd">
<view class="weui-label" style='width:65px;'>学号</view>
</view>
<view class="weui-cell__bd">
<input class="weui-input" placeholder="请输入你的学号" bindinput='studentIDChange'/>
</view>
</view>
</view>
<view class='list-title' style='margin-bottom:20px;'>上传相关学生证照片(能证明个人人身份)</view>
<view class="weui-uploader__bd">
<view class="weui-uploader__files" id="uploaderFiles">
<block wx:for="{{files}}" wx:key="*this">
<view class="weui-uploader__file" bindtap="previewImage" id="{{item}}">
<image class="weui-uploader__img" src="{{item}}" mode="aspectFill" />
</view>
</block>
</view>
<view class="weui-uploader__input-box" style=''>
<view class="weui-uploader__input" bindtap="chooseImage"></view>
</view>
</view>
<button class="weui-btn" type="default" bindtap='toVerify'>开始验证</button>
</form>
</view>
---------------------