PIbd31_Razubaev.S.M._PMU/lib/presentation/details_page/details_page.dart

41 lines
1.0 KiB
Dart
Raw Permalink Normal View History

2024-10-04 14:11:06 +04:00
import 'package:flutter/material.dart';
2024-10-16 12:08:15 +04:00
import 'package:flutter_app/domain/models/carddata.dart';
2024-10-04 14:11:06 +04:00
class DetailsPage extends StatelessWidget {
final CardData data;
const DetailsPage(this.data, {super.key});
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(),
body: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Padding(
padding: const EdgeInsets.only(bottom: 16.0),
2024-10-16 12:08:15 +04:00
child: ClipRRect(
borderRadius: BorderRadius.all(Radius.circular(20)),
child: Image.network(data.imageUrl ?? ''),
)
),
2024-10-04 14:11:06 +04:00
Padding(
padding: const EdgeInsets.only(bottom: 4.0),
child: Text(
data.text,
style: Theme.of(context).textTheme.headlineLarge,
)),
Text(
data.descriptionText,
style: Theme.of(context).textTheme.bodyLarge,
),
],
),
);
}
}