Interface ShowUploadFileOptions

The options to configure the file upload dialog.

Hierarchy

Properties

buttons?: MessageBubbleButtonProps[]

A list of buttons that will resolve the message. By default, a Proceed button with value ok. The helper will resolve with the value of the button that was clicked

description?: ReactNode

A description shown under the title. Usually, describes the contents of the step

error?: ReactNode

The error message to display if the user tries to upload too many files.

fileLimit?: number

The maximum number of files that can be uploaded.

fileUploadText?: ReactNode

The text of the upload file input.

fileUploadTitle: ReactNode

The title of the file upload dialog.

loadingText?: string

The text to display while the file is being uploaded.

overlay?: boolean

Obscure the content behind the message and prevent interaction

text: ReactNode

Markdown text to show in the content. Usually, the instructions for the current step. It also accepts ReactNodes

title?: ReactNode

A title shown in the header. Usually, the title of the step

uploadButton: ReactNode

The label to use for the upload button.

validate?: ((sdkFile) => Promise<{
    isValid: boolean;
    message: string;
}>)

Type declaration

    • (sdkFile): Promise<{
          isValid: boolean;
          message: string;
      }>
    • /**

      • A function that takes a DroppedFile object and returns a promise that resolves to an object with isValid and message properties.
      • If the isValid property is false, the message property should contain an error message.
      • If the isValid property is true, the message property should be empty.
      • If the validate function is not provided, all files will be considered valid.

      Parameters

      • sdkFile: DroppedFile

      Returns Promise<{
          isValid: boolean;
          message: string;
      }>

Generated using TypeDoc