Skip to content

Commit 293ee79

Browse files
committed
fix: 修复tab过长出现左右滚动时指示器位置计算错误
1 parent e697c50 commit 293ee79

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

uview-ui/components/u-tabs/u-tabs.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@
33
background: bgColor
44
}">
55
<!-- $u.getRect()对组件根节点无效,因为写了.in(this),故这里获取内层接点尺寸 -->
6-
<view :id="id">
6+
<view>
77
<scroll-view scroll-x class="u-scroll-view" :scroll-left="scrollLeft" scroll-with-animation>
8-
<view class="u-scroll-box" :class="{'u-tabs-scorll-flex': !isScroll}">
8+
<view class="u-scroll-box" :id="id" :class="{'u-tabs-scorll-flex': !isScroll}">
99
<view class="u-tab-item u-line-1" :id="'u-tab-item-' + index" v-for="(item, index) in list" :key="index" @tap="clickTab(index)"
1010
:style="[tabItemStyle(index)]">
1111
<u-badge :count="item[count] || item['count'] || 0" :offset="offset" size="mini"></u-badge>

0 commit comments

Comments
 (0)