You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
50 lines
1.5 KiB
50 lines
1.5 KiB
|
|
import 'package:flutter/material.dart';
|
|
|
|
import '../common/colo_extension.dart';
|
|
|
|
class TitleSubtitleCell extends StatelessWidget {
|
|
final String title;
|
|
final String subtitle;
|
|
const TitleSubtitleCell({super.key, required this.title, required this.subtitle});
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return Container(
|
|
padding: const EdgeInsets.symmetric(vertical: 10, horizontal: 8),
|
|
decoration: BoxDecoration(
|
|
color: TColor.white,
|
|
borderRadius: BorderRadius.circular(15),
|
|
boxShadow: const [BoxShadow(color: Colors.black12, blurRadius: 2)]),
|
|
child: Column(
|
|
children: [
|
|
ShaderMask(
|
|
blendMode: BlendMode.srcIn,
|
|
shaderCallback: (bounds) {
|
|
return LinearGradient(
|
|
colors: TColor.primaryG,
|
|
begin: Alignment.centerLeft,
|
|
end: Alignment.centerRight)
|
|
.createShader(
|
|
Rect.fromLTRB(0, 0, bounds.width, bounds.height));
|
|
},
|
|
child: Text(
|
|
title,
|
|
style: TextStyle(
|
|
color: TColor.white.withOpacity(0.7),
|
|
fontWeight: FontWeight.w500,
|
|
fontSize: 14),
|
|
),
|
|
),
|
|
Text(
|
|
subtitle,
|
|
style: TextStyle(
|
|
color: TColor.gray,
|
|
fontSize: 12,
|
|
),
|
|
),
|
|
],
|
|
),
|
|
);
|
|
}
|
|
} |