Skip to content

Conversation

@BadgerOps
Copy link
Owner

Summary

  • Add Playwright-based screenshot automation for README documentation
  • New DemoContext provides mock data with Air Force terminology (Maxwell AFB context)
  • Security: Demo mode only available in development builds (import.meta.env.DEV)
  • Desktop (1280×800) and mobile (375×667) screenshot capture
  • Video recording for GIF conversion with ffmpeg

New npm scripts

  • npm run screenshots - Capture all screenshots
  • npm run screenshots:desktop - Desktop only
  • npm run screenshots:mobile - Mobile only
  • npm run screenshots:video - Record videos for GIFs
  • npm run gifs - Convert videos to GIFs (requires ffmpeg)

Files added

  • screenshots/ - Playwright config, capture spec, GIF converter, README
  • src/contexts/DemoContext.jsx - Mock data and demo auth provider

Files modified

  • src/main.jsx - Wrap app with DemoProvider
  • src/contexts/AuthContext.jsx - Demo mode integration
  • src/hooks/usePosts.js, useAppConfig.js - Demo data support
  • package.json - New scripts and @playwright/test dependency
  • vitest.config.js - Exclude screenshots from vitest

Test plan

  • Run npm run screenshots with dev server - should generate screenshots in screenshots/output/
  • Verify demo mode shows Air Force mock data
  • Verify production build ignores ?demo= URL parameter
  • Run existing tests to ensure no regressions

🤖 Generated with Claude Code

Add Playwright-based screenshot automation to capture app screens with mock
data for README documentation. Uses a demo mode system that injects Air
Force-themed mock data (Maxwell AFB context) instead of connecting to Firebase.

Key features:
- DemoContext provides mock data for all app features
- Demo mode activated via URL param (?demo=admin or ?demo=user)
- Security: Demo mode only works in development builds (import.meta.env.DEV)
- Desktop (1280x800) and mobile (375x667) screenshots
- Video recording for GIF conversion with ffmpeg

npm scripts: screenshots, screenshots:desktop, screenshots:mobile, screenshots:video, gifs

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@github-actions
Copy link

github-actions bot commented Jan 28, 2026

🚀 Preview Deployment

Your preview is ready!

Preview URL: https://wots-app-484617--pr-37-z687rdkx.web.app

This preview will expire in 7 days.

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.

1 participant