Browse Source

Merge remote-tracking branch 'origin/master'

feature-1.0
Penny 3 years ago
parent
commit
2e20f968b6
  1. 9
      pages.json
  2. 151
      pages/index/index.vue

9
pages.json

@ -4,7 +4,8 @@
"path": "pages/index/index", "path": "pages/index/index",
"style": { "style": {
"navigationBarTitleText": "首页", "navigationBarTitleText": "首页",
"enablePullDownRefresh": false "enablePullDownRefresh": false,
"navigationBarBackgroundColor": "#FFC542"
} }
}, },
{ {
@ -219,10 +220,10 @@
}, },
//tab //tab
"tabBar": { "tabBar": {
"color": "#7A7E83", "color": "#899A96",
"selectedColor": "#1296DB", "selectedColor": "#1A1A1A",
"borderStyle": "black", "borderStyle": "black",
"backgroundColor": "#F8F8F8", "backgroundColor": "#30444E",
"list": [{ "list": [{
"pagePath": "pages/index/index", "pagePath": "pages/index/index",
"iconPath": "static/index-default.png", "iconPath": "static/index-default.png",

151
pages/index/index.vue

@ -16,32 +16,30 @@
</view> </view>
<view class="middle"> <view class="middle">
<uni-group mode="card"> <uni-row class="middle-uni-row" gutter="40">
<uni-grid :column="2" :square="true" :highlight="false" @change="change" :showBorder="true"> <uni-col :span="12" class="middle-uni-col" v-for="(val, i) in funcList" :index="i" :key="i">
<uni-grid-item v-for="(val, i) in funcList" :index="i" :key="i"> <view class="grid-item-box">
<view class="grid-item-box"> <!-- <uni-icons type="image" :size="30" color="#777" /> -->
<!-- <uni-icons type="image" :size="30" color="#777" /> --> <text class="text uni-white">{{ val.title }}</text>
<image :src="val.icon" class="iconImage" mode="aspectFill" /> <image :src="val.icon" class="iconImage" mode="aspectFill" />
<text class="text">{{ val.title }}</text> </view>
</view> </uni-col>
</uni-grid-item> </uni-row>
</uni-grid>
</uni-group>
</view> </view>
<view class="foot"> <view class="foot">
<uni-group mode="card" title="素材数据" style="text-align:center;"> <uni-row class="foot-uni-row" gutter="88">
<uni-grid :column="3" :square="true" :highlight="false"> <uni-col :span="8" class="foot-uni-col" v-for="(params, v) in list" :index="v" :key="v">
<uni-grid-item v-for="(params, v) in list" :index="v" :key="v"> <view class="grid-item-box uni-white">
<view class="grid-item-box"> <!-- <uni-icons type="image" :size="30" color="#777" /> -->
<!-- <uni-icons type="image" :size="30" color="#777" /> --> <view class="icom-div">
<image :src="params.icon" class="listIconImage" mode="aspectFill" /> <image :src="params.icon" class="listIconImage" mode="aspectFill" />
<text class="text">{{ params.text }}</text> </view>
<text class="text">{{ params.num }}</text> <text class="text">{{ params.text }}</text>
</view> <text class="text">{{ params.num }}</text>
</uni-grid-item> </view>
</uni-grid> </uni-col>
</uni-group> </uni-row>
</view> </view>
</view> </view>
@ -56,7 +54,11 @@
data() { data() {
return { return {
userInfo:{}, userInfo:{},
banner:[], banner:[
{
bannerImg: "/static/material.png"
}
],
current: 0, current: 0,
mode: 'nav', mode: 'nav',
swiperDotIndex: 0, swiperDotIndex: 0,
@ -76,37 +78,37 @@
list: [{ list: [{
typeId: 1, typeId: 1,
text: '头像', text: '头像',
num: '', num: '10',
icon: '/static/headBack.png' icon: '/static/headBack.png'
}, },
{ {
typeId: 2, typeId: 2,
text: 'Gif动图', text: 'Gif动图',
num: '', num: '10',
icon: '/static/gifBack.png' icon: '/static/gifBack.png'
}, },
{ {
typeId: 3, typeId: 3,
text: '手机壁纸', text: '手机壁纸',
num: '', num: '20',
icon: '/static/phoneBack.png' icon: '/static/phoneBack.png'
}, },
{ {
typeId: 4, typeId: 4,
text: '朋友圈', text: '朋友圈',
num: '', num: '10',
icon: '/static/friendBack.png' icon: '/static/friendBack.png'
}, },
{ {
typeId: 5, typeId: 5,
text: '表情包', text: '表情包',
num: '', num: '15',
icon: '/static/emoBack.png' icon: '/static/emoBack.png'
}, },
{ {
typeId: 6, typeId: 6,
text: 'iwatch', text: 'iwatch',
num: '', num: '3',
icon: '/static/iwatchBack.png' icon: '/static/iwatchBack.png'
} }
] ]
@ -121,9 +123,9 @@
showCancel: false, showCancel: false,
success() { success() {
// //
uni.reLaunch({ // uni.reLaunch({
url: '/pages/login/login' // url: '/pages/login/login'
}); // });
} }
}); });
} else { } else {
@ -277,9 +279,10 @@
@media screen and (min-width: 500rpx) { @media screen and (min-width: 500rpx) {
.uni-swiper-dot-box { .uni-swiper-dot-box {
width: 400rpx; width: 100%;
margin: 0 auto; height: 100%;
margin-top: 8rpx; // margin: 0 auto;
// margin-top: 8rpx;
} }
.image { .image {
@ -302,3 +305,79 @@
} }
</style> </style>
<style scoped lang="scss">
.container {
min-height: 100vh;
background: #FFC542;
border-top: 2rpx solid #FFC542;
.top {
width: 638rpx;
// height: 272rpx;
margin: 40rpx auto;
border-radius: 50rpx;
overflow: hidden;
}
.middle {
width: 638rpx;
margin: 0 auto;
.grid-item-box {
height: 360rpx;
background: rgb(62, 213, 152);
border-radius: 25px;
position: relative;
.text {
font-size: 48rpx;
position: absolute;
top: 84rpx;
left: auto;
right: auto;
}
.iconImage {
position: absolute;
bottom: 0;
left: auto;
right: auto;
width: 158rpx;
height: 186rpx;
}
}
}
.foot {
margin-top: 40rpx;
padding: 56rpx;
background: #2A3C44;
border-radius: 80rpx 0px 0px 0px;
.grid-item-box {
margin-bottom: 14rpx;
.icom-div {
background: #30444E;
border-radius: 24rpx;
.listIconImage {
height: 130rpx;
width: 130rpx;
}
}
.text {
text-align: center;
font-size: 24rpx;
line-height: 30rpx;
margin-top: 10rpx;
}
}
}
}
</style>
Loading…
Cancel
Save