Product Promotion
0x5a.live
for different kinds of informations and explorations.
GitHub - adrielcafe/krumbsview: 🍞 The ultimate breadcrumbs view for Android!
🍞 The ultimate breadcrumbs view for Android! Contribute to adrielcafe/krumbsview development by creating an account on GitHub.
Visit SiteGitHub - adrielcafe/krumbsview: 🍞 The ultimate breadcrumbs view for Android!
🍞 The ultimate breadcrumbs view for Android! Contribute to adrielcafe/krumbsview development by creating an account on GitHub.
Powered by 0x5a.live 💗
KrumbsView
The ultimate breadcrumbs view for Android!
Inspired by JotterPad's breadcrumbs.
Features:
- Custom typeface (from /assets and /res/font folders, also works with Downloadable Fonts)
- Customisable (text colors, text size, separator icon)
- Cool animations
- Swipe right to go back to the previous item
- Survive Activity recreations
- Extensible (open classes and protected members, extend it to get the job done!)
How to use
Import to your project
First, add it in your root build.gradle at the end of repositories:
allprojects {
repositories {
...
maven { url 'https://jitpack.io' }
}
}
Next, add the dependency to your app modules:
dependencies {
...
implementation 'com.github.adrielcafe:krumbsview:$latestVersion'
}
Current version:
XML
<cafe.adriel.krumbsview.KrumbsView
...
app:krumbsStartItem="[string]"
app:krumbsPaddingStartItem="[dimension]"
app:krumbsPreviousItemCharacters="[integer]"
app:krumbsTypeface="[string|font]"
app:krumbsTextSize="[dimension]"
app:krumbsBoldText="[true|false]"
app:krumbsCurrentItemTextColor="[color]"
app:krumbsPreviousItemTextColor="[color]"
app:krumbsSeparatorTintColor="[color]"
app:krumbsSeparatorIcon="[drawable]"
app:krumbsAnimationType="[slideLeftRight|fadeInOut|growShrink]"
app:krumbsAnimationDuration="[shortDuration|longDuration]"/>
Example:
<cafe.adriel.krumbsview.KrumbsView
android:id="@+id/krumbsView"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@color/colorPrimary"
app:krumbsStartItem="Home"
app:krumbsTypeface="@font/quicksand"
app:krumbsTextSize="24sp"
app:krumbsCurrentItemTextColor="@color/colorAccent"
app:krumbsPreviousItemTextColor="@color/colorPrimaryDark"
app:krumbsSeparatorTintColor="@color/colorPrimaryDark"
app:krumbsSeparatorIcon="@drawable/ic_play_arrow"
app:krumbsAnimationType="growShrink"
app:krumbsAnimationDuration="longDuration"/>
Kotlin/Java
with(krumbsView){
size
getItems()
getCurrentItem()
addItem(Krumb("Lorem Ipsum"))
removeLastItem()
removeAllItems()
goToFirstItem()
setOnPreviousItemClickListener { /* ... */ } // Swipe right also triggers this listener
// All XML options are available
setTypeface("fonts/quicksand.ttf") // From /assets folder
setTypeface(R.font.quicksand) // From /res/font folder
setTypeface(MyCustomTypeface)
setTextSizeSp(20f)
setTextSizePx(40f)
setBoldText(true)
setPaddingStartItem(10f)
setPreviousItemCharacters(2)
setCurrentItemTextColor(Color.WHITE)
setPreviousItemTextColor(color(R.color.transparent_white))
setSeparatorTintColor(color(R.color.transparent_white))
setSeparatorIcon(R.drawable.ic_keyboard_arrow_right)
setAnimationType(KrumbsAnimationType.GROW_SHRINK)
setAnimationDuration(KrumbsAnimationDuration.SHORT)
}
You can also use your custom Krumb implementation:
data class MyKrumb(val id: Int,
val folderName: String,
val createdAt: Date) : Krumb(folderName)
with(krumbsView){
addItem(MyKrumb(123, "Folder XYZ", now))
val myKrumb = getCurrentItem() as MyKrumb
}
Kotlin Resources
are all listed below.
GitHub - BenWoodworth/knbt: Kotlin NBT library for kotlinx.serialization
resource
~/github.com
resource
GitHub - brianmadden/krawler: A web crawling framework written in Kotlin
resource
~/github.com
resource
GitHub - OxygenCobalt/Auxio: A simple, rational music player for android
resource
~/github.com
resource
GitHub - eriksencosta/math-percentage: Percentage calculations made easy
resource
~/github.com
resource
GitHub - ctripcorp/mmkv-kotlin: A Kotlin Multiplatform porting for MMKV.
resource
~/github.com
resource
GitHub - Litote/kmongo: [deprecated] KMongo - a Kotlin toolkit for Mongo
resource
~/github.com
resource
Test-Driven Development Tutorial for Android: Getting Started
resource
~/www.raywenderlich.com
resource
GitHub - jacinpoz/rxaerospike: RxJava2 wrapper for aerospike-client-java
resource
~/github.com
resource
GitHub - pedrovgs/KotlinSnapshot: Snapshot Testing framework for Kotlin.
resource
~/github.com
resource
GitHub - hankdavidson/ktime: kotlin extensions to the java8 time library
resource
~/github.com
resource
GitHub - ziggy42/Blum: A simple android Twitter client written in Kotlin
resource
~/github.com
resource
Made with ❤️
to provide different kinds of informations and resources.