Skip to content

Commit 6201d50

Browse files
committed
Fix version update issues
1 parent c15202c commit 6201d50

File tree

17 files changed

+71
-42
lines changed

17 files changed

+71
-42
lines changed

JetLagged/app/build.gradle.kts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,8 +72,10 @@ android {
7272
isDebuggable = false
7373
}
7474
}
75-
kotlinOptions {
76-
jvmTarget = "17"
75+
kotlin {
76+
compilerOptions {
77+
jvmTarget = JvmTarget.fromTarget("17")
78+
}
7779
}
7880

7981
compileOptions {

JetNews/app/build.gradle.kts

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
2+
13
/*
24
* Copyright 2020 The Android Open Source Project
35
*
@@ -61,8 +63,10 @@ android {
6163
)
6264
}
6365
}
64-
kotlinOptions {
65-
jvmTarget = "17"
66+
kotlin {
67+
compilerOptions {
68+
jvmTarget = JvmTarget.fromTarget("17")
69+
}
6670
}
6771

6872
compileOptions {

JetNews/app/src/main/java/com/example/jetnews/ui/article/PostContent.kt

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -147,10 +147,7 @@ private fun PostMetadata(metadata: Metadata, modifier: Modifier = Modifier) {
147147
Text(
148148
text = stringResource(
149149
id = R.string.article_post_min_read,
150-
formatArgs = arrayOf(
151-
metadata.date,
152-
metadata.readTimeMinutes,
153-
),
150+
metadata.date, metadata.readTimeMinutes,
154151
),
155152
style = MaterialTheme.typography.bodySmall,
156153
)
@@ -174,18 +171,21 @@ private fun Paragraph(paragraph: Paragraph) {
174171
textStyle = textStyle,
175172
paragraphStyle = paragraphStyle,
176173
)
174+
177175
ParagraphType.CodeBlock -> CodeBlockParagraph(
178176
text = annotatedString,
179177
textStyle = textStyle,
180178
paragraphStyle = paragraphStyle,
181179
)
180+
182181
ParagraphType.Header -> {
183182
Text(
184183
modifier = Modifier.padding(4.dp),
185184
text = annotatedString,
186185
style = textStyle.merge(paragraphStyle),
187186
)
188187
}
188+
189189
else -> Text(
190190
modifier = Modifier.padding(4.dp),
191191
text = annotatedString,
@@ -251,16 +251,20 @@ private fun ParagraphType.getTextAndParagraphStyle(): ParagraphStyling {
251251
textStyle = typography.headlineSmall
252252
trailingPadding = 16.dp
253253
}
254+
254255
ParagraphType.Text -> {
255256
textStyle = typography.bodyLarge.copy(lineHeight = 28.sp)
256257
}
258+
257259
ParagraphType.Header -> {
258260
textStyle = typography.headlineMedium
259261
trailingPadding = 16.dp
260262
}
263+
261264
ParagraphType.CodeBlock -> textStyle = typography.bodyLarge.copy(
262265
fontFamily = FontFamily.Monospace,
263266
)
267+
264268
ParagraphType.Quote -> textStyle = typography.bodyLarge
265269
ParagraphType.Bullet -> {
266270
paragraphStyle = ParagraphStyle(textIndent = TextIndent(firstLine = 8.sp))
@@ -288,20 +292,23 @@ fun Markup.toAnnotatedStringItem(typography: Typography, codeBlockBackground: Co
288292
end,
289293
)
290294
}
295+
291296
MarkupType.Link -> {
292297
AnnotatedString.Range(
293298
typography.bodyLarge.copy(textDecoration = TextDecoration.Underline).toSpanStyle(),
294299
start,
295300
end,
296301
)
297302
}
303+
298304
MarkupType.Bold -> {
299305
AnnotatedString.Range(
300306
typography.bodyLarge.copy(fontWeight = FontWeight.Bold).toSpanStyle(),
301307
start,
302308
end,
303309
)
304310
}
311+
305312
MarkupType.Code -> {
306313
AnnotatedString.Range(
307314
typography.bodyLarge

JetNews/app/src/main/java/com/example/jetnews/ui/home/PostCardTop.kt

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -74,10 +74,8 @@ fun PostCardTop(post: Post, modifier: Modifier = Modifier) {
7474
Text(
7575
text = stringResource(
7676
id = R.string.home_post_min_read,
77-
formatArgs = arrayOf(
78-
post.metadata.date,
79-
post.metadata.readTimeMinutes,
80-
),
77+
post.metadata.date,
78+
post.metadata.readTimeMinutes,
8179
),
8280
style = typography.bodySmall,
8381
)

JetNews/app/src/main/java/com/example/jetnews/ui/home/PostCardYourNetwork.kt

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -86,10 +86,8 @@ fun PostCardPopular(post: Post, navigateToArticle: (String) -> Unit, modifier: M
8686
Text(
8787
text = stringResource(
8888
id = R.string.home_post_min_read,
89-
formatArgs = arrayOf(
90-
post.metadata.date,
91-
post.metadata.readTimeMinutes,
92-
),
89+
post.metadata.date,
90+
post.metadata.readTimeMinutes,
9391
),
9492
style = MaterialTheme.typography.bodySmall,
9593
)

JetNews/app/src/main/java/com/example/jetnews/ui/home/PostCards.kt

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -57,10 +57,8 @@ fun AuthorAndReadTime(post: Post, modifier: Modifier = Modifier) {
5757
Text(
5858
text = stringResource(
5959
id = R.string.home_post_min_read,
60-
formatArgs = arrayOf(
61-
post.metadata.author.name,
62-
post.metadata.readTimeMinutes,
63-
),
60+
post.metadata.author.name,
61+
post.metadata.readTimeMinutes,
6462
),
6563
style = MaterialTheme.typography.bodyMedium,
6664
)

Jetcaster/core/data-testing/build.gradle.kts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,10 @@ android {
5151
sourceCompatibility = JavaVersion.VERSION_17
5252
targetCompatibility = JavaVersion.VERSION_17
5353
}
54-
kotlinOptions {
55-
jvmTarget = "17"
54+
kotlin {
55+
compilerOptions {
56+
jvmTarget = JvmTarget.fromTarget("17")
57+
}
5658
}
5759
}
5860
dependencies {

Jetcaster/core/data/build.gradle.kts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,10 @@ android {
5454
sourceCompatibility = JavaVersion.VERSION_17
5555
targetCompatibility = JavaVersion.VERSION_17
5656
}
57-
kotlinOptions {
58-
jvmTarget = "17"
57+
kotlin {
58+
compilerOptions {
59+
jvmTarget = JvmTarget.fromTarget("17")
60+
}
5961
}
6062
}
6163
dependencies {

Jetcaster/core/designsystem/build.gradle.kts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,8 +56,10 @@ android {
5656
targetCompatibility = JavaVersion.VERSION_17
5757
}
5858

59-
kotlinOptions {
60-
jvmTarget = "17"
59+
kotlin {
60+
compilerOptions {
61+
jvmTarget = JvmTarget.fromTarget("17")
62+
}
6163
}
6264
}
6365

Jetcaster/core/domain-testing/build.gradle.kts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,10 @@ android {
4646
)
4747
}
4848
}
49-
kotlinOptions {
50-
jvmTarget = "17"
49+
kotlin {
50+
compilerOptions {
51+
jvmTarget = JvmTarget.fromTarget("17")
52+
}
5153
}
5254
compileOptions {
5355
isCoreLibraryDesugaringEnabled = true

0 commit comments

Comments
 (0)