Skip to content

fix(push-notifications): avoid duplicate macOS notification icons - #3114

Merged
SawyerHood merged 1 commit into
get-bb:mainfrom
smsunarto:scott/macos-notification-icon
Sep 5, 2026
Merged

fix(push-notifications): avoid duplicate macOS notification icons#3114
SawyerHood merged 1 commit into
get-bb:mainfrom
smsunarto:scott/macos-notification-icon

Conversation

@smsunarto

@smsunarto smsunarto commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

Human comments

What was wrong

Desktop notifications always supplied /icon-192.png through the Web Notification API. On macOS, Electron displays this as a content image alongside the app icon macOS already adds, producing two BB logos.

What changed

Omit the explicit notification icon when the desktop bridge identifies macOS. Keep the existing icon for web and Linux desktop notifications. Notification content, navigation, and deduplication remain unchanged.

How you verified

  • Added macOS, Linux, and web regression cases. Before the fix, only the macOS case failed because the extra icon was present. After the fix, all 20 plugin tests pass.
  • NODE_OPTIONS=--no-experimental-webstorage pnpm exec turbo run test typecheck --filter=bb-plugin-push-notifications passes on Node 22.23.2. Disabling Node's experimental web storage lets jsdom own localStorage.
  • Formatting and oxlint pass for both changed files.
  • Built and reloaded the plugin in the source-built Electron app, then triggered the real notifications.test RPC. Observed Electron's Notification constructor receiving the title, body, and tag with no icon. Native delivery remained enabled during observation. Desktop logs showed no notification errors.

Before and after

The after capture uses the source-built dev app, so the single application icon is Electron's development icon.

Before: duplicate icons After: single application icon
Before: two BB icons After: one application icon and no extra image

AGENT GENERATED

@SawyerHood
SawyerHood merged commit d0a9a70 into get-bb:main Sep 5, 2026
14 checks passed
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.

2 participants