Commit Graph

9 Commits

Author SHA1 Message Date
5154990acd feat(notifications): implement notification router with email, push, SMS support
- Add notification router (sendEmail, sendPush, sendSMS, device mgmt, prefs)
- Create provider clients: Resend, Firebase Admin (FCM), Twilio
- Add notification_preferences table to Drizzle schema
- Create branded email templates (welcome, alert, password reset, family invite, billing)
- Implement notification service with error handling and E.164 validation
- Wire router into app root
- Write unit tests with mocked providers (25 tests passing)
- Add resend, firebase-admin, twilio dependencies
2026-05-25 16:13:02 -04:00
40a9ef146c feat(billing): add subscription and Stripe billing router
- Add stripeCustomerId column to users table
- Create Stripe client initialization (web/src/server/stripe.ts)
- Add billing service with getOrCreateCustomer, checkout/portal sessions,
  subscription management, invoice listing, and webhook event handling
- Create billing tRPC router with getSubscription, createCheckoutSession,
  createPortalSession, cancelSubscription, reactivateSubscription, listInvoices
- Add raw webhook endpoint at /api/stripe/webhook with signature verification
- Define Valibot schemas for all billing procedure inputs
- Wire billing router into root tRPC router
- Update schema tests for new column/index counts
- Write unit tests for billing service and router
2026-05-25 16:07:00 -04:00
71972436b6 feat: add tRPC auth context, middleware, and protected procedures
- Install jose (JWT) and bcryptjs (password hashing) dependencies
- Create auth utilities: JWT sign/verify, password hash/verify, session management
- Create createTRPCContext that extracts auth from session cookie, Bearer JWT, or x-api-key
- Add publicProcedure, protectedProcedure, adminProcedure, rateLimitedProcedure with middleware
- Wire context builder into SolidStart tRPC API handler
- Update tRPC client to inject auth tokens and handle 401 redirects
- Add unit tests for JWT, password, context builder, and middleware
2026-05-25 15:46:52 -04:00
052e08c17b feat(db): add PostgreSQL connection, migration runner, and seed data
- Add pool export and graceful shutdown hook to db/index.ts
- Create migrate.ts — programmatic migration runner using drizzle-orm/migrator
- Create seed.ts — idempotent seed script with sample users, subscriptions,
  watchlist items, exposures, alerts, blog posts, properties, and removal requests
- Create db.test.ts — unit tests for db, migrate, and seed module exports
- Add web/.env.example documenting DATABASE_URL
- Add db:generate, db:push, db:migrate, db:seed scripts to web/package.json
2026-05-25 15:39:20 -04:00
bc20aeaeb6 feat: migrate full Prisma schema to Drizzle ORM (29 tables, 28 enums, 25 relations)
- Install drizzle-orm, drizzle-kit, pg, @types/pg in web/
- Create split schema directory with domain files:
  - auth (users, accounts, sessions, deviceTokens)
  - subscription (familyGroups, familyGroupMembers, subscriptions)
  - darkwatch (watchlistItems, exposures)
  - alerts
  - voiceprint (voiceEnrollments, voiceAnalyses, analysisJobs, analysisResults)
  - spamshield (spamFeedback, spamRules)
  - audit (auditLogs, kpiSnapshots)
  - correlation (normalizedAlerts, correlationGroups)
  - reports (securityReports)
  - marketing (waitlistEntries, blogPosts)
  - hometitle (propertyWatchlistItems, propertySnapshots, propertyChanges)
  - removebrokers (infoBrokers, removalRequests, brokerListings)
- Define all 28 PostgreSQL enums via pgEnum()
- Define all indexes, unique constraints, and foreign keys
- Define all 25 relation definitions via relations() helper
- Update drizzle.config.ts for PostgreSQL dialect
- Update db/index.ts for node-postgres connection
- Replace old placeholder schema.ts with barrel re-export
- Add 38 comprehensive schema tests
2026-05-25 15:35:10 -04:00
4118a25388 feat: add UI primitive library — Button, Card, Input, Badge, Modal, Toast
- Add cn() utility for class merging in lib/utils.ts
- Button: primary/secondary/ghost/danger variants, sm/md/lg sizes, disabled/loading states
- Card: gradient-card background with optional header/footer slots
- Input: text/email/password/number types with label, error, helper text, focus ring
- Badge: default/success/warning/error/info variants
- Modal: Portal-based dialog with focus trap, ESC/backdrop close, animations
- Toast: ToastProvider context with show/dismiss/auto-dismiss and variant support
- Barrel export via index.ts
- 46 unit tests across all primitives
- Configure vitest with vite-plugin-solid for JSX support
2026-05-25 13:03:00 -04:00
06bf9ac97c feat: add ShieldAI theme system with auto-shifting CSS and useTheme hook 2026-05-25 12:42:26 -04:00
f627033665 feat: establish unified project foundation with root config cleanup
- Archive legacy packages/, services/, server/ directories
- Update pnpm workspace to web + browser-ext
- Simplify root package.json scripts to delegate to web/
- Update turbo.json for new workspace structure
- Remove obsolete root config files (vite, tsconfig, etc.)
- Add .nvmrc, .editorconfig for consistent dev environment
- Update CI workflow to remove references to deleted packages
- Add missing dependencies (@tailwindcss/vite, tailwindcss) to web
- Add test and lint scripts to web package
- Verify pnpm install, build, and dev work correctly
2026-05-25 12:31:43 -04:00
24459442a2 android + ios base 2026-05-25 12:02:31 -04:00