From 81d171b4738c72991a6169a9d08e9775d1897f9d Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期四, 17 十月 2024 11:17:42 +0800 Subject: [PATCH] Merge branch 'master' into positec --- src/menu/stylecontroller/index.jsx | 15 +++++++++------ 1 files changed, 9 insertions(+), 6 deletions(-) diff --git a/src/menu/stylecontroller/index.jsx b/src/menu/stylecontroller/index.jsx index 850eafb..59dabec 100644 --- a/src/menu/stylecontroller/index.jsx +++ b/src/menu/stylecontroller/index.jsx @@ -130,9 +130,12 @@ } onCloseDrawer = () => { + const { type } = this.state let card = fromJS(this.state.card).toJS() - if (card.borderWidth === '0px' || !card.borderWidth) { + if (type === 'toolBtn' && card.borderWidth === '0px') { + delete card.borderColor + } else if (card.borderWidth === '0px' || !card.borderWidth) { delete card.borderWidth delete card.borderColor } @@ -893,11 +896,11 @@ label={<ColumnWidthOutlined title="杈规瀹藉害"/>} labelCol={{xs: { span: 24 }, sm: { span: 4 }}} wrapperCol={ {xs: { span: 24 }, sm: { span: 20 }} } > - {borposition === 'outer' ? <StyleInput defaultValue={card.borderWidth || ''} options={['px']} onChange={this.changeBorderWidth}/> : null} - {borposition === 'left' ? <StyleInput defaultValue={card.borderLeftWidth || ''} options={['px']} onChange={this.changeBorderWidth}/> : null} - {borposition === 'right' ? <StyleInput defaultValue={card.borderRightWidth || ''} options={['px']} onChange={this.changeBorderWidth}/> : null} - {borposition === 'top' ? <StyleInput defaultValue={card.borderTopWidth || ''} options={['px']} onChange={this.changeBorderWidth}/> : null} - {borposition === 'bottom' ? <StyleInput defaultValue={card.borderBottomWidth || ''} options={['px']} onChange={this.changeBorderWidth}/> : null} + {borposition === 'outer' ? <StyleInput clear={true} defaultValue={card.borderWidth || ''} options={['px']} onChange={this.changeBorderWidth}/> : null} + {borposition === 'left' ? <StyleInput clear={true} defaultValue={card.borderLeftWidth || ''} options={['px']} onChange={this.changeBorderWidth}/> : null} + {borposition === 'right' ? <StyleInput clear={true} defaultValue={card.borderRightWidth || ''} options={['px']} onChange={this.changeBorderWidth}/> : null} + {borposition === 'top' ? <StyleInput clear={true} defaultValue={card.borderTopWidth || ''} options={['px']} onChange={this.changeBorderWidth}/> : null} + {borposition === 'bottom' ? <StyleInput clear={true} defaultValue={card.borderBottomWidth || ''} options={['px']} onChange={this.changeBorderWidth}/> : null} </Form.Item> </Col> <Col span={24}> -- Gitblit v1.8.0