diff --git a/.github/workflows/android.yml b/.github/workflows/android.yml index 7826a41c..52bf9f58 100644 --- a/.github/workflows/android.yml +++ b/.github/workflows/android.yml @@ -4,10 +4,6 @@ on: pull_request: push: branches: [master] -concurrency: - group: ${{ github.ref }} - cancel-in-progress: true - jobs: check: runs-on: ubuntu-24.04 @@ -21,4 +17,4 @@ jobs: - name: Setup Android SDK uses: android-actions/setup-android@v4 - name: Build - run: ./gradlew assembleNext + run: ./gradlew assembleDebug diff --git a/.github/workflows/schedule.yml b/.github/workflows/schedule.yml index a42a9c48..eb891b66 100644 --- a/.github/workflows/schedule.yml +++ b/.github/workflows/schedule.yml @@ -6,10 +6,6 @@ on: schedule: - cron: '0 0 * * *' -concurrency: - group: ${{ github.ref }} - cancel-in-progress: true - jobs: check_date: runs-on: ubuntu-24.04 diff --git a/build.gradle b/build.gradle index 80cf474c..59a35139 100644 --- a/build.gradle +++ b/build.gradle @@ -14,6 +14,15 @@ if (keystorePropertiesFile.exists()) { keystoreProperties.load(new FileInputStream(keystorePropertiesFile)) } +configurations.all { + resolutionStrategy.eachDependency { + if (requested.group == "androidx.concurrent" && requested.name == "concurrent-futures") { + useVersion("1.2.0") + because("conflict between compose BOM (1.1.0) and test deps (1.2.0)") + } + } +} + android { compileSdk = 36 defaultConfig { @@ -33,7 +42,6 @@ android { addConstant("INTENT_NEW_EVENT_ACTION", "com.juick.NEW_EVENT_ACTION") buildConfigField "boolean", "HIDE_NSFW", "false" - buildConfigField "boolean", "ENABLE_COMPOSE_UI", "false" buildConfigField "boolean", "ENABLE_UPDATER", "true" testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" @@ -42,7 +50,6 @@ android { } buildFeatures { buildConfig true - viewBinding true compose true } compileOptions { @@ -66,10 +73,6 @@ android { minifyEnabled false signingConfig signingConfigs.release } - next { - initWith debug - buildConfigField "boolean", "ENABLE_COMPOSE_UI", "true" - } store { initWith release buildConfigField "boolean", "ENABLE_UPDATER", "false" @@ -126,12 +129,11 @@ dependencies { implementation libs.navigation.fragment.ktx implementation libs.navigation.ui.ktx implementation libs.savedstate.ktx - implementation libs.swiperefreshlayout implementation libs.lifecycle.viewmodel.compose + implementation libs.lifecycle.runtime.compose + implementation libs.runtime.livedata implementation libs.lifecycle.extensions - implementation libs.material - // Sign in with Google googleImplementation libs.credentials.play.services.auth googleImplementation libs.play.services.auth @@ -148,24 +150,27 @@ dependencies { implementation libs.retrofit implementation libs.converter.kotlinx.serialization - implementation libs.chatkit huaweiImplementation libs.push - implementation libs.fragmentviewbindingdelegate.kt - implementation libs.android.image.cropper // Compose - nextImplementation libs.activity.compose - nextImplementation libs.constraintlayout.compose - nextImplementation platform(libs.compose.bom) - nextImplementation libs.ui - nextImplementation libs.ui.graphics - nextImplementation libs.ui.viewbinding - nextImplementation libs.ui.tooling.preview - nextImplementation libs.material.icons.extended - nextImplementation libs.material3 - nextImplementation libs.ui.tooling + implementation libs.activity.compose + implementation libs.constraintlayout.compose + implementation platform(libs.compose.bom) + implementation libs.ui + implementation libs.ui.graphics + implementation libs.ui.tooling.preview + implementation libs.material.icons.extended + implementation libs.material3 + debugImplementation libs.ui.tooling + + // Navigation Compose + implementation libs.navigation.compose + + // Coil for image loading + implementation libs.coil.compose + implementation libs.coil.network.okhttp // Core library androidTestImplementation libs.test.core.ktx @@ -174,10 +179,11 @@ dependencies { androidTestImplementation libs.truth androidTestImplementation libs.espresso.core - // Espresso intents for intercepting ACTION_VIEW - androidTestImplementation libs.espresso.intents - // Fragment testing helpers (launchFragmentInContainer) - androidTestImplementation libs.fragment.testing + + // Compose UI testing + androidTestImplementation(platform(libs.compose.bom)) + androidTestImplementation libs.compose.ui.test.junit4 + debugImplementation libs.compose.ui.test.manifest // UI Automator androidTestImplementation libs.uiautomator.v18 } diff --git a/gradle.properties b/gradle.properties index 80cc0346..94fc9956 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,5 +1,5 @@ org.gradle.daemon=false -org.gradle.parallel=fasle +org.gradle.parallel=false org.gradle.jvmargs=-Xmx1536M org.gradle.vfs.watch=true android.useAndroidX=true diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index e6539c82..38dfa4e2 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -4,10 +4,10 @@ androidImageCropper = "4.7.0" appcompat = "1.7.1" browser = "1.10.0" chatkit = "5e99a8bf3c" +coil = "3.4.0" constraintlayoutCompose = "1.1.1" credentialsPlayServicesAuth = "1.6.0" -espressoCore = "3.6.1" -espressoIntents = "3.7.0" +espresso = "3.7.0" firebaseBom = "34.14.1" composeBom = "2026.05.01" fragmentTesting = "1.8.9" @@ -18,7 +18,7 @@ kotlinxSerializationJson = "1.11.0" coreKtx = "1.18.0" lifecycleVersion = "2.10.0" lifecycleExtensions = "2.2.0" -material = "1.14.0" +material3 = "1.4.0" navigationFragmentKtx = "2.9.8" okhttp = "5.4.0" oksse = "0.9.0" @@ -41,13 +41,15 @@ android-image-cropper = { module = "com.vanniktech:android-image-cropper", versi browser = { module = "androidx.browser:browser", version.ref = "browser" } appcompat = { module = "androidx.appcompat:appcompat", version.ref = "appcompat" } chatkit = { module = "com.github.vitalyster:ChatKit", version.ref = "chatkit" } +coil-compose = { module = "io.coil-kt.coil3:coil-compose", version.ref = "coil" } +coil-network-okhttp = { module = "io.coil-kt.coil3:coil-network-okhttp", version.ref = "coil" } compose-bom = { module = "androidx.compose:compose-bom", version.ref = "composeBom" } constraintlayout-compose = { module = "androidx.constraintlayout:constraintlayout-compose", version.ref = "constraintlayoutCompose" } converter-kotlinx-serialization = { module = "com.squareup.retrofit2:converter-kotlinx-serialization", version.ref = "retrofit" } core-ktx = { module = "androidx.core:core-ktx", version.ref = "coreKtx" } credentials-play-services-auth = { module = "androidx.credentials:credentials-play-services-auth", version.ref = "credentialsPlayServicesAuth" } -espresso-core = { module = "androidx.test.espresso:espresso-core", version.ref = "espressoCore" } -espresso-intents = { module = "androidx.test.espresso:espresso-intents", version.ref = "espressoIntents" } +espresso-core = { module = "androidx.test.espresso:espresso-core", version.ref = "espresso" } +espresso-intents = { module = "androidx.test.espresso:espresso-intents", version.ref = "espresso" } firebase-messaging = { module = "com.google.firebase:firebase-messaging" } firebase-bom = { module = "com.google.firebase:firebase-bom", version.ref = "firebaseBom" } fragment-testing = { module = "androidx.fragment:fragment-testing", version.ref = "fragmentTesting" } @@ -56,11 +58,15 @@ googleid = { module = "com.google.android.libraries.identity.googleid:googleid", junit = { module = "androidx.test.ext:junit", version.ref = "junit" } kotlinx-serialization-json = { module = "org.jetbrains.kotlinx:kotlinx-serialization-json", version.ref = "kotlinxSerializationJson" } lifecycle-viewmodel-compose = { module = "androidx.lifecycle:lifecycle-viewmodel-compose", version.ref = "lifecycleVersion" } +lifecycle-runtime-compose = { module = "androidx.lifecycle:lifecycle-runtime-compose", version.ref = "lifecycleVersion" } +runtime-livedata = { module = "androidx.compose.runtime:runtime-livedata" } +compose-ui-test-junit4 = { module = "androidx.compose.ui:ui-test-junit4" } +compose-ui-test-manifest = { module = "androidx.compose.ui:ui-test-manifest" } lifecycle-extensions = { module = "androidx.lifecycle:lifecycle-extensions", version.ref = "lifecycleExtensions" } logging-interceptor = { module = "com.squareup.okhttp3:logging-interceptor", version.ref = "okhttp" } -material = { module = "com.google.android.material:material", version.ref = "material" } -material3 = { module = "androidx.compose.material3:material3" } +material3 = { module = "androidx.compose.material3:material3", version.ref = "material3" } material-icons-extended = { module = "androidx.compose.material:material-icons-extended" } +navigation-compose = { module = "androidx.navigation:navigation-compose", version.ref = "navigationFragmentKtx" } navigation-fragment-ktx = { module = "androidx.navigation:navigation-fragment-ktx", version.ref = "navigationFragmentKtx" } navigation-ui-ktx = { module = "androidx.navigation:navigation-ui-ktx", version.ref = "navigationFragmentKtx" } okhttp = { module = "com.squareup.okhttp3:okhttp", version.ref = "okhttp" } diff --git a/src/androidTest/AndroidManifest.xml b/src/androidTest/AndroidManifest.xml index ae8f37a8..d2084741 100644 --- a/src/androidTest/AndroidManifest.xml +++ b/src/androidTest/AndroidManifest.xml @@ -1,6 +1,6 @@ - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/src/main/res/layout/activity_main.xml b/src/main/res/layout/activity_main.xml deleted file mode 100644 index 0baf0272..00000000 --- a/src/main/res/layout/activity_main.xml +++ /dev/null @@ -1,97 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - diff --git a/src/main/res/layout/activity_signup.xml b/src/main/res/layout/activity_signup.xml deleted file mode 100644 index 3f73ddc0..00000000 --- a/src/main/res/layout/activity_signup.xml +++ /dev/null @@ -1,60 +0,0 @@ - - - - - - - - - - - - - - diff --git a/src/main/res/layout/content_main.xml b/src/main/res/layout/content_main.xml deleted file mode 100644 index f31aa9ec..00000000 --- a/src/main/res/layout/content_main.xml +++ /dev/null @@ -1,26 +0,0 @@ - - - - \ No newline at end of file diff --git a/src/main/res/layout/dialog_crop.xml b/src/main/res/layout/dialog_crop.xml deleted file mode 100644 index 1ab2b671..00000000 --- a/src/main/res/layout/dialog_crop.xml +++ /dev/null @@ -1,40 +0,0 @@ - - - - - - - -