| | |
| | | user: { uuid: Utils.getuuid(), eleType: 'input', content: '邮箱/手机', style: {}}, |
| | | password: { uuid: Utils.getuuid(), eleType: 'input', content: '密码', style: {}}, |
| | | login: { uuid: Utils.getuuid(), eleType: 'button', content: '登录', style: {fontSize: '16px', color: '#ffffff', textAlign: 'center', lineHeight: 2.4, backgroundColor: '#44a8f2'}}, |
| | | phone: { uuid: Utils.getuuid(), eleType: 'button', content: '手机短信登录/注册', style: {fontSize: '16px', color: '#44a8f2', textAlign: 'center', lineHeight: 2.4, border: '1px solid #44a8f2'}}, |
| | | phone: { uuid: Utils.getuuid(), eleType: 'button', content: '手机短信登录', style: {fontSize: '16px', color: '#44a8f2', textAlign: 'center', lineHeight: 2.4, border: '1px solid #44a8f2'}}, |
| | | register: { uuid: Utils.getuuid(), eleType: 'text', content: '注册', style: {fontSize: '12px', color: '#44a8f2', textAlign: 'left'}}, |
| | | lose: { uuid: Utils.getuuid(), eleType: 'text', content: '忘记密码?', style: {fontSize: '12px', color: '#44a8f2', textAlign: 'right', textDecoration: 'underline'}}, |
| | | register: { uuid: Utils.getuuid(), eleType: 'text', subItems: [ |
| | | auth: { uuid: Utils.getuuid(), eleType: 'text', subItems: [ |
| | | {type: 'qq', icon: 'qq', label: 'QQ'}, |
| | | {type: 'wechat', icon: 'wechat', label: '微信'}, |
| | | ], content: '其他登录方式', style: {fontSize: '14px', color: '#bcbcbc', textAlign: 'center', marginTop: '30px', marginBottom: '20px'}}, |
| | |
| | | ...fromJS(card.register.style).toJS(), |
| | | componentId: card.uuid, |
| | | uuid: card.register.uuid, |
| | | items: ['font'], |
| | | } |
| | | this.props.triggerEdit(element) |
| | | } |
| | | |
| | | editAuth = (e) => { |
| | | const { card } = this.props |
| | | e.stopPropagation() |
| | | let element = { |
| | | ...fromJS(card.auth.style).toJS(), |
| | | componentId: card.uuid, |
| | | uuid: card.auth.uuid, |
| | | items: ['font', 'margin'], |
| | | } |
| | | this.props.triggerEdit(element) |
| | |
| | | <ContentUpdate element={card.phone} updateContent={(ele) => this.updateContent({...card, phone: ele})}/> |
| | | {card.phone.content} |
| | | </Button> |
| | | {card.lose ? <div className={'plat-name ' + (editId === card.lose.uuid ? 'editing' : '')} style={card.lose.style} onClick={this.editLose}> |
| | | <ContentUpdate element={card.lose} updateContent={(ele) => this.updateContent({...card, lose: ele})}/> |
| | | {card.lose.content} |
| | | <div className="row-box"> |
| | | {card.register ? <div className={'col-item ' + (editId === card.register.uuid ? 'editing' : '')} style={card.register.style} onClick={this.editRegister}> |
| | | <ContentUpdate element={card.register} updateContent={(ele) => this.updateContent({...card, register: ele})}/> |
| | | {card.register.content} |
| | | </div> : null} |
| | | {card.lose ? <div className={'col-item right ' + (editId === card.lose.uuid ? 'editing' : '')} style={card.lose.style} onClick={this.editLose}> |
| | | <ContentUpdate element={card.lose} updateContent={(ele) => this.updateContent({...card, lose: ele})}/> |
| | | {card.lose.content} |
| | | </div> : null} |
| | | <div style={{clear: 'both'}}></div> |
| | | </div> |
| | | {card.auth ? <div className={'plat-name ' + (editId === card.auth.uuid ? 'editing' : '')} style={card.auth.style} onClick={this.editAuth}> |
| | | <ContentUpdate element={card.auth} updateContent={(ele) => this.updateContent({...card, auth: ele})}/> |
| | | {card.auth.content} |
| | | </div> : null} |
| | | {card.register ? <div className={'plat-name ' + (editId === card.register.uuid ? 'editing' : '')} style={card.register.style} onClick={this.editRegister}> |
| | | <ContentUpdate element={card.register} updateContent={(ele) => this.updateContent({...card, register: ele})}/> |
| | | {card.register.content} |
| | | </div> : null} |
| | | {card.register ? <div className="other-register"> |
| | | {card.register.subItems.map(cell => ( |
| | | {card.auth ? <div className="other-auth"> |
| | | {card.auth.subItems.map(cell => ( |
| | | <span key={cell.type}> |
| | | <Icon type={cell.icon} /> |
| | | <p>{cell.label}</p> |