Skip to content

Commit

Permalink
Merge pull request #1872 from ardriveapp/PE-6802-timestamps
Browse files Browse the repository at this point in the history
PE-6802: feat(timestamps)
  • Loading branch information
thiagocarvalhodev authored Sep 26, 2024
2 parents ad4ae62 + 79e58cb commit ec13374
Show file tree
Hide file tree
Showing 6 changed files with 36 additions and 298 deletions.
20 changes: 10 additions & 10 deletions lib/components/details_panel.dart
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ import 'package:ardrive/core/arfs/entities/arfs_entities.dart';
import 'package:ardrive/core/crypto/crypto.dart';
import 'package:ardrive/download/multiple_file_download_modal.dart';
import 'package:ardrive/drive_explorer/thumbnail_creation/page/thumbnail_creation_modal.dart';
import 'package:ardrive/l11n/l11n.dart';
import 'package:ardrive/misc/resources.dart';
import 'package:ardrive/models/models.dart';
import 'package:ardrive/pages/drive_detail/components/drive_explorer_item_tile.dart';
Expand All @@ -26,6 +25,7 @@ import 'package:ardrive/services/services.dart';
import 'package:ardrive/theme/theme.dart';
import 'package:ardrive/utils/app_localizations_wrapper.dart';
import 'package:ardrive/utils/filesize.dart';
import 'package:ardrive/utils/format_date.dart';
import 'package:ardrive/utils/num_to_string_parsers.dart';
import 'package:ardrive/utils/open_url.dart';
import 'package:ardrive/utils/show_general_dialog.dart';
Expand Down Expand Up @@ -602,15 +602,15 @@ class _DetailsPanelState extends State<DetailsPanel> {
sizedBoxHeight16px,
DetailsPanelItem(
leading: Text(
yMMdDateFormatter.format(widget.item.lastUpdated),
formatDateToUtcString(widget.item.lastUpdated),
style: typography.paragraphNormal(),
),
itemTitle: appLocalizationsOf(context).lastUpdated,
),
sizedBoxHeight16px,
DetailsPanelItem(
leading: Text(
yMMdDateFormatter.format(widget.item.dateCreated),
formatDateToUtcString(widget.item.dateCreated),
style: typography.paragraphNormal(),
),
itemTitle: appLocalizationsOf(context).dateCreated,
Expand Down Expand Up @@ -672,15 +672,15 @@ class _DetailsPanelState extends State<DetailsPanel> {
sizedBoxHeight16px,
DetailsPanelItem(
leading: Text(
yMMdDateFormatter.format(widget.item.lastUpdated),
formatDateToUtcString(widget.item.lastUpdated),
style: typography.paragraphNormal(),
),
itemTitle: appLocalizationsOf(context).lastUpdated,
),
sizedBoxHeight16px,
DetailsPanelItem(
leading: Text(
yMMdDateFormatter.format(widget.item.dateCreated),
formatDateToUtcString(widget.item.dateCreated),
style: typography.paragraphNormal(),
),
itemTitle: appLocalizationsOf(context).dateCreated,
Expand Down Expand Up @@ -724,15 +724,15 @@ class _DetailsPanelState extends State<DetailsPanel> {
sizedBoxHeight16px,
DetailsPanelItem(
leading: Text(
yMMdDateFormatter.format(item.lastUpdated),
formatDateToUtcString(item.lastUpdated),
style: typography.paragraphNormal(),
),
itemTitle: appLocalizationsOf(context).lastUpdated,
),
sizedBoxHeight16px,
DetailsPanelItem(
leading: Text(
yMMdDateFormatter.format(item.dateCreated),
formatDateToUtcString(item.dateCreated),
style: typography.paragraphNormal(),
),
itemTitle: appLocalizationsOf(context).dateCreated,
Expand Down Expand Up @@ -901,7 +901,7 @@ class _DetailsPanelState extends State<DetailsPanel> {
default:
title = appLocalizationsOf(context).folderWasModified;
}
subtitle = yMMdDateFormatter.format(revision.dateCreated);
subtitle = formatDateToUtcString(revision.dateCreated);

return DetailsPanelItem(
itemSubtitle: subtitle,
Expand Down Expand Up @@ -944,7 +944,7 @@ class _DetailsPanelState extends State<DetailsPanel> {
title = appLocalizationsOf(context).driveWasModified;
}

subtitle = yMMdDateFormatter.format(revision.dateCreated);
subtitle = formatDateToUtcString(revision.dateCreated);

return DetailsPanelItem(
itemSubtitle: subtitle,
Expand Down Expand Up @@ -1023,7 +1023,7 @@ class _DetailsPanelState extends State<DetailsPanel> {
default:
title = appLocalizationsOf(context).fileWasModified;
}
subtitle = yMMdDateFormatter.format(file.unixTime);
subtitle = formatDateToUtcString(file.unixTime);

return DetailsPanelItem(
leading: leading ?? const SizedBox(),
Expand Down
4 changes: 2 additions & 2 deletions lib/pages/drive_detail/components/drive_detail_data_list.dart
Original file line number Diff line number Diff line change
Expand Up @@ -200,8 +200,8 @@ Widget _buildDataListContent(
name: row.name,
typography: typography,
size: row.size == null ? '-' : filesize(row.size),
lastUpdated: yMMdDateFormatter.format(row.lastUpdated),
dateCreated: yMMdDateFormatter.format(row.dateCreated),
lastUpdated: row.lastUpdated,
dateCreated: row.dateCreated,
dataTableItem: row,
license: row.licenseType == null
? ''
Expand Down
272 changes: 0 additions & 272 deletions lib/pages/drive_detail/components/drive_detail_data_table_source.dart

This file was deleted.

Loading

0 comments on commit ec13374

Please sign in to comment.