An open API service indexing awesome lists of open source software.

https://github.com/dora4/dview-bottombar


https://github.com/dora4/dview-bottombar

Last synced: 8 months ago
JSON representation

Awesome Lists containing this project

README

          

dview-bottombar
![Release](https://jitpack.io/v/dora4/dview-bottombar.svg)
--------------------------------

#### 卡片
![DORA视图 界面传送门](https://github.com/user-attachments/assets/4474df90-817e-48a5-9dfb-0efca43f68b8)

#### Gradle依赖配置

```groovy
// 添加以下代码到项目根目录下的build.gradle
allprojects {
repositories {
maven { url "https://jitpack.io" }
}
}
// 添加以下代码到app模块的build.gradle
dependencies {
implementation 'com.github.dora4:dview-bottombar:1.0'
}
```

#### 使用方式
```xml


@raw/tab_one_normal
@raw/tab_two_normal
@raw/tab_three_normal
@raw/tab_four_normal


@raw/tab_one_selected
@raw/tab_two_selected
@raw/tab_three_selected
@raw/tab_four_selected


Tab1
Tab2
Tab3
Tab4

```

```xml

```

```kotlin
bottomBar.setOnTabSelectedListener(object : DoraBottomBar.OnTabSelectedListener {
override fun onTabSelected(index: Int) {
when (index) {
0 -> showTabOne()
1 -> showTabTwo()
2 -> showTabThree()
3 -> showTabFour()
}
}
})
```