Skip to content

Can't change size Marker #5531

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
maihuy243 opened this issue May 28, 2025 · 4 comments
Open

Can't change size Marker #5531

maihuy243 opened this issue May 28, 2025 · 4 comments
Labels
bug Something isn't working

Comments

@maihuy243
Copy link

Summary

My marker is cropped and force at 38x38 on android

I can't change width and height

I'm running expo start

Currently: expo 53 + react-native 79 + new Arch

expo 51 rn74 doesn't have this problem

Reproducible sample code

<MapView
              ref={mapRef}
              initialCamera={camera}
              provider={
                Platform.OS === 'android' ? PROVIDER_GOOGLE : PROVIDER_DEFAULT
              }
              style={[{ width: '100%', flex: 1, margin: mapMargin }]}
              mapPadding={{
                top: 0,
                right: 0,
                bottom:
                  restaurantGrList.flatMap((v) => v.restaurant_list).length *
                  137.5,
                left: 0,
              }}
              showsUserLocation
              showsMyLocationButton
            >
              {restaurantGrList.map((group, i) => (
                <Marker
                  key={`restaurant-pin-${i}`}
                  coordinate={{
                    latitude: +group.latitude,
                    longitude: +group.longitude,
                  }}
                  draggable={false}
                 
                >
                  <HStack w="140px" rounded="full" alignItems="center"> // Not working width
                    ...Custom code
                    <Feather name="chevron-right" color={white} size={16} />
                  </HStack>
                </Marker>
              ))}
            </MapView>

Steps to reproduce

Marker view

Expected result

can change size or change default size marker

Actual result

marker crop 38x38

React Native Maps Version

1.20.1

What platforms are you seeing the problem on?

Android

React Native Version

0.79.2

What version of Expo are you using?

SDK 53

Device(s)

Android

Additional information

No response

@maihuy243 maihuy243 added the bug Something isn't working label May 28, 2025
@carlgrob5171989
Copy link

can you share your pod file?

@maihuy243
Copy link
Author

can you share your pod file?

i want resolve issue in dev-mode "expo start", not build native sir @carlgrob5171989

@1kuko3
Copy link

1kuko3 commented May 28, 2025

This PR: #5103 solved this issue for me. It is needed to create a patch (using yarn/bun/pnpm...) until this is resolved, merged, and released

@maihuy243
Copy link
Author

this is not working for me sir, i run the app with "expo start" in dev mode
but it resolves when i build the native app

first i want to resolve the issue in dev mode to resolve the error

does your patch work fine on expo go ? @1kuko3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants