subtracks/lib/app/ui/text.dart
2025-11-18 21:59:13 +09:00

44 lines
737 B
Dart

import 'package:flutter/material.dart';
class TextH1 extends StatelessWidget {
const TextH1(
this.data, {
super.key,
});
final String data;
@override
Widget build(BuildContext context) {
final theme = Theme.of(context);
return Text(
data,
style: theme.textTheme.headlineLarge?.copyWith(
fontWeight: FontWeight.w800,
),
);
}
}
class TextH2 extends StatelessWidget {
const TextH2(
this.data, {
super.key,
});
final String data;
@override
Widget build(BuildContext context) {
final theme = Theme.of(context);
return Text(
data,
style: theme.textTheme.headlineMedium?.copyWith(
fontWeight: FontWeight.w700,
),
);
}
}