diff --git a/android/build.gradle.kts b/android/build.gradle.kts new file mode 100644 index 0000000..80a2897 --- /dev/null +++ b/android/build.gradle.kts @@ -0,0 +1,51 @@ +plugins { + alias(libs.plugins.androidApplication) + alias(libs.plugins.jetbrainsKotlinCompose) + alias(libs.plugins.jetbrainsCompose) +} + +android { + namespace = "ch.dissem.yaep" + compileSdk = libs.versions.android.compileSdk.get().toInt() + + defaultConfig { + applicationId = "ch.dissem.yaep" + minSdk = libs.versions.android.minSdk.get().toInt() + targetSdk = libs.versions.android.targetSdk.get().toInt() + versionCode = 1 + versionName = "1.0" + } + + dependencies { + implementation(compose.components.resources) + implementation(compose.runtime) + implementation(compose.foundation) + implementation(compose.material3) + implementation(compose.ui) + implementation(compose.components.resources) + implementation(libs.androidx.activity.compose) +// implementation(libs.compose.ui.text.googlefonts) + implementation(projects.commonUI) + implementation(compose.components.uiToolingPreview) + + testImplementation(libs.kotlin.test) + testImplementation(libs.atrium) + } + + compileOptions { + sourceCompatibility = JavaVersion.VERSION_11 + targetCompatibility = JavaVersion.VERSION_11 + } + + buildTypes { + getByName("release") { + isMinifyEnabled = false + } + } + + packaging { + resources { + merges += "/META-INF/{AL2.0,LGPL2.1}" + } + } +} diff --git a/composeApp/src/androidMain/AndroidManifest.xml b/android/src/main/AndroidManifest.xml similarity index 90% rename from composeApp/src/androidMain/AndroidManifest.xml rename to android/src/main/AndroidManifest.xml index c5db0b1..5a8fa95 100644 --- a/composeApp/src/androidMain/AndroidManifest.xml +++ b/android/src/main/AndroidManifest.xml @@ -5,13 +5,12 @@ android:allowBackup="true" android:icon="@mipmap/ic_launcher" android:label="@string/app_name" - android:roundIcon="@mipmap/ic_launcher_round" android:supportsRtl="true" android:theme="@android:style/Theme.Material.Light.NoActionBar"> + android:name="ch.dissem.android.MainActivity"> diff --git a/android/src/main/ic_launcher-playstore.png b/android/src/main/ic_launcher-playstore.png new file mode 100644 index 0000000..a224038 Binary files /dev/null and b/android/src/main/ic_launcher-playstore.png differ diff --git a/composeApp/src/androidMain/kotlin/ch/dissem/yaep/MainActivity.kt b/android/src/main/kotlin/ch/dissem/android/MainActivity.kt similarity index 77% rename from composeApp/src/androidMain/kotlin/ch/dissem/yaep/MainActivity.kt rename to android/src/main/kotlin/ch/dissem/android/MainActivity.kt index e1a52cd..03576ab 100644 --- a/composeApp/src/androidMain/kotlin/ch/dissem/yaep/MainActivity.kt +++ b/android/src/main/kotlin/ch/dissem/android/MainActivity.kt @@ -1,11 +1,11 @@ -package ch.dissem.yaep +package ch.dissem.android -import App import android.os.Bundle import androidx.activity.ComponentActivity import androidx.activity.compose.setContent import androidx.compose.runtime.Composable -import androidx.compose.ui.tooling.preview.Preview +import ch.dissem.yaep.ui.common.App +import org.jetbrains.compose.ui.tooling.preview.Preview class MainActivity : ComponentActivity() { override fun onCreate(savedInstanceState: Bundle?) { diff --git a/android/src/main/res/drawable/ic_launcher_foreground.xml b/android/src/main/res/drawable/ic_launcher_foreground.xml new file mode 100644 index 0000000..5b1b9f6 --- /dev/null +++ b/android/src/main/res/drawable/ic_launcher_foreground.xml @@ -0,0 +1,15 @@ + + + + + diff --git a/composeApp/src/androidMain/res/mipmap-anydpi-v26/ic_launcher.xml b/android/src/main/res/mipmap-anydpi-v26/ic_launcher.xml similarity index 71% rename from composeApp/src/androidMain/res/mipmap-anydpi-v26/ic_launcher.xml rename to android/src/main/res/mipmap-anydpi-v26/ic_launcher.xml index eca70cf..7353dbd 100644 --- a/composeApp/src/androidMain/res/mipmap-anydpi-v26/ic_launcher.xml +++ b/android/src/main/res/mipmap-anydpi-v26/ic_launcher.xml @@ -1,5 +1,5 @@ - - + + \ No newline at end of file diff --git a/android/src/main/res/values/ic_launcher_background.xml b/android/src/main/res/values/ic_launcher_background.xml new file mode 100644 index 0000000..8fcb224 --- /dev/null +++ b/android/src/main/res/values/ic_launcher_background.xml @@ -0,0 +1,4 @@ + + + #165295 + \ No newline at end of file diff --git a/composeApp/src/androidMain/res/values/strings.xml b/android/src/main/res/values/strings.xml similarity index 100% rename from composeApp/src/androidMain/res/values/strings.xml rename to android/src/main/res/values/strings.xml diff --git a/build.gradle.kts b/build.gradle.kts index 74f0171..2a064b8 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -1,9 +1,18 @@ +import org.jetbrains.kotlin.gradle.dsl.JvmTarget +import org.jetbrains.kotlin.gradle.tasks.KotlinJvmCompile + plugins { // this is necessary to avoid the plugins to be loaded multiple times // in each subproject's classloader alias(libs.plugins.androidApplication) apply false alias(libs.plugins.androidLibrary) apply false alias(libs.plugins.jetbrainsCompose) apply false - alias(libs.plugins.kotlinMultiplatform) apply false - alias(libs.plugins.jetbrainsKotlinJvm) apply false -} \ No newline at end of file + alias(libs.plugins.kotlin.multiplatform) apply false + alias(libs.plugins.kotlin.jvm) apply false +} + +tasks.withType().configureEach { + compilerOptions { + jvmTarget.set(JvmTarget.JVM_11) + } +} diff --git a/commonUI/build.gradle.kts b/commonUI/build.gradle.kts new file mode 100644 index 0000000..b9774fd --- /dev/null +++ b/commonUI/build.gradle.kts @@ -0,0 +1,28 @@ +plugins { + alias(libs.plugins.kotlin.jvm) + alias(libs.plugins.jetbrainsKotlinCompose) + alias(libs.plugins.jetbrainsCompose) +} + +kotlin { + jvmToolchain(11) + + dependencies { + implementation(compose.components.resources) + implementation(compose.runtime) + implementation(compose.foundation) + implementation(compose.material3) + implementation(compose.ui) + implementation(compose.components.resources) + implementation(compose.components.uiToolingPreview) +// implementation(libs.compose.ui.text.googlefonts) + implementation(projects.domain) + + testImplementation(libs.kotlin.test) + testImplementation(libs.atrium) + } +} + +compose.resources { + publicResClass = true +} diff --git a/composeApp/src/commonMain/composeResources/drawable/compose-multiplatform.xml b/commonUI/src/main/composeResources/drawable/compose-multiplatform.xml similarity index 100% rename from composeApp/src/commonMain/composeResources/drawable/compose-multiplatform.xml rename to commonUI/src/main/composeResources/drawable/compose-multiplatform.xml diff --git a/composeApp/src/commonMain/composeResources/drawable/moon.xml b/commonUI/src/main/composeResources/drawable/moon.xml similarity index 100% rename from composeApp/src/commonMain/composeResources/drawable/moon.xml rename to commonUI/src/main/composeResources/drawable/moon.xml diff --git a/composeApp/src/commonMain/composeResources/drawable/neighbour.xml b/commonUI/src/main/composeResources/drawable/neighbour.xml similarity index 100% rename from composeApp/src/commonMain/composeResources/drawable/neighbour.xml rename to commonUI/src/main/composeResources/drawable/neighbour.xml diff --git a/composeApp/src/commonMain/composeResources/drawable/order.xml b/commonUI/src/main/composeResources/drawable/order.xml similarity index 100% rename from composeApp/src/commonMain/composeResources/drawable/order.xml rename to commonUI/src/main/composeResources/drawable/order.xml diff --git a/composeApp/src/commonMain/composeResources/drawable/sun.xml b/commonUI/src/main/composeResources/drawable/sun.xml similarity index 100% rename from composeApp/src/commonMain/composeResources/drawable/sun.xml rename to commonUI/src/main/composeResources/drawable/sun.xml diff --git a/composeApp/src/commonMain/composeResources/drawable/window-close.xml b/commonUI/src/main/composeResources/drawable/window-close.xml similarity index 100% rename from composeApp/src/commonMain/composeResources/drawable/window-close.xml rename to commonUI/src/main/composeResources/drawable/window-close.xml diff --git a/composeApp/src/commonMain/composeResources/drawable/window-maximize.xml b/commonUI/src/main/composeResources/drawable/window-maximize.xml similarity index 100% rename from composeApp/src/commonMain/composeResources/drawable/window-maximize.xml rename to commonUI/src/main/composeResources/drawable/window-maximize.xml diff --git a/composeApp/src/commonMain/composeResources/drawable/window-minimize.xml b/commonUI/src/main/composeResources/drawable/window-minimize.xml similarity index 100% rename from composeApp/src/commonMain/composeResources/drawable/window-minimize.xml rename to commonUI/src/main/composeResources/drawable/window-minimize.xml diff --git a/composeApp/src/commonMain/kotlin/App.kt b/commonUI/src/main/kotlin/ch/dissem/yaep/ui/common/App.kt similarity index 91% rename from composeApp/src/commonMain/kotlin/App.kt rename to commonUI/src/main/kotlin/ch/dissem/yaep/ui/common/App.kt index 842bfcf..b5c1cfc 100644 --- a/composeApp/src/commonMain/kotlin/App.kt +++ b/commonUI/src/main/kotlin/ch/dissem/yaep/ui/common/App.kt @@ -1,3 +1,5 @@ +package ch.dissem.yaep.ui.common + import androidx.compose.foundation.Image import androidx.compose.foundation.clickable import androidx.compose.foundation.layout.Column @@ -17,21 +19,19 @@ import androidx.compose.runtime.setValue import androidx.compose.ui.Modifier import androidx.compose.ui.draw.alpha import androidx.compose.ui.unit.dp -import domain.Clue -import domain.Grid -import domain.HorizontalClue -import domain.ItemClass -import domain.NeighbourClue -import domain.OrderClue -import domain.SameColumnClue -import domain.TripletClue -import domain.generateGame +import ch.dissem.yaep.domain.Clue +import ch.dissem.yaep.domain.Grid +import ch.dissem.yaep.domain.HorizontalClue +import ch.dissem.yaep.domain.ItemClass +import ch.dissem.yaep.domain.NeighbourClue +import ch.dissem.yaep.domain.OrderClue +import ch.dissem.yaep.domain.SameColumnClue +import ch.dissem.yaep.domain.TripletClue +import ch.dissem.yaep.domain.generateGame import org.jetbrains.compose.resources.painterResource -import ui.DrawItem -import ui.Selector -import yaep.composeapp.generated.resources.Res -import yaep.composeapp.generated.resources.neighbour -import yaep.composeapp.generated.resources.order +import yaep.commonui.generated.resources.Res +import yaep.commonui.generated.resources.neighbour +import yaep.commonui.generated.resources.order class DisplayClue(val clue: C) { var isActive by mutableStateOf(true) diff --git a/composeApp/src/commonMain/kotlin/ui/selector.kt b/commonUI/src/main/kotlin/ch/dissem/yaep/ui/common/selector.kt similarity index 89% rename from composeApp/src/commonMain/kotlin/ui/selector.kt rename to commonUI/src/main/kotlin/ch/dissem/yaep/ui/common/selector.kt index b02754f..bf3d61c 100644 --- a/composeApp/src/commonMain/kotlin/ui/selector.kt +++ b/commonUI/src/main/kotlin/ch/dissem/yaep/ui/common/selector.kt @@ -1,4 +1,4 @@ -package ui +package ch.dissem.yaep.ui.common import androidx.compose.foundation.Canvas import androidx.compose.foundation.clickable @@ -9,21 +9,15 @@ import androidx.compose.foundation.lazy.grid.GridCells import androidx.compose.foundation.lazy.grid.LazyVerticalGrid import androidx.compose.material3.OutlinedCard import androidx.compose.runtime.Composable -import androidx.compose.runtime.getValue -import androidx.compose.runtime.mutableStateOf -import androidx.compose.runtime.remember -import androidx.compose.runtime.setValue import androidx.compose.ui.Modifier import androidx.compose.ui.geometry.Offset import androidx.compose.ui.text.TextStyle import androidx.compose.ui.text.drawText import androidx.compose.ui.text.rememberTextMeasurer -import domain.Animals -import domain.Item -import domain.ItemClass -import domain.ItemClassCompanion -import org.jetbrains.compose.ui.tooling.preview.Preview -import ui.theme.emojiFontFamily +import ch.dissem.yaep.domain.Item +import ch.dissem.yaep.domain.ItemClass +import ch.dissem.yaep.domain.ItemClassCompanion +import ch.dissem.yaep.ui.common.theme.emojiFontFamily import kotlin.math.min @Composable diff --git a/composeApp/src/commonMain/kotlin/ui/theme/Color.kt b/commonUI/src/main/kotlin/ch/dissem/yaep/ui/common/theme/Color.kt similarity index 99% rename from composeApp/src/commonMain/kotlin/ui/theme/Color.kt rename to commonUI/src/main/kotlin/ch/dissem/yaep/ui/common/theme/Color.kt index 8f0cc20..3e44904 100644 --- a/composeApp/src/commonMain/kotlin/ui/theme/Color.kt +++ b/commonUI/src/main/kotlin/ch/dissem/yaep/ui/common/theme/Color.kt @@ -1,4 +1,4 @@ -package ui.theme +package ch.dissem.yaep.ui.common.theme import androidx.compose.ui.graphics.Color val primaryLight = Color(0xFF6D5E0F) diff --git a/composeApp/src/commonMain/kotlin/ui/theme/Theme.kt b/commonUI/src/main/kotlin/ch/dissem/yaep/ui/common/theme/Theme.kt similarity index 99% rename from composeApp/src/commonMain/kotlin/ui/theme/Theme.kt rename to commonUI/src/main/kotlin/ch/dissem/yaep/ui/common/theme/Theme.kt index 7141627..42f6d8f 100644 --- a/composeApp/src/commonMain/kotlin/ui/theme/Theme.kt +++ b/commonUI/src/main/kotlin/ch/dissem/yaep/ui/common/theme/Theme.kt @@ -1,4 +1,4 @@ -package ui.theme +package ch.dissem.yaep.ui.common.theme import androidx.compose.foundation.isSystemInDarkTheme import androidx.compose.material3.MaterialTheme import androidx.compose.material3.darkColorScheme diff --git a/composeApp/src/commonMain/kotlin/ui/theme/Type.kt b/commonUI/src/main/kotlin/ch/dissem/yaep/ui/common/theme/Type.kt similarity index 98% rename from composeApp/src/commonMain/kotlin/ui/theme/Type.kt rename to commonUI/src/main/kotlin/ch/dissem/yaep/ui/common/theme/Type.kt index ac78c17..8cdcbaf 100644 --- a/composeApp/src/commonMain/kotlin/ui/theme/Type.kt +++ b/commonUI/src/main/kotlin/ch/dissem/yaep/ui/common/theme/Type.kt @@ -1,4 +1,4 @@ -package ui.theme +package ch.dissem.yaep.ui.common.theme //import androidx.compose.material3.Typography //import androidx.compose.ui.text.TextStyle diff --git a/commonUI/src/main/kotlin/ch/dissem/yaep/ui/common/theme/emoji.kt b/commonUI/src/main/kotlin/ch/dissem/yaep/ui/common/theme/emoji.kt new file mode 100644 index 0000000..227aa3a --- /dev/null +++ b/commonUI/src/main/kotlin/ch/dissem/yaep/ui/common/theme/emoji.kt @@ -0,0 +1,5 @@ +package ch.dissem.yaep.ui.common.theme + +import androidx.compose.ui.text.font.FontFamily + +var emojiFontFamily: FontFamily? = null \ No newline at end of file diff --git a/composeApp/build.gradle.kts b/composeApp/build.gradle.kts deleted file mode 100644 index dc45c00..0000000 --- a/composeApp/build.gradle.kts +++ /dev/null @@ -1,113 +0,0 @@ -import org.jetbrains.compose.desktop.application.dsl.TargetFormat -import org.jetbrains.kotlin.gradle.dsl.JvmTarget -import org.jetbrains.kotlin.gradle.tasks.KotlinJvmCompile - -plugins { - alias(libs.plugins.kotlinMultiplatform) - alias(libs.plugins.androidApplication) - alias(libs.plugins.jetbrainsCompose) - alias(libs.plugins.jetbrainsKotlinCompose) -} - -tasks.withType().configureEach { - compilerOptions { - jvmTarget.set(JvmTarget.JVM_11) - } -} - -kotlin { - androidTarget() - jvm("desktop") - - @OptIn(org.jetbrains.compose.ExperimentalComposeLibrary::class) - sourceSets { - val androidUnitTest by getting - val desktopMain by getting - val desktopTest by getting - - androidMain.dependencies { - implementation(libs.compose.ui.tooling.preview) - implementation(libs.androidx.activity.compose) - } - commonMain.dependencies { - implementation(compose.runtime) - implementation(compose.foundation) - implementation(compose.material3) - implementation(compose.ui) - implementation(compose.components.resources) - implementation(compose.components.uiToolingPreview) - implementation(libs.compose.ui.text.googlefonts) - } - desktopMain.dependencies { - implementation(compose.desktop.currentOs) - } - androidUnitTest.dependencies { - implementation(libs.kotlin.test) - implementation(compose.uiTest) - implementation(libs.atrium) - } - commonTest.dependencies { - implementation(libs.kotlin.test) - implementation(libs.atrium) - } - desktopTest.dependencies { - implementation(libs.kotlin.test) - implementation(libs.atrium) - implementation(compose.desktop.uiTestJUnit4) - implementation(compose.desktop.currentOs) - } - } - -} - -android { - namespace = "ch.dissem.yaep" - compileSdk = libs.versions.android.compileSdk.get().toInt() - - sourceSets["main"].manifest.srcFile("src/androidMain/AndroidManifest.xml") - sourceSets["main"].res.srcDirs("src/androidMain/res") - sourceSets["main"].resources.srcDirs("src/commonMain/resources") - - defaultConfig { - applicationId = "ch.dissem.yaep" - minSdk = libs.versions.android.minSdk.get().toInt() - targetSdk = libs.versions.android.targetSdk.get().toInt() - versionCode = 1 - versionName = "1.0" - } - packaging { - resources { - excludes += "/META-INF/{AL2.0,LGPL2.1}" - } - } - buildTypes { - getByName("release") { - isMinifyEnabled = false - } - } - compileOptions { - sourceCompatibility = JavaVersion.VERSION_11 - targetCompatibility = JavaVersion.VERSION_11 - } - dependencies { - debugImplementation(libs.compose.ui.tooling) - } -} - -compose.desktop { - application { - mainClass = "MainKt" - - nativeDistributions { - targetFormats(TargetFormat.Dmg, TargetFormat.Msi, TargetFormat.Deb) - packageName = "ch.dissem.yaep" - packageVersion = "1.0.0" - - buildTypes.release.proguard { - configurationFiles.from(project.file("proguard-rules.pro")) - isEnabled.set(true) - obfuscate.set(true) - } - } - } -} diff --git a/composeApp/src/androidMain/kotlin/Platform.android.kt b/composeApp/src/androidMain/kotlin/Platform.android.kt deleted file mode 100644 index 4f3ea05..0000000 --- a/composeApp/src/androidMain/kotlin/Platform.android.kt +++ /dev/null @@ -1,7 +0,0 @@ -import android.os.Build - -class AndroidPlatform : Platform { - override val name: String = "Android ${Build.VERSION.SDK_INT}" -} - -actual fun getPlatform(): Platform = AndroidPlatform() \ No newline at end of file diff --git a/composeApp/src/androidMain/kotlin/ui/theme/emoji.kt b/composeApp/src/androidMain/kotlin/ui/theme/emoji.kt deleted file mode 100644 index 5f40962..0000000 --- a/composeApp/src/androidMain/kotlin/ui/theme/emoji.kt +++ /dev/null @@ -1,5 +0,0 @@ -package ui.theme - -import androidx.compose.ui.text.font.FontFamily - -actual val emojiFontFamily: FontFamily? = null \ No newline at end of file diff --git a/composeApp/src/androidMain/res/drawable-v24/ic_launcher_foreground.xml b/composeApp/src/androidMain/res/drawable-v24/ic_launcher_foreground.xml deleted file mode 100644 index 2b068d1..0000000 --- a/composeApp/src/androidMain/res/drawable-v24/ic_launcher_foreground.xml +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - - - \ No newline at end of file diff --git a/composeApp/src/androidMain/res/drawable/ic_launcher_background.xml b/composeApp/src/androidMain/res/drawable/ic_launcher_background.xml deleted file mode 100644 index e93e11a..0000000 --- a/composeApp/src/androidMain/res/drawable/ic_launcher_background.xml +++ /dev/null @@ -1,170 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/composeApp/src/androidMain/res/mipmap-anydpi-v26/ic_launcher_round.xml b/composeApp/src/androidMain/res/mipmap-anydpi-v26/ic_launcher_round.xml deleted file mode 100644 index eca70cf..0000000 --- a/composeApp/src/androidMain/res/mipmap-anydpi-v26/ic_launcher_round.xml +++ /dev/null @@ -1,5 +0,0 @@ - - - - - \ No newline at end of file diff --git a/composeApp/src/androidMain/res/mipmap-hdpi/ic_launcher.png b/composeApp/src/androidMain/res/mipmap-hdpi/ic_launcher.png deleted file mode 100644 index a571e60..0000000 Binary files a/composeApp/src/androidMain/res/mipmap-hdpi/ic_launcher.png and /dev/null differ diff --git a/composeApp/src/androidMain/res/mipmap-hdpi/ic_launcher_round.png b/composeApp/src/androidMain/res/mipmap-hdpi/ic_launcher_round.png deleted file mode 100644 index 61da551..0000000 Binary files a/composeApp/src/androidMain/res/mipmap-hdpi/ic_launcher_round.png and /dev/null differ diff --git a/composeApp/src/androidMain/res/mipmap-mdpi/ic_launcher.png b/composeApp/src/androidMain/res/mipmap-mdpi/ic_launcher.png deleted file mode 100644 index c41dd28..0000000 Binary files a/composeApp/src/androidMain/res/mipmap-mdpi/ic_launcher.png and /dev/null differ diff --git a/composeApp/src/androidMain/res/mipmap-mdpi/ic_launcher_round.png b/composeApp/src/androidMain/res/mipmap-mdpi/ic_launcher_round.png deleted file mode 100644 index db5080a..0000000 Binary files a/composeApp/src/androidMain/res/mipmap-mdpi/ic_launcher_round.png and /dev/null differ diff --git a/composeApp/src/androidMain/res/mipmap-xhdpi/ic_launcher.png b/composeApp/src/androidMain/res/mipmap-xhdpi/ic_launcher.png deleted file mode 100644 index 6dba46d..0000000 Binary files a/composeApp/src/androidMain/res/mipmap-xhdpi/ic_launcher.png and /dev/null differ diff --git a/composeApp/src/androidMain/res/mipmap-xhdpi/ic_launcher_round.png b/composeApp/src/androidMain/res/mipmap-xhdpi/ic_launcher_round.png deleted file mode 100644 index da31a87..0000000 Binary files a/composeApp/src/androidMain/res/mipmap-xhdpi/ic_launcher_round.png and /dev/null differ diff --git a/composeApp/src/androidMain/res/mipmap-xxhdpi/ic_launcher.png b/composeApp/src/androidMain/res/mipmap-xxhdpi/ic_launcher.png deleted file mode 100644 index 15ac681..0000000 Binary files a/composeApp/src/androidMain/res/mipmap-xxhdpi/ic_launcher.png and /dev/null differ diff --git a/composeApp/src/androidMain/res/mipmap-xxhdpi/ic_launcher_round.png b/composeApp/src/androidMain/res/mipmap-xxhdpi/ic_launcher_round.png deleted file mode 100644 index b216f2d..0000000 Binary files a/composeApp/src/androidMain/res/mipmap-xxhdpi/ic_launcher_round.png and /dev/null differ diff --git a/composeApp/src/androidMain/res/mipmap-xxxhdpi/ic_launcher.png b/composeApp/src/androidMain/res/mipmap-xxxhdpi/ic_launcher.png deleted file mode 100644 index f25a419..0000000 Binary files a/composeApp/src/androidMain/res/mipmap-xxxhdpi/ic_launcher.png and /dev/null differ diff --git a/composeApp/src/androidMain/res/mipmap-xxxhdpi/ic_launcher_round.png b/composeApp/src/androidMain/res/mipmap-xxxhdpi/ic_launcher_round.png deleted file mode 100644 index e96783c..0000000 Binary files a/composeApp/src/androidMain/res/mipmap-xxxhdpi/ic_launcher_round.png and /dev/null differ diff --git a/composeApp/src/androidMain/res/values-v23/font_certs.xml b/composeApp/src/androidMain/res/values-v23/font_certs.xml deleted file mode 100644 index 207b62f..0000000 --- a/composeApp/src/androidMain/res/values-v23/font_certs.xml +++ /dev/null @@ -1,32 +0,0 @@ - - - - - @array/com_google_android_gms_fonts_certs_dev - @array/com_google_android_gms_fonts_certs_prod - - - - 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 - - - diff --git a/composeApp/src/commonMain/kotlin/Greeting.kt b/composeApp/src/commonMain/kotlin/Greeting.kt deleted file mode 100644 index 887d835..0000000 --- a/composeApp/src/commonMain/kotlin/Greeting.kt +++ /dev/null @@ -1,7 +0,0 @@ -class Greeting { - private val platform = getPlatform() - - fun greet(): String { - return "Hello, ${platform.name}!" - } -} \ No newline at end of file diff --git a/composeApp/src/commonMain/kotlin/Platform.kt b/composeApp/src/commonMain/kotlin/Platform.kt deleted file mode 100644 index 87ca3ff..0000000 --- a/composeApp/src/commonMain/kotlin/Platform.kt +++ /dev/null @@ -1,5 +0,0 @@ -interface Platform { - val name: String -} - -expect fun getPlatform(): Platform \ No newline at end of file diff --git a/composeApp/src/commonMain/kotlin/ui/theme/emoji.kt b/composeApp/src/commonMain/kotlin/ui/theme/emoji.kt deleted file mode 100644 index e6c618c..0000000 --- a/composeApp/src/commonMain/kotlin/ui/theme/emoji.kt +++ /dev/null @@ -1,5 +0,0 @@ -package ui.theme - -import androidx.compose.ui.text.font.FontFamily - -expect val emojiFontFamily: FontFamily? \ No newline at end of file diff --git a/composeApp/src/desktopMain/kotlin/Platform.jvm.kt b/composeApp/src/desktopMain/kotlin/Platform.jvm.kt deleted file mode 100644 index f5e7e49..0000000 --- a/composeApp/src/desktopMain/kotlin/Platform.jvm.kt +++ /dev/null @@ -1,5 +0,0 @@ -class JVMPlatform: Platform { - override val name: String = "Java ${System.getProperty("java.version")}" -} - -actual fun getPlatform(): Platform = JVMPlatform() \ No newline at end of file diff --git a/composeApp/src/desktopMain/kotlin/ui/theme/emoji.kt b/composeApp/src/desktopMain/kotlin/ui/theme/emoji.kt deleted file mode 100644 index 9f7f8c3..0000000 --- a/composeApp/src/desktopMain/kotlin/ui/theme/emoji.kt +++ /dev/null @@ -1,14 +0,0 @@ -package ui.theme - -import androidx.compose.ui.text.font.FontFamily -import androidx.compose.ui.text.font.FontStyle -import androidx.compose.ui.text.font.FontWeight -import androidx.compose.ui.text.platform.Font - -actual val emojiFontFamily: FontFamily? = FontFamily( - Font( - resource = "NotoColorEmoji-Regular.ttf", - weight = FontWeight.W400, - style = FontStyle.Normal - ) -) \ No newline at end of file diff --git a/desktop/build.gradle.kts b/desktop/build.gradle.kts new file mode 100644 index 0000000..c701f3b --- /dev/null +++ b/desktop/build.gradle.kts @@ -0,0 +1,42 @@ +import org.jetbrains.compose.desktop.application.dsl.TargetFormat + +plugins { + alias(libs.plugins.kotlin.jvm) + alias(libs.plugins.jetbrainsKotlinCompose) + alias(libs.plugins.jetbrainsCompose) +} + +kotlin { + jvmToolchain(11) + + dependencies { + implementation(compose.desktop.currentOs) + implementation(compose.material3) + implementation(compose.components.resources) + implementation(projects.commonUI) + implementation(compose.components.uiToolingPreview) + + testImplementation(libs.kotlin.test) + testImplementation(libs.atrium) + testImplementation(compose.desktop.uiTestJUnit4) + testImplementation(compose.desktop.currentOs) + } +} + +compose.desktop { + application { + mainClass = "MainKt" + + nativeDistributions { + targetFormats(TargetFormat.Dmg, TargetFormat.Msi, TargetFormat.Deb) + packageName = "ch.dissem.yaep" + packageVersion = "1.0.0" + + buildTypes.release.proguard { + configurationFiles.from(project.file("proguard-rules.pro")) + isEnabled.set(true) + obfuscate.set(true) + } + } + } +} diff --git a/composeApp/proguard-rules.pro b/desktop/proguard-rules.pro similarity index 100% rename from composeApp/proguard-rules.pro rename to desktop/proguard-rules.pro diff --git a/composeApp/src/desktopMain/kotlin/desktop window.kt b/desktop/src/main/kotlin/ch/dissem/yaep/ui/desktop/desktop window.kt similarity index 91% rename from composeApp/src/desktopMain/kotlin/desktop window.kt rename to desktop/src/main/kotlin/ch/dissem/yaep/ui/desktop/desktop window.kt index f26adb8..58e4470 100644 --- a/composeApp/src/desktopMain/kotlin/desktop window.kt +++ b/desktop/src/main/kotlin/ch/dissem/yaep/ui/desktop/desktop window.kt @@ -17,14 +17,14 @@ import androidx.compose.ui.unit.dp import androidx.compose.ui.window.WindowPlacement import androidx.compose.ui.window.WindowScope import androidx.compose.ui.window.WindowState +import ch.dissem.yaep.ui.common.theme.AppTheme import org.jetbrains.compose.resources.painterResource -import ui.theme.AppTheme -import yaep.composeapp.generated.resources.Res -import yaep.composeapp.generated.resources.moon -import yaep.composeapp.generated.resources.sun -import yaep.composeapp.generated.resources.window_close -import yaep.composeapp.generated.resources.window_maximize -import yaep.composeapp.generated.resources.window_minimize +import yaep.commonui.generated.resources.Res +import yaep.commonui.generated.resources.moon +import yaep.commonui.generated.resources.sun +import yaep.commonui.generated.resources.window_close +import yaep.commonui.generated.resources.window_maximize +import yaep.commonui.generated.resources.window_minimize @Composable fun WindowScope.DesktopWindow( diff --git a/composeApp/src/desktopMain/kotlin/main.kt b/desktop/src/main/kotlin/ch/dissem/yaep/ui/desktop/main.kt similarity index 69% rename from composeApp/src/desktopMain/kotlin/main.kt rename to desktop/src/main/kotlin/ch/dissem/yaep/ui/desktop/main.kt index a3b3f12..ebbcd7f 100644 --- a/composeApp/src/desktopMain/kotlin/main.kt +++ b/desktop/src/main/kotlin/ch/dissem/yaep/ui/desktop/main.kt @@ -4,15 +4,29 @@ import androidx.compose.runtime.mutableStateOf import androidx.compose.runtime.remember import androidx.compose.runtime.setValue import androidx.compose.ui.Modifier +import androidx.compose.ui.text.font.FontFamily +import androidx.compose.ui.text.font.FontStyle +import androidx.compose.ui.text.font.FontWeight +import androidx.compose.ui.text.platform.Font import androidx.compose.ui.window.Window import androidx.compose.ui.window.WindowPlacement import androidx.compose.ui.window.application import androidx.compose.ui.window.rememberWindowState +import ch.dissem.yaep.ui.common.App +import ch.dissem.yaep.ui.common.theme.emojiFontFamily import org.jetbrains.compose.resources.painterResource -import yaep.composeapp.generated.resources.Res -import yaep.composeapp.generated.resources.moon +import yaep.commonui.generated.resources.Res +import yaep.commonui.generated.resources.moon fun main() = application { + emojiFontFamily = FontFamily( + Font( + resource = "NotoColorEmoji-Regular.ttf", + weight = FontWeight.W400, + style = FontStyle.Normal + ) + ) + Window( onCloseRequest = ::exitApplication, undecorated = true, diff --git a/composeApp/src/desktopMain/resources/NotoColorEmoji-Regular.ttf b/desktop/src/main/resources/NotoColorEmoji-Regular.ttf similarity index 100% rename from composeApp/src/desktopMain/resources/NotoColorEmoji-Regular.ttf rename to desktop/src/main/resources/NotoColorEmoji-Regular.ttf diff --git a/domain/build.gradle.kts b/domain/build.gradle.kts new file mode 100644 index 0000000..bfd157f --- /dev/null +++ b/domain/build.gradle.kts @@ -0,0 +1,12 @@ +plugins { + alias(libs.plugins.kotlin.jvm) +} + +kotlin { + jvmToolchain(11) + + dependencies { + testImplementation(libs.kotlin.test) + testImplementation(libs.atrium) + } +} \ No newline at end of file diff --git a/composeApp/src/commonMain/kotlin/domain/Game.kt b/domain/src/main/kotlin/ch/dissem/yaep/domain/Game.kt similarity index 97% rename from composeApp/src/commonMain/kotlin/domain/Game.kt rename to domain/src/main/kotlin/ch/dissem/yaep/domain/Game.kt index d033cfe..7ef6422 100644 --- a/composeApp/src/commonMain/kotlin/domain/Game.kt +++ b/domain/src/main/kotlin/ch/dissem/yaep/domain/Game.kt @@ -1,4 +1,4 @@ -package domain +package ch.dissem.yaep.domain class Game( val grid: Grid, diff --git a/composeApp/src/commonMain/kotlin/domain/clues.kt b/domain/src/main/kotlin/ch/dissem/yaep/domain/clues.kt similarity index 99% rename from composeApp/src/commonMain/kotlin/domain/clues.kt rename to domain/src/main/kotlin/ch/dissem/yaep/domain/clues.kt index ecf32e4..8eb29a9 100644 --- a/composeApp/src/commonMain/kotlin/domain/clues.kt +++ b/domain/src/main/kotlin/ch/dissem/yaep/domain/clues.kt @@ -1,4 +1,4 @@ -package domain +package ch.dissem.yaep.domain sealed class Clue { abstract fun isRuleViolated(grid: Grid): Boolean diff --git a/composeApp/src/commonMain/kotlin/domain/generator.kt b/domain/src/main/kotlin/ch/dissem/yaep/domain/generator.kt similarity index 96% rename from composeApp/src/commonMain/kotlin/domain/generator.kt rename to domain/src/main/kotlin/ch/dissem/yaep/domain/generator.kt index 099d4cb..612ab84 100644 --- a/composeApp/src/commonMain/kotlin/domain/generator.kt +++ b/domain/src/main/kotlin/ch/dissem/yaep/domain/generator.kt @@ -1,8 +1,8 @@ -package domain +package ch.dissem.yaep.domain -import domain.PuzzleSolution.MULTIPLE_SOLUTIONS -import domain.PuzzleSolution.NO_SOLUTION -import domain.PuzzleSolution.SOLVABLE +import ch.dissem.yaep.domain.PuzzleSolution.MULTIPLE_SOLUTIONS +import ch.dissem.yaep.domain.PuzzleSolution.NO_SOLUTION +import ch.dissem.yaep.domain.PuzzleSolution.SOLVABLE import kotlin.random.Random fun generateGame(size: Int = 6): Game { diff --git a/composeApp/src/commonMain/kotlin/domain/grid.kt b/domain/src/main/kotlin/ch/dissem/yaep/domain/grid.kt similarity index 86% rename from composeApp/src/commonMain/kotlin/domain/grid.kt rename to domain/src/main/kotlin/ch/dissem/yaep/domain/grid.kt index be94b2a..c17dbbd 100644 --- a/composeApp/src/commonMain/kotlin/domain/grid.kt +++ b/domain/src/main/kotlin/ch/dissem/yaep/domain/grid.kt @@ -1,9 +1,4 @@ -package domain - -import androidx.compose.runtime.getValue -import androidx.compose.runtime.mutableStateOf -import androidx.compose.runtime.setValue -import androidx.compose.runtime.toMutableStateList +package ch.dissem.yaep.domain class GameRow>( val category: ItemClassCompanion, @@ -59,14 +54,14 @@ fun List>>>.toGrid() = Grid( ) class GameCell>( - selection: Item?, + var selection: Item?, val solution: Item, - options: List> -) { - val options = options.toMutableStateList() - var selection by mutableStateOf(selection) - -} + val options: MutableList> +) +//{ +// val options = options.toMutableStateList() +// var selection by mutableStateOf(selection) +//} fun > GameCell?.mayBe(item: Item) = this != null && (selection == item || (selection == null && options.contains(item))) diff --git a/composeApp/src/commonMain/kotlin/domain/items.kt b/domain/src/main/kotlin/ch/dissem/yaep/domain/items.kt similarity index 99% rename from composeApp/src/commonMain/kotlin/domain/items.kt rename to domain/src/main/kotlin/ch/dissem/yaep/domain/items.kt index 1514402..3706953 100644 --- a/composeApp/src/commonMain/kotlin/domain/items.kt +++ b/domain/src/main/kotlin/ch/dissem/yaep/domain/items.kt @@ -1,4 +1,4 @@ -package domain +package ch.dissem.yaep.domain enum class Animals(symbol: String) : ItemClass { ZEBRA("🦓"), diff --git a/composeApp/src/commonTest/kotlin/domain/ClueTest.kt b/domain/src/test/kotlin/ch/dissem/yaep/domain/ClueTest.kt similarity index 96% rename from composeApp/src/commonTest/kotlin/domain/ClueTest.kt rename to domain/src/test/kotlin/ch/dissem/yaep/domain/ClueTest.kt index 44674a6..95e40ca 100644 --- a/composeApp/src/commonTest/kotlin/domain/ClueTest.kt +++ b/domain/src/test/kotlin/ch/dissem/yaep/domain/ClueTest.kt @@ -1,4 +1,4 @@ -package domain +package ch.dissem.yaep.domain abstract class ClueTest { protected val size = 6 diff --git a/composeApp/src/commonTest/kotlin/domain/GameTest.kt b/domain/src/test/kotlin/ch/dissem/yaep/domain/GameTest.kt similarity index 82% rename from composeApp/src/commonTest/kotlin/domain/GameTest.kt rename to domain/src/test/kotlin/ch/dissem/yaep/domain/GameTest.kt index a20a8f6..8795a85 100644 --- a/composeApp/src/commonTest/kotlin/domain/GameTest.kt +++ b/domain/src/test/kotlin/ch/dissem/yaep/domain/GameTest.kt @@ -1,14 +1,8 @@ -package domain +package ch.dissem.yaep.domain -import androidx.compose.runtime.TestOnly -import ch.tutteli.atrium.api.fluent.en_GB.extractSubject import ch.tutteli.atrium.api.fluent.en_GB.feature -import ch.tutteli.atrium.api.fluent.en_GB.size import ch.tutteli.atrium.api.fluent.en_GB.toBeLessThan import ch.tutteli.atrium.api.fluent.en_GB.toEqual -import ch.tutteli.atrium.api.fluent.en_GB.toHaveElementsAndAll -import ch.tutteli.atrium.api.fluent.en_GB.toHaveElementsAndNone -import ch.tutteli.atrium.api.fluent.en_GB.toHaveSize import ch.tutteli.atrium.api.verbs.expect import kotlin.test.Test diff --git a/composeApp/src/commonTest/kotlin/domain/NeighbourClueTest.kt b/domain/src/test/kotlin/ch/dissem/yaep/domain/NeighbourClueTest.kt similarity index 99% rename from composeApp/src/commonTest/kotlin/domain/NeighbourClueTest.kt rename to domain/src/test/kotlin/ch/dissem/yaep/domain/NeighbourClueTest.kt index aedbcf7..d16ac83 100644 --- a/composeApp/src/commonTest/kotlin/domain/NeighbourClueTest.kt +++ b/domain/src/test/kotlin/ch/dissem/yaep/domain/NeighbourClueTest.kt @@ -1,4 +1,4 @@ -package domain +package ch.dissem.yaep.domain import ch.tutteli.atrium.api.fluent.en_GB.toEqual import ch.tutteli.atrium.api.verbs.expect diff --git a/composeApp/src/commonTest/kotlin/domain/OrderClueTest.kt b/domain/src/test/kotlin/ch/dissem/yaep/domain/OrderClueTest.kt similarity index 96% rename from composeApp/src/commonTest/kotlin/domain/OrderClueTest.kt rename to domain/src/test/kotlin/ch/dissem/yaep/domain/OrderClueTest.kt index be919a7..e94a775 100644 --- a/composeApp/src/commonTest/kotlin/domain/OrderClueTest.kt +++ b/domain/src/test/kotlin/ch/dissem/yaep/domain/OrderClueTest.kt @@ -1,4 +1,4 @@ -package domain +package ch.dissem.yaep.domain import ch.tutteli.atrium.api.fluent.en_GB.toEqual import ch.tutteli.atrium.api.verbs.expect diff --git a/composeApp/src/commonTest/kotlin/domain/SameColumnClueTest.kt b/domain/src/test/kotlin/ch/dissem/yaep/domain/SameColumnClueTest.kt similarity index 99% rename from composeApp/src/commonTest/kotlin/domain/SameColumnClueTest.kt rename to domain/src/test/kotlin/ch/dissem/yaep/domain/SameColumnClueTest.kt index 12d5db0..e8b5d71 100644 --- a/composeApp/src/commonTest/kotlin/domain/SameColumnClueTest.kt +++ b/domain/src/test/kotlin/ch/dissem/yaep/domain/SameColumnClueTest.kt @@ -1,4 +1,4 @@ -package domain +package ch.dissem.yaep.domain import ch.tutteli.atrium.api.fluent.en_GB.toEqual import ch.tutteli.atrium.api.verbs.expect diff --git a/composeApp/src/commonTest/kotlin/domain/TripletClueTest.kt b/domain/src/test/kotlin/ch/dissem/yaep/domain/TripletClueTest.kt similarity index 99% rename from composeApp/src/commonTest/kotlin/domain/TripletClueTest.kt rename to domain/src/test/kotlin/ch/dissem/yaep/domain/TripletClueTest.kt index ee01b33..c0e2fe6 100644 --- a/composeApp/src/commonTest/kotlin/domain/TripletClueTest.kt +++ b/domain/src/test/kotlin/ch/dissem/yaep/domain/TripletClueTest.kt @@ -1,4 +1,4 @@ -package domain +package ch.dissem.yaep.domain import ch.tutteli.atrium.api.fluent.en_GB.toEqual import ch.tutteli.atrium.api.verbs.expect diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index b8bd4f3..2ae44df 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -1,5 +1,5 @@ [versions] -agp = "8.3.2" +agp = "8.5.0" android-compileSdk = "34" android-minSdk = "24" android-targetSdk = "34" @@ -10,9 +10,6 @@ kotlin = "2.0.0" [libraries] androidx-activity-compose = { module = "androidx.activity:activity-compose", version.ref = "androidx-activityCompose" } -compose-ui-tooling = { module = "androidx.compose.ui:ui-tooling", version.ref = "compose" } -compose-ui-tooling-preview = { module = "androidx.compose.ui:ui-tooling-preview", version.ref = "compose" } -compose-ui-text-googlefonts = { module = "androidx.compose.ui:ui-text-google-fonts", version.ref = "compose" } kotlin-test = { module = "org.jetbrains.kotlin:kotlin-test", version.ref = "kotlin" } atrium = { module = "ch.tutteli.atrium:atrium-fluent", version = "1.2.0" } @@ -21,5 +18,5 @@ androidApplication = { id = "com.android.application", version.ref = "agp" } androidLibrary = { id = "com.android.library", version.ref = "agp" } jetbrainsKotlinCompose = { id = "org.jetbrains.kotlin.plugin.compose", version.ref = "kotlin" } jetbrainsCompose = { id = "org.jetbrains.compose", version.ref = "compose-plugin" } -kotlinMultiplatform = { id = "org.jetbrains.kotlin.multiplatform", version.ref = "kotlin" } -jetbrainsKotlinJvm = { id = "org.jetbrains.kotlin.jvm", version.ref = "kotlin" } \ No newline at end of file +kotlin-multiplatform = { id = "org.jetbrains.kotlin.multiplatform", version.ref = "kotlin" } +kotlin-jvm = { id = "org.jetbrains.kotlin.jvm", version.ref = "kotlin" } \ No newline at end of file diff --git a/settings.gradle.kts b/settings.gradle.kts index f8b61e6..0e654dd 100644 --- a/settings.gradle.kts +++ b/settings.gradle.kts @@ -30,4 +30,7 @@ dependencyResolutionManagement { } } -include(":composeApp") +include(":domain") +include(":commonUI") +include(":desktop") +include(":android")