Browse Source

added visual density rule to follow for action widgets passed to TitleBarWidget

ashilkn 2 năm trước cách đây
mục cha
commit
1364ef3e04
1 tập tin đã thay đổi với 4 bổ sung0 xóa
  1. 4 0
      lib/ui/components/title_bar_widget.dart

+ 4 - 0
lib/ui/components/title_bar_widget.dart

@@ -6,6 +6,10 @@ class TitleBarWidget extends StatelessWidget {
   final String? caption;
   final Widget? flexibleSpaceTitle;
   final String? flexibleSpaceCaption;
+  //If passing IconButton, set visualDensity to -2 (horizontal & vertical).
+  //This could be applicable to other widgets too. If layout looks different see if
+  // VisualDensity property exists for the widget and try to find the right values.
+  // https://api.flutter.dev/flutter/material/VisualDensity-class.html
   final List<Widget>? actionIcons;
   final bool isTitleBigWithoutLeading;
   const TitleBarWidget({