首页标题如果只有一个的情况下, 显示深色

This commit is contained in:
zhl 2019-03-26 14:21:55 +08:00
parent 4ae0336e1d
commit 069c96693a
4 changed files with 11 additions and 4 deletions

View File

@ -35,6 +35,7 @@
"less": "^3.8.1",
"wepy-compiler-babel": "^1.5.3",
"wepy-compiler-less": "^1.3.14",
"wepy-plugin-imagemin": "^1.5.3",
"wepy-plugin-uglifyjs": "^1.3.7"
}
}

View File

@ -1,4 +1,4 @@
const env = 'test'; //product, test
const env = 'product'; //product, test
export default {
env: env,
// apiBase: env === 'test'? 'http://192.168.100.226' : 'https://ghost.kingsome.cn',

View File

@ -55,6 +55,9 @@
color: #777777;
position: relative;
}
.one-selected {
color: #777777;
}
.selected::after{
position: absolute;
left: 15px;
@ -70,7 +73,7 @@
<view class="comp-title">
<i class="icon-bookmark"></i>
<repeat for="{{titleList}}" item="titleStr" index="index">
<text class="{{idx === index ? 'selected': ''}}" @tap="selectTitle({{index}})">{{titleStr}}</text>
<text class="{{(titleList.length > 1 && idx === index) ? 'selected': ''}} {{titleList.length === 1 ? 'one-selected': ''}}" @tap="selectTitle({{index}})">{{titleStr}}</text>
<text class="title-divider {{titleStr? '' : 'hidden'}} {{index === titleList.length - 1 ? 'hidden' : ''}}"></text>
</repeat>
</view>

View File

@ -27,9 +27,12 @@
{{vip_btn_title}}</navigator>
</view>
</view>
<view class="zan-btn zan-btn--small zan-btn--primary button-hover {{showAll? '' : 'hidden'}}" @tap="showInviteView">获取游戏</view>
<view class="zan-btn zan-btn--small zan-btn--primary button-hover {{showAll? '' : 'hidden'}}" @tap="showInviteView">免费获取游戏</view>
<view class="userinfo-score {{showAll? '' : 'hidden'}}">金币: {{score}}</view>
</view>
<view class="">
</view>
</view>
<myGame class="{{(showAll && showMyGame)? '' : 'hidden'}}" :idx.sync="recentCurrent" :titleList.sync="myGameTitles"
:gameList.sync="myGameRecords" @recommendTap.user="recommendTap"
@ -116,7 +119,7 @@
},
myGameTitles: [],
recommendTitles: [],
recentCurrent: -1,
recentCurrent: 0,
};
methods = {