This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Composable | |
internal fun SlimeBottomBar( | |
navController: NavController, | |
items: List<BottomNavigationItems>, | |
) { | |
Column { | |
val currentRoute = navController.currentRouteAsState() | |
NavigationBar { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var isOriginalImageLoaded = false | |
// Thumbnail Request | |
val thumbRequest = ImageRequest.Builder(ctx) | |
.data(thumbUrl) | |
.target( | |
onSuccess = { result -> | |
// If highRes image is not loaded yet, | |
// show the thumbnail | |
if (!isOriginalImageLoaded) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
result.data?.let { list -> | |
val totalCount = list.count() | |
// example there are 2 uploadedPosts | |
list.forEach { review -> | |
if (review.status.contains("Live")) { | |
/** if totalCount (posts) are 2 and both of them are live, | |
* minus 1 for each live post, so totalCount would be 0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8"?> | |
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" | |
xmlns:app="http://schemas.android.com/apk/res-auto" | |
xmlns:tools="http://schemas.android.com/tools" | |
android:id="@+id/container" | |
android:layout_width="match_parent" | |
android:layout_height="match_parent" | |
android:orientation="vertical" | |
tools:context=".MainActivity"> |