当前位置:网站首页>Tabbar settings
Tabbar settings
2022-07-03 06:03:00 【LAN Yan】
ask :tabbar What does it do ?
answer : Bottom navigation
ask : What are the components of
answer :
"pagePath": "pages/index/index" Page path
- "text": " home page " Page name
"iconPath":"/images/tabbar/home.png" When not selected , Pictures on display
"selectedIconPath":"/images/tabbar/home-active.png" Picture when selected
Pictured

1. The first problem is tabbar Set up
Document links 1 uni-app Official website
https://uniapp.dcloud.net.cn/collocation/pages.html#tabbar
Document links 2
uni.setTabBarItem(OBJECT) | uni-app Official website
https://uniapp.dcloud.io/api/ui/tabbar.html
2. Put what you need tabbar Put the picture of '“static” In the folder
3. Follow the example prompted by the document , Add our own tabbar( Because I have written Baidu applet here tabbar, After a look, the code is almost the same , So copy it directly )
chart 1

Code ( Among them xxx Replace with your own page folder name and page name )
"tabBar": {
"list": [{
"pagePath": "pages/index/index",
"text": " home page ",
"iconPath": "static/images/tabbar/home.png",
"selectedIconPath": "static/images/tabbar/home-active.png"
},
{
"pagePath": "pages/xxx/xxx",
"text": "xxx",
"iconPath": "static/images/tabbar/counrty.png",
"selectedIconPath": "static/images/tabbar/country-active.png"
},
{
"pagePath": "pages/xxx/xxx",
"text": "xxx",
"iconPath": "static/images/tabbar/news.png",
"selectedIconPath": "static/images/tabbar/news-active.png"
},
{
"pagePath": "pages/xxx/xxx",
"text": "xxx",
"iconPath": "static/images/tabbar/ask.png",
"selectedIconPath": "static//images/tabbar/ask-active.png"
},
{
"pagePath": "pages/xxx/xxx",
"text": "xxx",
"iconPath": "static/images/tabbar/me.png",
"selectedIconPath": "static//images/tabbar/me-active.png"
}
],
"backgroundColor": "#ffffff",
"borderStyle": "white",
"color": "#000",
"selectedColor": "#6495ED"
},After doing this , Your project has a bottom navigation
Here's something else ,

- pages Configure the page path , A set of curly braces represents the configuration of a page
- path Is the path of the page in the project
- navigationBarTitleText It's the title of the page
边栏推荐
- [untitled]
- [advanced pointer (2)] | [function pointer, function pointer array, callback function] key analysis + code explanation
- Multithreading and high concurrency (7) -- from reentrantlock to AQS source code (20000 words, one understanding AQS)
- Detailed explanation of iptables (1): iptables concept
- Loss function in pytorch multi classification
- Download the corresponding version of chromedriver
- If function of MySQL
- PMP笔记记录
- Troubleshooting of 32GB Jetson Orin SOM failure to brush
- Solve the problem that Anaconda environment cannot be accessed in PowerShell
猜你喜欢

SVN分支管理
![[teacher Zhao Yuqiang] redis's slow query log](/img/a7/2140744ebad9f1dc0a609254cc618e.jpg)
[teacher Zhao Yuqiang] redis's slow query log

Personal outlook | looking forward to the future from Xiaobai's self analysis and future planning

Clickhouse learning notes (2): execution plan, table creation optimization, syntax optimization rules, query optimization, data consistency
![[trivia of two-dimensional array application] | [simple version] [detailed steps + code]](/img/84/98c1220d0f7bc3a948125ead6ff3d9.jpg)
[trivia of two-dimensional array application] | [simple version] [detailed steps + code]

Today, many CTOs were killed because they didn't achieve business

项目总结--01(接口的增删改查;多线程的使用)

Capacity expansion mechanism of map
![[escape character] [full of dry goods] super detailed explanation + code illustration!](/img/33/ec5a5e11bfd43f53f2767a9a0f0cc9.jpg)
[escape character] [full of dry goods] super detailed explanation + code illustration!

伯努利分布,二项分布和泊松分布以及最大似然之间的关系(未完成)
随机推荐
Life is a process of continuous learning
Detailed explanation of findloadedclass
[branch and cycle] | | super long detailed explanation + code analysis + a trick game
Redhat7 system root user password cracking
Capacity expansion mechanism of map
BeanDefinitionRegistryPostProcessor
Virtual memory technology sharing
How does win7 solve the problem that telnet is not an internal or external command
Clickhouse learning notes (2): execution plan, table creation optimization, syntax optimization rules, query optimization, data consistency
Today, many CTOs were killed because they didn't achieve business
@Import annotation: four ways to import configuration classes & source code analysis
GPS坐标转百度地图坐标的方法
If function of MySQL
PHP用ENV获取文件参数的时候拿到的是字符串
Intel's new GPU patent shows that its graphics card products will use MCM Packaging Technology
[together Shangshui Shuo series] day 7 content +day8
Kubernetes notes (III) controller
tabbar的设置
Exception when introducing redistemplate: noclassdeffounderror: com/fasterxml/jackson/core/jsonprocessingexception
CKA certification notes - CKA certification experience post
https://uniapp.dcloud.net.cn/collocation/pages.html#tabbar