Update dokka, update resource extractor, update js wrapper versions, remove js from sample as gradle cant find libs when building
This commit is contained in:
12 files changed
+74
-145
No files matched your search
+52
-58
@@ -32,7 +32,6 @@ plugins {
|
||||
kotlin(PluginsDeps.kotlinSerializationPlugin) version Versions.kotlinSerializationPlugin
|
||||
|
||||
}
|
||||
org.jetbrains.kotlin.gradle.targets.js.npm.NpmResolverPlugin.apply(project)
|
||||
|
||||
val sonatypeStaging = "https://oss.sonatype.org/service/local/staging/deploy/maven2/"
|
||||
val sonatypeSnapshots = "https://oss.sonatype.org/content/repositories/snapshots/"
|
||||
@@ -41,8 +40,6 @@ val sonatypeSnapshots = "https://oss.sonatype.org/content/repositories/snapshots
|
||||
|
||||
repositories {
|
||||
mavenCentral()
|
||||
jcenter()
|
||||
maven("https://dl.bintray.com/terl/lazysodium-maven")
|
||||
maven("https://oss.sonatype.org/content/repositories/snapshots/")
|
||||
|
||||
}
|
||||
@@ -63,28 +60,28 @@ kotlin {
|
||||
android()
|
||||
runningOnLinuxx86_64 {
|
||||
jvm()
|
||||
js(IR) {
|
||||
browser {
|
||||
webpackTask {
|
||||
|
||||
}
|
||||
testTask {
|
||||
useKarma {
|
||||
useChrome()
|
||||
}
|
||||
}
|
||||
}
|
||||
nodejs {
|
||||
testTask {
|
||||
useMocha() {
|
||||
timeout = "10s"
|
||||
}
|
||||
}
|
||||
}
|
||||
// js(IR) {
|
||||
// browser {
|
||||
// webpackTask {
|
||||
//
|
||||
// }
|
||||
// testTask {
|
||||
// useKarma {
|
||||
// useChrome()
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// nodejs {
|
||||
// testTask {
|
||||
// useMocha() {
|
||||
// timeout = "10s"
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
|
||||
// binaries.executable()
|
||||
|
||||
}
|
||||
// }
|
||||
|
||||
|
||||
linuxX64("linux") {
|
||||
@@ -205,11 +202,7 @@ kotlin {
|
||||
implementation("androidx.core:core-ktx:1.3.2")
|
||||
implementation("androidx.constraintlayout:constraintlayout:2.0.2")
|
||||
implementation("com.google.android.material:material:1.3.0-alpha03")
|
||||
// implementation("androidx.ui:ui-tooling:$composeDevVersion")
|
||||
// implementation("androidx.ui:ui-layout:$composeDevVersion")
|
||||
// implementation("androidx.ui:ui-material:$composeDevVersion")
|
||||
// implementation("androidx.ui:ui-foundation:$composeDevVersion")
|
||||
// implementation("androidx.ui:ui-framework:$composeDevVersion")
|
||||
|
||||
implementation(Deps.Android.coroutines)
|
||||
implementation(Deps.Android.timber)
|
||||
// implementation("androidx.compose:compose-runtime:$composeDevVersion")
|
||||
@@ -244,7 +237,7 @@ kotlin {
|
||||
val nativeMain by getting {
|
||||
dependsOn(commonMain)
|
||||
dependencies {
|
||||
implementation(Deps.Desktop.libui)
|
||||
|
||||
}
|
||||
}
|
||||
nativeMain
|
||||
@@ -252,7 +245,7 @@ kotlin {
|
||||
val nativeMain by creating {
|
||||
dependsOn(commonMain)
|
||||
dependencies {
|
||||
implementation(Deps.Desktop.libui)
|
||||
|
||||
}
|
||||
}
|
||||
nativeMain
|
||||
@@ -291,29 +284,30 @@ kotlin {
|
||||
implementation(kotlin(Deps.Jvm.reflection))
|
||||
}
|
||||
}
|
||||
val jsMain by getting {
|
||||
dependencies {
|
||||
implementation(kotlin(Deps.Js.stdLib))
|
||||
implementation(Deps.Js.coroutines)
|
||||
|
||||
// React
|
||||
implementation(Deps.Js.React.react)
|
||||
implementation(Deps.Js.React.reactDom)
|
||||
implementation(npm(Deps.Js.Npm.reactPair.first, Deps.Js.Npm.reactPair.second))
|
||||
implementation(npm(Deps.Js.Npm.reactDomPair.first, Deps.Js.Npm.reactDomPair.second))
|
||||
|
||||
// Styled
|
||||
implementation(Deps.Js.React.styled)
|
||||
implementation(npm(Deps.Js.Npm.styledComponentsPair.first, Deps.Js.Npm.styledComponentsPair.second))
|
||||
implementation(npm(Deps.Js.Npm.inlineStylePrefixesPair.first, Deps.Js.Npm.inlineStylePrefixesPair.second))
|
||||
|
||||
}
|
||||
}
|
||||
val jsTest by getting {
|
||||
dependencies {
|
||||
implementation(kotlin(Deps.Js.test))
|
||||
}
|
||||
}
|
||||
// val jsMain by getting {
|
||||
// dependencies {
|
||||
// implementation(kotlin(Deps.Js.stdLib))
|
||||
// implementation(Deps.Js.coroutines)
|
||||
//
|
||||
//
|
||||
// // React
|
||||
// implementation(Deps.Js.React.react)
|
||||
// implementation(Deps.Js.React.reactDom)
|
||||
//// implementation(npm(Deps.Js.Npm.reactPair.first, Deps.Js.Npm.reactPair.second))
|
||||
//// implementation(npm(Deps.Js.Npm.reactDomPair.first, Deps.Js.Npm.reactDomPair.second))
|
||||
//
|
||||
// // Styled
|
||||
// implementation(Deps.Js.React.styled)
|
||||
//// implementation(npm(Deps.Js.Npm.styledComponentsPair.first, Deps.Js.Npm.styledComponentsPair.second))
|
||||
//// implementation(npm(Deps.Js.Npm.inlineStylePrefixesPair.first, Deps.Js.Npm.inlineStylePrefixesPair.second))
|
||||
//
|
||||
// }
|
||||
// }
|
||||
// val jsTest by getting {
|
||||
// dependencies {
|
||||
// implementation(kotlin(Deps.Js.test))
|
||||
// }
|
||||
// }
|
||||
|
||||
val linuxMain by getting {
|
||||
dependsOn(nativeMain)
|
||||
@@ -481,12 +475,12 @@ tasks {
|
||||
}
|
||||
}
|
||||
|
||||
val jsNodeTest by getting(KotlinJsTest::class) {
|
||||
testLogging {
|
||||
events("PASSED", "FAILED", "SKIPPED")
|
||||
showStandardStreams = true
|
||||
}
|
||||
}
|
||||
// val jsNodeTest by getting(KotlinJsTest::class) {
|
||||
// testLogging {
|
||||
// events("PASSED", "FAILED", "SKIPPED")
|
||||
// showStandardStreams = true
|
||||
// }
|
||||
// }
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
import com.ionspin.kotlin.crypto.hash.Hash
|
||||
import com.ionspin.kotlin.crypto.util.encodeToUByteArray
|
||||
import com.ionspin.kotlin.crypto.util.toHexString
|
||||
import kotlinx.css.br
|
||||
import react.RBuilder
|
||||
import react.RComponent
|
||||
import react.RProps
|
||||
|
||||
@@ -2,5 +2,4 @@ import com.ionspin.kotlin.crypto.sample.Sample
|
||||
|
||||
fun main() : Unit {
|
||||
Sample.runSample()
|
||||
ui()
|
||||
}
|
||||
@@ -1,30 +0,0 @@
|
||||
import com.ionspin.kotlin.crypto.hash.Hash
|
||||
import com.ionspin.kotlin.crypto.util.encodeToUByteArray
|
||||
import com.ionspin.kotlin.crypto.util.toHexString
|
||||
import libui.ktx.TextArea
|
||||
import libui.ktx.appWindow
|
||||
import libui.ktx.button
|
||||
import libui.ktx.textarea
|
||||
import libui.ktx.vbox
|
||||
|
||||
fun ui() = appWindow(
|
||||
title = "Hello",
|
||||
width = 320,
|
||||
height = 240
|
||||
) {
|
||||
val hash = Hash.sha512("123".encodeToUByteArray())
|
||||
val text = "Hash (SHA512) of 123: ${hash.toHexString()}"
|
||||
vbox {
|
||||
lateinit var scroll: TextArea
|
||||
|
||||
button("Test") {
|
||||
action {
|
||||
scroll.append(text.trimMargin())
|
||||
}
|
||||
}
|
||||
scroll = textarea {
|
||||
readonly = true
|
||||
stretchy = true
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user