blob: e85f6a220313309b8889fe65c1545f6d3433e9f9 [file] [log] [blame]
/*
* Copyright 2024 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/**
* This file was created using the `create_project.py` script located in the
* `<AndroidX root>/development/project-creator` directory.
*
* Please use that script when creating a new project, rather than copying an existing project and
* modifying its settings.
*/
import androidx.build.KotlinTarget
import androidx.build.LibraryType
import androidx.build.PlatformIdentifier
plugins {
id("AndroidXPlugin")
id("AndroidXComposePlugin")
id("com.android.library")
}
androidXMultiplatform {
android()
defaultPlatform(PlatformIdentifier.ANDROID)
sourceSets {
commonMain {
dependencies {
api("androidx.lifecycle:lifecycle-viewmodel:2.8.7")
api("androidx.lifecycle:lifecycle-viewmodel-compose:2.8.7")
implementation(libs.kotlinStdlib)
implementation("androidx.compose.runtime:runtime:1.7.5")
implementation("androidx.compose.runtime:runtime-saveable:1.7.5")
implementation(project(":navigation3:navigation3"))
implementation(project(":savedstate:savedstate"))
implementation(project(":savedstate:savedstate-compose"))
}
}
commonTest {
dependencies {
implementation(libs.kotlinTest)
implementation(project(":kruth:kruth"))
implementation(project(":compose:runtime:runtime-test-utils"))
}
}
jvmMain {
dependsOn(commonMain)
dependencies {
}
}
androidMain {
dependsOn(jvmMain)
dependencies {
implementation("androidx.activity:activity-compose:1.10.0-beta01")
}
}
jvmTest {
dependsOn(commonTest)
dependencies {
}
}
androidInstrumentedTest {
dependsOn(jvmTest)
dependencies {
implementation(libs.testRules)
implementation(libs.testRunner)
implementation(libs.junit)
implementation(libs.testExtJunitKtx)
implementation(libs.truth)
implementation(project(":compose:test-utils"))
implementation("androidx.compose.ui:ui-test:1.7.5")
implementation("androidx.compose.ui:ui-test-junit4:1.7.5")
}
}
}
}
android {
compileSdk = 35
namespace = "androidx.lifecycle.viewmodel.navigation3"
}
androidx {
name = "Androidx Lifecycle Navigation3 ViewModel"
type = LibraryType.SNAPSHOT_ONLY_LIBRARY_ONLY_USED_BY_KOTLIN_CONSUMERS
inceptionYear = "2024"
description = "Provides the ViewModel wrapper for nav3."
doNotDocumentReason = "Not published to maven"
kotlinTarget = KotlinTarget.KOTLIN_1_9
}