import { ComponentHarness, BaseHarnessFilters, HarnessPredicate } from '@angular/cdk/testing'; /** Harness filters for ComConfirmPanelHarness. */ type ComConfirmPanelHarnessFilters = BaseHarnessFilters; /** Harness filters for ComConfirmTriggerHarness. */ interface ComConfirmTriggerHarnessFilters extends BaseHarnessFilters { /** Filter by the trigger element's text. */ text?: string | RegExp; } /** * Harness for interacting with a confirm panel in tests. * * The panel renders inside a CDK overlay with `role="alertdialog"`. * Obtain via `TestbedHarnessEnvironment.documentRootLoader(fixture)` or * through `ComConfirmTriggerHarness.getPanel()`. */ declare class ComConfirmPanelHarness extends ComponentHarness { static hostSelector: string; private readonly alertdialog; private readonly title; private readonly message; private readonly cancelButton; private readonly confirmButton; /** * Gets a HarnessPredicate for matching confirm panels. * @param options Filter options. */ static with(options?: ComConfirmPanelHarnessFilters): HarnessPredicate; /** Gets the title text, or null if no title is present. */ getTitleText(): Promise; /** Gets the message text. */ getMessageText(): Promise; /** Gets the confirm button text. */ getConfirmButtonText(): Promise; /** Gets the cancel button text. */ getCancelButtonText(): Promise; /** Clicks the confirm button. */ confirm(): Promise; /** Clicks the cancel button. */ cancel(): Promise; /** Gets the `data-state` attribute on the alertdialog element. */ getState(): Promise; } /** * Harness for interacting with a confirm trigger in tests. */ declare class ComConfirmTriggerHarness extends ComponentHarness { static hostSelector: string; private readonly documentRootLocator; /** * Gets a HarnessPredicate for matching confirm triggers. * @param options Filter options. */ static with(options?: ComConfirmTriggerHarnessFilters): HarnessPredicate; /** Gets the trigger element's text. */ getText(): Promise; /** Whether the confirm panel is currently open. */ isOpen(): Promise; /** Opens the confirm panel if it's closed. */ open(): Promise; /** Closes the confirm panel if it's open. */ close(): Promise; /** Gets the confirm panel harness, or null if the panel is closed. */ getPanel(): Promise; /** Opens the panel and clicks the confirm button. */ confirm(): Promise; /** Opens the panel and clicks the cancel button. */ cancel(): Promise; /** Focuses the trigger element. */ focus(): Promise; /** Blurs the trigger element. */ blur(): Promise; /** Whether the trigger element is focused. */ isFocused(): Promise; } export { ComConfirmPanelHarness, ComConfirmTriggerHarness }; export type { ComConfirmPanelHarnessFilters, ComConfirmTriggerHarnessFilters };