2024-09-24 13:29:59 +04:00
|
|
|
|
import 'package:flutter/material.dart';
|
|
|
|
|
|
|
|
|
|
class DetailPage extends StatelessWidget {
|
|
|
|
|
final String info;
|
2024-10-07 23:44:26 +04:00
|
|
|
|
final String? imgUrl;
|
2024-09-24 13:29:59 +04:00
|
|
|
|
|
2024-10-07 23:44:26 +04:00
|
|
|
|
const DetailPage({super.key, required this.info, this.imgUrl});
|
2024-09-24 13:29:59 +04:00
|
|
|
|
|
|
|
|
|
@override
|
|
|
|
|
Widget build(BuildContext context) {
|
|
|
|
|
return Scaffold(
|
|
|
|
|
appBar: AppBar(
|
|
|
|
|
title: const Text('Информация о продукции'),
|
|
|
|
|
),
|
|
|
|
|
body: Padding(
|
|
|
|
|
padding: const EdgeInsets.all(16.0),
|
2024-10-07 23:44:26 +04:00
|
|
|
|
child: Column(
|
|
|
|
|
children: [
|
|
|
|
|
Text(
|
|
|
|
|
info,
|
|
|
|
|
style: const TextStyle(fontSize: 18.0),
|
|
|
|
|
),
|
|
|
|
|
Image.network(
|
|
|
|
|
imgUrl ?? 'https://hlebzavod3.ru/images/virtuemart/product/011_IMG_9657.jpg',
|
|
|
|
|
fit: BoxFit.cover,
|
|
|
|
|
height: 150.0,
|
|
|
|
|
width: double.infinity,
|
|
|
|
|
),
|
|
|
|
|
],
|
2024-09-24 13:29:59 +04:00
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|
}
|