From d96bc38beaf6b39cc9f65105d9d6201745494f4c Mon Sep 17 00:00:00 2001 From: Peter Steinberger Date: Sat, 13 Dec 2025 23:29:10 +0000 Subject: [PATCH] style(macos): mark Reject destructive --- apps/macos/Sources/Clawdis/Bridge/BridgeServer.swift | 3 +++ apps/macos/Sources/Clawdis/NodePairingApprovalPrompter.swift | 3 +++ 2 files changed, 6 insertions(+) diff --git a/apps/macos/Sources/Clawdis/Bridge/BridgeServer.swift b/apps/macos/Sources/Clawdis/Bridge/BridgeServer.swift index e3c536fd2..37a901729 100644 --- a/apps/macos/Sources/Clawdis/Bridge/BridgeServer.swift +++ b/apps/macos/Sources/Clawdis/Bridge/BridgeServer.swift @@ -307,6 +307,9 @@ enum BridgePairingApprover { """ alert.addButton(withTitle: "Approve") alert.addButton(withTitle: "Reject") + if #available(macOS 11.0, *), alert.buttons.indices.contains(1) { + alert.buttons[1].hasDestructiveAction = true + } let resp = alert.runModal() cont.resume(returning: resp == .alertFirstButtonReturn) } diff --git a/apps/macos/Sources/Clawdis/NodePairingApprovalPrompter.swift b/apps/macos/Sources/Clawdis/NodePairingApprovalPrompter.swift index f09c752ad..d072205a3 100644 --- a/apps/macos/Sources/Clawdis/NodePairingApprovalPrompter.swift +++ b/apps/macos/Sources/Clawdis/NodePairingApprovalPrompter.swift @@ -80,6 +80,9 @@ final class NodePairingApprovalPrompter { alert.addButton(withTitle: "Approve") alert.addButton(withTitle: "Reject") alert.addButton(withTitle: "Later") + if #available(macOS 11.0, *), alert.buttons.indices.contains(1) { + alert.buttons[1].hasDestructiveAction = true + } let response = alert.runModal() Task { [weak self] in