微信小程序的语法学习1——icon,text,button,input;注册页面

Icon,text,input的使用

1.icon.wxml

<icon type="success"></icon>
	<!--绿色对勾-->
<icon type="info"></icon>
	<!--蓝色i-->
<icon type="warn"></icon>
	<!--红色!-->
<icon type="cancel"></icon>
	<!--红色×-->
<icon type="success" size="20"></icon>
	<!--单位px-->

2.text.wxml

<text selectable='{{true}}'>world</text>
	<!--文本是否可选-->

3.button.wxml
input.wxml

<button type="default">默认按钮</button>
<button type="primary">主要按钮</button>
<button type="warn">否定按钮</button>

<button size="mini">小按钮</button>

<!--plain镂空,disabled 不能按,loading等待刷新,disabled loading常连用-->

<input placeholder='please input'></input>
	<!--输入文本的默认文字'please input'提示输入-->
<input value='selected' disabled></input>
	<!--选中的文字-->
<input password></input>
	<!--密码文字-->

4.简单的注册页面
reg.wxml

<view class='fnt-weight'>注册信息填写</view>
<icon type="info"></icon>
<text>用户名:</text>
<input placeholder='请输入'></input>
<text>密码:</text>
<input password ploceholder='请输入密码'></input>
<button type="primary">提交</button>
<button type="warn">重填</button>

reg.wxss

.fnt-weight{
font-weight:bold;
}

reg.json

{
	"navigationBarTitleText":"用户注册"
}
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值