提交 1ece6dad 编写于 作者: DCloud-WZF's avatar DCloud-WZF 💬

refactor: 修复类型警告

上级 11d3afa6
...@@ -12,21 +12,21 @@ ...@@ -12,21 +12,21 @@
:inWhiteList="true"></u-link> :inWhiteList="true"></u-link>
</view> </view>
<uni-collapse> <uni-collapse>
<uni-collapse-item v-for="menuItem in menu" :key="menuItem!.id" :title="menuItem!.name" <uni-collapse-item v-for="menuItem in menu" :key="menuItem!.id" :title="menuItem.name"
class="item"> class="item">
<view v-for="page in menuItem!.pages" :key="page!.path" class="uni-navigate-item" hover-class="is--active" <view v-for="page in menuItem.pages" :key="page!.path" class="uni-navigate-item" hover-class="is--active"
@click="goPage(`/${page!.path}`)"> @click="goPage(`/${page.path}`)">
<text class="uni-navigate-text">{{ <text class="uni-navigate-text">{{
page!.style["navigationBarTitleText"] page.style["navigationBarTitleText"]
}}</text> }}</text>
<image :src="arrowRightIcon" class="uni-icon-size"></image> <image :src="arrowRightIcon" class="uni-icon-size"></image>
</view> </view>
<uni-collapse style="width: 100%" v-for="childMenu in menuItem!.children" :key="childMenu!.id"> <uni-collapse style="width: 100%" v-for="childMenu in menuItem.children" :key="childMenu!.id">
<uni-collapse-item :title="childMenu!.name" class="item" style="margin-bottom: 0"> <uni-collapse-item :title="childMenu.name" class="item" style="margin-bottom: 0">
<view class="uni-navigate-item" hover-class="is--active" v-for="childPage in childMenu!.pages" <view class="uni-navigate-item" hover-class="is--active" v-for="childPage in childMenu.pages"
:key="childPage!.path" @click="goPage(`/${childPage!.path}`)"> :key="childPage!.path" @click="goPage(`/${childPage.path}`)">
<text class="uni-navigate-text">{{ <text class="uni-navigate-text">{{
childPage!.style["navigationBarTitleText"] childPage.style["navigationBarTitleText"]
}}</text> }}</text>
<image :src="arrowRightIcon" class="uni-icon-size"></image> <image :src="arrowRightIcon" class="uni-icon-size"></image>
</view> </view>
......
...@@ -12,21 +12,21 @@ ...@@ -12,21 +12,21 @@
:inWhiteList="true"></u-link> :inWhiteList="true"></u-link>
</view> </view>
<uni-collapse> <uni-collapse>
<uni-collapse-item v-for="menuItem in menu" :key="menuItem!.id" :title="menuItem!.name" <uni-collapse-item v-for="menuItem in menu" :key="menuItem!.id" :title="menuItem.name"
class="item"> class="item">
<view v-for="page in menuItem!.pages" :key="page!.path" class="uni-navigate-item" hover-class="is--active" <view v-for="page in menuItem.pages" :key="page!.path" class="uni-navigate-item" hover-class="is--active"
@click="goPage(`/${page!.path}`)"> @click="goPage(`/${page.path}`)">
<text class="uni-navigate-text">{{ <text class="uni-navigate-text">{{
page!.style["navigationBarTitleText"] page.style["navigationBarTitleText"]
}}</text> }}</text>
<image :src="arrowRightIcon" class="uni-icon-size"></image> <image :src="arrowRightIcon" class="uni-icon-size"></image>
</view> </view>
<uni-collapse style="width: 100%" v-for="childMenu in menuItem!.children" :key="childMenu!.id"> <uni-collapse style="width: 100%" v-for="childMenu in menuItem.children" :key="childMenu!.id">
<uni-collapse-item :title="childMenu!.name" class="item" style="margin-bottom: 0"> <uni-collapse-item :title="childMenu.name" class="item" style="margin-bottom: 0">
<view class="uni-navigate-item" hover-class="is--active" v-for="childPage in childMenu!.pages" <view class="uni-navigate-item" hover-class="is--active" v-for="childPage in childMenu.pages"
:key="childPage!.path" @click="goPage(`/${childPage!.path}`)"> :key="childPage!.path" @click="goPage(`/${childPage.path}`)">
<text class="uni-navigate-text">{{ <text class="uni-navigate-text">{{
childPage!.style["navigationBarTitleText"] childPage.style["navigationBarTitleText"]
}}</text> }}</text>
<image :src="arrowRightIcon" class="uni-icon-size"></image> <image :src="arrowRightIcon" class="uni-icon-size"></image>
</view> </view>
......
...@@ -11,27 +11,28 @@ ...@@ -11,27 +11,28 @@
<u-link :href="'https://uniapp.dcloud.io/uni-app-x/component/'" <u-link :href="'https://uniapp.dcloud.io/uni-app-x/component/'"
:text="'https://uniapp.dcloud.io/uni-app-x/component/'" :inWhiteList="true"></u-link> :text="'https://uniapp.dcloud.io/uni-app-x/component/'" :inWhiteList="true"></u-link>
</view> </view>
<uni-collapse> <uni-collapse>
<uni-collapse-item v-for="menuItem in menu" :key="menuItem!.id" :title="menuItem!.name" class="item"> <uni-collapse-item v-for="menuItem in menu" :key="menuItem!.id" :title="menuItem.name"
<view v-for="page in menuItem!.pages" :key="page!.path" class="uni-navigate-item" hover-class="is--active" class="item">
@click="goPage(`/${page!.path}`)"> <view v-for="page in menuItem.pages" :key="page!.path" class="uni-navigate-item" hover-class="is--active"
<text class="uni-navigate-text">{{ @click="goPage(`/${page.path}`)">
page!.style["navigationBarTitleText"] <text class="uni-navigate-text">{{
}}</text> page.style["navigationBarTitleText"]
<image :src="arrowRightIcon" class="uni-icon-size"></image> }}</text>
</view> <image :src="arrowRightIcon" class="uni-icon-size"></image>
<uni-collapse style="width: 100%" v-for="childMenu in menuItem!.children" :key="childMenu!.id"> </view>
<uni-collapse-item :title="childMenu!.name" class="item" style="margin-bottom: 0"> <uni-collapse style="width: 100%" v-for="childMenu in menuItem.children" :key="childMenu!.id">
<view class="uni-navigate-item" hover-class="is--active" v-for="childPage in childMenu!.pages" <uni-collapse-item :title="childMenu.name" class="item" style="margin-bottom: 0">
:key="childPage!.path" @click="goPage(`/${childPage!.path}`)"> <view class="uni-navigate-item" hover-class="is--active" v-for="childPage in childMenu.pages"
<text class="uni-navigate-text">{{ :key="childPage!.path" @click="goPage(`/${childPage.path}`)">
childPage!.style["navigationBarTitleText"] <text class="uni-navigate-text">{{
}}</text> childPage.style["navigationBarTitleText"]
<image :src="arrowRightIcon" class="uni-icon-size"></image> }}</text>
</view> <image :src="arrowRightIcon" class="uni-icon-size"></image>
</uni-collapse-item> </view>
</uni-collapse> </uni-collapse-item>
</uni-collapse-item> </uni-collapse>
</uni-collapse-item>
</uni-collapse> </uni-collapse>
<!-- #ifdef UNI-APP-X && APP --> <!-- #ifdef UNI-APP-X && APP -->
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册