refactor: split up core into multiple modules

This commit is contained in:
Cilly Leang 2026-02-05 01:05:02 +11:00
parent 2725342c3f
commit 0d84411f14
Signed by: cilly
GPG key ID: 6500251E087653C9
38 changed files with 344 additions and 149 deletions

14
common/build.gradle.kts Normal file
View file

@ -0,0 +1,14 @@
plugins {
alias(libs.plugins.kotlinMultiplatform)
alias(libs.plugins.kotlinSerialization)
}
kotlin {
jvm()
sourceSets {
commonMain.dependencies {
implementation(libs.kotlinx.serialization.core)
}
}
}

View file

@ -0,0 +1,14 @@
package moe.lava.neon.common.captcha
import kotlinx.serialization.Serializable
@Serializable
data class CaptchaRequest(
val captchaKey: List<String>,
val captchaService: String,
val captchaSitekey: String?,
val captchaSessionId: String?,
val captchaRqdata: String?,
val captchaRqtoken: String?,
val shouldServeInvisible: Boolean? = false,
)

View file

@ -0,0 +1,6 @@
package moe.lava.neon.common.captcha
sealed class CaptchaResponse {
data class Success(val token: String) : CaptchaResponse()
data class Failed(val error: Throwable) : CaptchaResponse()
}