import type { ChainablePromiseElement } from 'webdriverio'; import { BottomBarPanel } from '../index.js'; import { BasePage, ElementWithContextMenu, IPageDecorator, VSCodeLocatorMap } from '../utils.js'; import { ProblemsView as ProblemsViewLocators, Marker as MarkerLocators } from '../../locators/1.73.0.js'; export interface ProblemsView extends IPageDecorator { } /** * Problems view in the bottom panel. * * ```ts * const bottomBar = workbench.getBottomBar() * const outputView = await bottomBar.openProblemsView() * console.log(await outputView.setFilter('Error')) * ``` * * @category BottomBar */ export declare class ProblemsView extends BasePage { panel: BottomBarPanel; /** * @private */ locatorKey: "ProblemsView"; constructor(locators: VSCodeLocatorMap, panel?: BottomBarPanel); /** * Set the filter using the input box on the problems view * @param pattern filter to use, preferably a glob pattern * @returns Promise resolving when the filter pattern is filled in */ setFilter(pattern: string): Promise; /** * Clear all filters * @returns Promise resolving to the filter field WebElement */ clearFilter(): Promise; /** * Collapse all collapsible markers in the problems view * @returns Promise resolving when the collapse all button is pressed */ collapseAll(): Promise; /** * @deprecated The method should not be used and getAllVisibleMarkers() should be used instead. */ getAllMarkers(): Promise; /** * Get all visible markers from the problems view with the given type. * Warning: this only returns the markers that are visible, and not the * entire list, so calls to this function may change depending on the * environment in which the tests are running in. * To get all markers regardless of type, use MarkerType.Any * @param type type of markers to retrieve * @returns Promise resolving to array of Marker objects */ getAllVisibleMarkers(type: MarkerType): Promise; /** * Gets the count badge * @returns Promise resolving to the WebElement representing the count badge */ getCountBadge(): Promise; } export interface Marker extends IPageDecorator { } /** * Page object for marker in problems view * * @category BottomBar */ export declare class Marker extends ElementWithContextMenu { view: ProblemsView; /** * @private */ locatorKey: "Marker"; problems: Problem[]; constructor(locators: VSCodeLocatorMap, element: ChainablePromiseElement, view: ProblemsView); /** * Get the type of the marker * Possible types are: File, Error, Warning * @returns Promise resolving to a MarkerType */ getType(): Promise; /** * Get the name of the file that has problems * @returns name of file containing problems */ getFileName(): Promise; /** * Get the error count of the file that has problems * @returns error count of file containing problems */ getProblemCount(): Promise; /** * Get the full text of the marker * @returns Promise resolving to marker text */ getText(): Promise; /** * Expand/Collapse the marker if possible * @param expand true to expand, false to collapse * @returns Promise resolving when the expand/collapse twistie is clicked */ toggleExpand(expand: boolean): Promise; } export interface Problem extends IPageDecorator { } /** * Page object for marker in problems view * * @category BottomBar */ export declare class Problem extends ElementWithContextMenu { /** * @private */ locatorKey: "Marker"; /** * Problem details * @returns problem description */ getText(): Promise; /** * Type of file where the problem is located * @returns source file type */ getSource(): Promise; /** * Location problem * @returns location of error as Array [line, column] */ getLocation(): Promise; /** * Get the type of the marker * Possible types are: File, Error, Warning * @returns Promise resolving to a MarkerType */ getType(): Promise; } /** * Possible types of markers * - File = expandable item representing a file * - Error = an error marker * - Warning = a warning marker * - Any = any of the above * * @hidden */ export declare enum MarkerType { File = "file", Unknown = "unknown", Error = "error", Warning = "warning", Any = "any" } //# sourceMappingURL=ProblemsView.d.ts.map