Przeglądaj źródła

血压类型高亮样式修改

zhouna 6 lat temu
rodzic
commit
10acb9d42a
1 zmienionych plików z 8 dodań i 4 usunięć
  1. 8 4
      src/components/MultSpread/index.jsx

+ 8 - 4
src/components/MultSpread/index.jsx

@@ -41,13 +41,13 @@ class MultSpread extends Component{
     this.handleEdit = this.handleEdit.bind(this);
   }
   getClass(){
-    const {saveText,ikey,showAdd,isImports} = this.props;
+    const {saveText,ikey,showAdd} = this.props;
     const labelInx = ikey.substr(1);
     const text = saveText&&saveText[+labelInx];
-    const orgBorder = isImports&&!text?style['orange-border']:'';
+    //const orgBorder = isImports&&!text?style['orange-border']:'';
     const isSelected = text?style['selected']:style['container'];
     const hasAdd = showAdd?style['add']:'';
-    return classNames(isSelected,hasAdd,orgBorder);
+    return classNames(isSelected,hasAdd);
   }
   saveDoms(it){
     const doms = this.state.numDoms;
@@ -203,8 +203,12 @@ class MultSpread extends Component{
   }
   getContClass(){
     const {editable} = this.state;
+    const {isImports,ikey,saveText} = this.props;
+    const labelInx = ikey.substr(1);
+    const text = saveText&&saveText[+labelInx];
+    const orgBorder = isImports&&!text?style['orange-border']:'';
     const edit = editable?style['blue-border']:'';
-    return classNames(edit);
+    return classNames(edit,orgBorder);
   }
   render(){
     const {showAdd,addLabelItem,ikey,copyId,textPrefix,textSuffix} = this.props;