mirror of
https://github.com/actualbudget/actual.git
synced 2026-04-30 10:14:53 -05:00
* Dummy commit * Delete js snapshots * Move extended expect and test to fixtures * Fix wrong commit * Update VRT * Dummy commit to run GH actions * Convert test page models to TS * Release notes * Fix typecheck errors * New page models to TS * Fix typecheck error * Fix page name * Put awaits on getTableTotals --------- Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
31 lines
833 B
TypeScript
31 lines
833 B
TypeScript
import { type Locator, type Page } from '@playwright/test';
|
|
|
|
import { EditNotesModal } from './mobile-edit-notes-modal';
|
|
|
|
export class CategoryMenuModal {
|
|
readonly page: Page;
|
|
readonly locator: Locator;
|
|
readonly heading: Locator;
|
|
readonly budgetAmountInput: Locator;
|
|
readonly editNotesButton: Locator;
|
|
|
|
constructor(locator: Locator) {
|
|
this.locator = locator;
|
|
this.page = locator.page();
|
|
|
|
this.heading = locator.getByRole('heading');
|
|
this.budgetAmountInput = locator.getByTestId('amount-input');
|
|
this.editNotesButton = locator.getByRole('button', { name: 'Edit notes' });
|
|
}
|
|
|
|
async close() {
|
|
await this.heading.getByRole('button', { name: 'Close' }).click();
|
|
}
|
|
|
|
async editNotes() {
|
|
await this.editNotesButton.click();
|
|
|
|
return new EditNotesModal(this.page.getByRole('dialog'));
|
|
}
|
|
}
|