|
@@ -57,17 +57,13 @@ componentWillReceiveProps(nextP){
|
|
|
that.context.scrollArea&&that.context.scrollArea.refresh();
|
|
|
});
|
|
|
}
|
|
|
- //bug2276,FF26初始光标位置问题
|
|
|
- if(!nextP.children&&!nextP.fuzhen){
|
|
|
- this.$div.current.innerHTML='';
|
|
|
- }
|
|
|
}
|
|
|
render(){
|
|
|
const {title,children,editable,className,handleFocus,fuzhen,border,handleBlur,titleTop,backgroundColor,boxId} = this.props;
|
|
|
return <div className={style["box"]+" "+"clearfix"} >
|
|
|
<div className={style["title"] + ' '+(className||'')} style={{marginTop:titleTop?'22px':''}}>{title}</div>
|
|
|
<div ref={this.$div} className={`${style["content"]} ${border?style["border"]:''} ${backgroundColor?style["noBorder"]:''}`} contentEditable={editable} style={this.getBoxStyle()} onFocus={editable?handleFocus:null} onInput={this.handleInput} onClick={(e)=>{this.handleClick(e);}} onBlur={handleBlur} id={boxId} onkeydown={handleEnter}>
|
|
|
- {fuzhen?children||fuzhen||'':children||''}
|
|
|
+ {fuzhen?children||fuzhen:children}
|
|
|
</div>
|
|
|
</div>
|
|
|
}
|