fix: 3620 unchecked checkbox color (#3685)

This commit is contained in:
Sarthak Kimtani 2023-10-13 18:36:13 +05:30 committed by GitHub
parent ec80f72c8f
commit 62f1d6eb82
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 13 additions and 15 deletions

View File

@ -381,14 +381,10 @@ Widget? _buildHeaderIcon(GroupData customData) {
switch (customData.fieldType) {
case FieldType.Checkbox:
final group = customData.asCheckboxGroup()!;
if (group.isCheck) {
widget = const FlowySvg(
FlowySvgs.check_filled_s,
blendMode: BlendMode.dst,
);
} else {
widget = const FlowySvg(FlowySvgs.uncheck_s);
}
widget = FlowySvg(
group.isCheck ? FlowySvgs.check_filled_s : FlowySvgs.uncheck_s,
blendMode: BlendMode.dst,
);
break;
case FieldType.DateTime:
case FieldType.LastEditedTime:

View File

@ -39,12 +39,11 @@ class _CheckboxCellState extends State<CheckboxCardCell> {
buildWhen: (previous, current) =>
previous.isSelected != current.isSelected,
builder: (context, state) {
final icon = state.isSelected
? const FlowySvg(
FlowySvgs.check_filled_s,
blendMode: BlendMode.dst,
)
: const FlowySvg(FlowySvgs.uncheck_s);
final icon = FlowySvg(
state.isSelected ? FlowySvgs.check_filled_s : FlowySvgs.uncheck_s,
blendMode: BlendMode.dst,
);
return Align(
alignment: Alignment.centerLeft,
child: Padding(

View File

@ -116,6 +116,9 @@ class CheckboxCellUncheck extends StatelessWidget {
@override
Widget build(BuildContext context) {
return const FlowySvg(FlowySvgs.uncheck_s);
return const FlowySvg(
FlowySvgs.uncheck_s,
blendMode: BlendMode.dst,
);
}
}