android-maps-compose icon indicating copy to clipboard operation
android-maps-compose copied to clipboard

Cannot add shadow to custom Marker info content

Open MaxMichel2 opened this issue 2 years ago • 3 comments

Environment details

  1. Specify the API at the beginning of the title (for example, "Places: ...") - Maps directly
  2. OS type and version - Android 10+
  3. Library version and other environment information - google.android.maps-compose=2.11.4

Steps to reproduce

  1. Create a custom content in a MarkerInfoWindow and apply a shadow Modifier to it
  2. The shadow isn't applied and doesn't appear anywhere on the info window

MaxMichel2 avatar May 17 '23 14:05 MaxMichel2

If you would like to upvote the priority of this issue, please comment below or react with :+1: so we can see what is popular when we triage.

@MaxMichel2 Thank you for opening this issue. 🙏 Please check out these other resources that might help you get to a resolution in the meantime:

This is an automated message, feel free to ignore.

wangela avatar May 17 '23 14:05 wangela

@MaxMichel2 , can you provide us with a code sample?

kikoso avatar Aug 15 '23 05:08 kikoso

Hi @kikoso I can provide a sample.

MarkerInfoWindow(
        state = MarkerState(location),
        icon = if (isSelected) selectedDescriptor else unselectedDescriptor,
        onClick = {
            isSelected = true
            false
        },
        onInfoWindowClick = {

        },
        onInfoWindowClose = {
            isSelected = false
        }
    ) {
        // Has 8.dp of elevation
        CustomElevatedCard (
            modifier = Modifier
                .padding(horizontal = 24.dp)
        )
        // Also tried wrapping this in a container with shadow modifier w/ no luck 
    }

Hope this is helpful

crgodfirnon avatar Nov 16 '23 18:11 crgodfirnon