element-x-android
element-x-android copied to clipboard
Tapping user mxid or room alias copies it to the clipboard
Content
Make user id and room alias text in room/user view pages clickable and copy the text to the clipboard on click.
One small issue with this implementation is the snackbars don't appear until the view is closed.. not sure why, because I copy-pasted some other code that does the same thing and it works fine. Coroutines in Kotlin are ~shit~ weird. Suggestions welcome 🙏🏻
Motivation and context
Fixes https://github.com/element-hq/element-x-android/issues/3496
(Do note that I have no idea what I'm doing.. I merely mimic what I see until it works)
Screenshots / GIFs
https://github.com/user-attachments/assets/50915a67-b92f-467d-8c1f-ec93fa00a83a
Tests
Finger touchy screeny
- Step 1
- Step 2
- Step ...
Tested devices
- [x] Physical
- [ ] Emulator
- OS version(s): Android 14
Checklist
- [ ] Changes have been tested on an Android device or Android emulator with API 23
- [ ] UI change has been tested on both light and dark themes
- [ ] Accessibility has been taken into account. See https://github.com/element-hq/element-x-android/blob/develop/CONTRIBUTING.md#accessibility
- [x] Pull request is based on the develop branch
- [x] Pull request title will be used in the release note, it clearly define what will change for the user
- [x] Pull request includes screenshots or videos if containing UI changes
- [x] Pull request includes a sign off
- [x] You've made a self review of your PR