• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

小程序UI

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

从input组件说起

<input maxlength="10" placeholder="最大输入长度10" />
<div id="wrapper" disabled$="{{disabled}}">\n <p id="placeholder" class$="{{_getPlaceholderClass(placeholderClass)}}" style$="{{placeholderStyle}}" parse-text-content>{{placeholder}} </p> <input id="input" type$="{{_getType(type,password)}}" maxlength$="{{maxlength}}" value$="{{showValue}}" disabled$="{{disabled}}" > </div>

wx-input { height: 1.4rem; display: -webkit-box; display: -ms-flexbox; display: flex; text-overflow: clip; overflow: hidden; white-space: nowrap; font-family: UICTFontTextStyleBody; min-height: 1.4rem; } wx-input input { min-height: 1.4rem; -webkit-box-flex: 1; -ms-flex: 1; flex: 1; border: none; height: inherit; width: inherit; font-size: inherit; font-weight: inherit; font-family: UICTFontTextStyleBody; color: inherit; background: inherit; display: inherit; padding: 0; margin: 0; outline: none; vertical-align: middle; text-align: inherit; overflow: inherit; white-space: inherit; text-overflow: inherit; -webkit-tap-highlight-color: transparent; } wx-input[disabled] p { color: grey; } wx-input div { min-height: 1.4rem; -webkit-box-flex: 1; -ms-flex: 1; flex: 1; text-overflow: inherit; border: none; height: inherit; width: inherit; font-size: inherit; font-weight: inherit; font-family: UICTFontTextStyleBody; color: inherit; background: inherit; display: -webkit-box; display: -ms-flexbox; display: flex; padding: 0; margin: 0; outline: none; text-align: inherit; -webkit-tap-highlight-color: transparent; } wx-input div[type=password] p { color: black; } wx-input div p { height: inherit; min-height: 1.4rem; display: -webkit-box; display: -ms-flexbox; display: flex; -webkit-box-pack: center; -ms-flex-pack: center; justify-content: center; -webkit-box-orient: vertical; -webkit-box-direction: normal; -ms-flex-direction: column; flex-direction: column; text-overflow: inherit; white-space: nowrap; overflow: hidden; vertical-align: middle; }

<loading hidden="{{hidden}}" bindchange="loadingChange">
<div class="wx-loading-mask" style$="background-color: transparent;"></div> <div class="wx-loading"> <i class="wx-loading-icon"></i> <p class="wx-loading-content"><wx-content></wx-content> </p> </div>

.wx-loading { position: fixed; z-index: 2000000000; width: 7.6em; min-height: 7.6em; top: 180px; left: 50%; margin-left: -3.8em; background: rgba(40, 40, 40, 0.75); text-align: center; border-radius: 5px; color: #FFFFFF; font-size: 16px; line-height: normal; } .wx-loading-icon { margin: 30px 0 10px; width: 38px; height: 38px; vertical-align: baseline; display: inline-block; -webkit-animation: weuiLoading 1s steps(12, end) infinite; animation: weuiLoading 1s steps(12, end) infinite; background: transparent url(data:image/svg+xml;base64,PHN2ZyBjbGFzcz0iciIgd2lkdGg9JzEyMHB4JyBoZWlnaHQ9JzEyMHB4JyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAxMDAgMTAwIj4KICAgIDxyZWN0IHg9IjAiIHk9IjAiIHdpZHRoPSIxMDAiIGhlaWdodD0iMTAwIiBmaWxsPSJub25lIiBjbGFzcz0iYmsiPjwvcmVjdD4KICAgIDxyZWN0IHg9JzQ2LjUnIHk9JzQwJyB3aWR0aD0nNycgaGVpZ2h0PScyMCcgcng9JzUnIHJ5PSc1JyBmaWxsPScjRTlFOUU5JwogICAgICAgICAgdHJhbnNmb3JtPSdyb3RhdGUoMCA1MCA1MCkgdHJhbnNsYXRlKDAgLTMwKSc+CiAgICA8L3JlY3Q+CiAgICA8cmVjdCB4PSc0Ni41JyB5PSc0MCcgd2lkdGg9JzcnIGhlaWdodD0nMjAnIHJ4PSc1JyByeT0nNScgZmlsbD0nIzk4OTY5NycKICAgICAgICAgIHRyYW5zZm9ybT0ncm90YXRlKDMwIDUwIDUwKSB0cmFuc2xhdGUoMCAtMzApJz4KICAgICAgICAgICAgICAgICByZXBlYXRDb3VudD0naW5kZWZpbml0ZScvPgogICAgPC9yZWN0PgogICAgPHJlY3QgeD0nNDYuNScgeT0nNDAnIHdpZHRoPSc3JyBoZWlnaHQ9JzIwJyBye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AgICAgICB0cmFuc2Zvcm09J3JvdGF0ZSgyMTAgNTAgNTApIHRyYW5zbGF0ZSgwIC0zMCknPgogICAgPC9yZWN0PgogICAgPHJlY3QgeD0nNDYuNScgeT0nNDAnIHdpZHRoPSc3JyBoZWlnaHQ9JzIwJyByeD0nNScgcnk9JzUnIGZpbGw9JyNDQkNCQ0InCiAgICAgICAgICB0cmFuc2Zvcm09J3JvdGF0ZSgyNDAgNTAgNTApIHRyYW5zbGF0ZSgwIC0zMCknPgogICAgPC9yZWN0PgogICAgPHJlY3QgeD0nNDYuNScgeT0nNDAnIHdpZHRoPSc3JyBoZWlnaHQ9JzIwJyByeD0nNScgcnk9JzUnIGZpbGw9JyNEMkQyRDInCiAgICAgICAgICB0cmFuc2Zvcm09J3JvdGF0ZSgyNzAgNTAgNTApIHRyYW5zbGF0ZSgwIC0zMCknPgogICAgPC9yZWN0PgogICAgPHJlY3QgeD0nNDYuNScgeT0nNDAnIHdpZHRoPSc3JyBoZWlnaHQ9JzIwJyByeD0nNScgcnk9JzUnIGZpbGw9JyNEQURBREEnCiAgICAgICAgICB0cmFuc2Zvcm09J3JvdGF0ZSgzMDAgNTAgNTApIHRyYW5zbGF0ZSgwIC0zMCknPgogICAgPC9yZWN0PgogICAgPHJlY3QgeD0nNDYuNScgeT0nNDAnIHdpZHRoPSc3JyBoZWlnaHQ9JzIwJyByeD0nNScgcnk9JzUnIGZpbGw9JyNFMkUyRTInCiAgICAgICAgICB0cmFuc2Zvcm09J3JvdGF0ZSgzMzAgNTAgNTApIHRyYW5zbGF0ZSgwIC0zMCknPgogICAgPC9yZWN0Pgo8L3N2Zz4=) no-repeat; background-size: 100%; } .wx-loading-content { margin: 0 0 15px; } .wx-loading-mask { position: fixed; z-index: 1000; width: 100%; height: 100%; top: 0; left: 0; } @-webkit-keyframes weuiLoading { 0% { -webkit-transform: rotate3d(0, 0, 1, 0deg); } 100% { -webkit-transform: rotate3d(0, 0, 1, 360deg); } } @keyframes weuiLoading { 0% { -webkit-transform: rotate3d(0, 0, 1, 0deg); } 100% { -webkit-transform: rotate3d(0, 0, 1, 360deg); } }


作者:Sumer
链接:https://www.jianshu.com/p/f9312a98ff10
來源:简书
简书著作权归作者所有,任何形式的转载都请联系作者获得授权并注明出处。

作者:Sumer
链接:https://www.jianshu.com/p/f9312a98ff10
來源:简书
简书著作权归作者所有,任何形式的转载都请联系作者获得授权并注明出处。

鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
自动生成.py文件头部的C语言小程序发布时间:2022-07-18
下一篇:
微信小程序简介发布时间:2022-07-18
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap