Skip to content

Apply Apple HIG design review fixes - #202

Open
31b4 wants to merge 8 commits into
mainfrom
feature/199-apple-design-fixes
Open

31b4 wants to merge 8 commits into
mainfrom
feature/199-apple-design-fixes

Conversation

@31b4

@31b4 31b4 commented Nov 8, 2026

Copy link
Copy Markdown
Member

Closes #199

Summary

This PR fixes the Critical and High findings from an Apple Human Interface Guidelines design review of the whole client. It covers contrast and minimum text size, consistent money and date formatting, following the system appearance, mobile navigation and header, a calmer Analytics page, animated dialogs that behave as swipeable sheets on phones, and consistent category icons. Financial behavior, API and MCP are unchanged: category icons are still stored as emoji, and only their rendering changes.

Changes

  • Contrast: a new --primary-fill token (Original dark only, #2d6dc8) brings white labels on filled controls from 3.55:1 to 5.08:1. The dark --destructive changes to #eb4747, bringing red text on cards from 4.03:1 to 5.09:1. Other themes are unchanged.
  • Minimum text size: all text-[9px]/text-[10px] are removed. Sub-12px text is now 12px, except uppercase labels at 11px. Chart axes move to 11px.
  • Shared formatter: new lib/format.ts (formatNumber, formatMoney, formatCompactNumber, formatPercent, formatDate, formatDateTime, formatTime). It always groups digits, uses a decimal comma, a true minus (U+2212), currency codes after the number, K/M/B compact suffixes, English dates and a 24-hour clock. About 70 call sites across Dashboard, Accounts, sidebar, Analytics, Investments, Recurring and Search use it. Editable inputs still use lib/amount.ts.
  • System appearance: the default is now System (it follows prefers-color-scheme live), with Light/Dark overrides in Settings. An explicit saved light/dark preference is still honored. The sidebar, More and mobile header theme toggles are removed.
  • Mobile navigation: the tab bar has four navigation tabs and no action. "New transaction" moves to the header as a filled button. The header keeps only privacy, search and new, as borderless 44px buttons. The header and tab bar use a translucent material, with reduced-transparency and increased-contrast fallbacks.
  • Analytics: summary cards are neutral, with color only on the figure; on phones they become a grouped card with one row per figure, so amounts never truncate. Mobile filters collapse into one summary row that opens a Filters sheet. The sticky filter bar uses the same material.
  • Dialogs: Modal now animates with framer-motion, which was already a dependency. The previous animate-in classes came from a plugin that isn't installed and did nothing. Phone sheets slide up, have a grabber, and dismiss on a downward swipe using momentum projection. Desktop dialogs scale and fade, drawers slide from the side, and reduced motion uses a crossfade. Tests run animations instantly through MotionGlobalConfig.skipAnimations.
  • Icons: the new CategoryIcon maps the stored emoji to Lucide line icons, falling back to a tag for unknown values. Transactions, calendar, Recurring, Top Expenses, breakdowns, the widget menus and the Settings icon picker use it. Emoji prefixes are removed from native <option>s and Money Map labels.
  • Tests: expectations are updated for the new formatting; new tests cover lib/format.ts and the system-appearance behavior.

Verification

  • npm test -w client: 592/592 pass.
  • (cd client && npx tsc -b): clean.
  • npm run lint -w client -- --max-warnings=0: clean.
  • VITE_API_AUTH_MODE=public VITE_API_DOMAIN=localhost:8787 npm run build: succeeds.
  • Contrast ratios were computed from the HSL tokens.
  • Manual check against a local public-mode API with a disposable seeded database, at 1440×900 and 375×812, dark and light:
    • Dashboard, Analytics, Accounts and Recurring render the new formats and icons.
    • The mobile tab bar has four tabs, and the header "+" opens the composer.
    • The Analytics Filters sheet opens and dismisses by swiping down.
    • Clearing the saved mode follows the system appearance.
  • Not run: integration tests, since no API, MCP or SQL changed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Apply Apple HIG design review fixes (critical and high)

1 participant