Skip to content

Commit b62ff8c

Browse files
authored
feat: update to sdk version 3 (#7)
BREAKING CHANGE: This removes Flutter 2.x support. Users of the package need to update to Flutter 3.x SDK versions to further use the package.
1 parent 777e65e commit b62ff8c

File tree

5 files changed

+6
-6
lines changed

5 files changed

+6
-6
lines changed

example/example.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import 'package:flutter/material.dart';
22
import 'package:generic_dropdown_widget/generic_dropdown_widget.dart';
33

4-
class Dropdown extends StatelessWidget {
4+
final class Dropdown extends StatelessWidget {
55
const Dropdown({super.key});
66

77
@override

lib/src/generic_dropdown.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ enum DropdownDirection {
7878
/// content. The [contentBuilder] receives a "repaint" and a
7979
/// "close" callbacks, which can help updating the content
8080
/// or closing the content entirely.
81-
class GenericDropdown extends StatefulWidget {
81+
final class GenericDropdown extends StatefulWidget {
8282
/// The anchor of the dropdown. Defines
8383
/// on which point of the toggle the content
8484
/// will be anchored. Defaults to [DropdownAnchor.bottomLeft].
@@ -132,7 +132,7 @@ class GenericDropdown extends StatefulWidget {
132132
State<GenericDropdown> createState() => _GenericDropdownState();
133133
}
134134

135-
class _GenericDropdownState extends State<GenericDropdown> {
135+
final class _GenericDropdownState extends State<GenericDropdown> {
136136
var _isOpen = false;
137137
OverlayEntry? _overlayEntry;
138138

lib/src/generic_dropdown_config_provider.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ import 'package:flutter/widgets.dart';
1212
/// at the wrong position. With this config, the dropdown can
1313
/// utilize the root storybook as root screen key to calculate
1414
/// the position of the content.
15-
class GenericDropdownConfigProvider extends InheritedWidget {
15+
final class GenericDropdownConfigProvider extends InheritedWidget {
1616
/// The key of the root screen that contains the dropdown.
1717
/// The screen is used to calculate the relative position
1818
/// of the content overlay to the toggle.

pubspec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ issue_tracker: https://github.com/smartive/flutter-generic-dropdown-widget/issue
77
repository: https://github.com/smartive/flutter-generic-dropdown-widget.git
88

99
environment:
10-
sdk: '>=2.19.3 <3.0.0'
10+
sdk: '>=3.0.0 <4.0.0'
1111
flutter: '>=1.17.0'
1212

1313
dependencies:

storybook/pubspec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ publish_to: 'none' # Remove this line if you wish to publish to pub.dev
44
version: 1.0.0+1
55

66
environment:
7-
sdk: '>=2.19.3 <3.0.0'
7+
sdk: '>=3.0.0 <4.0.0'
88

99
dependencies:
1010
flutter:

0 commit comments

Comments
 (0)