diff --git a/.idea/deploymentTargetDropDown.xml b/.idea/deploymentTargetDropDown.xml
index b47414d0..c27b699e 100644
--- a/.idea/deploymentTargetDropDown.xml
+++ b/.idea/deploymentTargetDropDown.xml
@@ -10,12 +10,12 @@
-
+
-
+
diff --git a/app/build.gradle b/app/build.gradle
index ea3b048b..8d80a7c3 100644
--- a/app/build.gradle
+++ b/app/build.gradle
@@ -3,18 +3,17 @@ plugins {
id 'kotlin-android'
id 'kotlin-kapt'
id 'dagger.hilt.android.plugin'
- //id 'com.google.gms.google-services'
}
android {
- compileSdk 33
+ compileSdk 34
defaultConfig {
applicationId "com.xquare.xquare_android"
- minSdk 24
- targetSdk 33
- versionCode 36
- versionName "1.6.3"
+ minSdkVersion 24
+ targetSdkVersion 33
+ versionCode 37
+ versionName "1.6.4"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
vectorDrawables {
@@ -50,47 +49,45 @@ android {
}
dependencies {
+
implementation project(":di")
implementation project(":domain")
-// implementation platform('com.google.firebase:firebase-bom:32.0.0')
-// implementation 'com.google.firebase:firebase-analytics-ktx'
+ implementation 'com.google.code.gson:gson:2.10.1'
+ implementation 'com.google.firebase:firebase-messaging:23.2.1'
+
+ implementation 'androidx.core:core-ktx:1.10.0'
+ implementation 'androidx.work:work-runtime-ktx:2.8.1'
- implementation 'com.google.firebase:firebase-messaging:23.1.2'
+ implementation 'androidx.lifecycle:lifecycle-runtime-ktx:2.6.2'
- implementation 'androidx.core:core-ktx:1.7.0'
+ implementation 'androidx.activity:activity-compose:1.7.2'
implementation "androidx.compose.ui:ui:$compose_version"
implementation "androidx.compose.material:material:$compose_version"
+ implementation "androidx.compose.ui:ui-tooling:$compose_version"
implementation "androidx.compose.ui:ui-tooling-preview:$compose_version"
- implementation 'androidx.work:work-runtime-ktx:2.7.1'
+ androidTestImplementation "androidx.compose.ui:ui-test-junit4:$compose_version"
- def nav_version = "2.5.3"
- implementation("androidx.navigation:navigation-compose:$nav_version")
+ implementation("io.coil-kt:coil-gif:2.4.0")
+ implementation("io.coil-kt:coil-compose:2.4.0")
+
+ implementation "androidx.navigation:navigation-compose:2.6.0"
implementation "com.google.dagger:hilt-android:$hilt_version"
- implementation "com.google.dagger:hilt-android-compiler:$hilt_version"
kapt "com.google.dagger:hilt-android-compiler:$hilt_version"
implementation "androidx.hilt:hilt-navigation-compose:1.0.0"
- implementation 'androidx.lifecycle:lifecycle-runtime-ktx:2.4.1'
- implementation 'androidx.activity:activity-compose:1.4.0'
+
testImplementation 'junit:junit:4.13.2'
- androidTestImplementation 'androidx.test.ext:junit:1.1.3'
- androidTestImplementation 'androidx.test.espresso:espresso-core:3.4.0'
- androidTestImplementation "androidx.compose.ui:ui-test-junit4:$compose_version"
- debugImplementation "androidx.compose.ui:ui-tooling:$compose_version"
+ androidTestImplementation 'androidx.test.ext:junit:1.1.5'
+ androidTestImplementation 'androidx.test.espresso:espresso-core:3.5.1'
implementation "com.jakewharton.threetenabp:threetenabp:1.3.1"
- implementation("io.coil-kt:coil-compose:2.0.0-rc01")
-
implementation "com.github.semicolondsm:SemicolonDesign_Android:1.3.0"
implementation "com.google.accompanist:accompanist-pager:0.26.5-rc"
implementation "com.google.accompanist:accompanist-pager-indicators:0.26.5-rc"
-
- implementation 'com.google.code.gson:gson:2.9.1'
implementation "androidx.swiperefreshlayout:swiperefreshlayout:1.1.0"
-
}
apply plugin: 'com.google.gms.google-services'
diff --git a/app/release/app-release.aab b/app/release/app-release.aab
index b1cea68c..638323f2 100644
Binary files a/app/release/app-release.aab and b/app/release/app-release.aab differ
diff --git a/app/src/main/java/com/xquare/xquare_android/MainActivity.kt b/app/src/main/java/com/xquare/xquare_android/MainActivity.kt
index 6d9c6315..3f226aa8 100644
--- a/app/src/main/java/com/xquare/xquare_android/MainActivity.kt
+++ b/app/src/main/java/com/xquare/xquare_android/MainActivity.kt
@@ -41,7 +41,7 @@ import com.xquare.xquare_android.feature.imagedetail.ImageDetailScreen
import com.xquare.xquare_android.feature.onboard.OnboardScreen
import com.xquare.xquare_android.feature.pick.PassScreen
import com.xquare.xquare_android.feature.point_history.PointHistoryScreen
-import com.xquare.xquare_android.feature.profile.ProfileScreen
+import com.xquare.xquare_android.feature.profile.MyPageScreen
import com.xquare.xquare_android.feature.release.ReleaseScreen
import com.xquare.xquare_android.feature.schedule.ScheduleScreen
import com.xquare.xquare_android.feature.schedule.WriteScheduleScreen
@@ -59,7 +59,6 @@ import com.xquare.xquare_android.util.getNavigationBarHeightDp
import com.xquare.xquare_android.util.getStatusBarHeightDp
import com.xquare.xquare_android.util.setStatusBarTransparent
import dagger.hilt.android.AndroidEntryPoint
-import java.io.File
import java.net.URLDecoder
import java.nio.charset.StandardCharsets
@@ -170,7 +169,7 @@ fun BaseApp() {
PointHistoryScreen(navController)
}
composable(AppNavigationItem.Profile.route) {
- ProfileScreen(navController)
+ MyPageScreen(navController)
}
composable(AppNavigationItem.Bug.route) {
BugReportScreen(navController)
diff --git a/app/src/main/java/com/xquare/xquare_android/feature/github/GithubDetail.kt b/app/src/main/java/com/xquare/xquare_android/feature/github/GithubDetail.kt
index 6ab9e686..f0363075 100644
--- a/app/src/main/java/com/xquare/xquare_android/feature/github/GithubDetail.kt
+++ b/app/src/main/java/com/xquare/xquare_android/feature/github/GithubDetail.kt
@@ -19,26 +19,22 @@ import androidx.compose.ui.Alignment
import androidx.compose.ui.Modifier
import androidx.compose.ui.draw.clip
import androidx.compose.ui.graphics.Color
-import androidx.compose.ui.graphics.painter.ColorPainter
import androidx.compose.ui.graphics.painter.Painter
import androidx.compose.ui.layout.ContentScale
-import androidx.compose.ui.res.painterResource
import androidx.compose.ui.text.font.FontWeight
import androidx.compose.ui.unit.Dp
import androidx.compose.ui.unit.dp
-import coil.compose.rememberAsyncImagePainter
import com.semicolon.design.Body1
import com.semicolon.design.Body2
import com.semicolon.design.Body3
import com.semicolon.design.Subtitle4
-import com.semicolon.design.color.primary.gray.gray200
import com.semicolon.design.color.primary.gray.gray50
import com.semicolon.design.color.primary.gray.gray700
import com.semicolon.design.color.primary.gray.gray900
import com.semicolon.design.color.primary.purple.purple200
import com.xquare.domain.entity.github.GithubInformationEntity
import com.xquare.domain.entity.github.GithubListEntity
-import com.xquare.xquare_android.R
+import com.xquare.xquare_android.util.rememberAsyncGifImagePainter
import java.text.DecimalFormat
fun formatNumberWithComma(number: Int): String {
@@ -62,11 +58,7 @@ fun GithubRankingItem(
verticalAlignment = Alignment.CenterVertically,
) {
Image(
- painter = rememberAsyncImagePainter(
- model = githubInformation?.profileFilename,
- placeholder = ColorPainter(gray200),
- error = painterResource(id = R.drawable.ic_profile_default)
- ),
+ painter = rememberAsyncGifImagePainter(githubInformation?.profileFilename),
contentScale = ContentScale.Crop,
contentDescription = null,
modifier = Modifier
@@ -75,8 +67,16 @@ fun GithubRankingItem(
)
Spacer(Modifier.size(10.dp))
Column {
- Body2(text = "${githubInformation?.ranking}위 : ${githubInformation?.name}", fontWeight = FontWeight.Medium, color = gray900)
- Body3(text = "@${githubInformation?.username}", fontWeight = FontWeight.Normal, color = gray700)
+ Body2(
+ text = "${githubInformation?.ranking}위 : ${githubInformation?.name}",
+ fontWeight = FontWeight.Medium,
+ color = gray900,
+ )
+ Body3(
+ text = "@${githubInformation?.username}",
+ fontWeight = FontWeight.Normal,
+ color = gray700,
+ )
}
Spacer(Modifier.weight(1f))
Box(
@@ -97,7 +97,7 @@ fun GithubRankingItem(
@Composable
fun GithubItem(
- githubList: GithubListEntity.GithubUserListEntity,
+ githubUser: GithubListEntity.GithubUserListEntity,
modifier: Modifier = Modifier,
crown: Painter,
color: Color,
@@ -105,14 +105,12 @@ fun GithubItem(
tint: Color,
image: Dp
) {
-
Column(
modifier = modifier
.background(gray50, RoundedCornerShape(12.dp))
.border(width = 1.dp, color = color, shape = RoundedCornerShape(12.dp)),
horizontalAlignment = Alignment.CenterHorizontally
) {
-
Column(
Modifier.padding(top = 10.dp, bottom = 10.dp),
horizontalAlignment = Alignment.CenterHorizontally
@@ -125,11 +123,7 @@ fun GithubItem(
tint = tint
)
Image(
- painter = rememberAsyncImagePainter(
- model = githubList.profile_file_name,
- placeholder = ColorPainter(gray200),
- error = painterResource(id = R.drawable.ic_profile_default)
- ),
+ painter = rememberAsyncGifImagePainter(githubUser.profile_file_name),
contentScale = ContentScale.Crop,
contentDescription = null,
modifier = Modifier
@@ -139,19 +133,31 @@ fun GithubItem(
)
}
Spacer(Modifier.height(centerPadding))
- Subtitle4(text = githubList.name, color = gray900, fontWeight = FontWeight.SemiBold)
- Body3(text = " @${githubList.username}", color = gray700, fontWeight = FontWeight.Normal)
- Body3(text = "${formatNumberWithComma(githubList.contributions)} 커밋", color = gray900, fontWeight = FontWeight.Medium)
+ Subtitle4(text = githubUser.name, color = gray900, fontWeight = FontWeight.SemiBold)
+ Body3(
+ text = " @${githubUser.username}",
+ color = gray700,
+ fontWeight = FontWeight.Normal
+ )
+ Body3(
+ text = "${formatNumberWithComma(githubUser.contributions)} 커밋",
+ color = gray900,
+ fontWeight = FontWeight.Medium
+ )
}
}
}
@Composable
fun GithubAllRankingItem(
- githubList: GithubListEntity.GithubUserListEntity,
+ githubUser: GithubListEntity.GithubUserListEntity,
borderState: Boolean,
) {
- val borderColor = if (borderState) purple200 else gray50
+ val borderColor = if (borderState) {
+ purple200
+ } else {
+ gray50
+ }
Row(
modifier = Modifier
.fillMaxWidth()
@@ -162,10 +168,7 @@ fun GithubAllRankingItem(
verticalAlignment = Alignment.CenterVertically,
) {
Image(
- painter = rememberAsyncImagePainter(
- model = githubList.profile_file_name,
- error = painterResource(id = R.drawable.ic_profile_default)
- ),
+ painter = rememberAsyncGifImagePainter(githubUser.profile_file_name),
contentScale = ContentScale.Crop,
contentDescription = null,
modifier = Modifier
@@ -174,8 +177,12 @@ fun GithubAllRankingItem(
)
Spacer(Modifier.size(10.dp))
Column {
- Body2(text = "${githubList.ranking}위 : ${githubList.name}", fontWeight = FontWeight.Medium, color = gray900)
- Body3(text = "@${githubList.username}", fontWeight = FontWeight.Normal, color = gray700)
+ Body2(
+ text = "${githubUser.ranking}위 : ${githubUser.name}",
+ fontWeight = FontWeight.Medium,
+ color = gray900
+ )
+ Body3(text = "@${githubUser.username}", fontWeight = FontWeight.Normal, color = gray700)
}
Spacer(Modifier.weight(1f))
Box(
@@ -185,7 +192,7 @@ fun GithubAllRankingItem(
.padding(bottom = 5.dp)
) {
Body1(
- text = "${formatNumberWithComma(githubList.contributions)} 커밋",
+ text = "${formatNumberWithComma(githubUser.contributions)} 커밋",
fontWeight = FontWeight.Medium,
color = gray900,
modifier = Modifier
diff --git a/app/src/main/java/com/xquare/xquare_android/feature/github/GithubScreen.kt b/app/src/main/java/com/xquare/xquare_android/feature/github/GithubScreen.kt
index 1e4b6e10..12cd34a5 100644
--- a/app/src/main/java/com/xquare/xquare_android/feature/github/GithubScreen.kt
+++ b/app/src/main/java/com/xquare/xquare_android/feature/github/GithubScreen.kt
@@ -113,7 +113,7 @@ fun Github(
) {
GithubItem(
modifier = Modifier.weight(1f),
- githubList = githubList.users[1],
+ githubUser = githubList.users[1],
crown = painterResource(id = R.drawable.ic_github_crown),
color = Silver,
centerPadding = 10.dp,
@@ -122,7 +122,7 @@ fun Github(
)
GithubItem(
modifier = Modifier.weight(1f),
- githubList = githubList.users[0],
+ githubUser = githubList.users[0],
crown = painterResource(id = R.drawable.ic_github_crown),
color = Gold,
centerPadding = 25.dp,
@@ -131,7 +131,7 @@ fun Github(
)
GithubItem(
modifier = Modifier.weight(1f),
- githubList = githubList.users[2],
+ githubUser = githubList.users[2],
crown = painterResource(id = R.drawable.ic_github_crown),
color = Bronze,
centerPadding = 8.dp,
@@ -158,7 +158,7 @@ fun Github(
) {
items(githubList.users.count()) {
GithubAllRankingItem(
- githubList = githubList.users[it],
+ githubUser = githubList.users[it],
borderState = false
)
}
diff --git a/app/src/main/java/com/xquare/xquare_android/feature/home/HomeScreen.kt b/app/src/main/java/com/xquare/xquare_android/feature/home/HomeScreen.kt
index 14b1e0c8..8c552db5 100644
--- a/app/src/main/java/com/xquare/xquare_android/feature/home/HomeScreen.kt
+++ b/app/src/main/java/com/xquare/xquare_android/feature/home/HomeScreen.kt
@@ -1,10 +1,28 @@
package com.xquare.xquare_android.feature.home
import android.view.WindowManager
-import androidx.compose.foundation.*
+import androidx.compose.foundation.Image
+import androidx.compose.foundation.background
+import androidx.compose.foundation.border
+import androidx.compose.foundation.clickable
+import androidx.compose.foundation.horizontalScroll
import androidx.compose.foundation.interaction.MutableInteractionSource
-import androidx.compose.foundation.layout.*
+import androidx.compose.foundation.layout.Arrangement
+import androidx.compose.foundation.layout.Box
+import androidx.compose.foundation.layout.Column
+import androidx.compose.foundation.layout.Row
+import androidx.compose.foundation.layout.Spacer
+import androidx.compose.foundation.layout.fillMaxSize
+import androidx.compose.foundation.layout.fillMaxWidth
+import androidx.compose.foundation.layout.height
+import androidx.compose.foundation.layout.padding
+import androidx.compose.foundation.layout.size
+import androidx.compose.foundation.layout.width
+import androidx.compose.foundation.layout.wrapContentWidth
+import androidx.compose.foundation.rememberScrollState
+import androidx.compose.foundation.shape.CircleShape
import androidx.compose.foundation.shape.RoundedCornerShape
+import androidx.compose.foundation.verticalScroll
import androidx.compose.material.Icon
import androidx.compose.material.Text
import androidx.compose.material.icons.Icons
@@ -27,25 +45,30 @@ import androidx.compose.ui.unit.dp
import androidx.compose.ui.unit.sp
import androidx.hilt.navigation.compose.hiltViewModel
import androidx.navigation.NavController
-import coil.compose.AsyncImage
import com.semicolon.design.Body1
import com.semicolon.design.Body2
import com.semicolon.design.Body3
import com.semicolon.design.Subtitle4
import com.semicolon.design.color.primary.black.black
-import com.semicolon.design.color.primary.gray.*
+import com.semicolon.design.color.primary.gray.gray400
+import com.semicolon.design.color.primary.gray.gray50
+import com.semicolon.design.color.primary.gray.gray500
+import com.semicolon.design.color.primary.gray.gray700
+import com.semicolon.design.color.primary.gray.gray800
+import com.semicolon.design.color.primary.gray.gray900
import com.semicolon.design.color.primary.purple.purple200
import com.semicolon.design.color.primary.purple.purple400
import com.semicolon.design.color.primary.white.white
import com.semicolon.design.notoSansFamily
+import com.xquare.domain.entity.meal.MealEntity
import com.xquare.domain.entity.pick.ClassPositionEntity
import com.xquare.domain.entity.pick.PassTimeEntity
-import com.xquare.domain.entity.meal.MealEntity
import com.xquare.domain.entity.user.HomeUserEntity
import com.xquare.xquare_android.MainActivity
import com.xquare.xquare_android.R
import com.xquare.xquare_android.navigation.AppNavigationItem
import com.xquare.xquare_android.util.DevicePaddings
+import com.xquare.xquare_android.util.rememberAsyncGifImagePainter
import org.threeten.bp.LocalDateTime
@Composable
@@ -179,16 +202,15 @@ fun HomeUserCard(userData: HomeUserEntity, onClick: () -> Unit) {
indication = null,
enabled = true
) { onClick() }
-
) {
- AsyncImage(
- model = userData.profileFileImage,
- error = painterResource(id = R.drawable.ic_profile_default),
+
+ Image(
+ painter = rememberAsyncGifImagePainter(data = userData.profileFileImage),
contentDescription = "profileImage",
contentScale = ContentScale.Crop,
modifier = Modifier
.size(44.dp)
- .clip(RoundedCornerShape(22.dp))
+ .clip(CircleShape),
)
Spacer(Modifier.size(12.dp))
Column {
@@ -197,11 +219,11 @@ fun HomeUserCard(userData: HomeUserEntity, onClick: () -> Unit) {
fontSize = 16.sp,
fontFamily = notoSansFamily,
fontWeight = FontWeight.Bold,
- color = gray900
+ color = gray900,
)
Body2(
text = "상점 ${userData.goodPoint}점 벌점 ${userData.badPoint}점",
- color = gray700
+ color = gray700,
)
}
}
@@ -268,7 +290,7 @@ fun HomeMealCard(
.size(12.dp)
.padding(horizontal = 12.dp)
)
- CompositionLocalProvider{
+ CompositionLocalProvider {
Row(
Modifier
.horizontalScroll(scrollState)
@@ -310,11 +332,10 @@ fun HomeMealCard(
}
-
@Composable
fun HomeMealItem(
title: String, menus: List, calorie: String,
- borderColor:Color,
+ borderColor: Color,
) {
val scrollState = rememberScrollState()
var borderColor = borderColor
@@ -418,6 +439,7 @@ fun HomePickContent(
}
}
}
+
@Composable
fun HomePickCard(
state: HomePickCardButtonState,
diff --git a/app/src/main/java/com/xquare/xquare_android/feature/profile/ProfileScreen.kt b/app/src/main/java/com/xquare/xquare_android/feature/profile/MyPageScreen.kt
similarity index 95%
rename from app/src/main/java/com/xquare/xquare_android/feature/profile/ProfileScreen.kt
rename to app/src/main/java/com/xquare/xquare_android/feature/profile/MyPageScreen.kt
index 3fcf76d5..645f252c 100644
--- a/app/src/main/java/com/xquare/xquare_android/feature/profile/ProfileScreen.kt
+++ b/app/src/main/java/com/xquare/xquare_android/feature/profile/MyPageScreen.kt
@@ -37,11 +37,9 @@ import androidx.compose.ui.text.font.FontWeight
import androidx.compose.ui.unit.dp
import androidx.hilt.navigation.compose.hiltViewModel
import androidx.navigation.NavController
-import coil.compose.AsyncImage
import com.semicolon.design.Body1
import com.semicolon.design.Body2
import com.semicolon.design.Body3
-import com.semicolon.design.color.primary.gray.gray200
import com.semicolon.design.color.primary.gray.gray50
import com.semicolon.design.color.primary.gray.gray700
import com.semicolon.design.color.primary.gray.gray900
@@ -56,12 +54,13 @@ import com.xquare.xquare_android.component.modal.ConfirmModal
import com.xquare.xquare_android.navigation.AppNavigationItem
import com.xquare.xquare_android.util.DevicePaddings
import com.xquare.xquare_android.util.makeToast
+import com.xquare.xquare_android.util.rememberAsyncGifImagePainter
import com.xquare.xquare_android.util.toFile
import org.threeten.bp.format.DateTimeFormatter
import java.io.File
@Composable
-fun ProfileScreen(navController: NavController) {
+fun MyPageScreen(navController: NavController) {
val context = LocalContext.current
val viewModel: ProfileViewModel = hiltViewModel()
var profile: ProfileEntity? by remember { mutableStateOf(null) }
@@ -190,18 +189,14 @@ private fun Profile(
val profileImageModifier = Modifier
.size(60.dp)
.clip(RoundedCornerShape(30.dp))
- .clickable(
- interactionSource = MutableInteractionSource(),
- indication = null,
- ) {
+ .clickable {
galleryState = true
}
Box {
- AsyncImage(
+ Image(
modifier = profileImageModifier,
- model = profile?.profileFileName,
- error = painterResource(id = R.drawable.ic_profile_default),
+ painter = rememberAsyncGifImagePainter(profile?.profileFileName),
contentScale = ContentScale.Crop,
contentDescription = null
)
@@ -353,11 +348,11 @@ private fun ButtonColumnMenu(
onClick: () -> Unit,
isConnected: Boolean?,
) {
- val textColor = when (isConnected){
+ val textColor = when (isConnected) {
true -> purple200
else -> white
}
- val buttonColor = when(isConnected) {
+ val buttonColor = when (isConnected) {
true -> purple50
else -> purple300
}
@@ -377,7 +372,7 @@ private fun ButtonColumnMenu(
Body1(
text = text,
color = gray900,
- modifier = Modifier.padding(start = 4.dp)
+ modifier = Modifier.padding(start = 8.dp)
)
Row(
modifier = Modifier
diff --git a/app/src/main/java/com/xquare/xquare_android/feature/setting/SettingScreen.kt b/app/src/main/java/com/xquare/xquare_android/feature/setting/SettingScreen.kt
index 58715b45..694c0e3a 100644
--- a/app/src/main/java/com/xquare/xquare_android/feature/setting/SettingScreen.kt
+++ b/app/src/main/java/com/xquare/xquare_android/feature/setting/SettingScreen.kt
@@ -73,6 +73,8 @@ fun SettingScreen(
}
}
}
+
+ SettingViewModel.Event.Success -> {}
}
}
}
diff --git a/app/src/main/java/com/xquare/xquare_android/util/ImageUtils.kt b/app/src/main/java/com/xquare/xquare_android/util/ImageUtils.kt
new file mode 100644
index 00000000..44a671b0
--- /dev/null
+++ b/app/src/main/java/com/xquare/xquare_android/util/ImageUtils.kt
@@ -0,0 +1,45 @@
+package com.xquare.xquare_android.util
+
+import android.os.Build
+import androidx.compose.runtime.Composable
+import androidx.compose.ui.graphics.painter.Painter
+import androidx.compose.ui.platform.LocalContext
+import androidx.compose.ui.res.painterResource
+import coil.ImageLoader
+import coil.compose.AsyncImagePainter
+import coil.compose.rememberAsyncImagePainter
+import coil.decode.GifDecoder
+import coil.decode.ImageDecoderDecoder
+import coil.request.ImageRequest
+import coil.size.Size
+import com.xquare.xquare_android.R
+
+@Composable
+fun rememberAsyncGifImagePainter(
+ data: Any?,
+ errorPainter: Painter = painterResource(id = R.drawable.ic_profile_default)
+): AsyncImagePainter {
+ val context = LocalContext.current
+
+ val model = ImageRequest.Builder(context)
+ .data(data)
+ .apply {
+ size(Size.ORIGINAL)
+ }.build()
+
+ val imageLoader = ImageLoader.Builder(context)
+ .components {
+ if (Build.VERSION.SDK_INT >= 28) {
+ add(ImageDecoderDecoder.Factory())
+ } else {
+ add(GifDecoder.Factory())
+ }
+ }
+ .build()
+
+ return rememberAsyncImagePainter(
+ model = model,
+ imageLoader = imageLoader,
+ error = errorPainter,
+ )
+}
diff --git a/build.gradle b/build.gradle
index 5dbff658..b73f1594 100644
--- a/build.gradle
+++ b/build.gradle
@@ -1,22 +1,22 @@
buildscript {
ext {
- compose_version = '1.2.0-rc01'
- kotlin_version = "1.6.21"
- hilt_version = '2.40.1'
+ compose_version = '1.4.3'
+ kotlin_version = "1.8.10"
+ hilt_version = '2.48'
}
dependencies {
classpath 'com.android.tools.build:gradle:7.4.2'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
classpath "com.google.dagger:hilt-android-gradle-plugin:$hilt_version"
- classpath 'com.google.gms:google-services:4.3.15'
+ classpath 'com.google.gms:google-services:4.4.0'
}
}// Top-level build file where you can add configuration options common to all sub-projects/modules.
plugins {
id 'com.android.application' version '7.4.2' apply false
id 'com.android.library' version '7.4.2' apply false
- id 'org.jetbrains.kotlin.android' version '1.6.21' apply false
+ id 'org.jetbrains.kotlin.android' version "1.8.10" apply false
}
-task clean(type: Delete) {
+tasks.register('clean', Delete) {
delete rootProject.buildDir
-}
\ No newline at end of file
+}
diff --git a/data/build.gradle b/data/build.gradle
index 9ee18c44..d37f6be3 100644
--- a/data/build.gradle
+++ b/data/build.gradle
@@ -35,23 +35,19 @@ dependencies {
implementation "javax.inject:javax.inject:1"
- implementation 'com.google.firebase:firebase-messaging:21.1.0'
-
- implementation 'androidx.core:core-ktx:1.7.0'
- implementation 'androidx.appcompat:appcompat:1.4.1'
+ implementation 'androidx.core:core-ktx:1.9.0'
+ implementation 'androidx.appcompat:appcompat:1.6.1'
testImplementation 'junit:junit:4.13.2'
- androidTestImplementation 'androidx.test.ext:junit:1.1.3'
- androidTestImplementation 'androidx.test.espresso:espresso-core:3.4.0'
+ androidTestImplementation 'androidx.test.ext:junit:1.1.5'
+ androidTestImplementation 'androidx.test.espresso:espresso-core:3.5.1'
implementation "com.squareup.retrofit2:retrofit:2.9.0"
implementation "com.squareup.retrofit2:converter-gson:2.9.0"
- implementation "com.squareup.okhttp3:okhttp:4.9.3"
-
- implementation "androidx.room:room-ktx:2.4.3"
- implementation "androidx.room:room-runtime:2.4.3"
- kapt "androidx.room:room-compiler:2.4.3"
+ implementation "com.squareup.okhttp3:okhttp:4.11.0"
- implementation "org.jetbrains.kotlinx:kotlinx-coroutines-core:1.6.0"
+ implementation "androidx.room:room-ktx:2.5.2"
+ implementation "androidx.room:room-runtime:2.5.2"
+ kapt "androidx.room:room-compiler:2.5.2"
implementation "com.jakewharton.threetenabp:threetenabp:1.3.1"
-}
\ No newline at end of file
+}
diff --git a/di/build.gradle b/di/build.gradle
index 20f8ba38..8bf85ed0 100644
--- a/di/build.gradle
+++ b/di/build.gradle
@@ -35,23 +35,23 @@ dependencies {
implementation project(":data")
implementation project(":domain")
- implementation 'androidx.core:core-ktx:1.7.0'
- implementation 'androidx.appcompat:appcompat:1.4.1'
+ implementation 'androidx.core:core-ktx:1.9.0'
+ implementation 'androidx.appcompat:appcompat:1.6.1'
testImplementation 'junit:junit:4.13.2'
- androidTestImplementation 'androidx.test.ext:junit:1.1.3'
- androidTestImplementation 'androidx.test.espresso:espresso-core:3.4.0'
+ androidTestImplementation 'androidx.test.ext:junit:1.1.5'
+ androidTestImplementation 'androidx.test.espresso:espresso-core:3.5.1'
implementation "com.google.dagger:hilt-android:$hilt_version"
kapt "com.google.dagger:hilt-android-compiler:$hilt_version"
implementation "com.squareup.retrofit2:retrofit:2.9.0"
implementation "com.squareup.retrofit2:converter-gson:2.9.0"
- implementation "com.squareup.okhttp3:okhttp:4.9.3"
+ implementation "com.squareup.okhttp3:okhttp:4.11.0"
implementation "com.squareup.okhttp3:logging-interceptor:4.9.3"
- implementation "androidx.room:room-ktx:2.4.3"
- implementation "androidx.room:room-runtime:2.4.3"
- kapt "androidx.room:room-compiler:2.4.3"
+ implementation "androidx.room:room-ktx:2.5.2"
+ implementation "androidx.room:room-runtime:2.5.2"
+ kapt "androidx.room:room-compiler:2.5.2"
- implementation "androidx.preference:preference-ktx:1.2.0"
-}
\ No newline at end of file
+ implementation "androidx.preference:preference-ktx:1.2.1"
+}
diff --git a/domain/build.gradle b/domain/build.gradle
index 485485ab..46b12217 100644
--- a/domain/build.gradle
+++ b/domain/build.gradle
@@ -30,16 +30,14 @@ android {
}
dependencies {
-
implementation "javax.inject:javax.inject:1"
- implementation 'androidx.core:core-ktx:1.7.0'
- implementation 'androidx.appcompat:appcompat:1.4.1'
- testImplementation 'junit:junit:4.13.2'
- androidTestImplementation 'androidx.test.ext:junit:1.1.3'
- androidTestImplementation 'androidx.test.espresso:espresso-core:3.4.0'
+ implementation 'androidx.core:core-ktx:1.9.0'
+ implementation 'androidx.appcompat:appcompat:1.6.1'
- implementation "org.jetbrains.kotlinx:kotlinx-coroutines-core:1.6.0"
+ testImplementation 'junit:junit:4.13.2'
+ androidTestImplementation 'androidx.test.ext:junit:1.1.5'
+ androidTestImplementation 'androidx.test.espresso:espresso-core:3.5.1'
implementation "com.jakewharton.threetenabp:threetenabp:1.3.1"
-}
\ No newline at end of file
+}