-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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 'Show on a map' button to Location in profile, fix layout #26214
Conversation
Not too important, but I think that it'd be a pretty neat touch. Also fixes a previously undiscovered visual bug when zooming in. A separate pull request was not made because adding more elements to the <li>'s makes the problem much more visible. Co-authored-by: Gusted <postmaster@gusted.xyz> Co-authored-by: Caesar Schinas <caesar@caesarschinas.com>
This feature was originally developed and reviewed in the following link - this version contains some extra fixes discussed after the merge happened but were left unnoticed: https://codeberg.org/forgejo/forgejo/pulls/1076 A previous PR of mine, #23900, apparently introduced some sort of a visual bug when zooming in, and that was made slightly worse with the addition of a second icon on a profile. P.S. Please make sure that the |
The motivation for this change is promoting other open protocols and also making these "black boxes that produce code for me" known as open-source contributors seem a bit more human by reminding people that these are people with totally different lives, a totally different background, that are leading a totally different life, yet you're still using their software and working with them: I think that a map serves the purpose of being a proper reminder for the humans that exist behind those profiles. This change would probably benefit forges / public instances and users working in distributed groups and does not take joke entries into account. I also intentionally avoided working with the API of OpenStreetMap as it is much less complicated for instance operators and much more privacy-respecting that way. (e.g. providing a location supplied by a user to a third party could be legally questionable in the EU) |
|
There is still one outstanding issue.
By the user, you mean? |
I think I'm done here and this is ready for a review. |
* upstream/main: (26 commits) Add 'Show on a map' button to Location in profile, fix layout (go-gitea#26214) Use shared template for webhook icons (go-gitea#26242) Reduce margins on user settings page, introduce `flex-container` (go-gitea#26046) Refactor and enhance issue indexer to support both searching, filtering and paging (go-gitea#26012) Show image size on view page (go-gitea#25884) Fix pull request check list is limited (go-gitea#26179) Fix API leaking Usermail if not logged in (go-gitea#25097) [skip ci] Updated licenses and gitignores Fix typo in metadata (go-gitea#26207) Update js and py dependencies (go-gitea#26243) De-emphasize issue sidebar buttons (go-gitea#26171) Don't autosize textarea in diff view (go-gitea#26233) Add `/public/assets` to `.ignore` (go-gitea#26232) Fix attachment clipboard copy on insecure origin (go-gitea#26224) Fix commit compare style (go-gitea#26209) Fix unable to display individual-level project (go-gitea#26198) Fix access check for org-level project (go-gitea#26182) Fixed incorrect locale references (go-gitea#26218) Use calendar icon for `Joined on...` in profiles (go-gitea#26215) Add changelog for 1.20.2 (go-gitea#26208) ...
Before: ![image](https://github.com/go-gitea/gitea/assets/18380374/55759aad-cbf7-4d91-8559-b7781d184911) After: ![image](https://github.com/go-gitea/gitea/assets/18380374/9de5136b-d0a0-4756-9426-125fd4b603d3) In #26214, we changed each row's display into `flex` which caused this problem. ![image](https://github.com/go-gitea/gitea/assets/18380374/66546e7e-a224-45e7-9008-224f0f2952c6) ![image](https://github.com/go-gitea/gitea/assets/18380374/e5190f88-e561-4361-894a-86c5fe88837e) In old version: ![image](https://github.com/go-gitea/gitea/assets/18380374/36e58e98-7d75-4a63-844a-2beee460997a) Maybe we can add paddings here? ![image](https://github.com/go-gitea/gitea/assets/18380374/dc61acd2-8995-46d4-b606-eb10c77dd877) In old version; ![image](https://github.com/go-gitea/gitea/assets/18380374/478acba7-0bbc-4852-b208-3ae43fcea976)
Follow-up to d58c542 for Forgejo. By default, Gitea does not select any map service that can be used to introduce a 'Show this place on a map' button in the location field of a user profile. Before I tried upstreaming this change to Gitea, this was the case in Forgejo. This patch essentially recovers this functionality, which is nice for public-facing instances and communities. Links to original PRs: - https://codeberg.org/forgejo/forgejo/pulls/1076 - go-gitea#26214 (cherry picked from commit bb187d5f617f8efceb41810d6ff9adcaa60450bb) (cherry picked from commit ce02ef9078a8731921caa4f7b0c1b0ac3b59a784) (cherry picked from commit 6b75c40e2575e23810880ee8e368dc1781e2b4e4) (cherry picked from commit 6bc8e9f5737f5721ddcd1ef5926a778a7f66a4a3) (cherry picked from commit 063f8afdf7c2cca014c60dcc3d78d270fd236f8f) (cherry picked from commit c5cc736b72e1ba980519e9258686f41e4eb78b42) (cherry picked from commit 7b1bb4bedc6196fb6e8516d9a34092b16d7fab05)
…o-gitea#26803) This change introduces a fix for the PR go-gitea#26214 to set the UserLocationMapURL correctly.
Not too important, but I think that it'd be a pretty neat touch.
Also fixes some layout bugs introduced by a previous PR.