A rotating number component inspired by Uacaps written in Jetpack Compose.
![](https://private-user-images.githubusercontent.com/35576161/256996749-ba1fdf2f-6c44-4540-b8e9-0ad647c6d797.gif?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjM3MTA0MTAsIm5iZiI6MTcyMzcxMDExMCwicGF0aCI6Ii8zNTU3NjE2MS8yNTY5OTY3NDktYmExZmRmMmYtNmM0NC00NTQwLWI4ZTktMGFkNjQ3YzZkNzk3LmdpZj9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA4MTUlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwODE1VDA4MjE1MFomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWIxMzBmYTFjYzQ5ZDc2YmU1Y2Q4NTcxNDM5YTEyMjc0NGVkMzZkMTkwZjc4MTljNTNjNmVhYmFkN2VlODZmYTYmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.BG21Ev4ZQitlXaPTu-a1MLRvLYN_pfCkSNQIP1w7tx0)
1- Add it in your settings.gradle - dependencyResolutionManagement
repositories {
...
maven { url 'https://jitpack.io' }
}
2- Add the dependency
dependencies {
implementation 'com.github.esatgozcu:Compose-Rolling-Number:1.0.5'
}
val number = remember { mutableStateOf(100) }
RollingNumberView(vm = RollingNumberVM(number.value.toString(), suffix = "$"))
Text(text = "Animate", Modifier.clickable {
number.value = number.value + 123.34355111
})