Skip to content
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

Add option to find own location in map views #7337

Closed
wants to merge 2 commits into from

Conversation

Johennes
Copy link
Contributor

@Johennes Johennes commented Feb 4, 2023

This exposes the default "find my location" button in the map view dialog for static and live locations. When the user is currently live-sharing their own location, the button is hidden.

Todo

I couldn't find a suitable existing icon for this so I reused one of the map marker icons for demonstration purposes. We'll probably need to make a new one.

It also currently only centers the map on the user location when clicking for the first time.

Screenshots

Simulator Screen Shot - iPhone 14 Pro Max - 2023-02-04 at 21 50 16
Simulator Screen Shot - iPhone 14 Pro Max - 2023-02-04 at 21 53 57

Pull Request Checklist

  • I read the contributing guide
  • UI change has been tested on both light and dark themes, in portrait and landscape orientations and on iPhone and iPad simulators
  • Accessibility has been taken into account.
  • Pull request is based on the develop branch
  • Pull request contains a changelog file in ./changelog.d
  • You've made a self review of your PR
  • Pull request includes screenshots or videos of UI changes
  • Pull request includes a sign off

@Johennes Johennes marked this pull request as draft February 4, 2023 20:55
@sonarcloud
Copy link

sonarcloud bot commented Feb 4, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
No Duplication information No Duplication information

@codecov
Copy link

codecov bot commented Feb 4, 2023

Codecov Report

Base: 12.09% // Head: 12.08% // Decreases project coverage by -0.01% ⚠️

Coverage data is based on head (59ae3a8) compared to base (3972da8).
Patch coverage: 7.31% of modified lines in pull request are covered.

Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #7337      +/-   ##
===========================================
- Coverage    12.09%   12.08%   -0.01%     
===========================================
  Files         1637     1637              
  Lines       161830   161846      +16     
  Branches     66429    66484      +55     
===========================================
- Hits         19566    19564       -2     
- Misses      141618   141636      +18     
  Partials       646      646              
Flag Coverage Δ
uitests 55.32% <9.09%> (-0.06%) ⬇️
unittests 5.97% <2.43%> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
Config/CryptoSDKConfiguration.swift 0.00% <0.00%> (ø)
...ot/Categories/MatrixSDKCrypto+LocalizedError.swift 0.00% <ø> (ø)
Riot/Managers/Settings/RiotSettings.swift 88.42% <ø> (ø)
Riot/Modules/Analytics/Analytics.swift 9.41% <0.00%> (ø)
Riot/Modules/Application/LegacyAppDelegate.m 14.55% <ø> (ø)
...Modules/Home/AllChats/AllChatsViewController.swift 29.35% <0.00%> (ø)
Riot/Modules/Settings/SettingsViewController.m 0.00% <0.00%> (ø)
...haringViewer/LiveLocationSharingViewerModels.swift 9.09% <ø> (ø)
...SharingViewer/View/LiveLocationSharingViewer.swift 0.70% <0.00%> (-0.06%) ⬇️
...ocationSharingViewer/View/StaticLocationView.swift 0.00% <0.00%> (ø)
... and 11 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@gaelledel
Copy link

gaelledel commented Feb 6, 2023

I'm not sure I understand the need of adding a button here as zoom in and finding user location should be automatic when opening the map. Also this is the space dedicated to the Sharing option why are you replacing it?

@Johennes
Copy link
Contributor Author

Johennes commented Feb 6, 2023

Thanks for getting back @gaelledel.

I'm not sure I understand the need of adding a button here as zoom in and finding user location should be automatic when opening the map.

This is for the case when the user is not sharing their own location but instead viewing somebody else's location share.

Also this is the space dedicated to the Sharing option why are you replacing it?

The screenshot is from the live location map view. That one currently doesn't have the share button. You are right though that for static location shares, the map view would have to show both, the share button and the "find my location" button.

@gaelledel
Copy link

@Johennes You can find a design reference for this here https://www.figma.com/file/uthEK6xuo9hSQRdWvPAre5/Location-Sharing?node-id=3103%3A64256&t=tF5nsVNzfBrN9ZYh-4

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.

2 participants