-
Notifications
You must be signed in to change notification settings - Fork 149
/
menu_dark_tile.dart
41 lines (39 loc) · 1.15 KB
/
menu_dark_tile.dart
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
import 'package:flutter/material.dart';
class MenuDarkTile extends StatelessWidget {
const MenuDarkTile({this.active, this.icon, this.title, this.onTap});
final bool active;
final IconData icon;
final String title;
final Function onTap;
@override
Widget build(BuildContext context) {
return GestureDetector(
onTap: onTap,
child: Container(
margin: EdgeInsets.symmetric(vertical: 5, horizontal: 25),
padding: EdgeInsets.only(top: 12, bottom: 12, left: 25),
decoration: BoxDecoration(
color: active ? Color(0xFF0F1736) : Colors.transparent,
borderRadius: BorderRadius.circular(10)),
child: Row(
mainAxisAlignment: MainAxisAlignment.start,
children: [
Icon(
icon,
color: active ? Color(0xFF37D2F8) : Colors.white24,
size: 18,
),
SizedBox(
width: 10,
),
Text(
title ?? "",
style: TextStyle(
color: active ? Colors.white : Colors.white24, fontSize: 12),
)
],
),
),
);
}
}