easy_box 0.0.2+1 copy "easy_box: ^0.0.2+1" to clipboard
easy_box: ^0.0.2+1 copied to clipboard

All in one widget, with all the most basic widget properties. Composing a tree of widgets depending on the properties that you request. Just organize everything with the Box.

Pub.dev package GitHub repository

Easy Box #

All in one widget, with all the most basic widget properties. Composing a tree of widgets depending on the properties that you request. Just organize everything with the Box.

Features #

  • Background
  • Size
  • Padding and Margin
  • Border
  • Shape
  • List
  • Alignment
  • Transform
  • Text Style

Getting started #

Install it using pub:

flutter pub add easy_box

And import the package:

import 'package:easy_box/easy_box.dart';

Usage #

Wrap your widget with the things you need, the Box widget will do the rest. Or not, you can also use it without any widget inside, whatever floats your boat.

Box(
  child: ... ,
)

Or wrap your list of widgets, using a children list or an itemBuilder. This will be a ListView or a Column/Row, depending on whether the alignment is set or not. The alignment property is used for that because alignment is only possible using Column/Rows.

Box(
  children: [ ... ],

  direction: Axis.horizontal,
  alignment: Alignment.center,
  spacing: Spacing.spaceAround
)

Choose your Box style and properties, it will create whatever structure it needs taking into account the widgets already requested above.

Box(
  width: 200,
  height: 300,

  backgroundColor: Colors.green,
  backgroundGrandient: LinearGradient( ... ),
  backgroundImage: DecorationImage( ... ),

  border: Border.all( ... ),
  borderRadius: BorderRadius.circular(10),

  shape: ... ,

  padding: EdgeInsets.all(10),
  margin: EdgeInsets.all(10)
)

Do a quick transform using translate, scale and rotate:

Box(
  translate: Offset( ... ),
  scale: 1.5,
  rotate: math.pi / 4
)

Choose the default text style for all the Text widgets inside your Box.

Box(
  textStyle: TextStyle(
    ...
  )
)

GitHub #

The widget code is available on Github: Flutter - EasyBox

2
likes
0
pub points
0%
popularity

Publisher

verified publisherdrafakiller.com

All in one widget, with all the most basic widget properties. Composing a tree of widgets depending on the properties that you request. Just organize everything with the Box.

Repository (GitHub)
View/report issues

License

unknown (LICENSE)

Dependencies

flutter

More

Packages that depend on easy_box