From 786276dd78cd138660340f079ba0a75db980f69d Mon Sep 17 00:00:00 2001 From: Lucas Vieira <6011385+lcsvcn@users.noreply.github.com> Date: Mon, 5 Dec 2022 14:13:25 -0300 Subject: [PATCH] fix formatting (#6) --- CHANGELOG.md | 6 +++++- lib/speed_dial_fab.dart | 16 +++++++++++----- pubspec.yaml | 2 +- 3 files changed, 17 insertions(+), 7 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index dd97988..0cb4b59 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ +## 2.3.0 +- Added primaryElevation and secondaryElevation[PR #5](https://github.com/lcsvcn/speed_dial_fab/pull/5) + + ## 2.2.3 -- Fix https://github.com/lcsvcn/speed_dial_fab/issues/4 +- Fix [Issue #5](https://github.com/lcsvcn/speed_dial_fab/issues/4) ## 2.2.2 - Fix analysis issues diff --git a/lib/speed_dial_fab.dart b/lib/speed_dial_fab.dart index 0c5bd6e..3a60612 100644 --- a/lib/speed_dial_fab.dart +++ b/lib/speed_dial_fab.dart @@ -72,7 +72,8 @@ class SpeedDialFabWidget extends StatefulWidget { State createState() => SpeedDialFabWidgetState(); } -class SpeedDialFabWidgetState extends State with TickerProviderStateMixin { +class SpeedDialFabWidgetState extends State + with TickerProviderStateMixin { late AnimationController _controller; @override @@ -82,11 +83,13 @@ class SpeedDialFabWidgetState extends State with TickerProvi duration: const Duration(milliseconds: 500), ); - if (widget.secondaryIconsList.length != widget.secondaryIconsOnPress.length) { + if (widget.secondaryIconsList.length != + widget.secondaryIconsOnPress.length) { throw ("secondaryIconsList should have the same length of secondaryIconsOnPress"); } if (widget.secondaryIconsText != null) { - if (widget.secondaryIconsText?.length != widget.secondaryIconsOnPress.length) { + if (widget.secondaryIconsText?.length != + widget.secondaryIconsOnPress.length) { throw ("secondaryIconsText should have the same length of secondaryIconsOnPress"); } } @@ -137,7 +140,8 @@ class SpeedDialFabWidgetState extends State with TickerProvi widget.secondaryIconsList[index], color: widget.secondaryForegroundColor, ), - onPressed: widget.secondaryIconsOnPress[index] as void Function(), + onPressed: + widget.secondaryIconsOnPress[index] as void Function(), ), Positioned( right: 51.0, @@ -184,7 +188,9 @@ class SpeedDialFabWidgetState extends State with TickerProvi ), alignment: FractionalOffset.center, child: Icon( - _controller.isDismissed ? widget.primaryIconExpand : widget.primaryIconCollapse, + _controller.isDismissed + ? widget.primaryIconExpand + : widget.primaryIconCollapse, color: widget.primaryForegroundColor, ), ); diff --git a/pubspec.yaml b/pubspec.yaml index 77fb074..7a2780a 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -2,7 +2,7 @@ name: speed_dial_fab description: This is a library that implements the Speed Dial Float Action Button in Flutter. Fell Free to colaborate, every PR is welcome! repository: https://github.com/lcsvcn/speed_dial_fab.git homepage: https://github.com/lcsvcn/speed_dial_fab.git -version: 2.2.3 +version: 2.3.0 environment: sdk: ">=2.12.0 <3.0.0"