cpd_2022_zi/lib/widgets/entry_detail_title.dart

34 lines
953 B
Dart

import 'package:flutter/material.dart';
import 'package:intl/intl.dart';
class EntryDetailTitle extends StatelessWidget {
final DateTime date;
final String entryData;
const EntryDetailTitle(
{super.key, required this.date, required this.entryData});
@override
Widget build(BuildContext context) {
return Row(
mainAxisAlignment: MainAxisAlignment.start,
children: [
Text(
DateFormat.MMMd('de').format(date),
style:
const TextStyle(color: Colors.white, fontWeight: FontWeight.bold),
),
Flexible(
child: Container(
padding: const EdgeInsets.symmetric(horizontal: 5.0),
child: Text(
entryData,
overflow: TextOverflow.ellipsis,
style: const TextStyle(
color: Colors.white, fontWeight: FontWeight.bold),
)))
],
);
}
}