Skip to content

armgit / macro

Public Imported from GitHub
0

Macro is a unified workspace for teams: email, chat, docs, tasks, agents, calls, and CRM — @-linked together with shared AI memory.

fix(notifications): open GitHub PR notifications in-app on mobile (#4496)

Jacob Beckerman92a2703f26cc
diff --git a/js/app/packages/notifications/notification-navigation.ts b/js/app/packages/notifications/notification-navigation.ts
index acb0452282..73af8c625d 100644
--- a/js/app/packages/notifications/notification-navigation.ts
+++ b/js/app/packages/notifications/notification-navigation.ts
@@ -11,6 +11,7 @@ import {
itemToBlockName,
resolveBlockAlias,
} from '@core/constant/allBlocks';
+import { USE_MACRO_PR_SUMMARY_BLOCK } from '@core/constant/featureFlags';
import type { NotificationType } from '@core/types';
import { openExternalUrl } from '@core/util/url';
import { getNotificationById } from '@queries/notification/user-notifications';
@@ -251,8 +252,12 @@ function getSupportedHandler(
) {
return null;
}
- return async () => {
- // TODO(dev-rb/github): Route GitHub PR notifications to /pr.
+ return async (lm: SplitManager, newSplit: boolean = false) => {
+ if (USE_MACRO_PR_SUMMARY_BLOCK) {
+ openSplitIfNotOpen(lm, 'pr', notification.entity_id, { newSplit });
+ return;
+ }
+
let url = meta.content.url;
if (meta.tag === 'github_pr_check_run') {
url = meta.content.checkUrl || meta.content.url;