import 'package:flutter/material.dart';
import 'package:shimmer/shimmer.dart';

class HomeGoodsItemSkeleton extends StatelessWidget {
  const HomeGoodsItemSkeleton({Key key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return Container(
      margin: EdgeInsets.only(left: 12.5, right: 12.5, top: 4, bottom: 4),
      padding: EdgeInsets.all(7.5),
      decoration: BoxDecoration(
          color: Colors.white,
          borderRadius: BorderRadius.all(Radius.circular(7.5))),
      child: Shimmer.fromColors(
        baseColor: Colors.grey[300],
        highlightColor: Colors.grey[100],
        child: Row(
          crossAxisAlignment: CrossAxisAlignment.start,
          children: <Widget>[
            Container(
              width: 126,
              height: 126,
              margin: EdgeInsets.only(right: 10),
              decoration: BoxDecoration(
                  color: Colors.white,
                  borderRadius: BorderRadius.all(Radius.circular(7.5))),
            ),
            Expanded(
                child: Column(
              crossAxisAlignment: CrossAxisAlignment.start,
              children: <Widget>[
                Container(
                  width: double.infinity,
                  height: 35,
                  color: Colors.white,
                ),
                Container(
                  margin: EdgeInsets.only(top: 6),
                  width: double.infinity,
                  height: 12,
                  color: Colors.white,
                ),
                Container(
                  margin: EdgeInsets.only(top: 6),
                  width: 80,
                  height: 12,
                  color: Colors.white,
                )
              ],
            ))
          ],
        ),
      ),
    );
  }
}
