PIbd-32_Shabunov_O.A._Mobil.../lib/presentation/details_page/details_page.dart
olshab a676d454ca implemented mock crypto repository
changed Cupertino search bar to Material UI 3
changed baseline color and card colors
implemented fetching crypto data from public API (untested)
2024-12-15 23:23:00 +04:00

30 lines
838 B
Dart

import 'package:flutter/material.dart';
import 'package:flutter_android_app/domain/models/card.dart';
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),
child: Image.network(data.imageUrl ?? ''),
),
Padding(
padding: const EdgeInsets.only(bottom: 4),
child: Text(data.title, style: Theme.of(context).textTheme.headlineLarge),
),
Text(data.currentPrice, style: Theme.of(context).textTheme.bodyLarge),
],
),
);
}
}