



























@@ -308,15 +308,58 @@ extension SettingsProTab {
308308self.detailStatusCard(
309309 icon: "checkmark.shield.fill",
310310 title: "Approvals",
311- detail: self.pendingApproval == nil ? "No gateway actions are waiting for review." :
312-"Review the pending gateway action.",
313- value: self.pendingApproval == nil ? "clear" : "1 waiting",
314- color: self.pendingApproval == nil ? OpenClawBrand.ok : OpenClawBrand.warn)
311+ detail: self.notificationsNeedAttention
312+? "Out-of-app approval alerts need notification permission."
313+: (self.pendingApproval == nil ? "No gateway actions are waiting for review." :
314+"Review the pending gateway action."),
315+ value: self.notificationsNeedAttention
316+? "alerts off"
317+: (self.pendingApproval == nil ? "clear" : "1 waiting"),
318+ color: self.notificationsNeedAttention ? OpenClawBrand.warn :
319+(self.pendingApproval == nil ? OpenClawBrand.ok : OpenClawBrand.warn))
320+321+if self.notificationsNeedAttention {
322+self.approvalNotificationsWarningCard
323+}
315324316325self.approvalsReviewCard
317326}
318327}
319328329+var approvalNotificationsWarningCard: some View {
330+ProCard(radius: SettingsLayout.cardRadius) {
331+VStack(alignment: .leading, spacing: 12) {
332+HStack(alignment: .top, spacing: 12) {
333+ProIconBadge(systemName: "bell.slash.fill", color: OpenClawBrand.warn)
334+VStack(alignment: .leading, spacing: 4) {
335+Text("Approval alerts are off")
336+.font(.subheadline.weight(.semibold))
337+Text(
338+"""
339+ OpenClaw can still show approval review while the app is open and connected. \
340+ Enable Notifications to receive approval prompts outside the app.
341+ """)
342+.font(.caption)
343+.foregroundStyle(.secondary)
344+.fixedSize(horizontal: false, vertical: true)
345+}
346+}
347+348+if self.directRoute == nil {
349+Button {
350+self.openNotificationsRouteFromApprovals()
351+} label: {
352+Label("Open Notifications", systemImage: "bell.badge")
353+.frame(maxWidth: .infinity)
354+}
355+.buttonStyle(.bordered)
356+.controlSize(.small)
357+}
358+}
359+}
360+.padding(.horizontal, OpenClawProMetric.pagePadding)
361+}
362+320363var approvalsReviewCard: some View {
321364ProCard(radius: SettingsLayout.cardRadius) {
322365VStack(alignment: .leading, spacing: 12) {
@@ -490,7 +533,7 @@ extension SettingsProTab {
490533self.detailStatusCard(
491534 icon: "bell",
492535 title: "Notifications",
493- detail: "Approvals and event alerts from OpenClaw.",
536+ detail: self.notificationStatusDetail,
494537 value: self.notificationStatusText,
495538 color: self.notificationStatus.color)
496539@@ -506,10 +549,25 @@ extension SettingsProTab {
506549}
507550.buttonStyle(.borderedProminent)
508551.controlSize(.small)
552+.disabled(self.notificationStatus == .checking || self.isRequestingNotificationAuthorization)
509553510-Text("OpenClaw uses notifications for approval prompts and mirrored event alerts.")
554+Text(self.notificationStatusDetail)
511555.font(.caption)
512556.foregroundStyle(.secondary)
557+.fixedSize(horizontal: false, vertical: true)
558+559+Divider()
560+561+HStack(alignment: .top, spacing: 10) {
562+Image(systemName: "network")
563+.font(.caption.weight(.semibold))
564+.foregroundStyle(OpenClawBrand.accent)
565+.frame(width: 22, height: 22)
566+Text(self.notificationRelayDetail)
567+.font(.caption)
568+.foregroundStyle(.secondary)
569+.fixedSize(horizontal: false, vertical: true)
570+}
513571}
514572}
515573.padding(.horizontal, OpenClawProMetric.pagePadding)
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。