

import '../../../../../../food_delivery_client.dart';

class WBasketBody extends StatelessWidget {
  const WBasketBody({super.key});

  @override
  Widget build(BuildContext context) {
    return BlocBuilder<BasketBloc, BasketState>(
      builder: (context, state) {
        return Column(
          children: [
            WBasketHeader(),
            if (state.status.isLoading()) WBasketLoading(),
            if (state.status.isLoaded())
              if (state.orders.isEmpty) WBasketEmpty() else WBasketCarts(),
          ],
        );
      },
    );
  }
}
