eazigrid 0.0.1 copy "eazigrid: ^0.0.1" to clipboard
eazigrid: ^0.0.1 copied to clipboard

Easy dynamic flutter row to list/grid widget. This widget arranges children as a row and or grid depending on the constraints of it's parent.

license pub package PRs Welcome

EAZI GRID

Easy dynamic Flutter row to list/grid. Starts out as a row and resizes to a grid - scaling to dimensions of parent widget.

Features #

  • Width of parent widget must be explicitly defined.
  • Height automatically shrinks or expands to wrap parent widget if height of parent is left unspecified.
  • Children can be made vertically scrollable if the parameter isScrollable is set to true.

Getting started #

Add package dependency to pubspec.yaml.

dependencies:
  flutter:
    sdk: flutter

  ...
  eazigrid: ^[latest_version]

Resolve overflow issues for automated testing by adding the following line to the main method in the main flutter file as shown in the example

  EaziGridFlowHandler.handleEaziError();

Usage #

ezgif com-gif-maker

Declare EaziGrid in a parent widget with width != infinty (See example)

EaziGrid(
  isScrollable: true,
  horizontalAlignment: EaziAlignment.start,
  children: [
  for(int i=0; i<=widget.totalItems; i++)
    TestGridItem(itemIndex: i)
])
Widget Parameters
  • isScrollable: makes resulting grid vertically scrollable if set to true.
  • horizontalAlignment: aligns children in each row by any of the options defined in EaziAlignment.
  • verticalAlignment: aligns grid rows vertically by any of the options in defined EaziAlignment.
  • children: all children must be widgets with explicitly defined heights and widths.

enum EaziAlignment { start, center, end }

Additional information #

Feel free to open issues for feature requests. If you'd like to contribute, send a PR.

TODO: 🤔 HAVE FUN 😬

3
likes
150
points
18
downloads

Publisher

verified publisheralgure.tech

Weekly Downloads

Easy dynamic flutter row to list/grid widget. This widget arranges children as a row and or grid depending on the constraints of it's parent.

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (license)

Dependencies

flutter

More

Packages that depend on eazigrid