Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
56 commits
Select commit Hold shift + click to select a range
083973d
allow parse Enum with nullable String
CaoGiaHieu-dev Feb 28, 2025
b50c1b2
bump and update change log
CaoGiaHieu-dev Feb 28, 2025
454b269
reformat
CaoGiaHieu-dev Feb 28, 2025
456d6c1
reformat
CaoGiaHieu-dev Feb 28, 2025
ba31e42
Merge branch 'main' into main
CaoGiaHieu-dev Feb 28, 2025
4fdc26a
update
CaoGiaHieu-dev Feb 28, 2025
13bdc00
update
CaoGiaHieu-dev Feb 28, 2025
6281ddd
update test
CaoGiaHieu-dev Feb 28, 2025
d220bd8
update
CaoGiaHieu-dev Feb 28, 2025
31ae729
fix suffix
CaoGiaHieu-dev Mar 1, 2025
5cb1f71
Merge branch 'main' into main
CaoGiaHieu-dev Mar 1, 2025
877c5fb
Merge branch 'main' into main
CaoGiaHieu-dev Mar 3, 2025
24f5301
Update CHANGELOG.md
CaoGiaHieu-dev Mar 4, 2025
11338d8
Merge branch 'main' into main
CaoGiaHieu-dev Mar 4, 2025
6b23b9d
Merge branch 'main' into main
CaoGiaHieu-dev Mar 4, 2025
c59d3e9
Merge branch 'flutter:main' into main
CaoGiaHieu-dev Mar 19, 2025
e9180dc
fix warning
CaoGiaHieu-dev Mar 19, 2025
aad960c
fix
CaoGiaHieu-dev Mar 19, 2025
c9dcab4
fix
CaoGiaHieu-dev Mar 19, 2025
fb94d91
fix gen lints
CaoGiaHieu-dev Mar 19, 2025
689c8cb
update
CaoGiaHieu-dev Mar 19, 2025
eaf2023
update change log
CaoGiaHieu-dev Mar 19, 2025
1461d76
Update CHANGELOG.md
CaoGiaHieu-dev Mar 20, 2025
d9fa7fc
Merge branch 'main' into main
CaoGiaHieu-dev Mar 20, 2025
1cd9202
Merge branch 'main' into main
CaoGiaHieu-dev Mar 21, 2025
ce7e829
Update pubspec.yaml
CaoGiaHieu-dev Mar 22, 2025
a0e602e
Merge branch 'main' into main
CaoGiaHieu-dev Mar 29, 2025
aa41975
Merge branch 'main' into main
CaoGiaHieu-dev Apr 2, 2025
84ce9ac
Merge branch 'main' into main
CaoGiaHieu-dev Apr 9, 2025
b4830ea
Merge branch 'main' into main
CaoGiaHieu-dev Apr 12, 2025
a572081
Merge branch 'main' into main
CaoGiaHieu-dev Apr 14, 2025
34d6bf3
Update type_helpers.dart
CaoGiaHieu-dev May 2, 2025
fbc2b8e
Update type_helpers.dart
CaoGiaHieu-dev May 2, 2025
db90f8b
Merge branch 'main' into main
CaoGiaHieu-dev May 2, 2025
a9a574c
Merge branch 'main' into main
CaoGiaHieu-dev May 3, 2025
a85e984
Merge branch 'main' into main
CaoGiaHieu-dev May 6, 2025
1c8c848
Merge branch 'main' into main
CaoGiaHieu-dev May 9, 2025
871a2d2
Update pubspec.yaml
CaoGiaHieu-dev May 9, 2025
685b8e8
Merge branch 'main' into main
CaoGiaHieu-dev May 10, 2025
50c4e78
Merge branch 'main' into main
CaoGiaHieu-dev May 16, 2025
960fd08
Merge branch 'main' into main
CaoGiaHieu-dev May 23, 2025
06a0d59
Merge branch 'main' into main
CaoGiaHieu-dev Jun 12, 2025
d1a7c75
Merge branch 'main' into main
CaoGiaHieu-dev Jul 7, 2025
4b79fe6
update
CaoGiaHieu-dev Jul 7, 2025
992a897
update
CaoGiaHieu-dev Jul 7, 2025
d0bbc51
bump
CaoGiaHieu-dev Jul 7, 2025
c0fb4cb
update
CaoGiaHieu-dev Jul 7, 2025
e7222c4
update
CaoGiaHieu-dev Jul 7, 2025
d7ffa9e
Merge branch 'main' into main
CaoGiaHieu-dev Jul 9, 2025
6b77867
Merge branch 'main' into main
CaoGiaHieu-dev Jul 22, 2025
2d4a5cc
Merge branch 'main' into CaoGiaHieu-dev/main
CaoGiaHieu-dev Aug 14, 2025
8b41333
Merge branch 'main' into main
CaoGiaHieu-dev Aug 15, 2025
2f59d48
Merge branch 'main' into main
CaoGiaHieu-dev Aug 15, 2025
6feaa64
fix
CaoGiaHieu-dev Aug 18, 2025
46923f3
Merge branch 'main' into main
CaoGiaHieu-dev Aug 18, 2025
b6942a8
Merge branch 'main' into main
CaoGiaHieu-dev Aug 20, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Merge branch 'main' into CaoGiaHieu-dev/main
* main: (56 commits)
  [go_router_builder] Support extension types (#9458)
  Roll Flutter from e2a347b to 34c2a3b (41 revisions) (#9803)
  [go_router_builder] Migrate to Element2 API and update dependencies (#9649)
  [in_app_purchase_storekit] Add support for quantity in consumable product purchases (#171570) (#9698)
  [pigeon] Improves documentation of `ProxyApi` and moves helper functions to a separate file (#9756)
  Roll Flutter from 1590543 to e2a347b (1 revision) (#9784)
  [camera_avfoundation] Implementation swift migration - part 11 (#9690)
  [camera_avfoundation] Fix crash when streaming while recording (#9691)
  Roll Flutter from 3821790 to 1590543 (14 revisions) (#9780)
  Roll Flutter from 92a6bfb to 3821790 (17 revisions) (#9778)
  [video_player] Improve KVO handling on iOS (#9718)
  [dependabot]: Bump the test-dependencies group across 15 directories with 7 updates (#9736)
  Roll Flutter from 9de63a0 to 92a6bfb (11 revisions) (#9769)
  [google_maps_flutter_platform_interface] Add Advanced markers support (#9737)
  [camera_android_camerax] Re-land "Force new Surface for each SurfaceRequest" (#9760)
  [google_maps_flutter] Add ability to perform Google Maps SDK warmup (#9674)
  Roll Flutter from 59fc766 to 9de63a0 (6 revisions) (#9764)
  [webview_flutter_wkwebview] Extended Web View API on iOS to add flexibility when working with local HTML content (#8787)
  [local_auth] Differentiate iOS authentication errors (#9705)
  manual roll to 59fc766 (#9758)
  ...

# Conflicts:
#	packages/go_router_builder/lib/src/type_helpers.dart
#	packages/go_router_builder/pubspec.yaml
  • Loading branch information
CaoGiaHieu-dev committed Aug 14, 2025
commit 2d4a5ccd14804fbd37a65fdf6b0a32f3d6a15df4
8 changes: 4 additions & 4 deletions packages/go_router_builder/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 3.2.1

- Fixes warnings in generated code of iterable parameters.

## 3.2.0

- Adds support for`extension type`.
Expand All @@ -10,10 +14,6 @@
- Improves test code formatting consistency.
- Updates minimum supported SDK version to Flutter 3.29/Dart 3.7.

## 3.0.2

- Fixes warnings in generated code of iterable parameters.

## 3.0.1

- Updates README.md to use the mixin `with _$RouteName`.
Expand Down
21 changes: 12 additions & 9 deletions packages/go_router_builder/lib/src/type_helpers.dart
Original file line number Diff line number Diff line change
Expand Up @@ -482,15 +482,17 @@ class _TypeHelperIterable extends _TypeHelperWithHelper {
// get correct type for iterable
String iterableCaster = '';
String fallBack = '';
if (const TypeChecker.fromRuntime(List)
.isAssignableFromType(parameterElement.type)) {
if (const TypeChecker.fromRuntime(
List,
).isAssignableFromType(parameterElement.type)) {
iterableCaster += '.toList()';
if (!parameterElement.type.isNullableType &&
!parameterElement.hasDefaultValue) {
fallBack = '?? const []';
}
} else if (const TypeChecker.fromRuntime(Set)
.isAssignableFromType(parameterElement.type)) {
} else if (const TypeChecker.fromRuntime(
Set,
).isAssignableFromType(parameterElement.type)) {
iterableCaster += '.toSet()';
if (!parameterElement.type.isNullableType &&
!parameterElement.hasDefaultValue) {
Expand All @@ -500,7 +502,7 @@ class _TypeHelperIterable extends _TypeHelperWithHelper {

return '''
state.uri.queryParametersAll[
${escapeDartString(parameterElement.name.kebab)}]
${escapeDartString(parameterElement.displayName.kebab)}]
?.map($entriesTypeDecoder)$convertToNotNull$iterableCaster$fallBack''';
}
return '''
Expand Down Expand Up @@ -559,10 +561,11 @@ abstract class _TypeHelperWithHelper extends _TypeHelper {
'${helperName(paramType)})';
}

final String nullableSuffix = paramType.isNullableType ||
(paramType.isEnum && !paramType.isNullableType)
? '!'
: '';
final String nullableSuffix =
paramType.isNullableType ||
(paramType.isEnum && !paramType.isNullableType)
? '!'
: '';

return '${helperName(paramType)}'
'(state.${_stateValueAccess(parameterElement, pathParameters)} ${!parameterElement.isRequired ? " ?? '' " : ''})$nullableSuffix';
Expand Down
4 changes: 2 additions & 2 deletions packages/go_router_builder/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: go_router_builder
description: >-
A builder that supports generated strongly-typed route helpers for
package:go_router
version: 3.0.2
version: 3.2.1
repository: https://github.com/flutter/packages/tree/main/packages/go_router_builder
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+go_router_builder%22

Expand All @@ -23,7 +23,7 @@ dependencies:

dev_dependencies:
build_test: ^3.3.0
dart_style: '>=2.3.7 <4.0.0'
dart_style: ">=2.3.7 <4.0.0"
flutter:
sdk: flutter
go_router: ^16.0.0
Expand Down
You are viewing a condensed version of this merge commit. You can view the full changes here.