From 783becf363f727000358b9ae0d93d60e394c431f Mon Sep 17 00:00:00 2001 From: dongj0316 <475586651@qq.com> Date: Thu, 30 May 2019 17:09:02 +0800 Subject: [PATCH] [Improvement] IndexBar: Use transform to optimize (#3408) --- packages/index-anchor/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/index-anchor/index.js b/packages/index-anchor/index.js index 30f32d4cc..201445170 100644 --- a/packages/index-anchor/index.js +++ b/packages/index-anchor/index.js @@ -25,7 +25,7 @@ export default sfc({ anchorStyle() { if (this.sticky) { return { - top: `${this.top}px`, + transform: `translate3d(0, ${this.top}px, 0)`, color: this.parent.highlightColor, zIndex: `${this.parent.zIndex}` };