mirror of
https://github.com/actualbudget/actual.git
synced 2026-04-30 10:14:53 -05:00
* vrt * Fix account menu test * Fix payee icons and category notes * vrt * vrt * Fix notes button * VRT * VRT * React Aria Button - All except filters and autocomplete * Release notes * Fix typecheck errors * Fix typecheck error * Fix button links * Update * Fix typecheck error * Fix link button variant * Fix typecheck error * Fix typecheck error * Fix typecheck error * Fix border * Fix mobile accounts page * VRT * Fix playwright config * Revert MobileForms and TransactionEdit * VRT * Remove borderRadius * Fix add account button * VRT * Revert VRT * Fix tests * Fix Cover and Transfer modals * Fix lint error
31 lines
652 B
JavaScript
31 lines
652 B
JavaScript
import { MobileAccountPage } from './mobile-account-page';
|
|
|
|
export class MobileAccountsPage {
|
|
constructor(page) {
|
|
this.page = page;
|
|
|
|
this.accounts = this.page.getByTestId('account');
|
|
}
|
|
|
|
/**
|
|
* Get the name and balance of the nth account
|
|
*/
|
|
async getNthAccount(idx) {
|
|
const accountRow = this.accounts.nth(idx);
|
|
|
|
return {
|
|
name: accountRow.getByTestId('account-name'),
|
|
balance: accountRow.getByTestId('account-balance'),
|
|
};
|
|
}
|
|
|
|
/**
|
|
* Click on the n-th account to open it up
|
|
*/
|
|
async openNthAccount(idx) {
|
|
await this.accounts.nth(idx).click();
|
|
|
|
return new MobileAccountPage(this.page);
|
|
}
|
|
}
|