Skip to content

Commit

Permalink
Fix linter warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelspiss committed Nov 3, 2024
1 parent f2a3593 commit 01bac00
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 18 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
## 10.8.0
* Upgrade to Font Awesome 6.6.0
* Fix linter warnings

## 10.7.0
* Upgrade to Font Awesome 6.5.1
Expand Down
4 changes: 2 additions & 2 deletions example/lib/main.dart
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ void main() {
}

class FontAwesomeGalleryApp extends StatelessWidget {
const FontAwesomeGalleryApp({Key? key}) : super(key: key);
const FontAwesomeGalleryApp({super.key});

@override
Widget build(BuildContext context) {
Expand All @@ -26,7 +26,7 @@ class FontAwesomeGalleryApp extends StatelessWidget {
}

class FontAwesomeGalleryHome extends StatefulWidget {
const FontAwesomeGalleryHome({Key? key}) : super(key: key);
const FontAwesomeGalleryHome({super.key});

@override
State<StatefulWidget> createState() => FontAwesomeGalleryHomeState();
Expand Down
2 changes: 1 addition & 1 deletion lib/font_awesome_flutter.dart
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
library font_awesome_flutter;
library;

import 'package:flutter/widgets.dart';
import 'package:font_awesome_flutter/src/icon_data.dart';
Expand Down
4 changes: 2 additions & 2 deletions lib/src/fa_icon.dart
Original file line number Diff line number Diff line change
Expand Up @@ -22,13 +22,13 @@ class FaIcon extends StatelessWidget {
/// The [size] and [color] default to the value given by the current [IconTheme].
const FaIcon(
this.icon, {
Key? key,
super.key,
this.size,
this.color,
this.semanticLabel,
this.textDirection,
this.shadows,
}) : super(key: key);
});

/// The icon to display. Available icons are listed in [FontAwesomeIcons].
///
Expand Down
20 changes: 7 additions & 13 deletions lib/src/icon_data.dart
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
library font_awesome_flutter;
library;

import 'package:flutter/widgets.dart';

/// [IconData] for a font awesome brand icon from a code point
///
/// Code points can be obtained from fontawesome.com
class IconDataBrands extends IconData {
const IconDataBrands(int codePoint)
const IconDataBrands(super.codePoint)
: super(
codePoint,
fontFamily: 'FontAwesomeBrands',
fontPackage: 'font_awesome_flutter',
);
Expand All @@ -18,9 +17,8 @@ class IconDataBrands extends IconData {
///
/// Code points can be obtained from fontawesome.com
class IconDataSolid extends IconData {
const IconDataSolid(int codePoint)
const IconDataSolid(super.codePoint)
: super(
codePoint,
fontFamily: 'FontAwesomeSolid',
fontPackage: 'font_awesome_flutter',
);
Expand All @@ -30,9 +28,8 @@ class IconDataSolid extends IconData {
///
/// Code points can be obtained from fontawesome.com
class IconDataRegular extends IconData {
const IconDataRegular(int codePoint)
const IconDataRegular(super.codePoint)
: super(
codePoint,
fontFamily: 'FontAwesomeRegular',
fontPackage: 'font_awesome_flutter',
);
Expand All @@ -43,9 +40,8 @@ class IconDataRegular extends IconData {
///
/// Code points can be obtained from fontawesome.com
class IconDataLight extends IconData {
const IconDataLight(int codePoint)
const IconDataLight(super.codePoint)
: super(
codePoint,
fontFamily: 'FontAwesomeLight',
fontPackage: 'font_awesome_flutter',
);
Expand All @@ -63,9 +59,8 @@ class IconDataDuotone extends IconData {
/// but has to be an [IconData] object.
final IconData? secondary;

const IconDataDuotone(int codePoint, {this.secondary})
const IconDataDuotone(super.codePoint, {this.secondary})
: super(
codePoint,
fontFamily: 'FontAwesomeDuotone',
fontPackage: 'font_awesome_flutter',
);
Expand All @@ -76,9 +71,8 @@ class IconDataDuotone extends IconData {
///
/// Code points can be obtained from fontawesome.com
class IconDataThin extends IconData {
const IconDataThin(int codePoint)
const IconDataThin(super.codePoint)
: super(
codePoint,
fontFamily: 'FontAwesomeThin',
fontPackage: 'font_awesome_flutter',
);
Expand Down

0 comments on commit 01bac00

Please sign in to comment.