From d074bedd5c2834113fe0c4ed5a3c78ec905681c3 Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期五, 10 九月 2021 16:02:57 +0800 Subject: [PATCH] 2021-09-10 --- src/pc/components/login/normal-login/index.jsx | 17 +++++++++++++++-- 1 files changed, 15 insertions(+), 2 deletions(-) diff --git a/src/pc/components/login/normal-login/index.jsx b/src/pc/components/login/normal-login/index.jsx index 74ec83e..bd48443 100644 --- a/src/pc/components/login/normal-login/index.jsx +++ b/src/pc/components/login/normal-login/index.jsx @@ -10,10 +10,11 @@ import zhCN from '@/locales/zh-CN/model.js' import enUS from '@/locales/en-US/model.js' import { resetStyle } from '@/utils/utils-custom.js' +import getWrapForm from './options' import './index.scss' const LoginForm = asyncComponent(() => import('./loginform')) -const WrapComponent = asyncIconComponent(() => import('../wrapsetting')) +const NormalForm = asyncIconComponent(() => import('@/components/normalform')) class PropCardEditComponent extends Component { static propTpyes = { @@ -141,6 +142,16 @@ } } + getWrapForms = () => { + const { wrap } = this.state.card + + return getWrapForm(wrap) + } + + updateWrap = (res) => { + this.updateComponent({...this.state.card, wrap: res}) + } + render() { const { card, dict } = this.state let style = resetStyle(card.style) @@ -159,7 +170,9 @@ <div className="login-edit-box" style={style} onClick={this.clickComponent} id={card.uuid}> <Popover overlayClassName="mk-popover-control-wrap" mouseLeaveDelay={0.2} mouseEnterDelay={0.2} content={ <div className="mk-popover-control"> - <WrapComponent config={card} updateConfig={this.updateComponent} /> + <NormalForm title="鐧诲綍璁剧疆" width={800} update={this.updateWrap} getForms={this.getWrapForms}> + <Icon type="edit" style={{color: '#1890ff'}} title="缂栬緫"/> + </NormalForm> <Icon className="style" title="璋冩暣鏍峰紡" onClick={this.changeStyle} type="font-colors" /> <Icon className="close" title="鍒犻櫎缁勪欢" type="delete" onClick={() => this.props.deletecomponent(card.uuid)} /> </div> -- Gitblit v1.8.0