diff --git a/CHANGELOG.md b/CHANGELOG.md index 0181e334..aa3ba6f8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,6 @@ +## [1.7.2] +* Add padding as parameter to MacosTabView constructor. + ## [1.7.1] * Fixed an issue where end sidebar window breakpoints were not respected diff --git a/lib/src/layout/tab_view/tab_view.dart b/lib/src/layout/tab_view/tab_view.dart index c12375c2..03d9b91b 100644 --- a/lib/src/layout/tab_view/tab_view.dart +++ b/lib/src/layout/tab_view/tab_view.dart @@ -43,6 +43,7 @@ class MacosTabView extends StatefulWidget { required this.tabs, required this.children, this.position = MacosTabPosition.top, + this.padding = const EdgeInsets.all(12.0), }) : assert(controller.length == children.length && controller.length == tabs.length); @@ -60,6 +61,11 @@ class MacosTabView extends StatefulWidget { /// The placement of the [tabs], typically [MacosTabPosition.top]. final MacosTabPosition position; + /// The padding of the tab view widget. + /// + /// Defaults to `EdgeInsets.all(12.0)`. + final EdgeInsetsGeometry padding; + @override State createState() => _MacosTabViewState(); } @@ -153,7 +159,7 @@ class _MacosTabViewState extends State { alignment: Alignment.center, children: [ Padding( - padding: const EdgeInsets.all(12.0), + padding: widget.padding, child: DecoratedBox( decoration: BoxDecoration( color: brightness.resolve( diff --git a/pubspec.yaml b/pubspec.yaml index 53cd6f60..c1fe81fd 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,6 +1,6 @@ name: macos_ui description: Flutter widgets and themes implementing the current macOS design language. -version: 1.7.1 +version: 1.7.2 homepage: "https://macosui.dev" repository: "https://github.com/GroovinChip/macos_ui"