Skip to content

Commit

Permalink
Merge pull request #20 from hotwired/non-destructive-confirm
Browse files Browse the repository at this point in the history
Make confirm button blue, not red
  • Loading branch information
joemasilotti authored May 15, 2024
2 parents 6ba212d + 141b178 commit aa529a0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Source/Turbo/Navigator/WKUIController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ open class WKUIController: NSObject, WKUIDelegate {

open func webView(_ webView: WKWebView, runJavaScriptConfirmPanelWithMessage message: String, initiatedByFrame frame: WKFrameInfo, completionHandler: @escaping (Bool) -> Void) {
let alert = UIAlertController(title: message, message: nil, preferredStyle: .alert)
alert.addAction(UIAlertAction(title: "OK", style: .destructive) { _ in
alert.addAction(UIAlertAction(title: "OK", style: .default) { _ in
completionHandler(true)
})
alert.addAction(UIAlertAction(title: "Cancel", style: .cancel) { _ in
Expand Down

0 comments on commit aa529a0

Please # to comment.