优化scroll组件, 支持动态高度

master
yutent 2023-04-07 10:46:29 +08:00
parent 624f275cee
commit 58be54911b
1 changed files with 4 additions and 0 deletions

View File

@ -26,6 +26,7 @@ class Scroll extends Component {
position: relative; position: relative;
width: 100%; width: 100%;
height: 100%; height: 100%;
max-height: inherit;
} }
.wrapper { .wrapper {
@ -33,6 +34,7 @@ class Scroll extends Component {
scrollbar-width: none; scrollbar-width: none;
width: 100%; width: 100%;
height: 100%; height: 100%;
max-height: inherit;
scrollbar-width: 0; scrollbar-width: 0;
&::-webkit-scrollbar { &::-webkit-scrollbar {
@ -232,6 +234,8 @@ class Scroll extends Component {
} else { } else {
this.$refs.y.parentNode.style.display = 'none' this.$refs.y.parentNode.style.display = 'none'
} }
// this.$requestUpdate()
} }
_fetchScrollX(moveX) { _fetchScrollX(moveX) {