Skip to content

Commit 3c5a9ac

Browse files
Merge pull request juliansteenbakker#1423 from juliansteenbakker/develop
feat: release of v7.0.0
2 parents e8bfe5f + 0c9b959 commit 3c5a9ac

File tree

132 files changed

+5508
-3969
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

132 files changed

+5508
-3969
lines changed
Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
name: 📊 Code Coverage
2+
3+
on: [push, pull_request]
4+
5+
env:
6+
PUB_ENVIRONMENT: bot.github
7+
8+
jobs:
9+
test_with_coverage:
10+
name: 🧪 Unit Tests
11+
runs-on: ubuntu-latest
12+
timeout-minutes: 20
13+
14+
steps:
15+
# Checkout the Repository
16+
- name: 📥 Checkout Repository
17+
uses: actions/checkout@v4
18+
19+
# Setup Flutter SDK with Cache
20+
- name: ⚡ Set Up Flutter
21+
uses: subosito/flutter-action@v2
22+
with:
23+
channel: stable
24+
cache: true
25+
26+
# Cache Pub Dependencies
27+
- name: 📦 Cache Pub Dependencies
28+
uses: actions/cache@v4
29+
with:
30+
path: |
31+
~/.pub-cache
32+
.dart_tool
33+
key: ${{ runner.os }}-pub-${{ hashFiles('**/pubspec.yaml') }}
34+
restore-keys: |
35+
${{ runner.os }}-pub-
36+
37+
# Install Project Dependencies
38+
- name: 🚀 Install Dependencies
39+
run: flutter pub get
40+
41+
# Run Tests with Code Coverage
42+
- name: ✅ Run Unit Tests with Coverage
43+
run: flutter test --coverage
44+
45+
# Upload Coverage Report as Artifact
46+
- name: 📊 Upload Coverage Report
47+
uses: actions/upload-artifact@v4
48+
with:
49+
name: coverage-report
50+
path: coverage/lcov.info
51+
52+
# Upload Coverage to Codecov
53+
- name: ☁️ Upload Coverage to Codecov
54+
uses: codecov/codecov-action@v5
55+
with:
56+
token: ${{ secrets.CODECOV_TOKEN }}
57+
files: coverage/lcov.info
58+
flags: unittests
59+
name: codecov-flutter
60+
fail_ci_if_error: true

.github/workflows/code-quality.yml

Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
name: 📝 Code Quality
2+
3+
on: [push, pull_request]
4+
5+
defaults:
6+
run:
7+
shell: bash
8+
9+
env:
10+
PUB_ENVIRONMENT: bot.github
11+
12+
jobs:
13+
analysis:
14+
name: 🔍 Analysis
15+
runs-on: ubuntu-latest
16+
17+
steps:
18+
- name: 📥 Checkout Code
19+
uses: actions/checkout@v4
20+
21+
- name: ⚡ Set Up Flutter
22+
uses: subosito/flutter-action@v2
23+
with:
24+
channel: stable
25+
cache: true
26+
27+
- name: 🔍 Flutter Version Info
28+
run: flutter doctor -v
29+
30+
- name: 📦 Cache Pub Dependencies
31+
uses: actions/cache@v4
32+
with:
33+
path: |
34+
~/.pub-cache
35+
.dart_tool
36+
key: ${{ runner.os }}-pub-${{ hashFiles('**/pubspec.yaml') }}
37+
restore-keys: |
38+
${{ runner.os }}-pub-
39+
40+
- name: 🔧 Bootstrap Workspace
41+
run: flutter pub get
42+
43+
- name: ✅ Lint Code
44+
run: flutter analyze
45+
46+
formatting:
47+
name: 🎨 Formatting
48+
needs: analysis # This makes formatting start after analysis is complete
49+
runs-on: ubuntu-latest
50+
51+
steps:
52+
- name: 📥 Checkout Code
53+
uses: actions/checkout@v4
54+
55+
- name: ⚡ Set Up Flutter
56+
uses: subosito/flutter-action@v2
57+
with:
58+
channel: stable
59+
cache: true
60+
61+
- name: 🔧 Bootstrap Workspace
62+
run: flutter pub get
63+
64+
- name: 🎯 Check Code Formatting
65+
run: dart format --set-exit-if-changed .

.github/workflows/flutter.yml

Lines changed: 0 additions & 63 deletions
This file was deleted.

.github/workflows/release-please.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
release-please:
88
runs-on: ubuntu-latest
99
steps:
10-
- uses: GoogleCloudPlatform/release-please-action@v4.1.3
10+
- uses: GoogleCloudPlatform/release-please-action@v4.2.0
1111
with:
1212
token: ${{ secrets.GITHUB_TOKEN }}
1313
release-type: simple

CHANGELOG.md

Lines changed: 180 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,183 @@
1+
## 7.0.0
2+
3+
This version finalizes all changes from the beta and release candidate cycles and introduces major improvements, bug fixes, and breaking changes.
4+
5+
**BREAKING CHANGES:**
6+
7+
* Requires Flutter 3.29.0 or higher.
8+
* The initial camera facing direction in `MobileScannerState` is now `CameraFacing.unknown`.
9+
* Removed the deprecated `EncryptionType.none`. Use `EncryptionType.unknown` instead.
10+
* The `errorBuilder` and `placeholderBuilder` no longer have a Widget argument.
11+
* Removed the `MobileScannerErrorBuilder` typedef.
12+
13+
**Highlights**
14+
15+
* [iOS/macOS] Migrated to the Vision API with a unified Apple codebase.
16+
* [Android] Removed dependency on `kotlin-bom` and updated CameraX and camera-camera2 dependencies.
17+
* Support for pause/resume functionality across platforms.
18+
* `MobileScannerErrorCode` now includes readable error messages in debug mode.
19+
* Hot-restart during development now works correctly.
20+
* Added overlay widgets for barcode and scan window visualization.
21+
* Exposed new API parameters like `autoZoom`, `invertImage`, and lifecycle handling.
22+
23+
**Bug Fixes and Improvements**
24+
25+
* [Apple]
26+
* Fixed rotation, orientation, and zoom behavior.
27+
* Resolved incorrect barcode overlay dimensions and corner coordinates.
28+
* Fixed a crash when stopping the camera with a nil device.
29+
* Fixed build issues including optional chaining on non-optional values.
30+
* [Android]
31+
* Fixed rotation and orientation issues.
32+
* Resolved timing issues in `SurfaceProducer` with Kotlin 1.8+.
33+
* Fixed resource leaks and improved image analysis compatibility.
34+
* Improved logging behavior (CameraX logs only errors).
35+
* [macOS]
36+
* Fixed mirrored images and build issues.
37+
* [Web]
38+
* Fixed barcode overlay not displaying due to incorrect corner point data.
39+
40+
## 7.0.0-rc.2
41+
42+
Bugs fixed:
43+
* [Apple] Fixed build issues "Cannot use optional chaining on non-optional value".
44+
45+
## 7.0.0-rc.1
46+
47+
After six months of development, Version 7.0.0 is finally moving out of beta with this release candidate!
48+
A stable release is scheduled for next week.
49+
50+
Improvements:
51+
* [Android] Remove the dependency on `org.jetbrains.kotlin:kotlin-bom`.
52+
* [Android] Updated camerax dependencies.
53+
* Hot-restart for development purposes is now working correctly
54+
* Added message to `MobileScannerErrorCode`, which will be shown if kDebugMode is true. Otherwise, a generic error message will appear.
55+
* Fixed issues regarding initialization of the `MobileScannerController`, which could result in a black screen without error message.
56+
57+
Bugs fixed:
58+
* [Android] Fixed rotation & orientation issues.
59+
* [Apple] Fixed rotation & orientation issues.
60+
* [Apple] Fixed a crash when stopping the camera when the camera device is nil.
61+
* [macOS] Fixed image not being mirrored.
62+
* [Web] Fixed barcode corners not being passed correctly resulting in no overlay being drawn.
63+
64+
## 7.0.0-beta.9
65+
66+
**BREAKING CHANGES:**
67+
68+
* This release requires Flutter 3.29.0 or higher.
69+
70+
Bugs fixed:
71+
* [Android] Fixed a timing issue for the SurfaceProducer implementation, by switching to the `onSurfaceCleanup` callback.
72+
73+
## 7.0.0-beta.8
74+
75+
Improvements:
76+
* Updated examples in example app.
77+
* Added [useAppLifecycleState] parameter to enable or disable handling of lifecycle state when no controller is passed.
78+
* Dispose function of [MobileScanner] is now async.
79+
* The [BarcodeOverlay] now correctly disposes the text painter.
80+
81+
Bugs fixed:
82+
* [Apple] Fixed barcode corners representation for barcode overlay.
83+
* [Apple] Fixed zoom callback not working.
84+
* [Apple] Updated zoom scale factor to match Android implementation.
85+
* Fixed build issues on older kotlin versions.
86+
87+
## 7.0.0-beta.7
88+
89+
**BREAKING CHANGES:**
90+
91+
* The initial state of the `MobileScannerState` camera facing direction is changed to `CameraFacing.unknown`.
92+
93+
Improvements:
94+
* [Android] Turn off logging for CameraX, except for the `Log.ERROR` logging level.
95+
* Added `CameraFacing.external` and `CameraFacing.unknown` enum values.
96+
97+
Bugs fixed:
98+
* [Android] Fixed an issue when compiling with Kotlin 1.8.0 or higher.
99+
100+
## 7.0.0-beta.6
101+
102+
**BREAKING CHANGES:**
103+
104+
* This release requires Flutter 3.27.0 or higher.
105+
106+
Improvements:
107+
* [Android] Added support for Impeller.
108+
* [Apple] Added support for `rawBytes` from the Vision API observations.
109+
* Export the `MobileScannerViewAttributes` and `StartOptions` types, to allow them in tests.
110+
111+
Bugs fixed:
112+
* [Apple] Fixed a bug that caused a crash when the capture session could not add the video input.
113+
114+
## 7.0.0-beta.5
115+
116+
Improvements:
117+
* [Android] Added `autoZoom` parameter to auto zoom if the detected code is to far from the camera.
118+
* [Android] Added `invertImage` parameter to invert image colors for analyzer to support white-on-black barcodes, which are not supported by MLKit.
119+
* [Android] Updated camera-camera2 dependencies.
120+
* Added pause functionality to all platforms.
121+
122+
Bugs fixed:
123+
* [Android] Fixed resources not being closed.
124+
125+
## 7.0.0-beta.4
126+
127+
**BREAKING CHANGES:**
128+
129+
* The `updateScanWindow` method is now private. Instead, update the scan window in the `MobileScanner` widget directly.
130+
* The deprecated `EncryptionType.none` constant has been removed. Use `EncryptionType.unknown` instead.
131+
* The `errorBuilder` and `placeholderBuilder` of the `MobileScanner` widget no longer take a Widget argument, as it was unused.
132+
* The `MobileScannerErrorBuilder` typedef has been removed.
133+
134+
Bugs fixed:
135+
* [Apple] Fixed an issue which caused the scanWindow to always be present, even when reset to no value.
136+
* [Apple] Fixed an issue that caused the barcode size to report the wrong height.
137+
* [Apple] Fixed a bug that caused the corner points to not be returned in clockwise orientation.
138+
* [Apple] Fixed an issue where `analyzeImage` would not throw an error if no valid image is provided as argument.
139+
* [Apple] Fixed an issue where `analyzeImage` would not return if no barcodes are found in the image.
140+
* [Apple] Fixed an issue where the iOS Simulator did not report that analyzing images from a file is unsupported.
141+
* [Android] Fixed an issue where `analyzeImage` would not return if no valid image is provided as argument.
142+
143+
Improvements:
144+
* Added a basic barcode overlay widget, for use with the camera preview.
145+
* Added a basic scan window overlay widget, for use with the camera preview.
146+
* Update the bundled MLKit model for Android to version `17.3.0`.
147+
* Added documentation in places where it was missing.
148+
* Added `color` and `style` properties to the `BarcodePainter` widget.
149+
* Enabled Swift Package Manager for the example app.
150+
151+
## 7.0.0-beta.3
152+
153+
* Fixed a build issue on macOS.
154+
155+
## 7.0.0-beta.2
156+
157+
Bugs fixed:
158+
* [Apple] Fixed an issue with the zoom slider being non-functional.
159+
* [Apple] Fixed an issue where the flash would briefly show when the camera is turned on.
160+
* [Apple] Fixed an issue that prevented the scan window from working.
161+
* [Apple] Fixed an issue that caused the barcode overlay to use the wrong dimensions.
162+
163+
Improvements:
164+
* [iOS] Adds support for Swift Package Manager.
165+
166+
Known issues:
167+
* BoxFit.cover & BoxFit.fitHeight produce the wrong width in the barcode overlay.
168+
169+
## 7.0.0-beta.1
170+
171+
Improvements:
172+
* [iOS] Migrate to the Vision API.
173+
* [iOS] Updated the minimum iOS version back down to 12.0.
174+
* [Apple] Merged the iOS and MacOS sources.
175+
176+
Known issues:
177+
* [Apple] The zoom slider does not work correctly.
178+
* [Apple] The scan window does not work correctly.
179+
* [Apple] The camera flash briefly shows when the camera is started.
180+
1181
## 6.0.10
2182
* [Apple] Fixed a crash when stopping the camera when the camera device is nil.
3183

0 commit comments

Comments
 (0)