1+ import 'package:app_flowy/plugins/grid/application/field/field_cache.dart' ;
2+ import 'package:app_flowy/plugins/grid/presentation/widgets/header/field_type_extension.dart' ;
3+ import 'package:flowy_infra/image.dart' ;
14import 'package:flowy_infra/theme.dart' ;
5+ import 'package:flowy_infra_ui/style_widget/button.dart' ;
6+ import 'package:flowy_infra_ui/style_widget/text.dart' ;
7+ import 'package:flowy_sdk/protobuf/flowy-grid/field_entities.pb.dart' ;
28import 'package:flutter/material.dart' ;
39import 'package:provider/provider.dart' ;
410
511class GridGroupList extends StatelessWidget {
6- const GridGroupList ({Key ? key}) : super (key: key);
12+ final String viewId;
13+ final GridFieldCache fieldCache;
14+ const GridGroupList ({
15+ required this .viewId,
16+ required this .fieldCache,
17+ Key ? key,
18+ }) : super (key: key);
719
820 @override
921 Widget build (BuildContext context) {
1022 return Container ();
1123 }
24+
25+ void show (BuildContext context) {}
1226}
1327
1428class _GridGroupCell extends StatelessWidget {
15- const _GridGroupCell ({Key ? key}) : super (key: key);
29+ final FieldPB field;
30+ const _GridGroupCell ({required this .field, Key ? key}) : super (key: key);
1631
1732 @override
1833 Widget build (BuildContext context) {
@@ -22,6 +37,16 @@ class _GridGroupCell extends StatelessWidget {
2237 // ? svgWidget('home/show', color: theme.iconColor)
2338 // : svgWidget('home/hide', color: theme.iconColor);
2439
25- return Container ();
40+ // Padding(
41+ // padding: const EdgeInsets.only(right: 6),
42+ // child: svgWidget("grid/checkmark"),
43+ // ),
44+
45+ return FlowyButton (
46+ text: FlowyText .medium (field.name, fontSize: 12 ),
47+ hoverColor: theme.hover,
48+ leftIcon: svgWidget (field.fieldType.iconName (), color: theme.iconColor),
49+ onTap: () {},
50+ );
2651 }
2752}
0 commit comments