Skip to content

Commit

Permalink
fix: 修复 scroll-view 组件在 taro-h5 端的兼容问题
Browse files Browse the repository at this point in the history
  • Loading branch information
eiinu committed Aug 2, 2023
1 parent c692ef9 commit 32d156f
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/packages/__VUE/tabs/index.taro.vue
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<template>
<view class="nut-tabs" :class="[direction]" ref="container">
<scroll-view
<nut-scroll-view
:scroll-x="getScrollX"
:scroll-y="getScrollY"
:scroll-with-animation="scrollWithAnimation"
Expand Down Expand Up @@ -32,7 +32,7 @@
<view v-if="canShowLabel" class="nut-tabs__titles-item nut-tabs__titles-placeholder"></view>
</template>
</view>
</scroll-view>
</nut-scroll-view>
<view
class="nut-tabs__content"
ref="tabsContentRef"
Expand All @@ -58,6 +58,7 @@ import Taro from '@tarojs/taro';
import type { RectItem } from './types';
import { useTabContentTouch } from './hooks';
import { useTaroRect } from '@/packages/utils/useTaroRect';
import { ScrollView } from '@tarojs/components';
export class Title {
title = '';
Expand All @@ -70,7 +71,8 @@ export type TabsSize = 'large' | 'normal' | 'small';
const { create } = createComponent('tabs');
export default create({
components: {
JoySmile
JoySmile,
'nut-scroll-view': ScrollView
},
props: {
modelValue: {
Expand Down

0 comments on commit 32d156f

Please sign in to comment.