feat: 首次提交
This commit is contained in:
61
pages/component/nav/tabbar-C/pageA.vue
Normal file
61
pages/component/nav/tabbar-C/pageA.vue
Normal file
@ -0,0 +1,61 @@
|
||||
<!--本文件由FirstUI授权予新疆天衡创新研究院有限公司(手机号:1 86 1 407254 9,身份证尾号:5A07X5)专用,请尊重知识产权,勿私下传播,违者追究法律责任。-->
|
||||
<template>
|
||||
<view class="fui-wrap">
|
||||
<view class="fui-header">
|
||||
<view class="fui-title__text">PageA:组件</view>
|
||||
<view class="fui-desc__text">Tabbar 标签栏,用于在不同功能模块之间进行切换,小图标建议尺寸84*84。</view>
|
||||
</view>
|
||||
<view class="fui-body">
|
||||
|
||||
<fui-divider text="往下滑动~" backgroundColor="#fff"></fui-divider>
|
||||
</view>
|
||||
<view class="fui-footer">到达底部</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: "pageA",
|
||||
data() {
|
||||
return {
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.fui-header {
|
||||
width: 100%;
|
||||
padding: 52rpx 32rpx;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.fui-body {
|
||||
width: 100%;
|
||||
height: 800px;
|
||||
padding:0 32rpx;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
|
||||
.fui-title__text {
|
||||
text-align: left;
|
||||
font-size: 36rpx;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.fui-desc__text {
|
||||
margin-top: 8rpx;
|
||||
color: #B2B2B2;
|
||||
text-align: left;
|
||||
font-size: 28rpx;
|
||||
font-weight: 400;
|
||||
word-break: break-all;
|
||||
}
|
||||
.fui-footer{
|
||||
padding: 64rpx 32rpx;
|
||||
text-align: center;
|
||||
font-size: 24rpx;
|
||||
}
|
||||
</style>
|
52
pages/component/nav/tabbar-C/pageB.vue
Normal file
52
pages/component/nav/tabbar-C/pageB.vue
Normal file
@ -0,0 +1,52 @@
|
||||
<!--本文件由FirstUI授权予新疆天衡创新研究院有限公司(手机号:18 61 4 07 25 49,身份证尾号:5A07X5)专用,请尊重知识产权,勿私下传播,违者追究法律责任。-->
|
||||
<template>
|
||||
<view class="fui-wrap">
|
||||
<view class="fui-header">
|
||||
<view class="fui-title__text">PageB:布局</view>
|
||||
<view class="fui-desc__text">非必要情况下建议使用原生配置tababr。</view>
|
||||
</view>
|
||||
<view class="fui-body">
|
||||
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: "pageB",
|
||||
data() {
|
||||
return {
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style>
|
||||
.fui-header {
|
||||
width: 100%;
|
||||
padding: 52rpx 32rpx;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.fui-body {
|
||||
width: 100%;
|
||||
padding-bottom: 64rpx;
|
||||
}
|
||||
|
||||
|
||||
.fui-title__text {
|
||||
text-align: left;
|
||||
font-size: 36rpx;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.fui-desc__text {
|
||||
margin-top: 8rpx;
|
||||
color: #B2B2B2;
|
||||
text-align: left;
|
||||
font-size: 28rpx;
|
||||
font-weight: 400;
|
||||
word-break: break-all;
|
||||
}
|
||||
</style>
|
52
pages/component/nav/tabbar-C/pageC.vue
Normal file
52
pages/component/nav/tabbar-C/pageC.vue
Normal file
@ -0,0 +1,52 @@
|
||||
<!--本文件由FirstUI授权予新疆天衡创新研究院有限公司(手机号:18 6 14 07254 9,身份证尾号:5A07X5)专用,请尊重知识产权,勿私下传播,违者追究法律责任。-->
|
||||
<template>
|
||||
<view class="fui-wrap">
|
||||
<view class="fui-header">
|
||||
<view class="fui-title__text">PageC:模板</view>
|
||||
<view class="fui-desc__text">由于Nvue端Android下内容超出会强制隐藏,所以App-Nvue暂不支持中间凸起图标,可使用原生tabbar配置。</view>
|
||||
</view>
|
||||
<view class="fui-body">
|
||||
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: "pageC",
|
||||
data() {
|
||||
return {
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style>
|
||||
.fui-header {
|
||||
width: 100%;
|
||||
padding: 52rpx 32rpx;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.fui-body {
|
||||
width: 100%;
|
||||
padding-bottom: 64rpx;
|
||||
}
|
||||
|
||||
|
||||
.fui-title__text {
|
||||
text-align: left;
|
||||
font-size: 36rpx;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.fui-desc__text {
|
||||
margin-top: 8rpx;
|
||||
color: #B2B2B2;
|
||||
text-align: left;
|
||||
font-size: 28rpx;
|
||||
font-weight: 400;
|
||||
word-break: break-all;
|
||||
}
|
||||
</style>
|
98
pages/component/nav/tabbar-C/pageD.vue
Normal file
98
pages/component/nav/tabbar-C/pageD.vue
Normal file
@ -0,0 +1,98 @@
|
||||
<!--本文件由FirstUI授权予新疆天衡创新研究院有限公司(手机号:1 861 4 0 72 5 4 9,身份证尾号:5A07X5)专用,请尊重知识产权,勿私下传播,违者追究法律责任。-->
|
||||
<template>
|
||||
<view class="fui-wrap">
|
||||
<view class="fui-logo__box">
|
||||
<image src="/static/images/common/img_logo.png" class="fui-logo" mode="widthFix"></image>
|
||||
<view class="fui-title">First UI</view>
|
||||
<view class="fui-version">Version {{version}}</view>
|
||||
</view>
|
||||
|
||||
<view class="fui-page__bd">
|
||||
<view class="fui-desc">
|
||||
<text class="fui-mr">First UI</text> 是一套基于uni-app开发的组件化、可复用、易扩展、低耦合的跨平台移动端UI 组件库。
|
||||
</view>
|
||||
<fui-list-cell topBorder arrow @click="getLink">
|
||||
去STAR
|
||||
</fui-list-cell>
|
||||
<fui-list-cell arrow @click="href('/pages/my/updated/updated')">
|
||||
功能介绍
|
||||
</fui-list-cell>
|
||||
<fui-list-cell bottomLeft="0" arrow @click="href('/pages/my/vip/vip')">
|
||||
会员介绍
|
||||
</fui-list-cell>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import {
|
||||
mapState
|
||||
} from 'vuex'
|
||||
import $fui from '@/components/firstui/fui-clipboard';
|
||||
export default {
|
||||
computed: mapState(['version','status']),
|
||||
data() {
|
||||
return {
|
||||
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
getLink(e) {
|
||||
// #ifdef MP-BAIDU
|
||||
if(this.status==0){
|
||||
this.fui.toast('暂不支持此功能~')
|
||||
return;
|
||||
}
|
||||
// #endif
|
||||
$fui.getClipboardData('https://github.com/FirstUI/FirstUI', res => {
|
||||
this.fui.toast('GitHub地址复制成功');
|
||||
}, e);
|
||||
},
|
||||
href(page){
|
||||
this.fui.href(page)
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style>
|
||||
|
||||
.fui-logo__box {
|
||||
width: 100%;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
padding-top: 64rpx;
|
||||
padding-bottom: 64rpx;
|
||||
}
|
||||
|
||||
.fui-logo {
|
||||
width: 120rpx;
|
||||
height: 120rpx;
|
||||
border-radius: 24rpx;
|
||||
}
|
||||
|
||||
.fui-title {
|
||||
font-size: 36rpx;
|
||||
padding-top: 24rpx;
|
||||
}
|
||||
|
||||
.fui-version {
|
||||
padding-top: 8rpx;
|
||||
font-size: 24rpx;
|
||||
font-weight: 400;
|
||||
}
|
||||
.fui-desc {
|
||||
font-size: 28rpx;
|
||||
line-height: 56rpx;
|
||||
padding: 0 32rpx;
|
||||
margin-bottom: 64rpx;
|
||||
box-sizing: border-box;
|
||||
font-weight: 400;
|
||||
}
|
||||
|
||||
.fui-mr {
|
||||
margin-right: 8rpx;
|
||||
}
|
||||
</style>
|
86
pages/component/nav/tabbar-C/tabbar-C.vue
Normal file
86
pages/component/nav/tabbar-C/tabbar-C.vue
Normal file
@ -0,0 +1,86 @@
|
||||
<!--本文件由FirstUI授权予新疆天衡创新研究院有限公司(手机号:1 86 1407 2 549,身份证尾号:5A07X5)专用,请尊重知识产权,勿私下传播,违者追究法律责任。-->
|
||||
<template>
|
||||
<view class="fui-wrap">
|
||||
<view class="fui-page__wrap" :style="{paddingBottom:height+'px'}">
|
||||
<page-a v-if="current===0"></page-a>
|
||||
<page-b v-if="current===1"></page-b>
|
||||
<page-c v-if="current===2"></page-c>
|
||||
<page-d v-if="current===3"></page-d>
|
||||
</view>
|
||||
<fui-tabbar :tabBar="tabBar" :current="current" @init="init" @click="itemClick"></fui-tabbar>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import pageA from './pageA.vue'
|
||||
import pageB from './pageB.vue'
|
||||
import pageC from './pageC.vue'
|
||||
import pageD from './pageD.vue'
|
||||
export default {
|
||||
components: {
|
||||
pageA,
|
||||
pageB,
|
||||
pageC,
|
||||
pageD
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
current: 0,
|
||||
tabBar: [{
|
||||
text: "组件",
|
||||
iconPath: "/static/images/tabbar/assembly_default_3x.png",
|
||||
selectedIconPath: "/static/images/tabbar/assembly_selected_3x.png"
|
||||
},
|
||||
{
|
||||
text: "布局",
|
||||
iconPath: "/static/images/tabbar/layout_default_3x.png",
|
||||
selectedIconPath: "/static/images/tabbar/layout_selected_3x.png"
|
||||
},
|
||||
{
|
||||
text: "模板",
|
||||
iconPath: "/static/images/tabbar/mod_default_3x.png",
|
||||
selectedIconPath: "/static/images/tabbar/mod_selected_3x.png"
|
||||
},
|
||||
{
|
||||
text: "我的",
|
||||
iconPath: "/static/images/tabbar/my_default_3x.png",
|
||||
selectedIconPath: "/static/images/tabbar/my_selected_3x.png"
|
||||
}
|
||||
],
|
||||
height: 0
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
init(e) {
|
||||
//处理tabbar高度,避免内容被tabbar遮住
|
||||
this.height = e.height
|
||||
},
|
||||
itemClick(e) {
|
||||
console.log(e)
|
||||
//这里可以做其他验证处理,比如登录等
|
||||
//....
|
||||
//验证通过执行以下逻辑
|
||||
this.current = e.index
|
||||
|
||||
uni.setNavigationBarTitle({
|
||||
title:['组件','布局','模板','我的'][e.index]
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style>
|
||||
page {
|
||||
background-color: #fff;
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
.fui-wrap {
|
||||
/* #ifndef APP-NVUE */
|
||||
width: 100%;
|
||||
padding-bottom: constant(safe-area-inset-bottom);
|
||||
padding-bottom: env(safe-area-inset-bottom);
|
||||
/* #endif */
|
||||
}
|
||||
</style>
|
Reference in New Issue
Block a user