Quick Wins Implementation Plan
For agentic workers: REQUIRED SUB-SKILL: Use superpowers:subagent-driven-development (recommended) or superpowers:executing-plans to implement this plan task-by-task. Steps use checkbox (- [ ]) syntax for tracking.
Goal: Fix passkey SVG visibility in light mode, add a global bridge inbox toast for new X-ray arrivals, and replace the 153k hardcoded referral calculator default with live plan prices.
Architecture: Three independent UI/backend fixes — no new files required, all changes extend existing components in-place.
Tech Stack: React, TypeScript, Sonner (toasts), existing serverComm, lucide-react, Hono
File Map
| File | Change |
|---|---|
ui/public/passkey-rounded.svg | fill="#ffffff" → fill="currentColor" |
ui/src/components/icons/PasskeyIcon.tsx | Forward className, wrap with theme-aware color |
ui/src/contexts/ClinicEventsContext.tsx | No change — kept as pure state |
ui/src/components/shared/XrayArrivalToast.tsx | New — tiny component, mounts once, fires toast on new_xray |
ui/src/App.tsx | Mount <XrayArrivalToast /> inside ClinicEventsProvider |
ui/src/components/referrals/ReferralsModule.tsx | Replace '153000' default with fetched plan price |
ui/src/lib/serverComm.ts | Add annualPrice to getSubscriptionPlans() return type |
Task 1: Passkey SVG — Light Mode Fix
Files:-
Modify:
ui/public/passkey-rounded.svg -
Modify:
ui/src/components/icons/PasskeyIcon.tsx - Step 1: Fix SVG fill
ui/public/passkey-rounded.svg. Change fill="#ffffff" to fill="currentColor". The entire file should become:
- Step 2: Read
PasskeyIcon.tsx
ui/src/components/icons/PasskeyIcon.tsx fully to understand its current props and usage.
- Step 3: Add theme-aware color class
<img> tag (or however the SVG is rendered) so the icon inherits text-foreground for theme awareness. The component should accept and forward a className prop. If the icon currently uses <img src="/passkey-rounded.svg">, switch to an inline <img> with className that sets color context — but since SVG fill="currentColor" only works with inline SVG or CSS color, wrap the img in a span with text-foreground dark:text-white:
ui/src/index.css (or global styles):
- Step 4: Verify visually
npm run dev in ui/. Open the PasskeySetupModal and SecuritySettingsPage in both light and dark mode. Confirm icon is visible in both.
- Step 5: Commit
Task 2: Bridge Inbox — Global Toast for New X-ray
Files:- Create:
ui/src/components/shared/XrayArrivalToast.tsx - Modify:
ui/src/App.tsx
new_xray event to all connected clinic users via SSE. This event lands in ClinicEventsContext as lastEvent. Currently no toast is shown. The bridge inbox view is at /dashboard?view=bridge-inbox.
- Step 1: Create
XrayArrivalToast.tsx
- Step 2: Mount in
App.tsx
ui/src/App.tsx to find where ClinicEventsProvider wraps the app. Add <XrayArrivalToast /> inside that provider (it needs access to useEventBus). Find the <ClinicEventsProvider> tag and add the component as a child:
- Step 3: Verify
/dashboard?view=bridge-inbox.
- Step 4: Commit
Task 3: Referral Calculator — Remove 153k Hardcoding
Files:- Modify:
ui/src/lib/serverComm.ts— addannualPriceto return type - Modify:
ui/src/components/referrals/ReferralsModule.tsx— fetch plans, default to Pro annual price
exampleNetAmount initialized to '153000' (the Pro annual price). The actual Pro annual price in DB is 152990.00. Rather than hardcode it, fetch plans from the API and use the Pro plan’s annualPrice. The calculator input field stays editable — we just initialize it correctly and add a plan selector.
- Step 1: Add
annualPriceto serverComm type
ui/src/lib/serverComm.ts, find the getSubscriptionPlans() function (around line 2097) and update its return type:
- Step 2: Update
ReferralsModule.tsx
ui/src/components/referrals/ReferralsModule.tsx fully first.
Replace the hardcoded useState('153000') with a plan-driven default. Add plan fetching on mount. The calculator gets a plan selector dropdown above the amount input:
exampleNetAmount input is rendered (around line 223) and add above it:
"153000" to "Enter annual plan amount".
- Step 3: Verify
- Step 4: Commit

