Open feivur opened 3 weeks ago
We are also experiencing case 1. This issue seems to be a follow up to this issue/PR/comment.
I our case it also happens without clustering (also on v6.1.2):
MyGoogleMap(
cameraPositionState = cameraPositionState,
uiSettings = MapUiSettings(
compassEnabled = false,
indoorLevelPickerEnabled = false,
mapToolbarEnabled = false,
myLocationButtonEnabled = false,
rotationGesturesEnabled = false,
scrollGesturesEnabled = false,
scrollGesturesEnabledDuringRotateOrZoom = false,
tiltGesturesEnabled = false,
zoomControlsEnabled = false,
zoomGesturesEnabled = false,
),
liteMode = true,
modifier = Modifier
.height(115.dp)
.fillMaxWidth(),
) {
val markerState = remember(coordinates) { MarkerState(position = coordinates) }
MarkerComposable(
state = markerState,
title = stringResource(R.string.some_description),
) {
Icon(
imageVector = MyDrawables.MapMarker,
contentDescription = null,
tint = Color.Blue,
modifier = Modifier.size(16.dp),
)
}
}
I am already defining a size
for the icon, so my only idea would be to use requiredSize
instead to ignore any incoming constraints. Do you think that would help? Unfortunately this issue is relatively rare and we could not reproduce it yet locally, only ours users are able to get it.
Is your feature request related to a problem? Please describe. Now we cannot use Marker or MarkerComposable in blocks clusterContent and clusterItemContent of Clustering (com.google.maps.android.compose.clustering.Clustering) Therefore, it is not possible to drag and drop custom markers.
Describe the solution you'd like I want to use features together: custom markers, dragging and clustering.
MarkerComposableinside Clustering leads to a crash: case 1 java.lang.IllegalStateException: The ComposeView was measured to have a width or height of zero. Make sure that the content has a non-zero size.
Marker inside Clustering leads to a crash: case 2 java.lang.IllegalStateException: Invalid applier
maps-compose version is 6.1.2
Case 1
Case 2