val alert = UIAlertController.alertControllerWithTitle( title = state.title, message = state.text, preferredStyle = UIAlertControllerStyleAlert, ) state.confirmButton.let { button -> alert.addAction( UIAlertAction.actionWithTitle( title = button.text, style = UIAlertActionStyleDefault, handler = { button.action() }, ), ) } state.dismissButton-.let { button -> alert.addAction( UIAlertAction.actionWithTitle( title = button.text, style = UIAlertActionStyleCancel, handler = { button.action() }, ), ) } LocalUIViewController.current.showViewController( vc = alert, sender = null, ) } Dialog.kt Dialog.ios.kt UIKit UIAlertController commonMain iosMain