diff --git a/app/build.gradle.kts b/app/build.gradle.kts index 9b905993..b3d64af9 100644 --- a/app/build.gradle.kts +++ b/app/build.gradle.kts @@ -49,6 +49,8 @@ android { dependencies { implementation(project(":domain")) implementation(project(":data")) + implementation(project(":design-system")) + implementation(project(":presentation-compose")) implementation(AndroidX.CORE_KTX) implementation(AndroidX.APP_COMPAT) diff --git a/presentation-compose/.gitignore b/presentation-compose/.gitignore new file mode 100644 index 00000000..42afabfd --- /dev/null +++ b/presentation-compose/.gitignore @@ -0,0 +1 @@ +/build \ No newline at end of file diff --git a/presentation-compose/build.gradle.kts b/presentation-compose/build.gradle.kts new file mode 100644 index 00000000..cdb150ca --- /dev/null +++ b/presentation-compose/build.gradle.kts @@ -0,0 +1,101 @@ +plugins { + id("com.android.library") + id("dagger.hilt.android.plugin") + kotlin("android") + kotlin("kapt") + id("androidx.navigation.safeargs.kotlin") + id("com.google.gms.google-services") + id("kotlin-parcelize") +} + +android { + namespace = "com.plub.presentation_compose" + compileSdk = 33 + + defaultConfig { + minSdk = 26 + + testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner" + consumerProguardFiles("consumer-rules.pro") + } + + buildTypes { + release { + isMinifyEnabled = false + proguardFiles( + getDefaultProguardFile("proguard-android-optimize.txt"), + "proguard-rules.pro" + ) + } + } + compileOptions { + sourceCompatibility = JavaVersion.VERSION_1_8 + targetCompatibility = JavaVersion.VERSION_1_8 + } + kotlinOptions { + jvmTarget = "1.8" + } + buildFeatures { + viewBinding = true + } +} + +dependencies { + implementation(project(":domain")) + implementation(project(":design-system")) + + implementation(Kotlin.KOTLIN_STDLIB) + implementation(Kotlin.COROUTINES_ANDROID) + implementation(Kotlin.COROUTINES_CORE) + + implementation(AndroidX.APP_COMPAT) + implementation(AndroidX.CORE_KTX) + implementation(AndroidX.LIFECYCLE_RUNTIME_KTX) + implementation(AndroidX.CONSTRAINT_LAYOUT) + implementation(AndroidX.LIFECYCLE_VIEW_MODEL_KTX) + implementation(AndroidX.ACTIVITY_KTX) + implementation(AndroidX.FRAGMENT_KTX) + implementation(AndroidX.NAVIGATION_FRAGMENT_KTX) + implementation(AndroidX.NAVIGATION_UI_KTX) + implementation(AndroidX.LEGACY_SUPPORT) + implementation(AndroidX.RECYCLER_VIEW) + implementation(AndroidX.PAGING3_RUNTIME) + implementation(AndroidX.PAGING3_COMMON_KTX) + + implementation(Libraries.CALENDAR_VIEW) + implementation(Libraries.COIL) + implementation(Libraries.TIMBER) + implementation(Libraries.LOTTIE) + implementation(Libraries.INDICATOR) + implementation(Libraries.KAKAO) + implementation(Libraries.TED_PERMISSION) + implementation(Libraries.THREE_TEN_ABP) + implementation(Libraries.IMAGE_CROPPER) + implementation(Libraries.POWER_MENU) + + implementation(Google.MATERIAL) + implementation(Google.HILT_ANDROID) + implementation(Google.GOOGLE_PLAY_SERVICE) + implementation(Google.FLEX_BOX) + implementation(Google.FIREBASE_BOM) + implementation(Google.FCM) + implementation(Google.FCM_KTX) + + implementation(Glide.GLIDE) + implementation("com.google.android.material:material:1.9.0") + implementation("androidx.appcompat:appcompat:1.6.1") + implementation("androidx.constraintlayout:constraintlayout:2.1.4") + implementation("androidx.navigation:navigation-fragment-ktx:2.7.3") + implementation("androidx.navigation:navigation-ui-ktx:2.7.3") + annotationProcessor(Glide.GLIDE_COMPILER) + + implementation(Compose.COMPOSE_ACTIVITY) + implementation(Compose.COMPOSE_MATERIAL) + implementation(Compose.COMPOSE_PREVIEW) + implementation(Compose.COMPOSE_UI) + implementation(Compose.COMPOSE_NAV) + implementation(Compose.COMPOSE_ANI_NAV) + implementation(Compose.COMPOSE_UI_TOOL) + + kapt(Google.HILT_ANDROID_COMPILER) +} \ No newline at end of file diff --git a/presentation-compose/consumer-rules.pro b/presentation-compose/consumer-rules.pro new file mode 100644 index 00000000..e69de29b diff --git a/presentation-compose/proguard-rules.pro b/presentation-compose/proguard-rules.pro new file mode 100644 index 00000000..481bb434 --- /dev/null +++ b/presentation-compose/proguard-rules.pro @@ -0,0 +1,21 @@ +# Add project specific ProGuard rules here. +# You can control the set of applied configuration files using the +# proguardFiles setting in build.gradle. +# +# For more details, see +# http://developer.android.com/guide/developing/tools/proguard.html + +# If your project uses WebView with JS, uncomment the following +# and specify the fully qualified class name to the JavaScript interface +# class: +#-keepclassmembers class fqcn.of.javascript.interface.for.webview { +# public *; +#} + +# Uncomment this to preserve the line number information for +# debugging stack traces. +#-keepattributes SourceFile,LineNumberTable + +# If you keep the line number information, uncomment this to +# hide the original source file name. +#-renamesourcefileattribute SourceFile \ No newline at end of file diff --git a/presentation-compose/src/androidTest/java/com/plub/presentation_compose/ExampleInstrumentedTest.kt b/presentation-compose/src/androidTest/java/com/plub/presentation_compose/ExampleInstrumentedTest.kt new file mode 100644 index 00000000..bf229951 --- /dev/null +++ b/presentation-compose/src/androidTest/java/com/plub/presentation_compose/ExampleInstrumentedTest.kt @@ -0,0 +1,24 @@ +package com.plub.presentation_compose + +import androidx.test.platform.app.InstrumentationRegistry +import androidx.test.ext.junit.runners.AndroidJUnit4 + +import org.junit.Test +import org.junit.runner.RunWith + +import org.junit.Assert.* + +/** + * Instrumented test, which will execute on an Android device. + * + * See [testing documentation](http://d.android.com/tools/testing). + */ +@RunWith(AndroidJUnit4::class) +class ExampleInstrumentedTest { + @Test + fun useAppContext() { + // Context of the app under test. + val appContext = InstrumentationRegistry.getInstrumentation().targetContext + assertEquals("com.plub.presentation_compose.test", appContext.packageName) + } +} \ No newline at end of file diff --git a/presentation-compose/src/main/AndroidManifest.xml b/presentation-compose/src/main/AndroidManifest.xml new file mode 100644 index 00000000..745d2758 --- /dev/null +++ b/presentation-compose/src/main/AndroidManifest.xml @@ -0,0 +1,12 @@ + + + + + + + + \ No newline at end of file diff --git a/presentation-compose/src/test/java/com/plub/presentation_compose/ExampleUnitTest.kt b/presentation-compose/src/test/java/com/plub/presentation_compose/ExampleUnitTest.kt new file mode 100644 index 00000000..db727e0c --- /dev/null +++ b/presentation-compose/src/test/java/com/plub/presentation_compose/ExampleUnitTest.kt @@ -0,0 +1,17 @@ +package com.plub.presentation_compose + +import org.junit.Test + +import org.junit.Assert.* + +/** + * Example local unit test, which will execute on the development machine (host). + * + * See [testing documentation](http://d.android.com/tools/testing). + */ +class ExampleUnitTest { + @Test + fun addition_isCorrect() { + assertEquals(4, 2 + 2) + } +} \ No newline at end of file diff --git a/settings.gradle.kts b/settings.gradle.kts index f490af8d..2972e513 100644 --- a/settings.gradle.kts +++ b/settings.gradle.kts @@ -3,3 +3,4 @@ include (":app") include (":domain") include (":data") include(":design-system") +include(":presentation-compose")