SubfolderAPI interface

An interface representing subfolder related APIs

Methods

openSubfolderPickerDialog(OpenSubfolderPickerDialogConfig)

Opens the subfolder picker dialog.

Method Details

openSubfolderPickerDialog(OpenSubfolderPickerDialogConfig)

Opens the subfolder picker dialog.

function openSubfolderPickerDialog(config: OpenSubfolderPickerDialogConfig): Promise<OpenSubfolderPickerDialogResult>

Parameters

config
OpenSubfolderPickerDialogConfig

OpenSubfolderPickerDialogConfig including:

  • initialSubfolderId: The id of the subfolder that the picker initially displays. - Optional
  • title: The text to be displayed as the title.
  • confirmButtonText: The text to be displayed on the confirm button.
  • allowSelectWorkspace: If to show the workspace list for switching workpsace. - Optional with default value false
  • semanticInputLabelText: The text to be displayed as the label of semantic input box, if is undefiend or empty string, the semantic input box will be hidden. - Optional
  • semanticInputPlaceholder: The text id of the target workspace. - Optional
  • messageBarModel: The config of message bar, including message text, type and link. - Optional
  • allowSelectItemTypes: The item types could be selected in the dialog, if is undefined or empty, the result will contain the id of the currently browsering subfolder. - Optional
  • allowMultiSelection: If allow select multiple items. - Optional with default value false
  • showNewButton: If to show the new button. - Optional with default value false

Returns

A promise which resolves when the subfolder picker dialog closed If confirm button is clicked, the value will be SubfolderPickerResult which including:

  • selectedWorkspaceObjectId: The objectId of the selected workspace. Available when allowSelectWorkspace is true.
  • selectedSubfolderId: The id of the selected subfolder. Available when allowSelectItemTypes is undefined or empty.
  • selectedItems: The unique identifiers of the selected items. Available when allowSelectItemTypes is not undefined or empty.
  • semanticInputValue: The input value. Available when semanticInputLabelText is not undefined or empty. If cancel button is clicked, the value will be undefined.