Skip to content

Commit

Permalink
feat: Added Inter font family
Browse files Browse the repository at this point in the history
  • Loading branch information
mateusz-bak committed Nov 13, 2023
1 parent 160d88c commit ed394df
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 0 deletions.
Binary file added assets/fonts/Inter-Bold.ttf
Binary file not shown.
Binary file added assets/fonts/Inter-Regular.ttf
Binary file not shown.
1 change: 1 addition & 0 deletions lib/core/constants/enums.dart
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ enum Font {
quicksand,
barlow,
jost,
inter,
}

enum BookFormat {
Expand Down
12 changes: 12 additions & 0 deletions lib/ui/settings_screen/settings_apperance_screen.dart
Original file line number Diff line number Diff line change
Expand Up @@ -194,6 +194,15 @@ class SettingsApperanceScreen extends StatelessWidget {
),
),
const SizedBox(height: 5),
SettingsDialogButton(
text: 'Inter',
onPressed: () => _setFont(
context,
state,
Font.inter,
),
),
const SizedBox(height: 5),
SettingsDialogButton(
text: 'Kanit',
onPressed: () => _setFont(
Expand Down Expand Up @@ -591,6 +600,9 @@ class SettingsApperanceScreen extends StatelessWidget {
case Font.barlow:
fontFamily = 'Barlow';
break;
case Font.inter:
fontFamily = 'Inter';
break;
case Font.jost:
fontFamily = 'Jost';
break;
Expand Down
5 changes: 5 additions & 0 deletions pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,11 @@ flutter:
- asset: assets/fonts/Barlow-Regular.ttf
- asset: assets/fonts/Barlow-Bold.ttf
weight: 700
- family: Inter
fonts:
- asset: assets/fonts/Inter-Regular.ttf
- asset: assets/fonts/Inter-Bold.ttf
weight: 700
- family: Jost
fonts:
- asset: assets/fonts/Jost-Regular.ttf
Expand Down

0 comments on commit ed394df

Please sign in to comment.