mirror of
https://github.com/youzan/vant.git
synced 2025-10-19 18:14:13 +00:00
fix(IndexBar): fix the problem of rolling out parent boundaries when sucking bottom (#4218)
This commit is contained in:
@@ -14,7 +14,8 @@ export default createComponent({
|
||||
data() {
|
||||
return {
|
||||
top: 0,
|
||||
active: false
|
||||
active: false,
|
||||
position: 'static'
|
||||
};
|
||||
},
|
||||
|
||||
@@ -26,9 +27,10 @@ export default createComponent({
|
||||
anchorStyle() {
|
||||
if (this.sticky) {
|
||||
return {
|
||||
position: this.position,
|
||||
zIndex: `${this.parent.zIndex}`,
|
||||
transform: `translate3d(0, ${this.top}px, 0)`,
|
||||
color: this.parent.highlightColor,
|
||||
zIndex: `${this.parent.zIndex}`
|
||||
};
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user