Skip to content

Commit 92b000c

Browse files
committed
Fix fluttercommunity#100, by adding support for thin style (pro)
1 parent b7f5a7c commit 92b000c

File tree

2 files changed

+19
-2
lines changed

2 files changed

+19
-2
lines changed

lib/src/icon_data.dart

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ class IconDataRegular extends IconData {
3939
}
4040

4141
/// [IconData] for a font awesome light icon from a code point. Only works if
42-
/// light icons (pro) have been installed.
42+
/// light icons (font awesome pro) have been installed.
4343
///
4444
/// Code points can be obtained from fontawesome.com
4545
class IconDataLight extends IconData {
@@ -52,7 +52,7 @@ class IconDataLight extends IconData {
5252
}
5353

5454
/// [IconData] for a font awesome duotone icon from a code point. Only works if
55-
/// duotone icons (pro) have been installed.
55+
/// duotone icons (font awesome pro) have been installed.
5656
///
5757
/// Code points can be obtained from fontawesome.com. Each duotone icon has
5858
/// a primary [codePoint] and a [secondary]. Due to tree-shaking restraints,
@@ -69,3 +69,16 @@ class IconDataDuotone extends IconData {
6969
fontPackage: 'font_awesome_flutter',
7070
);
7171
}
72+
73+
/// [IconData] for a font awesome thin icon from a code point. Only works if
74+
/// thin icons (font awesome pro, v6+) have been installed.
75+
///
76+
/// Code points can be obtained from fontawesome.com
77+
class IconDataThin extends IconData {
78+
const IconDataThin(int codePoint)
79+
: super(
80+
codePoint,
81+
fontFamily: 'FontAwesomeThin',
82+
fontPackage: 'font_awesome_flutter',
83+
);
84+
}

pubspec.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,3 +37,7 @@ flutter:
3737
# fonts:
3838
# - asset: lib/fonts/fa-duotone-900.ttf
3939
# weight: 900
40+
# - family: FontAwesomeThin
41+
# fonts:
42+
# - asset: lib/fonts/fa-thin-100.ttf
43+
# weight: 100

0 commit comments

Comments
 (0)