Open kd1398 opened 3 months ago
Hey @kd1398 thanks for reporting this, do you mind sharing a dummy sample phone number and country code used?
Yeah sure, Country code: +1 (CA) Phone number: 2277999888
Just pasted the number and I can see it is valid
Okay got it, which API level are using on your emulator so that I can try and replicate the issue on my end?
Sorry for deleting the above video. I am using VanillaIceCream version and device is Pixel 7 Pro API VanillaIceCream
Hey @kd1398 ,
I have tried replicating this issue without success. For now, I have added null safety to the phone number transformer to unblock you. I will keep this issue open to investigate it further.
Kindly try updating the library to version 1.2.5 and let me know if you are still experiencing the crash.
Thank you for testing. But in both versions of the API it is crashing with same error
I'd advise you to create a simple project with only the Kompose picker for replication, if it still does not work, push the code to GitHub so that I can check it out
Okay I can test that and let you know but I am not able to understand what causing this issue?
Hello I tried on different project and it worked but i found out that I am using implementation("androidx.compose.foundation:foundation-layout:1.7.0-beta04") for ContextualFlowRow composable and this is not compatible with this. So if I removed that dependency it was working fine.
So, can you please look into it. Thank you
I also facing same issue. And on entering phone number. App crashing. And same I facing issue due to navigation compose and hilt navigation compose implementation(libs.androidx.navigation.compose) implementation(libs.androidx.hilt.navigation.compose)
Is it the same reason as this one - https://github.com/joelkanyi/kompose-country-code-picker/issues/73#issuecomment-2261125508
Using some alpha or beta version of a certain library?
I encountered an issue while using the KomposeCountryCodePicker in my application. When I try to input a more than 8-digit into the field, the application throws an IllegalStateException with the following message:
This error seems to occur due to an invalid mapping being returned by the OffsetMapping.transformedToOriginal method. It appears that the method is trying to map the offset 0 from the transformed text to -1 in the original text, which is not a valid offset.
Steps to reproduce:
Expected behavior: The application should allow the user to input a 10-digit phone number without any issues.
Actual behavior: The application throws an IllegalStateException when the user tries to input a 10-digit phone number.
I am using the following environment:
I would appreciate any help in resolving this issue. Thank you.