pmu_flutter/lec5/lib/view/home_page/home_card_text.dart

34 lines
731 B
Dart
Raw Permalink Normal View History

2024-10-11 19:12:12 +04:00
part of 'home_card.dart';
class _CardText extends StatelessWidget {
final String text;
final String descriptionText;
const _CardText(
this.text, {
required this.descriptionText,
});
@override
Widget build(BuildContext context) {
return Expanded(
child: Padding(
padding: const EdgeInsets.only(left: 8),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(
text,
style: Theme.of(context).textTheme.headlineLarge,
),
Text(
descriptionText,
style: Theme.of(context).textTheme.bodyLarge,
)
],
),
),
);
}
}