You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
52 lines
1.4 KiB
Dart
52 lines
1.4 KiB
Dart
import 'package:flutter/material.dart';
|
|
import 'package:diplomaticquarterapp/widgets/data_display/text.dart';
|
|
|
|
class ServicesContainer extends StatelessWidget {
|
|
final String title;
|
|
final String imageLocation;
|
|
final Function onTap;
|
|
|
|
ServicesContainer({this.title, this.imageLocation, this.onTap});
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return InkWell(
|
|
onTap: () => onTap(),
|
|
child: Container(
|
|
height: 60,
|
|
margin: EdgeInsets.all(8),
|
|
decoration: BoxDecoration(
|
|
color: Theme.of(context).textTheme.headline2.color,
|
|
shape: BoxShape.rectangle,
|
|
borderRadius: BorderRadius.circular(7),
|
|
),
|
|
child: Padding(
|
|
padding: const EdgeInsets.all(8.0),
|
|
child: Column(
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
mainAxisAlignment: MainAxisAlignment.center,
|
|
children: <Widget>[
|
|
Row(
|
|
children: [
|
|
Image.asset(
|
|
imageLocation,
|
|
height: 30,
|
|
width: 40,
|
|
),
|
|
SizedBox(
|
|
width: 20,
|
|
),
|
|
Texts(
|
|
title,
|
|
fontSize: 16,
|
|
color: Colors.black,
|
|
),
|
|
],
|
|
),
|
|
],
|
|
),
|
|
),
|
|
),
|
|
);
|
|
}
|
|
}
|