当前位置:网站首页>小程序vant tab组件解决文字过多显示不全的问题
小程序vant tab组件解决文字过多显示不全的问题
2022-07-04 22:30:00 【宋小羽】
使用小程序时,某些分类名称可能会过长,导致tab组件显示就会出现下图显示不全的问题。
方法步骤
1. 增加tab-class
标签样式类
<!--增加tab-class定义-->
<van-tabs tab-class="tab-class" sticky class="nav" active="{
{ active }}" bind:change="onCateChange">
<van-tab wx:for="{
{cate_list}}" wx:key="index" title="{
{item.name}}"></van-tab>
</van-tabs>
2. 增加样式设置
.tab-class {
flex: none !important;
}
参考文档
边栏推荐
- 啃下大骨头——排序(二)
- 集群的概述与定义,一看就会
- Hit the core in the advanced area of misc in the attack and defense world
- 【烹饪记录】--- 青椒炒千张
- 剑指 Offer 67. 把字符串转换成整数
- 攻防世界 MISC 進階區 Erik-Baleog-and-Olaf
- About stack area, heap area, global area, text constant area and program code area
- 关于栈区、堆区、全局区、文字常量区、程序代码区
- Unity vscode emmylua configuration error resolution
- 安装人大金仓数据库
猜你喜欢
质量体系建设之路的分分合合
It is said that software testing is very simple, but why are there so many dissuasions?
Redis入门完整教程:GEO
串口数据帧
MySQL Architecture - logical architecture
[the 2023 autumn recruitment of MIHA tour] open [the only exclusive internal push code of school recruitment eytuc]
Redis入门完整教程:列表讲解
Redis入门完整教程:键管理
Google Earth engine (GEE) - globfire daily fire data set based on mcd64a1
Attack and defense world misc advanced area Hong
随机推荐
攻防世界 MISC 高手进阶区 001 normal_png
MySQL Architecture - logical architecture
LOGO特训营 第四节 字体设计的重要性
Redis入门完整教程:哈希说明
Redis入门完整教程:Redis Shell
Analysis of the self increasing and self decreasing of C language function parameters
蓝队攻防演练中的三段作战
The new version judges the code of PC and mobile terminal, the mobile terminal jumps to the mobile terminal, and the PC jumps to the latest valid code of PC terminal
Persistence mechanism of redis
剑指 Offer 67. 把字符串转换成整数
leetcode 72. Edit distance edit distance (medium)
[the 2023 autumn recruitment of MIHA tour] open [the only exclusive internal push code of school recruitment eytuc]
[Lua] Int64 support
【烹饪记录】--- 青椒炒千张
都说软件测试很简单有手就行,但为何仍有这么多劝退的?
Attack and defense world misc advanced grace-50
Gnawing down the big bone - sorting (II)
POM in idea XML dependency cannot be imported
华泰证券是国家认可的券商吗?开户安不安全?
Li Kou 98: verify binary search tree