Skip to content

Commit

Permalink
Merge branch 'master' into enhancement/context_menus/sidebar
Browse files Browse the repository at this point in the history
  • Loading branch information
UnderKoen committed Dec 9, 2024
2 parents 5a4f6a5 + 5717d90 commit 2afa941
Show file tree
Hide file tree
Showing 216 changed files with 4,821 additions and 3,177 deletions.
2 changes: 1 addition & 1 deletion packages/api/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@actual-app/api",
"version": "24.11.0",
"version": "24.12.0",
"license": "MIT",
"description": "An API for Actual",
"engines": {
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
8 changes: 8 additions & 0 deletions packages/desktop-client/e2e/page-models/mobile-navigation.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import { MobileAccountPage } from './mobile-account-page';
import { MobileAccountsPage } from './mobile-accounts-page';
import { MobileBudgetPage } from './mobile-budget-page';
import { MobileTransactionEntryPage } from './mobile-transaction-entry-page';
Expand All @@ -22,6 +23,13 @@ export class MobileNavigation {
return new MobileAccountsPage(this.page);
}

async goToUncategorizedPage() {
const button = this.page.getByRole('button', { name: /uncategorized/ });
await button.click();

return new MobileAccountPage(this.page);
}

async goToTransactionEntryPage() {
const link = this.page.getByRole('link', { name: 'Transaction' });
await link.click();
Expand Down
3 changes: 2 additions & 1 deletion packages/desktop-client/e2e/page-models/reports-page.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,9 @@ export class ReportsPage {

async goToCustomReportPage() {
await this.pageContent
.getByRole('button', { name: 'Create new custom report' })
.getByRole('button', { name: 'Add new widget' })
.click();
await this.page.getByRole('button', { name: 'New custom report' }).click();
return new CustomReportPage(this.page);
}

Expand Down
17 changes: 0 additions & 17 deletions packages/desktop-client/e2e/page-models/settings-page.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,27 +8,10 @@ export class SettingsPage {
}

async useBudgetType(budgetType) {
await this.enableExperimentalFeature('Budget mode toggle');

const switchBudgetTypeButton = this.page.getByRole('button', {
name: `Switch to ${budgetType} budgeting`,
});

await switchBudgetTypeButton.click();
}

async enableExperimentalFeature(featureName) {
const advancedSettingsButton = this.page.getByTestId('advanced-settings');
await advancedSettingsButton.click();

const experimentalSettingsButton = this.page.getByTestId(
'experimental-settings',
);
await experimentalSettingsButton.click();

const featureCheckbox = this.page.getByRole('checkbox', {
name: featureName,
});
await featureCheckbox.click();
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
77 changes: 72 additions & 5 deletions packages/desktop-client/e2e/transactions.mobile.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,8 @@ test.describe('Mobile Transactions', () => {
);
await expect(page).toMatchThemeScreenshots();

const accountPage = await transactionEntryPage.createTransaction();

await expect(accountPage.transactions.nth(0)).toHaveText(
'KrogerClothing-12.34',
);
await transactionEntryPage.createTransaction();
await expect(page.getByLabel('Transaction list')).toHaveCount(0);
await expect(page).toMatchThemeScreenshots();
});

Expand Down Expand Up @@ -82,4 +79,74 @@ test.describe('Mobile Transactions', () => {
'KrogerClothing-12.34',
);
});

test('creates an uncategorized transaction from `/accounts/uncategorized` page', async () => {
// Create uncategorized transaction
let transactionEntryPage = await navigation.goToTransactionEntryPage();
await transactionEntryPage.amountField.fill('12.35');
// Click anywhere to cancel active edit.
await transactionEntryPage.header.click();
await transactionEntryPage.fillField(
page.getByTestId('account-field'),
'Ally Savings',
);
await transactionEntryPage.createTransaction();

const uncategorizedPage = await navigation.goToUncategorizedPage();
transactionEntryPage = await uncategorizedPage.clickCreateTransaction();

await expect(transactionEntryPage.header).toHaveText('New Transaction');

await transactionEntryPage.amountField.fill('12.34');
// Click anywhere to cancel active edit.
await transactionEntryPage.header.click();
await transactionEntryPage.fillField(
page.getByTestId('payee-field'),
'Kroger',
);

await transactionEntryPage.createTransaction();

await expect(uncategorizedPage.transactions.nth(0)).toHaveText(
'KrogerUncategorized-12.34',
);
await expect(page).toMatchThemeScreenshots();
});

test('creates a categorized transaction from `/accounts/uncategorized` page', async () => {
// Create uncategorized transaction
let transactionEntryPage = await navigation.goToTransactionEntryPage();
await transactionEntryPage.amountField.fill('12.35');
// Click anywhere to cancel active edit.
await transactionEntryPage.header.click();
await transactionEntryPage.fillField(
page.getByTestId('account-field'),
'Ally Savings',
);
await transactionEntryPage.createTransaction();

const uncategorizedPage = await navigation.goToUncategorizedPage();
transactionEntryPage = await uncategorizedPage.clickCreateTransaction();

await expect(transactionEntryPage.header).toHaveText('New Transaction');

await transactionEntryPage.amountField.fill('12.34');
// Click anywhere to cancel active edit.
await transactionEntryPage.header.click();
await transactionEntryPage.fillField(
page.getByTestId('payee-field'),
'Kroger',
);
await transactionEntryPage.fillField(
page.getByTestId('category-field'),
'Clothing',
);

await transactionEntryPage.createTransaction();

await expect(uncategorizedPage.transactions.nth(0)).toHaveText(
'(No payee)Uncategorized-12.35',
);
await expect(page).toMatchThemeScreenshots();
});
});
8 changes: 4 additions & 4 deletions packages/desktop-client/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@actual-app/web",
"version": "24.11.0",
"version": "24.12.0",
"license": "MIT",
"files": [
"build"
Expand Down Expand Up @@ -50,8 +50,8 @@
"promise-retry": "^2.0.1",
"re-resizable": "^6.9.17",
"react": "18.2.0",
"react-aria": "^3.34.3",
"react-aria-components": "^1.3.3",
"react-aria": "^3.35.1",
"react-aria-components": "^1.4.1",
"react-dnd": "^16.0.1",
"react-dnd-html5-backend": "^16.0.1",
"react-dom": "18.2.0",
Expand All @@ -65,7 +65,7 @@
"react-router-dom": "6.21.3",
"react-simple-pull-to-refresh": "^1.3.3",
"react-spring": "^9.7.3",
"react-stately": "^3.10.9",
"react-stately": "^3.33.0",
"react-virtualized-auto-sizer": "^1.0.21",
"recharts": "^2.10.4",
"redux": "^4.2.1",
Expand Down
49 changes: 23 additions & 26 deletions packages/desktop-client/src/components/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ import { FinancesApp } from './FinancesApp';
import { ManagementApp } from './manager/ManagementApp';
import { Modals } from './Modals';
import { ResponsiveProvider } from './responsive/ResponsiveProvider';
import { ScrollProvider } from './ScrollProvider';
import { SidebarProvider } from './sidebar/SidebarProvider';
import { UpdateNotification } from './UpdateNotification';

Expand Down Expand Up @@ -180,36 +179,34 @@ export function App() {
<SidebarProvider>
<BudgetMonthCountProvider>
<DndProvider backend={HTML5Backend}>
<ScrollProvider>
<View
data-theme={theme}
style={{
height: '100%',
display: 'flex',
flexDirection: 'column',
}}
>
<View
data-theme={theme}
key={
hiddenScrollbars ? 'hidden-scrollbars' : 'scrollbars'
}
style={{
height: '100%',
display: 'flex',
flexDirection: 'column',
flexGrow: 1,
overflow: 'hidden',
...styles.lightScrollbar,
}}
>
<View
key={
hiddenScrollbars ? 'hidden-scrollbars' : 'scrollbars'
}
style={{
flexGrow: 1,
overflow: 'hidden',
...styles.lightScrollbar,
}}
>
<ErrorBoundary FallbackComponent={ErrorFallback}>
{process.env.REACT_APP_REVIEW_ID &&
!Platform.isPlaywright && <DevelopmentTopBar />}
<AppInner />
</ErrorBoundary>
<ThemeStyle />
<Modals />
<UpdateNotification />
</View>
<ErrorBoundary FallbackComponent={ErrorFallback}>
{process.env.REACT_APP_REVIEW_ID &&
!Platform.isPlaywright && <DevelopmentTopBar />}
<AppInner />
</ErrorBoundary>
<ThemeStyle />
<Modals />
<UpdateNotification />
</View>
</ScrollProvider>
</View>
</DndProvider>
</BudgetMonthCountProvider>
</SidebarProvider>
Expand Down
Loading

0 comments on commit 2afa941

Please sign in to comment.