diff --git a/lib/widgets/sheets/select_flow_icon_sheet/select_icon_flow_icon_sheet.dart b/lib/widgets/sheets/select_flow_icon_sheet/select_icon_flow_icon_sheet.dart index 3a7cf18f..1eb4aca0 100644 --- a/lib/widgets/sheets/select_flow_icon_sheet/select_icon_flow_icon_sheet.dart +++ b/lib/widgets/sheets/select_flow_icon_sheet/select_icon_flow_icon_sheet.dart @@ -92,22 +92,38 @@ class _SelectIconFlowIconSheetState extends State controller: _controller, children: [ GridView.builder( - itemBuilder: (context, index) => IconButton( - onPressed: () => updateSimpleIcon(simpleIconsResult[index].key), - icon: Icon(simpleIconsResult[index].value), - iconSize: 48.0, - ), + itemBuilder: (context, index) { + final bool selected = + value is IconFlowIcon && + (value as IconFlowIcon).iconData == + simpleIconsResult[index].value; + + return IconButton( + onPressed: () => updateSimpleIcon(simpleIconsResult[index].key), + icon: Icon(simpleIconsResult[index].value), + iconSize: 48.0, + isSelected: selected, + ); + }, itemCount: simpleIconsResult.length, gridDelegate: const SliverGridDelegateWithMaxCrossAxisExtent( maxCrossAxisExtent: 72.0, ), ), GridView.builder( - itemBuilder: (context, index) => IconButton( - onPressed: () => updateIcon(materialSymbolsResult[index]), - icon: Icon(materialSymbolsResult[index]), - iconSize: 48.0, - ), + itemBuilder: (context, index) { + final bool selected = + value is IconFlowIcon && + (value as IconFlowIcon).iconData == + materialSymbolsResult[index]; + + return IconButton( + onPressed: () => updateIcon(materialSymbolsResult[index]), + icon: Icon(materialSymbolsResult[index]), + iconSize: 48.0, + isSelected: selected, + ); + }, itemCount: materialSymbolsResult.length, gridDelegate: const SliverGridDelegateWithMaxCrossAxisExtent( maxCrossAxisExtent: 72.0, diff --git a/pubspec.yaml b/pubspec.yaml index 946cd298..ad5a30d6 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -3,7 +3,7 @@ description: A personal finance managing app publish_to: "none" # Remove this line if you wish to publish to pub.dev -version: "0.23.1+349" +version: "0.23.1+350" environment: sdk: ">=3.10.0 <4.0.0"