fix(components): [virtual-table] horizontal scroll (#7538)

This commit is contained in:
JeremyWuuuuu
2022-05-06 21:28:57 +08:00
committed by GitHub
parent d8775701d5
commit 52a528fde7
2 changed files with 6 additions and 2 deletions

View File

@@ -71,8 +71,6 @@ const Row = ({ cells, rowData }) => {
}
Row.inheritAttrs = false
console.log(data)
</script>
<style>

View File

@@ -39,6 +39,12 @@ export const useGridWheel = (
x = 0
}
// Special case for windows machine with shift key + wheel scrolling
if (e.shiftKey && y !== 0) {
x = y
y = 0
}
if (
hasReachedEdge(xOffset, yOffset) &&
hasReachedEdge(xOffset + x, yOffset + y)