feat: 增加onBodyMouseLeave回调函数

This commit is contained in:
izbz wh 2020-11-18 16:46:19 +08:00
parent bac23ca5c0
commit cb40026e8c
5 changed files with 42 additions and 90 deletions

4
dist/demo.css vendored
View File

@ -452,8 +452,8 @@
color: rgb(33, 33, 33);
background-clip: padding-box;
-webkit-user-select: none;
/*
Introduced in IE 10.
/*
Introduced in IE 10.
*/
-ms-user-select: none;
user-select: none; }

2
dist/demo.css.map vendored

File diff suppressed because one or more lines are too long

119
dist/demo.js vendored

File diff suppressed because one or more lines are too long

2
dist/demo.js.map vendored

File diff suppressed because one or more lines are too long

View File

@ -67,6 +67,7 @@ const propTypes = {
headerDisplayInRow: PropTypes.bool, // 表头内容超出列宽度时进行换行 or 以...形式展现
showRowNum: PropTypes.oneOfType([PropTypes.bool, PropTypes.object]), // 表格是否自动生成序号,格式为{base:number || 0,defaultKey:string || '_index',defaultName:string || '序号'}
onPaste:PropTypes.func,
onBodyMouseLeave: PropTypes.func
};
const defaultProps = {
@ -1287,6 +1288,10 @@ class Table extends Component {
}
onBodyMouseLeave(e){
this.hideHoverDom(e);
const {onBodyMouseLeave} = this.props;
if(onBodyMouseLeave) {
onBodyMouseLeave()
}
}
detectScrollTarget(e) {