parent
7e51359d15
commit
7b0c3c9e40
@ -1,18 +1,18 @@
|
|||||||
library flutter_icons;
|
library flutter_icons;
|
||||||
|
|
||||||
export 'ionicons.dart';
|
export 'src/ionicons.dart';
|
||||||
export 'ant_design.dart';
|
export 'src/ant_design.dart';
|
||||||
export 'font_awesome.dart';
|
export 'src/font_awesome.dart';
|
||||||
export 'material_icons.dart';
|
export 'src/material_icons.dart';
|
||||||
export 'entypo.dart';
|
export 'src/entypo.dart';
|
||||||
export 'evil_icons.dart';
|
export 'src/evil_icons.dart';
|
||||||
export 'feather.dart';
|
export 'src/feather.dart';
|
||||||
export 'material_community_icons.dart';
|
export 'src/material_community_icons.dart';
|
||||||
export 'octicons.dart';
|
export 'src/octicons.dart';
|
||||||
export 'simple_line_icons.dart';
|
export 'src/simple_line_icons.dart';
|
||||||
export 'zocial.dart';
|
export 'src/zocial.dart';
|
||||||
export 'foundation.dart';
|
export 'src/foundation.dart';
|
||||||
export 'font_awesome_5.dart';
|
export 'src/font_awesome_5.dart';
|
||||||
export 'flutter_icon_data.dart' show IconWeight;
|
export 'src/flutter_icon_data.dart' show IconWeight;
|
||||||
export 'icon_toggle.dart';
|
export 'src/icon_toggle.dart';
|
||||||
export 'weather_icons.dart';
|
export 'src/weather_icons.dart';
|
||||||
|
@ -1,7 +1,11 @@
|
|||||||
import 'flutter_icon_data.dart';
|
import 'flutter_icon_data.dart';
|
||||||
|
|
||||||
class FontAwesome5 {
|
class FontAwesome5 {
|
||||||
static getIconData(iconName, {IconWeight weight}) {
|
static getIconData(iconName, {IconWeight weight = IconWeight.Regular}) {
|
||||||
|
assert(
|
||||||
|
hasIconData(iconName, weight: weight),
|
||||||
|
"The icon $iconName does not exist in the FontAwesome5($weight)",
|
||||||
|
);
|
||||||
return FlutterIconData.fontAwesome5(_fontAwesome5[iconName],
|
return FlutterIconData.fontAwesome5(_fontAwesome5[iconName],
|
||||||
weight: weight);
|
weight: weight);
|
||||||
}
|
}
|
Loading…
Reference in new issue