Files
kulakpos_app/journey/001_Adjust_Product_Padding_Walkthrough.md
2026-02-07 23:09:06 +07:00

1.3 KiB

Walkthrough - Moved Save Button to Bottom Navigation Bar

I have updated the AddProduct screen to improve user experience by making the "Save & Publish" / "Update" button always visible.

Changes

1. Moved Button to Bottom Navigation Bar

The ElevatedButton for saving or updating the product has been moved from the end of the scrollable form to the Scaffold's bottomNavigationBar.

  • File: lib/Screens/Products/add product/add_product.dart
  • Change: Wrapped the button in a Container with shadow and padding, and assigned it to bottomNavigationBar.
  • Benefit: The button is now fixed at the bottom of the screen, making it accessible at any scroll position.

2. Adjusted Scroll Padding

Added bottom padding to the SingleChildScrollView to ensure the last form fields (like Warranty/Guarantee) are not obscured by the new bottom bar.

  • File: lib/Screens/Products/add product/add_product.dart
  • Change: Updated padding to EdgeInsets.only(left: 16, right: 16, top: 16, bottom: 80).

Verification Results

Automated Tests

  • Not applicable for this UI change.

Manual Verification

  • Verified that the code structure correctly places the button outside the scroll view.
  • Verified that the onPressed logic utilizes the correct ref and context.