|
@@ -7,7 +7,6 @@ import androidx.compose.foundation.selection.selectable
|
|
import androidx.compose.foundation.shape.CircleShape
|
|
import androidx.compose.foundation.shape.CircleShape
|
|
import androidx.compose.material.icons.Icons
|
|
import androidx.compose.material.icons.Icons
|
|
import androidx.compose.material.icons.filled.Close
|
|
import androidx.compose.material.icons.filled.Close
|
|
-import androidx.compose.material.icons.filled.Info
|
|
|
|
import androidx.compose.material.icons.filled.Person
|
|
import androidx.compose.material.icons.filled.Person
|
|
import androidx.compose.material.icons.filled.Search
|
|
import androidx.compose.material.icons.filled.Search
|
|
import androidx.compose.material.icons.filled.Verified
|
|
import androidx.compose.material.icons.filled.Verified
|
|
@@ -215,9 +214,7 @@ fun SearchResultList(
|
|
.size(48.dp)
|
|
.size(48.dp)
|
|
.clip(CircleShape)
|
|
.clip(CircleShape)
|
|
.background(Color.LightGray),
|
|
.background(Color.LightGray),
|
|
-// .padding(8.dp),
|
|
|
|
error = rememberVectorPainter(image = Icons.Default.Person),
|
|
error = rememberVectorPainter(image = Icons.Default.Person),
|
|
-// colorFilter = ColorFilter.tint(Color.White)
|
|
|
|
)
|
|
)
|
|
}
|
|
}
|
|
)
|
|
)
|
|
@@ -227,13 +224,27 @@ fun SearchResultList(
|
|
val buddy = list[selectedItem]
|
|
val buddy = list[selectedItem]
|
|
AlertDialog(
|
|
AlertDialog(
|
|
icon = {
|
|
icon = {
|
|
- Icon(Icons.Default.Info, contentDescription = "Example Icon")
|
|
|
|
|
|
+ AsyncImage(
|
|
|
|
+ model = ImageRequest.Builder(LocalContext.current)
|
|
|
|
+ .data("https://digixplatform.com/filepalio/image/${buddy.image_id}")
|
|
|
|
+ .addHeader("Cookie", "PHPSESSID=123;MOBILE=123")
|
|
|
|
+ .crossfade(true)
|
|
|
|
+ .build(),
|
|
|
|
+ placeholder = rememberVectorPainter(image = Icons.Default.Person),
|
|
|
|
+ contentDescription = "",
|
|
|
|
+ contentScale = ContentScale.Crop,
|
|
|
|
+ modifier = Modifier
|
|
|
|
+ .size(48.dp)
|
|
|
|
+ .clip(CircleShape)
|
|
|
|
+ .background(Color.LightGray),
|
|
|
|
+ error = rememberVectorPainter(image = Icons.Default.Person),
|
|
|
|
+ )
|
|
},
|
|
},
|
|
title = {
|
|
title = {
|
|
- Text(text = "Add contact")
|
|
|
|
|
|
+ Text(text = "Add contact?")
|
|
},
|
|
},
|
|
text = {
|
|
text = {
|
|
- Text(text = "Do you want add ${buddy.first_name} to your contact?")
|
|
|
|
|
|
+ Text(text = "Contact will show in the list and can't be removed")
|
|
},
|
|
},
|
|
onDismissRequest = {
|
|
onDismissRequest = {
|
|
openAlertDialog.value = false
|
|
openAlertDialog.value = false
|
|
@@ -244,7 +255,7 @@ fun SearchResultList(
|
|
viewModel.addFriend(buddy.f_pin)
|
|
viewModel.addFriend(buddy.f_pin)
|
|
}
|
|
}
|
|
) {
|
|
) {
|
|
- Text("Confirm")
|
|
|
|
|
|
+ Text("Add")
|
|
}
|
|
}
|
|
},
|
|
},
|
|
dismissButton = {
|
|
dismissButton = {
|