Commit graph

18 commits

Author SHA1 Message Date
d838d1be96
Step 4: Add admin UI page for pricing configuration
- Add pricing API functions to admin.ts
- Create admin pricing page with form and validation
- Add MANAGE_PRICING permission to auth context
- Add pricing to admin navigation
- Add translations for pricing page (en, ca, es)
- Update PageLayout and Header types for new page
2025-12-26 20:17:48 +01:00
a5a1a2c1ad
Phase 4: Translate Shared Components - common, navigation, status labels
- Translate LoadingState and EmptyState components (common namespace)
- Translate Header navigation labels (navigation namespace)
- Translate StatusBadge trade status labels (exchange namespace)
- Create navigation.json translation files for es, en, ca
- Create exchange.json translation files for status/direction/transfer labels
- Update IntlProvider to load navigation and exchange namespaces
- Update frontend tests to expect Spanish translations (default language)
- Configure Playwright to use English language for e2e tests via storageState
- Fix test expectations to match translated strings

All frontend and e2e tests passing.
2025-12-25 22:06:39 +01:00
f86ec8b62d
Phase 2: Language Context & Selector - Add language dropdown to Header and auth pages
- Create LanguageSelector component with dropdown (shows flag + name)
- Add LanguageSelector to Header (right side, near user email/logout)
- Add LanguageSelector to login, signup, and signup/[code] pages
- Create test-utils.tsx with renderWithProviders helper
- Add vitest.setup.ts to mock localStorage
- Update all test files to use renderWithProviders
- Language selector persists choice in localStorage
- HTML lang attribute updates dynamically based on selected language

All frontend and e2e tests passing.
2025-12-25 21:54:19 +01:00
4e6f38e4a1
refactor: Extract SatsDisplay component and fix page IDs
- Extract SatsDisplay component to shared components directory
- Fix page IDs: rename 'admin-appointments' to 'admin-trades'
- Fix trades page using correct 'trades' page ID
2025-12-23 10:44:11 +01:00
d6002b0cfc
Phase 3.3: Add Admin Trades page
New /admin/trades page for managing exchange trades:
- Upcoming trades tab with user contact info
- History tab with status/user search filters
- Complete/No-show/Cancel actions for admin
- Trade details: direction, amounts, rates, premium

Update navigation:
- Admin home redirects to /admin/trades
- Regular user home redirects to /exchange
- Header shows 'Trades' for admin
2025-12-22 20:06:16 +01:00
3785d6242d
Phase 3.2: Add My Trades page
New /trades page for viewing user's Bitcoin trades:
- Upcoming trades with cancel functionality
- Trade history (completed, cancelled, no-show)
- Direction badges (BUY/SELL with colors)
- EUR ↔ BTC amounts in readable format
- Rate and premium display

Update Header navigation:
- Exchange replaces Book for regular users
- My Trades replaces Appointments

Update profile page test for new nav items.
2025-12-22 20:02:00 +01:00
a5c1eccb4b
Phase 0.2: Remove frontend deprecated code
- Delete pages: sum, audit, admin/random-jobs
- Delete old homepage (counter) and create redirect page
- Update Header.tsx: remove Counter, Sum, Audit, Random Jobs nav items
- Update auth-context.tsx: remove VIEW_COUNTER, INCREMENT_COUNTER, USE_SUM permissions
- Update profile/page.test.tsx: fix nav link assertions
2025-12-22 18:09:09 +01:00
c2dd7b5b91
feat: add price history admin page with fetch button 2025-12-22 15:49:41 +01:00
b8470b77a7
Phase 5: Frontend Admin Page
- Create /admin/random-jobs/page.tsx with outcomes table
- Add 'admin-random-jobs' to PageId type in Header
- Add 'Random Jobs' nav item to ADMIN_NAV_ITEMS
- Display: ID, Job ID, Triggered By, Value, Duration, Status, Created At
- Uses VIEW_AUDIT permission
2025-12-21 22:55:56 +01:00
37de6f70e0
Add Prettier for TypeScript formatting
- Install prettier
- Configure .prettierrc.json and .prettierignore
- Add npm scripts: format, format:check
- Add Makefile target: format-frontend
- Format all frontend files
2025-12-21 21:59:26 +01:00
b3e00b0745
Phase 6: Admin appointments view and cancellation with UI and backend tests 2025-12-21 00:30:09 +01:00
5108a620e7
Phase 5: User appointments view and cancellation with UI and e2e tests 2025-12-21 00:24:16 +01:00
8ff03a8ec3
Phase 4: Booking UI for regular users with date selection, slot booking, and e2e tests 2025-12-21 00:15:29 +01:00
f6cf093cb1
Phase 2: Admin availability UI with calendar grid, edit modal, and e2e tests 2025-12-20 23:54:34 +01:00
d3638e2e69
implemented 2025-12-20 23:06:05 +01:00
23049da55a
first round of review 2025-12-20 11:43:32 +01:00
870804e7b9
first implementation 2025-12-20 11:12:11 +01:00
75cfc6c928
some fixes and refactors 2025-12-19 11:08:19 +01:00