Files
NTO-2025-Android-TeamTask/app/build.gradle.kts
v3less11 2e332b8ff9 added generalscreen
added booking screeen
2025-12-11 20:50:28 +03:00

127 lines
4.5 KiB
Kotlin
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
plugins {
composeCompiler
kotlinAndroid
kotlinSerialization version Version.Kotlin.language
androidApplication
}
val packageName = "ru.myitschool.work"
android {
namespace = packageName
compileSdk = Version.Android.Sdk.compile
defaultConfig {
applicationId = packageName
minSdk = Version.Android.Sdk.min
targetSdk = Version.Android.Sdk.target
versionCode = 1
versionName = "1.0"
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
}
buildFeatures.compose = true
buildFeatures.viewBinding = true
compileOptions {
sourceCompatibility = Version.Kotlin.javaSource
targetCompatibility = Version.Kotlin.javaSource
}
kotlinOptions {
jvmTarget = Version.Kotlin.jvmTarget
}
}
dependencies {
// Базовая библиотека Compose (если есть в проекте)
defaultComposeLibrary()
// DataStore для хранения настроек
implementation("androidx.datastore:datastore-preferences:1.1.7")
// Коллекции
implementation("org.jetbrains.kotlinx:kotlinx-collections-immutable:0.4.0")
// Navigation Compose
implementation("androidx.navigation:navigation-compose:2.9.6")
// ===== КЛЮЧЕВЫЕ ЗАВИСИМОСТИ ДЛЯ РАБОТЫ: =====
// Core KTX
implementation("androidx.core:core-ktx:1.12.0")
// Lifecycle
implementation("androidx.lifecycle:lifecycle-runtime-ktx:2.7.0")
implementation("androidx.lifecycle:lifecycle-viewmodel-ktx:2.7.0")
// ⚠️ САМАЯ ВАЖНАЯ: Activity Compose (рабочая версия)
implementation("androidx.activity:activity-compose:1.8.0")
// ViewModel для Compose
implementation("androidx.lifecycle:lifecycle-viewmodel-compose:2.8.5")
// ===== COMPOSE: =====
// Compose BOM (управляет версиями)
implementation(platform("androidx.compose:compose-bom:2024.02.00"))
// Базовые библиотеки Compose (без версий - берутся из BOM)
implementation("androidx.compose.ui:ui")
implementation("androidx.compose.ui:ui-graphics")
implementation("androidx.compose.ui:ui-tooling-preview")
implementation("androidx.compose.ui:ui-tooling")
// Material3
implementation("androidx.compose.material3:material3")
implementation("androidx.compose.material3:material3-window-size-class")
// Иконки Material (ОБЯЗАТЕЛЬНО для Icons.Default)
implementation("androidx.compose.material:material-icons-extended")
// Foundation
implementation("androidx.compose.foundation:foundation")
implementation("androidx.compose.foundation:foundation-layout")
// Runtime для StateFlow
implementation("androidx.compose.runtime:runtime-livedata")
// ===== СЕТЬ И ИЗОБРАЖЕНИЯ: =====
// Coil для загрузки изображений (версия 2.x - проще)
implementation("io.coil-kt:coil-compose:2.5.0")
// Ktor (РЕКОМЕНДУЮ 2.3.8 вместо 3.3.1)
val ktor = "2.3.8" // ← ИЗМЕНИЛ НА 2.3.8 (стабильнее)
implementation("io.ktor:ktor-client-core:$ktor")
implementation("io.ktor:ktor-client-cio:$ktor")
implementation("io.ktor:ktor-client-content-negotiation:$ktor")
implementation("io.ktor:ktor-serialization-kotlinx-json:$ktor")
implementation("io.ktor:ktor-client-core:2.3.8")
implementation("io.ktor:ktor-client-cio:2.3.8")
implementation("io.ktor:ktor-client-content-negotiation:2.3.8")
implementation("io.ktor:ktor-serialization-kotlinx-json:2.3.8")
implementation("io.ktor:ktor-client-logging:2.3.8") // Добавьте это!
// Kotlinx Serialization
implementation("org.jetbrains.kotlinx:kotlinx-serialization-json:1.6.2")
// Coil для изображений
implementation("io.coil-kt:coil-compose:2.6.0")
// Kotlinx Serialization
implementation("org.jetbrains.kotlinx:kotlinx-serialization-json:1.9.0")
// Coroutines
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-android:1.8.1")
// ===== ТЕСТИРОВАНИЕ: =====
testImplementation("junit:junit:4.13.2")
androidTestImplementation("androidx.test.ext:junit:1.1.5")
androidTestImplementation("androidx.test.espresso:espresso-core:3.5.1")
androidTestImplementation("androidx.compose.ui:ui-test-junit4")
debugImplementation("androidx.compose.ui:ui-tooling")
debugImplementation("androidx.compose.ui:ui-test-manifest")
}