divadretlaw / CustomAlert

🔔 Custom Alert for SwiftUI
MIT License
190 stars 18 forks source link

Buttons no longer working on iOS 18 #28

Closed XelarCraft closed 1 month ago

XelarCraft commented 1 month ago

.customAlert("Some Title", isPresented: $showDialog) { VStack{ SmallTextJustified(name: "Some message body") Spacer() }

        } actions: {

            Button(role: .destructive) {
                showDialog = false
            } label: {
                MediumText(name: "Cancel")
            }

            Button {
                showDialog = false
                print("Some message")
            } label: {
                MediumText(name: "Proceed")
            }
        }

The logic to be executed on button press is no longer getting executed on devices running iOS 18.

divadretlaw commented 1 month ago

Thank you for reporting this issue.

I was able to reproduce the issue when using older Xcode versions.

Should be fixed in 4.0.1