diff --git a/android/capacitor/src/main/java/com/getcapacitor/Dialogs.java b/android/capacitor/src/main/java/com/getcapacitor/Dialogs.java index 8022e7c68f..321b2c28bf 100644 --- a/android/capacitor/src/main/java/com/getcapacitor/Dialogs.java +++ b/android/capacitor/src/main/java/com/getcapacitor/Dialogs.java @@ -158,7 +158,7 @@ public void run() { final AlertDialog.Builder builder = new AlertDialog.Builder(context); final EditText input = new EditText(context); - input.setText(promptInputPlaceholder); + input.setHint(promptInputPlaceholder); builder .setMessage(message) diff --git a/ios/Capacitor/Capacitor/Plugins/Modals.swift b/ios/Capacitor/Capacitor/Plugins/Modals.swift index 5712587354..0840a6d666 100644 --- a/ios/Capacitor/Capacitor/Plugins/Modals.swift +++ b/ios/Capacitor/Capacitor/Plugins/Modals.swift @@ -64,7 +64,7 @@ public class CAPModalsPlugin : CAPPlugin { DispatchQueue.main.async { alert.addTextField { (textField) in - textField.text = inputPlaceholder + textField.placeholder = inputPlaceholder } alert.addAction(UIAlertAction(title: okButtonTitle, style: UIAlertAction.Style.default, handler: { (action) -> Void in