diff --git a/frontend/appflowy_flutter/lib/plugins/database/widgets/field/type_option_editor/date/date_time_format.dart b/frontend/appflowy_flutter/lib/plugins/database/widgets/field/type_option_editor/date/date_time_format.dart index 862e46fc3b..8c417f40c9 100644 --- a/frontend/appflowy_flutter/lib/plugins/database/widgets/field/type_option_editor/date/date_time_format.dart +++ b/frontend/appflowy_flutter/lib/plugins/database/widgets/field/type_option_editor/date/date_time_format.dart @@ -241,10 +241,12 @@ class IncludeTimeButton extends StatelessWidget { super.key, required this.onChanged, required this.includeTime, + this.showIcon = true, }); final Function(bool value) onChanged; final bool includeTime; + final bool showIcon; @override Widget build(BuildContext context) { @@ -254,11 +256,13 @@ class IncludeTimeButton extends StatelessWidget { padding: GridSize.typeOptionContentInsets, child: Row( children: [ - FlowySvg( - FlowySvgs.clock_alarm_s, - color: Theme.of(context).iconTheme.color, - ), - const HSpace(6), + if (showIcon) ...[ + FlowySvg( + FlowySvgs.clock_alarm_s, + color: Theme.of(context).iconTheme.color, + ), + const HSpace(6), + ], FlowyText(LocaleKeys.grid_field_includeTime.tr()), const Spacer(), Toggle( diff --git a/frontend/appflowy_flutter/lib/plugins/database/widgets/field/type_option_editor/timestamp.dart b/frontend/appflowy_flutter/lib/plugins/database/widgets/field/type_option_editor/timestamp.dart index e67929d2dc..f11bea9ebb 100644 --- a/frontend/appflowy_flutter/lib/plugins/database/widgets/field/type_option_editor/timestamp.dart +++ b/frontend/appflowy_flutter/lib/plugins/database/widgets/field/type_option_editor/timestamp.dart @@ -30,6 +30,8 @@ class TimestampTypeOptionEditorFactory implements TypeOptionEditorFactory { Padding( padding: const EdgeInsets.symmetric(horizontal: 12.0), child: IncludeTimeButton( + includeTime: typeOption.includeTime, + showIcon: false, onChanged: (value) { final newTypeOption = _updateTypeOption( typeOption: typeOption, @@ -37,7 +39,6 @@ class TimestampTypeOptionEditorFactory implements TypeOptionEditorFactory { ); onTypeOptionUpdated(newTypeOption.writeToBuffer()); }, - includeTime: typeOption.includeTime, ), ), ],