/** * Copyright (c) 2025, Salesforce, Inc. * All rights reserved. * For full license text, see the LICENSE file or https://utam.dev/salesforce/license */ import { Driver as _Driver, Element as _Element, Locator as _Locator, BaseUtamElement as _BaseUtamElement, UtamBaseRootPageObject as _UtamBaseRootPageObject, ActionableUtamElement as _ActionableUtamElement, ClickableUtamElement as _ClickableUtamElement } from '@utam/core'; import _Icon from 'salesforce-pageobjects/lightning/pageObjects/icon'; import _Spinner from 'salesforce-pageobjects/lightning/pageObjects/spinner'; import _UpsertWorkspaceModal from 'salesforce-pageobjects/dev/workspace/pageObjects/upsertWorkspaceModal'; /** * A dropdown component that allows users to select a workspace from a list, update the current workspace, create a new workspace, or navigate to the project home page. It also displays a loading state and handles errors. * Selector: dev_workspace-workspace-picker * generated from JSON dist/dev/workspace/workspacePicker.utam.json * @version 2026-03-09T13:56:35.206Z * @author Salesforce */ declare class WorkspacePicker extends _UtamBaseRootPageObject { constructor(driver: _Driver, element?: _Element, locator?: _Locator); /** * Simulate a click on the workspace picker button to open or close the dropdown */ toggleWorkspacePicker(): Promise; /** * Return the text of the workspace title for assertion * @return string */ assertWorkspaceTitle(): Promise; /** * Simulate a click on the link to create a new workspace */ clickCreateNewWorkspace(): Promise; /** * Simulate a click on a workspace to select it * @param _workspaceListItemsIndex index of parent element */ selectWorkspace(_workspaceListItemsIndex: number): Promise; /** * Return the text of the workspace label for assertion * @return string * @param _workspaceListItemsIndex index of parent element */ assertWorkspaceLabel(_workspaceListItemsIndex: number): Promise; /** * Check if the dropdown menu is visible for assertion * @return boolean */ assertDropdownMenuVisibility(): Promise; /** * Returns true if element "dropdownMenu" present on the page * @return boolean */ verifyDropdownMenuPresence(): Promise; waitForLoadingIcon(): Promise<_Icon>; waitForLoadingSpinner(): Promise<_Spinner>; /** * Icon indicating loading state */ getLoadingIcon(): Promise<_Icon | null>; /** * Spinner indicating loading state */ getLoadingSpinner(): Promise<_Spinner | null>; /** * Icon for the workspace */ getWorkspaceIcon(): Promise<_Icon | null>; /** * Icon to indicate dropdown state (open or closed) */ getDropdownIcon(): Promise<_Icon>; /** * List items representing each workspace */ getWorkspaceListItems(): Promise<(_BaseUtamElement)[] | null>; /** * Icon indicating the selected workspace * @param _workspaceListItemsIndex index of parent element */ getSelectedWorkspaceIcon(_workspaceListItemsIndex: number): Promise<_Icon | null>; /** * Icon to navigate to the project home page */ getStudioRedirectIcon(): Promise<(_BaseUtamElement & _ActionableUtamElement & _ClickableUtamElement) | null>; getUpsertWorkspaceModal(): Promise<_UpsertWorkspaceModal | null>; } export = WorkspacePicker;