copy_size_widget 1.0.0 copy "copy_size_widget: ^1.0.0" to clipboard
copy_size_widget: ^1.0.0 copied to clipboard

A widget that sizes itself using another widget's size.

A widget that sizes itself using another widget's size.

Usage #

  double _size = 200;
  final copyKey = GlobalKey();

  @override
  Widget build(BuildContext context) {
    return Column(
      mainAxisAlignment: MainAxisAlignment.spaceBetween,
      children: <Widget>[
        CopySizeWidget(
          copyKey: copyKey,
          child: Container(
            color: Colors.red,
            child: const Placeholder(),
          ),
        ),
        Container(
          key: copyKey,
          color: Colors.blue,
          width: _size,
          height: _size,
          child: const Placeholder(),
        ),
      ],
    );
  }

2
likes
160
points
15
downloads

Publisher

unverified uploader

Weekly Downloads

A widget that sizes itself using another widget's size.

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (license)

Dependencies

flutter

More

Packages that depend on copy_size_widget