40 lines
890 B
Dart
40 lines
890 B
Dart
import 'package:flutter/material.dart';
|
|
|
|
class ElevatedCard extends StatelessWidget {
|
|
final Widget child;
|
|
final String title;
|
|
|
|
const ElevatedCard({
|
|
Key? key,
|
|
required this.child,
|
|
required this.title,
|
|
}) : super(key: key);
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return Card(
|
|
elevation: 4.0,
|
|
shape: RoundedRectangleBorder(
|
|
borderRadius: BorderRadius.circular(16.0),
|
|
),
|
|
child: Padding(
|
|
padding: const EdgeInsets.all(14.0),
|
|
child: Column(
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
children: [
|
|
Text(
|
|
title,
|
|
style: const TextStyle(
|
|
fontSize: 16.0,
|
|
fontWeight: FontWeight.bold,
|
|
),
|
|
),
|
|
const SizedBox(height: 8.0),
|
|
child,
|
|
],
|
|
),
|
|
),
|
|
);
|
|
}
|
|
}
|