Skip to content

Add configurable camera preview scaling options#126

Merged
ismoy merged 9 commits into
mainfrom
develop
May 5, 2026
Merged

Add configurable camera preview scaling options#126
ismoy merged 9 commits into
mainfrom
develop

Conversation

@ismoy
Copy link
Copy Markdown
Owner

@ismoy ismoy commented May 5, 2026

Description

Fixes #


Type of Change

  • Bug fix (non-breaking change that fixes an issue)
  • New feature (non-breaking change that adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation update
  • Refactoring / code cleanup (no functional changes)
  • Performance improvement
  • Test additions or improvements
  • Security fix

Testing

  • Unit tests (commonTest)
  • Android instrumented tests
  • iOS tests
  • Tested manually on Android
  • Tested manually on iOS
  • Tested on Desktop (JVM)
  • Tested on Web (JS / Wasm)

Test configuration:

  • Device / Emulator:
  • OS version:
  • Library version tested against:

Screenshots / Screen Recording (if applicable)

Before After

Checklist

  • My code follows the Kotlin coding conventions
  • I have run ./gradlew detekt and there are no new issues
  • I have added/updated tests to cover my changes
  • All existing tests pass (./gradlew test)
  • I have updated the relevant documentation (KDoc, docs/, README if needed)
  • I have added an entry to docs/CHANGELOG.md under [Unreleased]
  • My branch is based on develop (not main)
  • I have not introduced any breaking API changes (or they are documented and justified)

Additional Notes

jadlr and others added 9 commits May 2, 2026 08:51
The Android PreviewView was hardcoded to FILL_CENTER, which crops the 4:3
camera feed to fit tall phone viewports. The captured image, however, is
saved at full 4:3 — so the confirmation screen reveals content that was
not visible during framing.

Expose PreviewScaleType on CameraCaptureConfig and CameraPreviewConfig so
callers can opt into FIT_CENTER (letterbox the preview to match capture).
Defaults to FILL_CENTER to preserve existing behavior.
Merge pull request #122 from ismoy/develop
…ate code comments

- Add `CameraScaleType` enum to control Android camera preview scaling (FILL vs FIT)
- Add `confirmationImageContentScale` to `PermissionAndConfirmationConfig` for post-capture preview customization
- Update documentation and changelog to reflect v1.0.41 changes
@ismoy ismoy merged commit 90f2937 into main May 5, 2026
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.

2 participants