当前位置:网站首页>[style set 1] tab
[style set 1] tab
2022-07-28 01:38:00 【Hey, little apple】

template
<view class="subsection">
<view v-for="(item,index) in list" :key="index" @click="tabsChange(index)">
<view :class="{active: index == current}">
{
{
item.name}}
</view>
</view>
</view>
js
list: [{
name: ' Total sum '
}, {
name: ' gift '
}, {
name: ' Number of votes ',
}],
current:0, // 0 Total sum 1 gift 2 Number of votes
// tab bar Switch
function tabsChange(index){
console.log(index)
state.current = index;
}
style
.subsection{
height: 96rpx;
line-height: 96rpx;
background-color: #fff;
font-size: 32rpx;
font-weight: 400;
color: #777777;
line-height: 44rpx;
disflex:flex;
align-item:center;
justify-content: space-around;
.active{
color: #333;
font-weight: 500;
border-bottom: 4rpx solid #5377B5;
}
}
边栏推荐
- 梳理 SQL 性能优化,收藏经典!
- Redefine analysis - release of eventbridge real-time event analysis platform
- Codeforces暑期训练周报(7.14~7.20)
- 使用Gateway的流式api修改请求路径
- Tool function: pay the non empty field value in one workspace to the same field in another workspace
- 彻底搞懂kubernetes调度框架与插件
- Shenzhen Huaqiang announced that it plans to invest no more than 20million yuan in BYD semiconductor
- ICML2022 | 在线决策Transformer
- Oracle Rac 集群文件目录迁移
- Centralized management of clusters
猜你喜欢

String
![[C language] file operation](/img/6e/b8f3466ca0a5f7424afcab561124af.png)
[C language] file operation

I want to get 20K after 3 years of experience, but I haven't got it for half a month?

Lua get started quickly

docker 本地搭建mysql主从

【样式集合1】tab 栏

Learn how Baidu PaddlePaddle easydl realizes automatic animal recognition in aquarium

Redefine analysis - release of eventbridge real-time event analysis platform

路由策略简介

idea常用的快捷键汇总
随机推荐
Icml2022 | online decision transformer
面试题 01.06. 字符串压缩
路由策略简介
C language main function transfer parameters
Fluent call interface UI
Xinyi information technology, a domestic NB IOT chip manufacturer, received 200million yuan of a+ round financing
Interpretation of new features | the restriction of MySQL 8.0 on gtid is lifted
Summary of common shortcut keys in idea
Realize ABCD letter increment
Tool function: pay the non empty field value in one workspace to the same field in another workspace
梳理 SQL 性能优化,收藏经典!
How to make digital retail undertake the development task of the era of traffic and retention may be the key
我的富二代朋友
[game] Nintendo Nintendo switch ultra detailed purchase / use guide and precautions (continuous update according to your own use...)
Codeforces暑期训练周报(7.21~7.27)
面试题 01.07. 旋转矩阵
Nokia announces cooperation with Broadcom to develop 5g chip
BYD semiconductor completed the a+ round financing of 800million yuan: 30 well-known investment institutions entered the market, with a valuation of 10.2 billion yuan!
At the meeting on June 19, SMIC may set the fastest listing record in China!
Software test interview question: think_ What is the function of time?