ente/lib/ui/settings/settings_section_title.dart

33 lines
761 B
Dart
Raw Normal View History

import 'package:flutter/material.dart';
class SettingsSectionTitle extends StatelessWidget {
final String title;
2021-07-27 14:51:45 +00:00
final Color color;
const SettingsSectionTitle(
this.title, {
Key key,
this.color,
}) : super(key: key);
@override
Widget build(BuildContext context) {
2021-07-27 14:51:45 +00:00
return Column(children: [
Padding(padding: EdgeInsets.all(4)),
Align(
alignment: Alignment.centerLeft,
child: Text(
title,
style: color != null
? Theme.of(context)
.textTheme
.headline6
.merge(TextStyle(color: color))
: Theme.of(context).textTheme.headline6,
),
),
Padding(padding: EdgeInsets.all(4)),
2021-07-27 14:51:45 +00:00
]);
}
}