Skip to content

Commit

Permalink
deps: Update zeta-icon library (#51)
Browse files Browse the repository at this point in the history
Updating to icons version 0.3.1
---------

Co-authored-by: zeta-icons-bot <[email protected]>
Co-authored-by: github-actions <[email protected]>
  • Loading branch information
3 people authored Apr 25, 2024
1 parent cef3b4d commit ae9a53f
Show file tree
Hide file tree
Showing 6 changed files with 2,247 additions and 2,239 deletions.
2 changes: 1 addition & 1 deletion example/lib/pages/assets/icons_example.dart
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ class _IconsExampleState extends State<IconsExample> {
Wrap(
spacing: 8,
runSpacing: 8,
children: iconsRounded.values.map((e) => Icon(e)).toList(),
children: iconsRound.values.map((e) => Icon(e)).toList(),
),
const SizedBox(height: 20),
Text('Sharp', style: ZetaTextStyles.bodyLarge),
Expand Down
2 changes: 1 addition & 1 deletion example/widgetbook/pages/assets/icon_widgetbook.dart
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import '../../test/test_components.dart';

Widget iconsUseCase(BuildContext context) {
Map<String, IconData> icons =
((context.knobs.boolean(label: 'Rounded', initialValue: true)) ? iconsRounded : iconsSharp);
((context.knobs.boolean(label: 'Rounded', initialValue: true)) ? iconsRound : iconsSharp);

final Map<String, IconData> sortedIcons = Map.fromEntries(icons.entries.toList()
..sort((a, b) {
Expand Down
4 changes: 2 additions & 2 deletions example/widgetbook/utils/utils.dart
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import 'package:zeta_flutter/zeta_flutter.dart';

String iconLabelBuilder(IconData? value, [bool rounded = true]) {
return ((rounded
? iconsRounded.entries.firstWhere((element) => element.value == value)
? iconsRound.entries.firstWhere((element) => element.value == value)
: iconsSharp.entries.firstWhere((element) => element.value == value))
.key
.split('.')
Expand All @@ -14,7 +14,7 @@ String iconLabelBuilder(IconData? value, [bool rounded = true]) {
.join(' ');
}

List<IconData> iconOptions(rounded) => rounded ? iconsRounded.values.toList() : iconsSharp.values.toList();
List<IconData> iconOptions(rounded) => rounded ? iconsRound.values.toList() : iconsSharp.values.toList();

String enumLabelBuilder(Enum? value) => value?.name.split('.').last.capitalize() ?? '';

Expand Down
Binary file modified lib/src/assets/fonts/zeta-icons-round.ttf
Binary file not shown.
Binary file modified lib/src/assets/fonts/zeta-icons-sharp.ttf
Binary file not shown.
Loading

0 comments on commit ae9a53f

Please sign in to comment.