32 lines
677 B
Dart
32 lines
677 B
Dart
import 'package:flutter/material.dart';
|
|
import 'package:lamiter/Extension/build_context.dart';
|
|
|
|
class TFQTitle extends StatelessWidget {
|
|
final String title;
|
|
final bool readOnly;
|
|
final bool required;
|
|
|
|
const TFQTitle({
|
|
super.key,
|
|
required this.title,
|
|
required this.readOnly,
|
|
required this.required,
|
|
});
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return Row(
|
|
children: [
|
|
Opacity(
|
|
opacity: readOnly ? 0.5 : 0.75,
|
|
child: Text(title, style: context.lL),
|
|
),
|
|
Text(
|
|
required && !readOnly ? ' *' : '',
|
|
style: const TextStyle(color: Colors.red),
|
|
),
|
|
],
|
|
);
|
|
}
|
|
}
|