调整oj编辑器公式展示issue

video_transcode
杨树明 5 years ago
parent 1747f0819d
commit 91790bfdaa

@ -1,7 +1,7 @@
/* /*
* @Description: 评论表单 * @Description: 评论表单
* @Author: tangjiang * @Author: tangjiang
* @Github: * @Github:
* @Date: 2019-12-17 17:32:55 * @Date: 2019-12-17 17:32:55
* @LastEditors : tangjiang * @LastEditors : tangjiang
* @LastEditTime : 2020-01-06 18:42:09 * @LastEditTime : 2020-01-06 18:42:09
@ -18,7 +18,7 @@ function CommentForm (props) {
const { const {
onCancel, onCancel,
onSubmit, onSubmit,
form, form,
type type
} = props; } = props;
@ -47,7 +47,7 @@ function CommentForm (props) {
setShowQuill(false); setShowQuill(false);
setCtx(''); setCtx('');
props.form.resetFields(); props.form.resetFields();
onCancel && onCancel(); onCancel && onCancel();
} }
// 编辑器内容变化时 // 编辑器内容变化时
@ -98,7 +98,7 @@ function CommentForm (props) {
{ required: true, message: '评论内容不能为空'} { required: true, message: '评论内容不能为空'}
], ],
})( })(
<Input <Input
onClick={() => handleInputClick(type)} onClick={() => handleInputClick(type)}
placeholder="说点儿什么~" placeholder="说点儿什么~"
className={showQuill ? '' : 'show_input'} className={showQuill ? '' : 'show_input'}
@ -110,13 +110,13 @@ function CommentForm (props) {
/> />
) )
} }
<QuillForEditor <QuillForEditor
imgAttrs={{width: '60px', height: '30px'}} imgAttrs={{width: '60px', height: '30px'}}
wrapStyle={{ wrapStyle={{
height: showQuill ? 'auto' : '0px', height: showQuill ? 'auto' : '0px',
opacity: showQuill ? 1 : 0, opacity: showQuill ? 1 : 0,
overflow: showQuill ? 'none' : 'hidden', overflow: showQuill ? 'none' : 'none',
transition: 'all 0.3s' transition: 'all 0.3s'
}} }}
autoFocus={focus} autoFocus={focus}

Loading…
Cancel
Save