修改了源码 在小程序端正常 其他端需要再调试一下 直接上代码
找到 node_modules -->uview-ui-->components-->u-index-list-->u-index-list.vue
<!-- @touchstart="touchStart" -->
<view
class="u-index-list__letter"
ref="u-index-list__letter"
:style="{ top: $u.addUnit(letterInfo.top || 100) }"
@touchmove.stop.prevent="touchMove"
@touchend.stop.prevent="touchEnd"
@touchcancel.stop.prevent="touchEnd"
>
<view
class="u-index-list__letter__item"
v-for="(item, index) in uIndexList"
@click.stop.prevent="selectClcik(item,index)"
:key="index"
:style="{
backgroundColor: activeIndex === index ? activeColor : 'transparent'
}"
>
<text
class="u-index-list__letter__item__index"
:style="{col