Skip to content

Commit d16737f

Browse files
committed
Ignore fvm folder
1 parent 70519aa commit d16737f

File tree

3 files changed

+6
-4
lines changed

3 files changed

+6
-4
lines changed

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,3 +42,6 @@ lib/generated_plugin_registrant.dart
4242

4343
# Generated documentattion
4444
doc/
45+
46+
# FVM
47+
.fvm/

example/lib/main.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ class MyHomePageState extends State<MyHomePage> {
108108
FormBuilderColorPicker(
109109
attribute: 'color_picker',
110110
// initialValue: Colors.yellow,
111-
colorPickerType: ColorPickerType.SlidePicker,
111+
colorPickerType: ColorPickerType.BlockPicker,
112112
decoration: const InputDecoration(labelText: 'Pick Color'),
113113
),
114114
SizedBox(height: 15),

lib/src/fields/form_builder_color_picker.dart

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -157,6 +157,7 @@ class _FormBuilderColorPickerState extends State<FormBuilderColorPicker> {
157157
autovalidate: widget.autovalidate ?? false,
158158
builder: (FormFieldState<Color> field) {
159159
_effectiveController.text = HexColor(field.value)?.toHex();
160+
final defaultBorderColor = Colors.grey;
160161

161162
return TextField(
162163
style: widget.style,
@@ -174,9 +175,7 @@ class _FormBuilderColorPickerState extends State<FormBuilderColorPicker> {
174175
borderRadius: BorderRadius.all(
175176
Radius.circular(constraints.minHeight / 2),
176177
),
177-
border: Border.all(
178-
color: Colors.black,
179-
),
178+
border: Border.all(color: field.value ?? defaultBorderColor),
180179
),
181180
);
182181
},

0 commit comments

Comments
 (0)