Class BrowserPrompt

java.lang.Object
org.vaadin.firitin.util.BrowserPrompt

public class BrowserPrompt extends Object
Helper class to use browser prompts.
  • Constructor Details

    • BrowserPrompt

      public BrowserPrompt()
  • Method Details

    • showPrompt

      public static CompletableFuture<String> showPrompt(String message)
      Shows a browser prompt.
      Parameters:
      message - the message to show
      Returns:
      the value entered by the user
    • showPrompt

      public static CompletableFuture<String> showPrompt(String message, String defaultValue)
      Shows a browser prompt.
      Parameters:
      message - the message to show
      defaultValue - the default value to show
      Returns:
      the value entered by the user
    • showPrompt

      public static CompletableFuture<String> showPrompt(com.vaadin.flow.component.UI ui, String message, String defaultValue)
      Shows a browser prompt.
      Parameters:
      ui - the UI to use
      message - the message to show
      defaultValue - the default value to show
      Returns:
      the value entered by the user