super_extensions
super_extensions copied to clipboard
FEAT: Extension for Padding Class
Description
Added 3 types of Extension Method that deals with Padding for List<Widget> types (Row, Column)
paddingDirectional method provides fine-grained control over directional spacing, allowing you to customize padding for the top, bottom, left, and right sides individually.
paddingSymmetric method simplifies the process of achieving uniform spacing by applying consistent vertical and horizontal padding to each widget in the list.
paddingAll method streamlines layout adjustments by uniformly applying the same padding value to all sides of each widget, ensuring a cohesive and polished design.
- [x] โจ Ran
dartdoc - [x] ๐ ๏ธ Added proper documentation
- [x] โ No warnings or errors in the code
- [x] โ If added a new extension, added in Readme and example too
- [x] ๐งช If added a new extension, written proper test cases for it
Type of Change
- [x] โจ New feature (non-breaking change which adds functionality)
- [ ] ๐ ๏ธ Bug fix (non-breaking change which fixes an issue)
- [ ] โ Breaking change (fix or feature that would cause existing functionality to change)
- [x] ๐งน Code refactor
- [ ] โ Build configuration change
- [x] ๐ Documentation
- [ ] ๐๏ธ Chore
Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:
Comparison is base (
2a53519) 100.00% compared to head (49f245c) 100.00%.
Additional details and impacted files
@@ Coverage Diff @@
## main #32 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 7 8 +1
Lines 104 119 +15
=========================================
+ Hits 104 119 +15
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Hey, I added some new extension methods also wrote tests for them @AbhishekDoshi26
@deepraj02 sorry for the delay, I was busy with the preps of Flutter Conf India.
I don't get the use-case of this extension. I mean, if I want to give padding to each element of my column/row, I will just give the padding to the column instead of giving to each element. As per your code that I understood, it is giving padding (only, symmetric and all) to the elements of List<Widget>.
Can you explain the use-case of the same?
@deepraj02 can you update me on this?