Skip to content

Commit

Permalink
Merge pull request #3 from ding1dingx/dev
Browse files Browse the repository at this point in the history
Dev
  • Loading branch information
syxc authored Oct 27, 2024
2 parents a165af7 + 376aa08 commit 4af4447
Show file tree
Hide file tree
Showing 10 changed files with 27 additions and 11 deletions.
7 changes: 5 additions & 2 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,11 @@ indent_size = 2
indent_style = space
insert_final_newline = true
trim_trailing_whitespace = true
max_line_length = 100

[*.java]
ij_java_use_single_class_imports = true
max_line_length = 120

[*.{kt,kts}]
ij_kotlin_imports_layout = *
Expand All @@ -20,8 +22,9 @@ ktlint_standard_property-naming = disabled
ktlint_standard_backing-property-naming = disabled
ktlint_function_naming_ignore_when_annotated_with = Composable, Test

[*.md]
[*.{md,mdx,diff}]
trim_trailing_whitespace = false

[Makefile]
indent_style = tab
indent_size = 4
indent_style = tab
2 changes: 1 addition & 1 deletion .idea/kotlinc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions build-logic/convention/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ repositories {
mavenCentral()
gradlePluginPortal()
google()
maven("https://maven.aliyun.com/repository/public")
maven("https://maven.aliyun.com/repository/gradle-plugin")
maven("https://maven.aliyun.com/repository/google")
}

group = "com.jithub.app.build-logic"
Expand Down
5 changes: 5 additions & 0 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@ buildscript {
}
}
gradlePluginPortal()
maven("https://maven.aliyun.com/repository/public")
maven("https://maven.aliyun.com/repository/google")
maven("https://maven.aliyun.com/repository/gradle-plugin")
}
dependencies {
classpath(libs.redwood.gradle.plugin)
Expand Down Expand Up @@ -38,6 +41,8 @@ allprojects {
includeGroupAndSubgroups("com.google")
}
}
maven("https://maven.aliyun.com/repository/public")
maven("https://maven.aliyun.com/repository/google")
maven("https://jitpack.io")
}
apply(plugin = "com.jithub.gradle.build-support")
Expand Down
6 changes: 3 additions & 3 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
[versions]
kotlin = "2.0.20"
kotlin = "2.0.21"
agp = "8.2.2"
redwood = "0.14.0"
redwood = "0.15.0"

androidx-activityCompose = "1.9.1"
androidx-appcompat = "1.7.0"
androidx-constraintlayout = "2.1.4"
androidx-core-ktx = "1.13.1"
androidx-material = "1.12.0"

jbr-compose = "1.6.11"
jbr-compose = "1.7.0"

androidx-espresso-core = "3.6.1"
androidx-test-junit = "1.2.1"
Expand Down
2 changes: 1 addition & 1 deletion gradle/moko.versions.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[versions]
# https://repo.maven.apache.org/maven2/dev/icerock/moko/resources/
resources = "0.24.2"
resources = "0.24.3"

[plugins]

Expand Down
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.8-bin.zip
distributionUrl=https\://mirrors.aliyun.com/macports/distfiles/gradle/gradle-8.8-bin.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
package com.jithub.app.shared.redwood

import app.cash.redwood.layout.RedwoodLayout
import app.cash.redwood.schema.Default
import app.cash.redwood.schema.Property
import app.cash.redwood.schema.Schema
import app.cash.redwood.schema.Schema.Dependency
Expand All @@ -27,7 +26,6 @@ data class Text(@Property(1) val text: String?)
data class Button(
@Property(1) val text: String?,
@Property(2)
@Default("true")
val enabled: Boolean = true,
@Property(3) val onClick: (() -> Unit)? = null,
)
3 changes: 3 additions & 0 deletions settings.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ pluginManagement {
}
}
gradlePluginPortal()
maven("https://maven.aliyun.com/repository/public")
maven("https://maven.aliyun.com/repository/google")
maven("https://maven.aliyun.com/repository/gradle-plugin")
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,11 @@ import com.jithub.app.shared.redwood.compose.Button
import com.jithub.app.shared.redwood.compose.Text

@Composable
fun Counter(modifier: Modifier = Modifier, value: Int = 0, labels: StringList? = StringList(listOf())) {
fun Counter(
modifier: Modifier = Modifier,
value: Int = 0,
labels: StringList? = StringList(listOf()),
) {
var count by rememberSaveable { mutableIntStateOf(value) }
Column(
width = Constraint.Fill,
Expand Down

0 comments on commit 4af4447

Please sign in to comment.