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

feat(reactions): add emoji keyboard [WPB-4292] #2310

Closed
wants to merge 2 commits into from

Conversation

vitorhugods
Copy link
Member


PR Submission Checklist for internal contributors

  • The PR Title

    • conforms to the style of semantic commits messages¹ supported in Wire's Github Workflow²
    • contains a reference JIRA issue number like SQPIT-764
    • answers the question: If merged, this PR will: ... ³
  • The PR Description

    • is free of optional paragraphs and you have filled the relevant parts to the best of your ability

What's new in this PR?

Issues

Users can only select reaction emojis from a small set of hardcoded reactions.

Solutions

Add a full emoji keyboard / emoji picker.

As I wrote down in this article. I couldn't find a perfect emoji picker with recent emoji, search, compose support, etc.

I went with the Google-provided Emoji2 Picker, which doesn't have search support, nor first-class compose support, but looks nice and it's simple to use.

The issue with scrolling

Material3's ModalBottomSheet does not support disabling the swipe up/down gesture. The swipe gesture conflicts with the emoji picker scroll, making it almost useless.

After some days fiddling with it, I attempted to use different bottom sheets using Compose, until I eventually gave up and switched to BottomSheetDialog (not Compose).

This one was easy to enable/disable the dragging using the BottomSheetBehavior. But in order to keep it draggable by the top handle, required the creation of a DraggableByHandleBottomSheetBehavior, which checks if the touch is inside the DragHandle or not.

Also, one dark theme definition was needed in order to get the right contrasting text colors in the bottom sheet / emoji picker.

Testing

Manually tested

Attachments

Emoji.Picker.webm

PR Post Merge Checklist for internal contributors

  • If any soft of configuration variable was introduced by this PR, it has been added to the relevant documents and the CI jobs have been updated.

References
  1. https://sparkbox.com/foundry/semantic_commit_messages
  2. https://github.com/wireapp/.github#usage
  3. E.g. feat(conversation-list): Sort conversations by most emojis in the title #SQPIT-764.

@vitorhugods vitorhugods requested review from a team, typfel, alexandreferris, borichellow, mchenani and Garzas and removed request for a team October 9, 2023 15:30
@vitorhugods vitorhugods requested review from saleniuk and removed request for typfel October 9, 2023 15:31
@github-actions
Copy link
Contributor

github-actions bot commented Oct 9, 2023

Test Results

0 tests   0 ✔️  0s ⏱️
0 suites  0 💤
0 files    0

Results for commit 9cd2172.

@AndroidBob
Copy link
Collaborator

Build 1204 failed.

@vitorhugods
Copy link
Member Author

Closed as release/candidate doesn't have compileSdk >= 34

@vitorhugods vitorhugods closed this Oct 9, 2023
@yamilmedina yamilmedina deleted the feat/reactions/emoji-keyboard branch April 12, 2024 21:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants