Skip to content

Conversation

avashilling
Copy link
Contributor

@avashilling avashilling commented Aug 1, 2025

Removes highlight that you get from scrolling to a pinned message, when that message is unpinned. It also calls the unpinEvent function from clicking on the upper right pin icon, as well as the one on the pin bar so that the actions are consistent. Closes #2078

Thank you so much for your contribution to FluffyChat ❤️❤️❤️

Please make sure that your Pull Request meet the following acceptance criteria:

  • Code formatting and import sorting has been done with dart format lib/ test/ and dart run import_sorter:main --no-comments
  • The commit message uses the format of Conventional Commits
  • The commit message describes what has been changed, why it has been changed and how it has been changed
  • Every new feature or change of the design/GUI is linked to an approved design proposal in an issue
  • Every new feature in the app or the build system has a strategy how this will be tested and maintained from now on for every release, e.g. a volunteer who takes over maintainership

Pull Request has been tested on:

  • Android
  • iOS
  • Browser (Chromium based)
  • Browser (Firefox based)
  • Browser (WebKit based)
  • Desktop Linux
  • Desktop Windows
  • Desktop macOS

pinnedEventIds.contains(selectedEventIds.single);
if (unpin) {
pinnedEventIds.removeWhere(selectedEventIds.contains);
unpinEvent(selectedEventIds.single);
Copy link
Owner

@krille-chan krille-chan Aug 6, 2025

Choose a reason for hiding this comment

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

I don't understand this change. Why do you now call the unpinEvent method here?

edit: Ah to also trigger the remove highlight. But then you need to return here as well, because otherwise the code below the if else statement is still executed.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I see, fixed!

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.

Pin highlight stays after message is unpinned

2 participants