Skip to content

Commit

Permalink
Use default hierarchy template
Browse files Browse the repository at this point in the history
  • Loading branch information
twyatt committed Nov 22, 2023
1 parent 529c8bc commit 28dc9f7
Show file tree
Hide file tree
Showing 14 changed files with 121 additions and 378 deletions.
27 changes: 5 additions & 22 deletions axis/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -23,30 +23,13 @@ kotlin {
iosArm64()

sourceSets {
val commonMain by getting {
dependencies {
api(projects.scale)
api(projects.selection)
}
commonMain.dependencies {
api(projects.scale)
api(projects.selection)
}

val commonTest by getting {
dependencies {
implementation(kotlin("test-common"))
implementation(kotlin("test-annotations-common"))
}
}

val jvmTest by getting {
dependencies {
implementation(kotlin("test-junit"))
}
}

val jsTest by getting {
dependencies {
implementation(kotlin("test-js"))
}
commonTest.dependencies {
implementation(kotlin("test"))
}
}
}
66 changes: 21 additions & 45 deletions box/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -16,59 +16,35 @@ kotlin {
iosArm64()

sourceSets {
val commonMain by getting {
dependencies {
api(projects.axis)
api(projects.color)
api(projects.element)
api(projects.hierarchy)
api(projects.interpolate)
api(projects.kanvas)
api(projects.scale)
api(projects.selection)
api(projects.shape)
api(projects.time)
}
commonMain.dependencies {
api(projects.axis)
api(projects.color)
api(projects.element)
api(projects.hierarchy)
api(projects.interpolate)
api(projects.kanvas)
api(projects.scale)
api(projects.selection)
api(projects.shape)
api(projects.time)
}

val commonTest by getting {
dependencies {
implementation(kotlin("reflect"))
implementation(kotlin("test-common"))
implementation(kotlin("test-annotations-common"))
}
commonTest.dependencies {
implementation(kotlin("reflect"))
implementation(kotlin("test"))
}

val androidMain by getting {
dependencies {
api(projects.elementView)
}
androidMain.dependencies {
api(projects.elementView)
}

val androidUnitTest by getting {
dependencies {
implementation(kotlin("test-junit"))
implementation(libs.androidx.test)
implementation(libs.robolectric)
}
getByName("androidUnitTest").dependencies {
implementation(libs.androidx.test)
implementation(libs.robolectric)
}

val jvmTest by getting {
dependencies {
implementation(kotlin("test-junit"))
}
}

val jsMain by getting {
dependencies {
api(projects.elementView)
}
}

val jsTest by getting {
dependencies {
implementation(kotlin("test-js"))
}
jsMain.dependencies {
api(projects.elementView)
}
}
}
Expand Down
19 changes: 2 additions & 17 deletions color/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -24,23 +24,8 @@ kotlin {
iosArm64()

sourceSets {
val commonTest by getting {
dependencies {
implementation(kotlin("test-common"))
implementation(kotlin("test-annotations-common"))
}
}

val jvmTest by getting {
dependencies {
implementation(kotlin("test-junit"))
}
}

val jsTest by getting {
dependencies {
implementation(kotlin("test-js"))
}
commonTest.dependencies {
implementation(kotlin("test"))
}
}
}
30 changes: 12 additions & 18 deletions compose/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -14,29 +14,23 @@ kotlin {
explicitApi()
jvmToolchain(libs.versions.jvm.toolchain.get().toInt())

androidTarget() { publishAllLibraryVariants() }
androidTarget().publishAllLibraryVariants()
jvm("desktop")

sourceSets {
val commonMain by getting {
dependencies {
api(projects.kanvas)
api(projects.element)
api(compose.runtime)
api(compose.foundation)
api(compose.material)
implementation(libs.datetime)
}
commonMain.dependencies {
api(projects.kanvas)
api(projects.element)
api(compose.runtime)
api(compose.foundation)
api(compose.material)
implementation(libs.datetime)
}
val commonTest by getting {
dependencies {
implementation(kotlin("test"))
}
commonTest.dependencies {
implementation(kotlin("test"))
}
val desktopMain by getting {
dependencies {
api(compose.preview)
}
getByName("desktopMain").dependencies {
api(compose.preview)
}
}
}
Expand Down
42 changes: 13 additions & 29 deletions element-view/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -14,41 +14,25 @@ kotlin {
js().browser()

sourceSets {
val commonMain by getting {
dependencies {
api(projects.element)
api(libs.coroutines.core)
}
commonMain.dependencies {
api(projects.element)
api(libs.coroutines.core)
}

val commonTest by getting {
dependencies {
implementation(kotlin("reflect"))
implementation(kotlin("test-common"))
implementation(kotlin("test-annotations-common"))
}
commonTest.dependencies {
implementation(kotlin("reflect"))
implementation(kotlin("test"))
}

val androidMain by getting {
dependencies {
implementation(libs.androidx.appcompat)
implementation(libs.androidx.lifecycle.runtime)
implementation(libs.coroutines.android)
}
androidMain.dependencies {
implementation(libs.androidx.appcompat)
implementation(libs.androidx.lifecycle.runtime)
implementation(libs.coroutines.android)
}

val androidUnitTest by getting {
dependencies {
implementation(kotlin("test-junit"))
implementation(libs.androidx.test)
implementation(libs.robolectric)
}
}

val jsTest by getting {
dependencies {
implementation(kotlin("test-js"))
}
getByName("androidUnitTest").dependencies {
implementation(libs.androidx.test)
implementation(libs.robolectric)
}
}
}
Expand Down
25 changes: 4 additions & 21 deletions element/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -23,29 +23,12 @@ kotlin {
iosArm64()

sourceSets {
val commonMain by getting {
dependencies {
api(projects.kanvas)
}
commonMain.dependencies {
api(projects.kanvas)
}

val commonTest by getting {
dependencies {
implementation(kotlin("test-common"))
implementation(kotlin("test-annotations-common"))
}
}

val jvmTest by getting {
dependencies {
implementation(kotlin("test-junit"))
}
}

val jsTest by getting {
dependencies {
implementation(kotlin("test-js"))
}
commonTest.dependencies {
implementation(kotlin("test"))
}
}
}
19 changes: 2 additions & 17 deletions hierarchy/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -23,23 +23,8 @@ kotlin {
iosArm64()

sourceSets {
val commonTest by getting {
dependencies {
implementation(kotlin("test-common"))
implementation(kotlin("test-annotations-common"))
}
}

val jvmTest by getting {
dependencies {
implementation(kotlin("test-junit"))
}
}

val jsTest by getting {
dependencies {
implementation(kotlin("test-js"))
}
commonTest.dependencies {
implementation(kotlin("test"))
}
}
}
29 changes: 6 additions & 23 deletions interpolate/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -23,31 +23,14 @@ kotlin {
iosArm64()

sourceSets {
val commonMain by getting {
dependencies {
api(projects.kanvas)
api(libs.datetime)
implementation(projects.time)
}
commonMain.dependencies {
api(projects.kanvas)
api(libs.datetime)
implementation(projects.time)
}

val commonTest by getting {
dependencies {
implementation(kotlin("test-common"))
implementation(kotlin("test-annotations-common"))
}
}

val jvmTest by getting {
dependencies {
implementation(kotlin("test-junit"))
}
}

val jsTest by getting {
dependencies {
implementation(kotlin("test-js"))
}
commonTest.dependencies {
implementation(kotlin("test"))
}
}
}
Loading

0 comments on commit 28dc9f7

Please sign in to comment.