From b6462347a937541cfc217c0fbbb285d81dbad8dc Mon Sep 17 00:00:00 2001 From: HansiWursti Date: Sat, 6 Jan 2024 23:33:59 +0100 Subject: [PATCH 1/2] Add "error" Page for special accounts in Mobile (#2114) * Add "error" Page for special accounts in Mobile --- .../src/components/accounts/MobileAccount.jsx | 26 ++++++++++++++++++- upcoming-release-notes/2114.md | 6 +++++ 2 files changed, 31 insertions(+), 1 deletion(-) create mode 100644 upcoming-release-notes/2114.md diff --git a/packages/desktop-client/src/components/accounts/MobileAccount.jsx b/packages/desktop-client/src/components/accounts/MobileAccount.jsx index f0a1f4ae5e0..85233245dd7 100644 --- a/packages/desktop-client/src/components/accounts/MobileAccount.jsx +++ b/packages/desktop-client/src/components/accounts/MobileAccount.jsx @@ -22,7 +22,10 @@ import { import { useCategories } from '../../hooks/useCategories'; import { useNavigate } from '../../hooks/useNavigate'; import { useSetThemeColor } from '../../hooks/useSetThemeColor'; -import { theme } from '../../style'; +import { theme, styles } from '../../style'; +import Button from '../common/Button'; +import Text from '../common/Text'; +import View from '../common/View'; import { AccountDetails } from './MobileAccountDetails'; @@ -171,6 +174,27 @@ export function Account(props) { return null; } + if ( + accountId === 'budgeted' || + accountId === 'offbudget' || + accountId === 'uncategorized' + ) { + return ( + + + There is no Mobile View at the moment + + + + ); + } + const account = accounts.find(acct => acct.id === accountId); const isNewTransaction = id => { diff --git a/upcoming-release-notes/2114.md b/upcoming-release-notes/2114.md new file mode 100644 index 00000000000..0e02c17de1c --- /dev/null +++ b/upcoming-release-notes/2114.md @@ -0,0 +1,6 @@ +--- +category: Bugfix +authors: [HansiWursti] +--- + +mobile: error page for special account urls From e0d82fd4f983c6f8451d670ec86b04fb797b7bde Mon Sep 17 00:00:00 2001 From: DJ Mountney Date: Sat, 6 Jan 2024 15:20:19 -0800 Subject: [PATCH 2/2] Revert "Add "error" Page for special accounts in Mobile" (#2186) * Revert "Add "error" Page for special accounts in Mobile (#2114)" This reverts commit b6462347a937541cfc217c0fbbb285d81dbad8dc. --- .../src/components/accounts/MobileAccount.jsx | 26 +------------------ upcoming-release-notes/2114.md | 6 ----- upcoming-release-notes/2186.md | 6 +++++ 3 files changed, 7 insertions(+), 31 deletions(-) delete mode 100644 upcoming-release-notes/2114.md create mode 100644 upcoming-release-notes/2186.md diff --git a/packages/desktop-client/src/components/accounts/MobileAccount.jsx b/packages/desktop-client/src/components/accounts/MobileAccount.jsx index 85233245dd7..f0a1f4ae5e0 100644 --- a/packages/desktop-client/src/components/accounts/MobileAccount.jsx +++ b/packages/desktop-client/src/components/accounts/MobileAccount.jsx @@ -22,10 +22,7 @@ import { import { useCategories } from '../../hooks/useCategories'; import { useNavigate } from '../../hooks/useNavigate'; import { useSetThemeColor } from '../../hooks/useSetThemeColor'; -import { theme, styles } from '../../style'; -import Button from '../common/Button'; -import Text from '../common/Text'; -import View from '../common/View'; +import { theme } from '../../style'; import { AccountDetails } from './MobileAccountDetails'; @@ -174,27 +171,6 @@ export function Account(props) { return null; } - if ( - accountId === 'budgeted' || - accountId === 'offbudget' || - accountId === 'uncategorized' - ) { - return ( - - - There is no Mobile View at the moment - - - - ); - } - const account = accounts.find(acct => acct.id === accountId); const isNewTransaction = id => { diff --git a/upcoming-release-notes/2114.md b/upcoming-release-notes/2114.md deleted file mode 100644 index 0e02c17de1c..00000000000 --- a/upcoming-release-notes/2114.md +++ /dev/null @@ -1,6 +0,0 @@ ---- -category: Bugfix -authors: [HansiWursti] ---- - -mobile: error page for special account urls diff --git a/upcoming-release-notes/2186.md b/upcoming-release-notes/2186.md new file mode 100644 index 00000000000..a9b4cdfea69 --- /dev/null +++ b/upcoming-release-notes/2186.md @@ -0,0 +1,6 @@ +--- +category: Maintenance +authors: [twk3] +--- + +Revert to fix master: Add error Page for special accounts in Mobile