Package-level declarations

Types

Link copied to clipboard

CountryCodePicker is an interface that provides the different utilities for the country code picker.

Functions

Link copied to clipboard
fun CountrySelectionDialog(countryList: List<Country>, containerColor: Color, contentColor: Color, onDismissRequest: () -> Unit, onSelect: (item: Country) -> Unit, modifier: Modifier = Modifier, properties: DialogProperties = DialogProperties( usePlatformDefaultWidth = false, ), title: @Composable () -> Unit = { Text( modifier = Modifier .offset(y = (-2).dp) .qaAutomationTestTag("countryDialogTitle"), text = stringResource(Res.string.select_country), style = MaterialTheme.typography.titleMedium, color = contentColor, ) }, backIcon: @Composable () -> Unit = { Icon( painter = painterResource(Res.drawable.ic_arrow_back), contentDescription = "Back", tint = contentColor, ) }, searchIcon: @Composable () -> Unit = { Icon( painter = painterResource(Res.drawable.ic_search), contentDescription = "Search", tint = contentColor, ) })

CountrySelectionDialog is a composable that displays a dialog for selecting a country.

Link copied to clipboard
fun KomposeCountryCodePicker(state: CountryCodePicker, text: String, modifier: Modifier = Modifier, onValueChange: (String) -> Unit = {}, error: Boolean = false, showOnlyCountryCodePicker: Boolean = false, shape: Shape = MaterialTheme.shapes.medium, placeholder: @Composable (defaultLang: String) -> Unit = { defaultLang -> DefaultPlaceholder(defaultLang) }, colors: TextFieldColors = TextFieldDefaults.colors(), trailingIcon: @Composable () -> Unit? = null, countrySelectionDialogContainerColor: Color = MaterialTheme.colorScheme.background, countrySelectionDialogContentColor: Color = MaterialTheme.colorScheme.onBackground, countrySelectionDialogTitle: @Composable () -> Unit = { Text( modifier = Modifier .offset(y = (-2).dp) .qaAutomationTestTag("countryDialogTitle"), text = stringResource(Res.string.select_country), style = MaterialTheme.typography.titleMedium, color = countrySelectionDialogContentColor, ) }, countrySelectionDialogBackIcon: @Composable () -> Unit = { Icon( painter = painterResource(Res.drawable.ic_arrow_back), contentDescription = "Back", tint = countrySelectionDialogContentColor, ) }, countrySelectionDialogSearchIcon: @Composable () -> Unit = { Icon( painter = painterResource(Res.drawable.ic_search), contentDescription = "Search", tint = countrySelectionDialogContentColor, ) }, interactionSource: MutableInteractionSource = MutableInteractionSource(), selectedCountryFlagSize: FlagSize = FlagSize(28.dp, 18.dp), textStyle: TextStyle = LocalTextStyle.current, enabled: Boolean = true, keyboardOptions: KeyboardOptions = KeyboardOptions.Default.copy( keyboardType = KeyboardType.Phone, imeAction = ImeAction.Next, ), keyboardActions: KeyboardActions = KeyboardActions.Default)

KomposeCountryCodePicker is a composable that displays a text field with a country code picker dialog.

Link copied to clipboard
fun rememberKomposeCountryCodePickerState(defaultCountryCode: String? = null, limitedCountries: List<String> = emptyList(), priorityCountries: List<String> = emptyList(), showCountryCode: Boolean = true, showCountryFlag: Boolean = true): CountryCodePicker

Creates a CountryCodePicker that is remembered across compositions.