12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061 |
- import 'package:flutter/material.dart';
- import 'package:fooddeliveryapp/model/constants.dart';
- import 'package:fooddeliveryapp/model/product.dart';
- import 'counter_with_fav_btn.dart';
- import 'description.dart';
- import 'product_title_with_image.dart';
- class DetailsBody extends StatelessWidget {
- final Product? product;
- const DetailsBody({Key? key, this.product}) : super(key: key);
- @override
- Widget build(BuildContext context) {
- // It provide us total height and width
- Size size = MediaQuery.of(context).size;
- return SingleChildScrollView(
- child: Column(
- children: [
- SizedBox(
- height: size.height * 1.2,
- child: Stack(
- children: [
- Container(
- margin: EdgeInsets.only(top: size.height * 0.4),
- padding: EdgeInsets.only(
- top: size.height * 0.12,
- left: kDefaultPaddin,
- right: kDefaultPaddin,
- ),
- // height: 500,
- decoration: BoxDecoration(
- color: Colors.white,
- borderRadius: BorderRadius.only(
- topLeft: Radius.circular(24),
- topRight: Radius.circular(24),
- ),
- ),
- child: Column(
- children: [
- // ColorAndSize(product: product),
- // SizedBox(height: kDefaultPaddin / 2),
- Description(product: product),
- SizedBox(height: kDefaultPaddin / 2),
- CounterWithFavBtn(
- product: product,
- ),
- SizedBox(height: kDefaultPaddin / 2),
- // AddToCart(product: product)
- ],
- ),
- ),
- ProductTitleWithImage(product: product)
- ],
- ),
- )
- ],
- ),
- );
- }
- }
|