From fe838f60f733b9476ecc0526f0202273836cedcb Mon Sep 17 00:00:00 2001 From: thuhole Date: Thu, 25 Jun 2020 15:44:06 +0800 Subject: [PATCH] bug fix --- src/UserAction.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/UserAction.js b/src/UserAction.js index 7c89f78..578b96f 100644 --- a/src/UserAction.js +++ b/src/UserAction.js @@ -9,6 +9,7 @@ import {cache} from './cache'; import {API_VERSION_PARAM, THUHOLE_API_ROOT, API, get_json, token_param} from './flows_api'; import './UserAction.css'; +import {ColorPicker} from "./color_picker"; const BASE64_RATE=4/3; const MAX_IMG_DIAM=8000; @@ -399,6 +400,7 @@ export class ReplyForm extends Component { this.on_change_bound=this.on_change.bind(this); this.area_ref=this.props.area_ref||React.createRef(); this.global_keypress_handler_bound=this.global_keypress_handler.bind(this); + this.color_picker=new ColorPicker(); } global_keypress_handler(e) { @@ -476,7 +478,7 @@ export class ReplyForm extends Component { { this.state.preview ?
- +
: } @@ -509,6 +511,7 @@ export class PostForm extends Component { this.area_ref=React.createRef(); this.on_change_bound=this.on_change.bind(this); this.on_img_change_bound=this.on_img_change.bind(this); + this.color_picker=new ColorPicker(); } componentDidMount() { @@ -736,7 +739,7 @@ export class PostForm extends Component { { this.state.preview ?
- +
: }