diff --git a/example/pubspec.lock b/example/pubspec.lock index b0642fb83..6099c1dd6 100644 --- a/example/pubspec.lock +++ b/example/pubspec.lock @@ -60,7 +60,7 @@ packages: path: ".." relative: true source: path - version: "9.4.0" + version: "9.4.1" flutter_lints: dependency: "direct dev" description: @@ -224,10 +224,10 @@ packages: dependency: transitive description: name: vm_service - sha256: f652077d0bdf60abe4c1f6377448e8655008eef28f128bc023f7b5e8dfeb48fc + sha256: "5c5f338a667b4c644744b661f309fb8080bb94b18a7e91ef1dbd343bed00ed6d" url: "https://pub.dev" source: hosted - version: "14.2.4" + version: "14.2.5" sdks: dart: ">=3.5.0 <4.0.0" flutter: ">=3.24.0" diff --git a/lib/src/fields/form_builder_choice_chips.dart b/lib/src/fields/form_builder_choice_chips.dart index 58db23f2c..662922a58 100644 --- a/lib/src/fields/form_builder_choice_chips.dart +++ b/lib/src/fields/form_builder_choice_chips.dart @@ -252,6 +252,14 @@ class FormBuilderChoiceChip extends FormBuilderFieldDecoration { final ShapeBorder avatarBorder; + /// Indicates whether a checkmark should be displayed on the selected choice chip. + /// + /// Defaults to `true`. + /// + /// When set to `true`, a checkmark will appear on the selected chip to visually + /// indicate its selection status. If set to `false`, no checkmark will be shown. + final bool showCheckmark; + /// Creates a list of `Chip`s that acts like radio buttons FormBuilderChoiceChip({ super.autovalidateMode = AutovalidateMode.disabled, @@ -290,6 +298,7 @@ class FormBuilderChoiceChip extends FormBuilderFieldDecoration { this.textDirection, this.verticalDirection = VerticalDirection.down, this.visualDensity, + this.showCheckmark = true, }) : super(builder: (FormFieldState field) { final state = field as _FormBuilderChoiceChipState; @@ -330,6 +339,7 @@ class FormBuilderChoiceChip extends FormBuilderFieldDecoration { padding: padding, visualDensity: visualDensity, avatarBorder: avatarBorder, + showCheckmark: showCheckmark, ), ], ), diff --git a/pubspec.lock b/pubspec.lock index 159bea511..29c46a5c8 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -204,10 +204,10 @@ packages: dependency: transitive description: name: vm_service - sha256: f652077d0bdf60abe4c1f6377448e8655008eef28f128bc023f7b5e8dfeb48fc + sha256: "5c5f338a667b4c644744b661f309fb8080bb94b18a7e91ef1dbd343bed00ed6d" url: "https://pub.dev" source: hosted - version: "14.2.4" + version: "14.2.5" sdks: dart: ">=3.5.0 <4.0.0" flutter: ">=3.24.0"