Commit 670ecc2b by zhanghaozhe

我的宝箱滑块验证样式

parent 0755e325
...@@ -7,14 +7,14 @@ const scene = 'nc_login_h5' ...@@ -7,14 +7,14 @@ const scene = 'nc_login_h5'
class CaptchaAli extends Component { class CaptchaAli extends Component {
nc = null nc = null
el = null
state = { state = {
isLoaded: false isLoaded: false
} }
componentDidMount() { componentDidMount() {
const _this = this const _this = this
const el = document.querySelector('#nc') this.el && initCaptchaNC(() => {
el && initCaptchaNC(() => {
const nc_token = [appkey, (new Date()).getTime(), Math.random()].join(':'); const nc_token = [appkey, (new Date()).getTime(), Math.random()].join(':');
this.nc = NoCaptcha.init({ this.nc = NoCaptcha.init({
renderTo: '#nc', renderTo: '#nc',
...@@ -46,7 +46,7 @@ class CaptchaAli extends Component { ...@@ -46,7 +46,7 @@ class CaptchaAli extends Component {
const {mb = 30} = this.props const {mb = 30} = this.props
return ( return (
<div id={'captcha'} style={{marginBottom: `${mb}px`}}> <div id={'captcha'} style={{marginBottom: `${mb}px`}}>
<div id="nc"></div> <div id="nc" ref={el => this.el = el}></div>
</div> </div>
); );
} }
......
...@@ -204,7 +204,7 @@ class BindPhone extends Component { ...@@ -204,7 +204,7 @@ class BindPhone extends Component {
}} }}
/> />
</div> </div>
<CaptchaAli getInstance={this.getCaptchaInstance} onVerify={this.onVerify}/> <CaptchaAli getInstance={this.getCaptchaInstance} onVerify={this.onVerify} mb={15}/>
<div className="popup-form__item"> <div className="popup-form__item">
<Field <Field
name="code" name="code"
......
...@@ -2,9 +2,10 @@ ...@@ -2,9 +2,10 @@
// .popup-form { // .popup-form {
// text-align: center; // text-align: center;
.popup-packet__button--bundle { .popup-packet__button--bundle {
margin-top: 5px; margin-top: 5px;
} }
// } // }
[data-skip="default"] { [data-skip="default"] {
...@@ -17,7 +18,7 @@ ...@@ -17,7 +18,7 @@
border-right-style: none; border-right-style: none;
border-radius: 6px 0 0 6px; border-radius: 6px 0 0 6px;
} }
.popup-form__button--code { .popup-form__button--code {
border-radius: 6px; border-radius: 6px;
} }
...@@ -28,7 +29,7 @@ ...@@ -28,7 +29,7 @@
border-radius: 15px; border-radius: 15px;
font-size: 13px; font-size: 13px;
} }
.popup-form__ipt { .popup-form__ipt {
border: 1px solid #99D6FF; border: 1px solid #99D6FF;
border-radius: 6px; border-radius: 6px;
...@@ -90,10 +91,44 @@ ...@@ -90,10 +91,44 @@
} }
.popup-form { .popup-form {
// width: 290px;
// height: 257px;
// padding: 20px 20px 0;
box-sizing: border-box; box-sizing: border-box;
#captcha {
margin: 0 auto;
width: 269px;
height: 40px;
#nc {
height: 100%;
}
._nc {
.stage1 {
height: 100%;
.slider {
height: 100%;
.label {
height: 40px;
line-height: 40px;
}
.button {
width: 40px;
height: 40px;
.icon{
left: 5px;
}
}
.bg-green{
height: 40px;
line-height: 40px;
}
}
}
}
}
} }
.popup-form__item { .popup-form__item {
...@@ -101,7 +136,7 @@ ...@@ -101,7 +136,7 @@
align-items: center; align-items: center;
justify-content: center; justify-content: center;
margin: 0 auto 15px; margin: 0 auto 15px;
.popup-form__ipt { .popup-form__ipt {
flex: 1; flex: 1;
} }
...@@ -173,8 +208,8 @@ ...@@ -173,8 +208,8 @@
width: 110px; width: 110px;
height: 36px; height: 36px;
padding: 0; padding: 0;
border: 1px solid #E5E5E5; border: 1px solid #E5E5E5;
box-sizing: border-box; box-sizing: border-box;
font-size: 13px; font-size: 13px;
color: #999; color: #999;
text-align: center; text-align: center;
......
...@@ -301,7 +301,7 @@ export default [ ...@@ -301,7 +301,7 @@ export default [
}, },
//限时免费落地页 //限时免费落地页
{ {
path:'/free', path: '/free',
exact: true, exact: true,
component: loadable(() => import(/*limit-free*/'@/components/limit-free')) component: loadable(() => import(/*limit-free*/'@/components/limit-free'))
}, },
...@@ -313,7 +313,7 @@ export default [ ...@@ -313,7 +313,7 @@ export default [
// 新的开宝箱活动-我的宝箱 // 新的开宝箱活动-我的宝箱
{ {
path: '/box/yearTreasure', path: '/box/yearTreasure',
component: loadable(() => import(/* webpackChunkName: 'treasure-box-mybox' */ '@components/activity/treasure-box/myTreasure/index')) component: loadable(() => import(/* webpackChunkName: 'treasure-box-mybox' */ '@components/activity/treasure-box/myTreasure/index')),
}, },
// 新的开宝箱活动-扫码、分享页 // 新的开宝箱活动-扫码、分享页
{ {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment