@@ -6,9 +6,11 @@ import 'package:app_flowy/workspace/presentation/plugins/grid/src/layout/sizes.d
66import 'package:app_flowy/workspace/presentation/plugins/grid/src/widgets/cell/prelude.dart' ;
77import 'package:app_flowy/workspace/presentation/plugins/grid/src/widgets/header/field_cell.dart' ;
88import 'package:app_flowy/workspace/presentation/plugins/grid/src/widgets/header/field_editor.dart' ;
9+ import 'package:flowy_infra/image.dart' ;
910import 'package:flowy_infra/theme.dart' ;
1011import 'package:flowy_infra_ui/flowy_infra_ui.dart' ;
1112import 'package:flowy_infra_ui/style_widget/hover.dart' ;
13+ import 'package:flowy_infra_ui/style_widget/icon_button.dart' ;
1214import 'package:flowy_infra_ui/style_widget/scrolling/styled_scroll_bar.dart' ;
1315import 'package:flowy_infra_ui/widget/spacing.dart' ;
1416import 'package:flowy_sdk/protobuf/flowy-grid-data-model/grid.pb.dart' show FieldType;
@@ -66,12 +68,36 @@ class _RowDetailPageState extends State<RowDetailPage> {
6668 },
6769 child: Padding (
6870 padding: const EdgeInsets .symmetric (horizontal: 80 , vertical: 40 ),
69- child: _PropertyList (cellCache: widget.cellCache),
71+ child: Column (
72+ children: [
73+ SizedBox (
74+ height: 40 ,
75+ child: Row (
76+ children: const [Spacer (), _CloseButton ()],
77+ )),
78+ Expanded (child: _PropertyList (cellCache: widget.cellCache)),
79+ ],
80+ ),
7081 ),
7182 );
7283 }
7384}
7485
86+ class _CloseButton extends StatelessWidget {
87+ const _CloseButton ({Key ? key}) : super (key: key);
88+
89+ @override
90+ Widget build (BuildContext context) {
91+ final theme = context.watch <AppTheme >();
92+ return FlowyIconButton (
93+ width: 24 ,
94+ onPressed: () => FlowyOverlay .of (context).remove (RowDetailPage .identifier ()),
95+ iconPadding: const EdgeInsets .fromLTRB (2 , 2 , 2 , 2 ),
96+ icon: svgWidget ("home/close" , color: theme.iconColor),
97+ );
98+ }
99+ }
100+
75101class _PropertyList extends StatelessWidget {
76102 final GridCellCache cellCache;
77103 final ScrollController _scrollController;
0 commit comments