diff --git a/example/lib/sample3.dart b/example/lib/sample3.dart index 308df75..3ed59ce 100644 --- a/example/lib/sample3.dart +++ b/example/lib/sample3.dart @@ -43,13 +43,17 @@ class Sample3 extends StatelessWidget { /// Returns the custom [Widget] to be rendered as the *"Done"* button. Widget _buildMyDoneWidget() { - return Row( - mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ - Text('My Done Widget'), - const SizedBox(width: 10.0), - Icon(Icons.arrow_drop_down, size: 20.0), - ], + return Center( + child: Padding( + padding: const EdgeInsets.symmetric(horizontal: 12), + child: Row( + children: [ + Text('My Done Widget'), + const SizedBox(width: 10.0), + Icon(Icons.arrow_drop_down, size: 20.0), + ], + ), + ), ); } } diff --git a/example/lib/sample5.dart b/example/lib/sample5.dart index a993e0c..92d14c3 100644 --- a/example/lib/sample5.dart +++ b/example/lib/sample5.dart @@ -63,13 +63,17 @@ class Sample5 extends StatelessWidget { /// Returns the custom [Widget] to be rendered as the *"Done"* button. Widget _buildMyDoneWidget() { - return Row( - mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ - Text('My Done Widget'), - const SizedBox(width: 10.0), - Icon(Icons.arrow_drop_down, size: 20.0), - ], + return Center( + child: Padding( + padding: const EdgeInsets.symmetric(horizontal: 12), + child: Row( + children: [ + Text('My Done Widget'), + const SizedBox(width: 10.0), + Icon(Icons.arrow_drop_down, size: 20.0), + ], + ), + ), ); } } diff --git a/lib/keyboard_actions.dart b/lib/keyboard_actions.dart index 61eed37..f12f865 100644 --- a/lib/keyboard_actions.dart +++ b/lib/keyboard_actions.dart @@ -561,18 +561,20 @@ class KeyboardActionstate extends State } _clearFocus(); }, - child: Container( - padding: - EdgeInsets.symmetric(vertical: 8.0, horizontal: 12.0), - child: config?.defaultDoneWidget ?? - Text( + child: config?.defaultDoneWidget ?? + Container( + padding: EdgeInsets.symmetric( + vertical: 6.0, + horizontal: 12.0, + ), + child: Text( config?.defaultDoneButtonText ?? "Done", style: TextStyle( fontSize: 16.0, fontWeight: FontWeight.w500, ), ), - ), + ), ), ), if (_currentAction?.toolbarButtons != null)