fix(google-chat) - fix(alibaba-chat) update unread badge - #698
Open
dansleboby wants to merge 3 commits into
Open
fix(google-chat) - fix(alibaba-chat) update unread badge#698dansleboby wants to merge 3 commits into
dansleboby wants to merge 3 commits into
Conversation
Add a MutationObserver to detect unread badge changes in Google Chat and recalculate the Ferdium badge immediately. DOM mutations are batched with requestAnimationFrame to avoid redundant badge updates. The existing Ferdium loop is kept as a fallback. The aggregate Shortcuts section is still ignored to prevent unread messages from being counted twice.
Update the Ferdium badge logic to select the last .option-item in the inbox panel and read its .item-unread-num value. The unread value is now safely parsed as an integer, with empty or invalid values defaulting to 0.
SpecialAro
requested changes
Aug 13, 2026
SpecialAro
left a comment
Member
There was a problem hiding this comment.
Thanks for the fixes! The Alibaba Chat and ClickUp changes look reasonable, but I think this PR needs a small update before merging.
The Google Chat change has now been superseded by #701, which is already merged and uses a simpler unread-count implementation. Could you please rebase this PR and drop the Google Chat changes to avoid overwriting the newer fix?
Also, please bump the recipe versions for Alibaba Chat and ClickUp. Ferdium relies on recipe version bumps to distribute updated recipes to users.
With those changes, this should be in good shape.
3 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Pre-flight Checklist
Please ensure you've completed all of the following.
Description of Change
Add a MutationObserver to detect unread badge changes in Google Chat and recalculate the Ferdium badge immediately. DOM mutations are batched with requestAnimationFrame to avoid redundant badge updates. The existing Ferdium loop is kept as a fallback. The aggregate Shortcuts section is still ignored to prevent unread messages from being counted twice.