From 56ee375ee9be05f8d80cc74c618035c4a2d5766c Mon Sep 17 00:00:00 2001 From: Ammar Ahmed Date: Mon, 18 May 2026 12:21:37 +0500 Subject: [PATCH] mobile: update ui --- apps/mobile/app/common/design/theme.ts | 15 +- apps/mobile/app/components/auth/login.tsx | 8 +- .../mobile/app/components/auth/two-factor.tsx | 5 +- .../app/components/dialog/dialog-buttons.tsx | 4 +- .../list-items/headers/section-header.tsx | 8 +- .../app/components/list-items/note/index.tsx | 161 ++++++++++-------- .../list-items/selection-wrapper/index.tsx | 29 +++- apps/mobile/app/components/list/card.tsx | 3 +- apps/mobile/app/components/list/empty.tsx | 75 ++++---- .../app/components/paywall/compare-plans.tsx | 12 +- apps/mobile/app/components/paywall/index.tsx | 74 ++++---- .../app/components/paywall/plan-card.tsx | 7 +- .../components/sheets/add-notebook/index.tsx | 51 +++--- .../app/components/sheets/buy-plan/index.tsx | 10 +- .../app/components/sheets/sort/index.tsx | 23 ++- .../mobile/app/components/side-menu/index.tsx | 2 +- .../app/components/side-menu/menu-item.tsx | 2 +- .../components/side-menu/notebook-item.tsx | 6 +- .../side-menu/side-menu-list-empty.tsx | 9 +- .../side-menu/side-menu-notebooks.tsx | 2 +- .../components/side-menu/side-menu-tags.tsx | 4 +- .../components/side-menu/tab-bar-button.tsx | 8 +- .../app/components/ui/input/form-input.tsx | 3 +- .../app/components/ui/pressable/index.tsx | 19 ++- apps/mobile/app/screens/home/index.tsx | 6 +- apps/mobile/app/services/settings.ts | 5 +- apps/mobile/app/stores/use-theme-store.ts | 5 +- .../fonts/notesnook-icons.glyphmap.json | 2 +- apps/mobile/fonts/notesnook-icons.ttf | Bin 11172 -> 11880 bytes .../ios/nanoicons-fonts/notesnook-icons.ttf | Bin 11172 -> 11880 bytes packages/icons/svgs/cloud.svg | 3 + packages/icons/svgs/file.svg | 3 + packages/icons/svgs/image-outline.svg | 3 + packages/icons/svgs/lock.svg | 10 ++ packages/intl/locale/en.po | 20 ++- packages/intl/locale/pseudo-LOCALE.po | 20 ++- packages/intl/src/strings.ts | 10 +- 37 files changed, 372 insertions(+), 255 deletions(-) create mode 100755 packages/icons/svgs/cloud.svg create mode 100755 packages/icons/svgs/file.svg create mode 100755 packages/icons/svgs/image-outline.svg create mode 100755 packages/icons/svgs/lock.svg diff --git a/apps/mobile/app/common/design/theme.ts b/apps/mobile/app/common/design/theme.ts index 59aba2d68..cb259645a 100644 --- a/apps/mobile/app/common/design/theme.ts +++ b/apps/mobile/app/common/design/theme.ts @@ -49,7 +49,7 @@ export const THEME_LIGHT: ThemeDefinition = { heading: "#181818", icon: "#181818", separator: "#F0F0F0", - placeholder: "#a9a9a9", + placeholder: "#858585", hover: "#eee", backdrop: "#0000001a", buttonForeground: "#FFFFFF" @@ -63,7 +63,7 @@ export const THEME_LIGHT: ThemeDefinition = { heading: "#4B4B4B", icon: "#666666", separator: "#E8E8E8", - placeholder: "#a9a9a9", + placeholder: "#999999", hover: "#dbdbdb", backdrop: "#0000001a", buttonForeground: "#181818" @@ -101,7 +101,7 @@ export const THEME_LIGHT: ThemeDefinition = { background: "#00883610", border: "#008836", heading: "#212121", - icon: "#FFFFFF", + icon: "#181818", separator: "#E8E8E8", placeholder: "#a9a9a9", hover: "#eee", @@ -146,13 +146,18 @@ export const THEME_LIGHT: ThemeDefinition = { }, secondary: { background: "#EEEEEE" }, selected: { - background: "#ddd", + background: "#00883610", hover: "#eee" } }, contextMenu: { primary: { background: "#f7f7f7" } }, editor: { selected: { background: "#e1e1e1" } }, - sheet: { selected: { paragraph: "#008836" } } + sheet: { selected: { paragraph: "#008836" } }, + list: { + secondary: { + heading: "#A6A6A6" + } + } } }; diff --git a/apps/mobile/app/components/auth/login.tsx b/apps/mobile/app/components/auth/login.tsx index 41b52bf00..3b2cb8847 100644 --- a/apps/mobile/app/components/auth/login.tsx +++ b/apps/mobile/app/components/auth/login.tsx @@ -238,6 +238,9 @@ export const Login = ({ fontFamily="REGULAR" fontSize={AppFontSize.sm} type="plain" + textStyle={{ + color: colors.secondary.paragraph + }} /> void + callback: (success: boolean) => void, + onerror: (error: Error) => void ) => { try { const success = await db.user.authenticateMultiFactorCode( @@ -342,6 +346,8 @@ export const Login = ({ if ((e as Error).message === "invalid_grant") { setLoading(false); setStep(LoginSteps.emailAuth); + } else { + onerror(e as Error); } } }} diff --git a/apps/mobile/app/components/auth/two-factor.tsx b/apps/mobile/app/components/auth/two-factor.tsx index fe52f2b1b..6db55cb9b 100644 --- a/apps/mobile/app/components/auth/two-factor.tsx +++ b/apps/mobile/app/components/auth/two-factor.tsx @@ -158,6 +158,7 @@ const TwoFactorVerification = ({ setSending(false); } catch (e) { setSending(false); + console.log("error e"); setError( new Error(`Error sending 2FA Code. Tap "Send code" to try again `) ); @@ -268,7 +269,9 @@ const TwoFactorVerification = ({ style={{ textAlign: "center", marginVertical: DefaultAppStyles.GAP_VERTICAL_SMALL, - maxWidth: 250 + maxWidth: 250, + alignSelf: "center", + marginTop: -10 }} >