Skip to content
This repository was archived by the owner on Nov 30, 2023. It is now read-only.

Commit 2aadd08

Browse files
authored
Material icon medium dartpad demo (#75)
* Material icon medium dartpad demo * removed unnecessary widget cast * wrapped with scaffold and center
1 parent 3d40d4d commit 2aadd08

File tree

2 files changed

+50
-0
lines changed

2 files changed

+50
-0
lines changed
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
name: Material Icons Demonstration
2+
mode: flutter
3+
files:
4+
- name: main.dart

medium/material_icons/main.dart

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
import 'package:flutter/material.dart';
2+
3+
void main() => runApp(MyApp());
4+
5+
class MyApp extends StatelessWidget {
6+
@override
7+
Widget build(BuildContext context) {
8+
return MaterialApp(
9+
title: 'Material Icon Demo',
10+
home: MyHomePage(),
11+
);
12+
}
13+
}
14+
15+
class MyHomePage extends StatelessWidget {
16+
@override
17+
Widget build(BuildContext context) {
18+
return Scaffold(
19+
body: Center(
20+
child: Row(
21+
mainAxisAlignment: MainAxisAlignment.spaceAround,
22+
children: const [
23+
Icon(
24+
Icons.masks_rounded,
25+
color: Colors.pink,
26+
size: 24.0,
27+
semanticLabel: 'Wear a mask',
28+
),
29+
Icon(
30+
Icons.wash_rounded,
31+
color: Colors.green,
32+
size: 30.0,
33+
semanticLabel: 'Wash your hands',
34+
),
35+
Icon(
36+
Icons.six_ft_apart_rounded,
37+
color: Colors.blue,
38+
size: 36.0,
39+
semanticLabel: 'Socially distance',
40+
),
41+
],
42+
),
43+
),
44+
);
45+
}
46+
}

0 commit comments

Comments
 (0)