screenstack_sdk 2.0.2
screenstack_sdk: ^2.0.2 copied to clipboard
Automated screenshot capture for Flutter apps. Configure routes, capture screens during CI/CD builds, and upload to ScreenStack device frames for app store assets.
Changelog #
2.0.2 #
Documentation #
- Authentication guide: Comprehensive section on handling auth in screenshots
- Option 1: Setup/teardown callbacks with Firebase, Supabase, custom examples
- Option 2: Demo/screenshot mode pattern for bypassing auth
- Option 3: Test-specific routes (e.g.,
/preview/dashboard)
- Environment variables: Guidance on storing secrets in CI/CD pipelines
- Best practices: Updated auth section with practical examples
2.0.1 #
New Features #
setupcallback: Run authentication or data seeding before capture startsteardowncallback: Run cleanup after capture completesScreenStackCallbacktype: Type alias for setup/teardown functions
Example #
await captureScreenStackScreenshots(
tester,
binding,
config,
setup: (tester, context) async {
// Authenticate before capturing protected screens
await AuthService.signIn(email: 'test@example.com', password: 'test');
await tester.pumpAndSettle();
},
teardown: (tester, context) async {
await AuthService.signOut();
},
);
2.0.0 #
Breaking Changes #
captureScreenStackScreenshots()now returnsCaptureSessionResultinstead ofvoid
New Features #
- Multi-canvas support: Upload screenshots to multiple canvases simultaneously
FrameTargetclass: Type-safe canvas/view targeting withFrameTarget(canvas: 'iOS', view: 'Home')Screenclass: Define routes with explicit upload targetsScreenStackConfig.advanced()constructor: For multi-canvas projectsScreen.withPaths()factory: Parse targets from"canvas/view"string formatFrameTarget.parse()factory: Create targets from path strings- JSON manifest generation:
manifest.jsonwith capture results and targets CaptureResultclass: Detailed results per captured screenCaptureSessionResultclass: Session summary with success/failure counts- Config validation:
config.validate()returns list of configuration errors - Per-screen settle delay: Override global delay for specific screens
Improvements #
- Comprehensive library documentation with examples
- Better error messages for navigation failures
- Emoji-enhanced console output for capture progress
effectiveNamegetter auto-generates filename from route if not specified
Documentation #
- Complete API reference in README
- ScreenStack hierarchy explanation
- Workflow diagram
- Best practices and troubleshooting guide
1.0.0 #
- Initial release
ScreenStackConfigclass for type-safe configurationcaptureScreenStackScreenshots()helper for integration tests- Support for go_router and Navigator navigation
- Configurable settle delay