plugins {
    id 'com.android.library'
}
android {
    defaultConfig {
        minSdkVersion 21
        targetSdkVersion 35
        compileSdk 35
        testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
    }

    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
            consumerProguardFiles 'proguard-rules.pro'
        }
    }
    publishing {
        singleVariant('release') {
            withSourcesJar()
        }
    }
    namespace = "pub.doric"
}

dependencies {
    implementation fileTree(dir: 'libs', include: ['*.jar'])

    implementation 'androidx.appcompat:appcompat:1.3.1'
    api 'com.github.penfeizhou:jsc4a:0.4.0'
    //api "pub.doric:jse:${rootProject.ext.Version}"
    implementation 'com.squareup.okhttp3:okhttp:3.12.1'
    implementation('com.github.penfeizhou.android.animation:glide-plugin:3.0.5') {
        exclude group: 'com.github.bumptech.glide'
    }
    implementation 'com.github.bumptech.glide:glide:4.11.0'
    implementation "com.google.android.material:material:1.2.1"

    def nav_version = "2.3.0"

    implementation "androidx.navigation:navigation-fragment:$nav_version"
    implementation "androidx.navigation:navigation-ui:$nav_version"

    implementation "com.qmuiteam:qmui:2.1.0"

    testImplementation 'junit:junit:4.13'
    androidTestImplementation 'androidx.test.ext:junit:1.1.1'
    androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0'

    implementation 'com.facebook.yoga.android:yoga-layout:1.19.0'
    implementation 'androidx.localbroadcastmanager:localbroadcastmanager:1.0.0'
    implementation 'androidx.swiperefreshlayout:swiperefreshlayout:1.1.0'
    implementation 'com.facebook.soloader:soloader:0.12.1'
    implementation 'com.facebook.fbjni:fbjni:0.7.0'
}

if (new File('scripts/upload.gradle').exists()) {
    apply from: rootProject.file('scripts/upload.gradle')
}
