Skip to content

Conversation

@hayata-suenaga
Copy link
Contributor

@hayata-suenaga hayata-suenaga commented Aug 4, 2023

Details

This PR creates a cross-platform MapView component.

Related Issues

Expensify/App#22703

Manual Tests

The component is tested in this App PR. I can open a follow up PR to include automated tests on the library itself after high priority issues are done. However, I don't have a good idea on how to test visual elements on Map.

Linked PRs

Expensify/App#24306

@hayata-suenaga hayata-suenaga self-assigned this Aug 4, 2023
@neil-marcellini neil-marcellini self-requested a review August 10, 2023 19:08
@hayata-suenaga hayata-suenaga marked this pull request as ready for review August 11, 2023 19:06
Copy link
Contributor

@thienlnam thienlnam left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, can’t speak much to the Mapbox stuff but left some comments regarding keeping conventions same as App styling

@thienlnam thienlnam merged commit 9ef450c into main Aug 11, 2023
@thienlnam thienlnam deleted the hayata-implement-MapView branch August 11, 2023 21:57
Comment on lines +36 to +47
useImperativeHandle(
ref,
() => ({
flyTo: (location: [number, number], animationDuration?: number) => cameraRef.current?.flyTo(location, animationDuration),
}),
[],
);

// Initialize Mapbox on first mount
useEffect(() => {
Mapbox.setAccessToken(accessToken);
}, []);

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This code caused Expensify/App#25732. Map box API doesn't seem to support flyTo well enough on native platforms.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it's rather the issue with the libraries themself than a regression but yea we should have tested this thoroughly

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants