plugins {
    id("com.android.library")
    id("org.jetbrains.kotlin.android")
    id("com.google.devtools.ksp")
}

android {
    namespace = "com.isidroid.ui.print_job"
    compileSdk = BuildVersions.COMPILE_SDK

    defaultConfig {
        minSdk = BuildVersions.MIN_SDK

        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_17
        targetCompatibility = JavaVersion.VERSION_17
    }
    kotlinOptions {
        jvmTarget = "17"
    }
    buildFeatures {
        compose = true
    }
    composeOptions {
        kotlinCompilerExtensionVersion = BuildVersions.KOTLIN_COMPILER_EXT_VERSION
    }
    packaging {
        resources {
            excludes += "/META-INF/{AL2.0,LGPL2.1}"
        }
    }
}

dependencies {
    api(project((":ui:compose_components")))


    api("androidx.core:core-ktx:${GoogleVersions.coreKtx}")
    api("androidx.appcompat:appcompat:${GoogleVersions.appCompat}")

    // compose
    api(platform("androidx.compose:compose-bom:${GoogleVersions.composeBom}"))
    api("androidx.compose.ui:ui")
    api("androidx.compose.ui:ui-graphics")
    api("androidx.compose.ui:ui-tooling-preview")
    api("androidx.compose.material3:material3")
    api("androidx.constraintlayout:constraintlayout-compose:${GoogleVersions.constraint}")

    // tools
    api("com.jakewharton.timber:timber:${ToolsVersions.timber}")
    api("com.airbnb.android:lottie-compose:${ToolsVersions.lottie}")

    // testing
    testImplementation("junit:junit:${TestVersions.junit}")
    androidTestImplementation("androidx.test.ext:junit:${TestVersions.junitExt}")
    androidTestImplementation("androidx.test.espresso:espresso-core:${TestVersions.espressoCore}")
    androidTestImplementation(platform("androidx.compose:compose-bom:${GoogleVersions.composeBom}"))
    androidTestImplementation("androidx.compose.ui:ui-test-junit4")
    debugImplementation("androidx.compose.ui:ui-tooling")
    debugImplementation("androidx.compose.ui:ui-test-manifest")
}