Skip to content

Commit 516232b

Browse files
committed
fixed compatibility issues
1 parent b226b99 commit 516232b

File tree

9 files changed

+30
-17
lines changed

9 files changed

+30
-17
lines changed

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,10 @@
2626
- 🏳️ Includes country flags
2727

2828
## Download
29+
[![Maven Central](https://img.shields.io/maven-central/v/io.github.androidpoet/countrypicker.svg?label=Maven%20Central)](https://search.maven.org/search?q=g:%22io.github.androidpoet%22%20AND%20a:%22countrypicker%22)
30+
31+
### Gradle
32+
2933

3034
Add the dependency below to your **module**'s `build.gradle` file:
3135

buildSrc/src/main/kotlin/io/androidpoet/countrypicker/Configuration.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ object Configuration {
66
const val minSdk = 21
77
const val majorVersion = 0
88
const val minorVersion = 1
9-
const val patchVersion = 1
9+
const val patchVersion = 2
1010
const val versionName = "$majorVersion.$minorVersion.$patchVersion"
1111
const val versionCode = 1
1212
const val snapshotVersionName = "$majorVersion.$minorVersion.${patchVersion + 1}-SNAPSHOT"

countrypicker/api/android/countrypicker.api

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ public final class io/androidpoet/countrypicker/Country$Companion {
5454
}
5555

5656
public final class io/androidpoet/countrypicker/CountryPickerKt {
57-
public static final fun CountryPicker (Lkotlin/jvm/functions/Function1;ZLkotlin/jvm/functions/Function0;Landroidx/compose/runtime/Composer;I)V
57+
public static final fun CountryPicker-vtnTUvE (Lkotlin/jvm/functions/Function1;ZLkotlin/jvm/functions/Function0;ZJJJLandroidx/compose/runtime/Composer;II)V
5858
}
5959

6060
public final class io/androidpoet/countrypicker/CountryPickerState {

countrypicker/api/desktop/countrypicker.api

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ public final class io/androidpoet/countrypicker/Country$Companion {
5454
}
5555

5656
public final class io/androidpoet/countrypicker/CountryPickerKt {
57-
public static final fun CountryPicker (Lkotlin/jvm/functions/Function1;ZLkotlin/jvm/functions/Function0;Landroidx/compose/runtime/Composer;I)V
57+
public static final fun CountryPicker-vtnTUvE (Lkotlin/jvm/functions/Function1;ZLkotlin/jvm/functions/Function0;ZJJJLandroidx/compose/runtime/Composer;II)V
5858
}
5959

6060
public final class io/androidpoet/countrypicker/CountryPickerState {

countrypicker/build.gradle.kts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,6 @@ kotlin {
8484
implementation(compose.material3)
8585
implementation(compose.runtime)
8686
implementation(compose.animation)
87-
implementation(compose.foundation)
8887
implementation(compose.components.resources)
8988
implementation(libs.kotlinx.serialization.json)
9089
implementation(libs.kotlin.codepoints.deluxe)

countrypicker/src/commonMain/kotlin/io/androidpoet/countrypicker/Country.kt

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,14 +14,15 @@
1414
* limitations under the License.
1515
*/
1616
package io.androidpoet.countrypicker
17+
1718
import kotlinx.serialization.Serializable
1819

1920
@Serializable
2021
public data class Country(
2122
val name: String,
2223
val alpha2: String,
2324
val phoneCountryCode: String,
24-
val localeForICU: String? = null, // Optional fields
25-
val currencyCode: String? = null, // Optional fields
25+
val localeForICU: String? = null,
26+
val currencyCode: String? = null,
2627
val flag: String? = null,
2728
)

countrypicker/src/commonMain/kotlin/io/androidpoet/countrypicker/CountryUtils.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ internal object CountryUtils {
3030
}
3131
}
3232
}
33-
33+
3434
internal fun loadCountries(jsonString: String): List<Country> =
3535
runCatching {
3636
Json

countrypicker/src/commonMain/resources/files/countries.json

Lines changed: 18 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2,47 +2,56 @@
22
{
33
"name": "Afghanistan",
44
"alpha2": "AF",
5-
"phoneCountryCode": "+93"
5+
"phoneCountryCode": "+93",
6+
"currencyCode": "AFN"
67
},
78
{
89
"name": "Aland Islands",
910
"alpha2": "AX",
10-
"phoneCountryCode": "+358"
11+
"phoneCountryCode": "+358",
12+
"currencyCode": "EUR"
1113
},
1214
{
1315
"name": "Albania",
1416
"alpha2": "AL",
15-
"phoneCountryCode": "+355"
17+
"phoneCountryCode": "+355",
18+
"currencyCode": "ALL"
1619
},
1720
{
1821
"name": "Algeria",
1922
"alpha2": "DZ",
20-
"phoneCountryCode": "+213"
23+
"phoneCountryCode": "+213",
24+
"currencyCode": "DZD"
2125
},
2226
{
2327
"name": "American Samoa",
2428
"alpha2": "AS",
25-
"phoneCountryCode": "+1 684"
29+
"phoneCountryCode": "+1 684",
30+
"currencyCode": "USD"
2631
},
2732
{
2833
"name": "Andorra",
2934
"alpha2": "AD",
30-
"phoneCountryCode": "+376"
35+
"phoneCountryCode": "+376",
36+
"currencyCode": "EUR"
3137
},
3238
{
3339
"name": "Angola",
3440
"alpha2": "AO",
35-
"phoneCountryCode": "+244"
41+
"phoneCountryCode": "+244",
42+
"currencyCode": "AOA"
3643
},
3744
{
3845
"name": "Anguilla",
3946
"alpha2": "AI",
40-
"phoneCountryCode": "+1 264"
47+
"phoneCountryCode": "+1 264",
48+
"currencyCode": "XCD"
4149
},
4250
{
4351
"name": "Antarctica",
4452
"alpha2": "AQ",
45-
"phoneCountryCode": "+672"
53+
"phoneCountryCode": "+672",
54+
"currencyCode": "Various"
4655
},
4756
{
4857
"name": "Antigua and Barbuda",

gradle/libs.versions.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ nexusPlugin = "0.29.0"
55
kotlin = "2.0.20"
66
kotlinBinaryCompatibility = "0.16.3"
77
jvmTarget = "11"
8-
androidxComposeBom = "2024.08.00"
8+
androidxComposeBom = "2024.09.01"
99
androidxActivity = "1.9.1"
1010
androidxTest = "1.6.2"
1111
baselineProfiles = "1.3.1"

0 commit comments

Comments
 (0)