We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent fd35007 commit eef6170Copy full SHA for eef6170
packages/form_builder_extra_fields/lib/src/fields/form_builder_color_picker.dart
@@ -17,13 +17,13 @@ extension on Color {
17
/// Prefixes a hash sign if [leadingHashSign] is set to `true` (default is `true`).
18
String toHex({bool leadingHashSign = true}) {
19
/// Converts an rgba value (0-255) into a 2-digit Hex code.
20
- String _hexValue(int rgbaVal) {
+ String hexValue(int rgbaVal) {
21
assert(rgbaVal == rgbaVal & 0xFF);
22
return rgbaVal.toRadixString(16).padLeft(2, '0').toUpperCase();
23
}
24
25
return '${leadingHashSign ? '#' : ''}'
26
- '${_hexValue(alpha)}${_hexValue(red)}${_hexValue(green)}${_hexValue(blue)}';
+ '${hexValue(alpha)}${hexValue(red)}${hexValue(green)}${hexValue(blue)}';
27
28
29
0 commit comments