Jelajahi Sumber

模板部分滚动条显示出来

Luolei 6 tahun lalu
induk
melakukan
e6659190bc

+ 0 - 3
src/components/MainSuit/index.jsx

@@ -141,9 +141,6 @@ class MainSuit extends Component{
       leftL = getPageCoordinate(e).boxLeft
     }else{
       const ele = document.activeElement;
-      if(ele.toString().indexOf('HTMLSpanElement') == -1){     //点击的不是span无法聚焦就不再设置位置
-        // return;    先注释
-      }
       leftL = ele.offsetLeft+60
     }
     this.setState({

+ 5 - 7
src/components/TemplateItems/index.jsx

@@ -68,13 +68,11 @@ class TemplateItems extends React.Component {
                             <span className={`${style['fr-element']} ${style['manger']}`} onClick={handleMangerTemplate}>管理</span>
                     </div>) : null
                 }
-                <div style={{width:'450px',overflow:'hidden'}}>
-                    <div className={style.tempLists} ref={this.$cont}>
-                        {
-                            this.genItems().length > 0?this.genItems():
-                            <Empty message={'还没有保存模板'}></Empty>
-                        }
-                    </div>
+                <div className={style.tempLists} ref={this.$cont}>
+                    {
+                        this.genItems().length > 0?this.genItems():
+                        <Empty message={'还没有保存模板'}></Empty>
+                    }
                 </div>
             </div>
         )

+ 1 - 5
src/components/TemplateItems/index.less

@@ -5,12 +5,8 @@
     user-select: none;
     position: relative;
     .tempLists {
-        overflow-y: scroll;
+        overflow-y: auto;
         background-color: #fff;
-        width: 466px;
-        // &::-webkit-scrollbar {
-        //     display: none;
-        // }
     }
     .wrapperTop {
         height: 36px;