Skip to content

Commit 29310fb

Browse files
committed
fix: use same timestamp pattern as Timing Information card
- Remove custom timestamp handling with 'Z' suffix logic - Follow exact same pattern as createdAt/confirmedAt in Timing Information card - Use new Date(log.timestamp) directly like other timestamp displays - Fixes '55 days ago' timestamp display issue
1 parent 707076d commit 29310fb

File tree

1 file changed

+2
-8
lines changed

1 file changed

+2
-8
lines changed

apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/transactions/tx/[id]/transaction-details-ui.tsx

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -417,12 +417,6 @@ function ActivityLogEntryItem({
417417
}) {
418418
const [isExpanded, setIsExpanded] = useState(false);
419419

420-
// Fix timestamp by ensuring it has 'Z' suffix for proper UTC parsing
421-
const fixedTimestamp = log.timestamp.endsWith("Z")
422-
? log.timestamp
423-
: `${log.timestamp}Z`;
424-
const timestamp = new Date(fixedTimestamp);
425-
426420
// Get dot color based on event type
427421
const getDotColor = (eventType: string) => {
428422
const type = eventType.toLowerCase();
@@ -457,7 +451,7 @@ function ActivityLogEntryItem({
457451
<div className="flex items-center gap-2">
458452
<span className="font-medium text-sm">{log.stageName}</span>
459453
<span className="text-muted-foreground text-xs">
460-
{formatDistanceToNowStrict(timestamp, {
454+
{formatDistanceToNowStrict(new Date(log.timestamp), {
461455
addSuffix: true,
462456
})}
463457
</span>
@@ -487,7 +481,7 @@ function ActivityLogEntryItem({
487481
<div>
488482
<div className="text-muted-foreground">Timestamp</div>
489483
<div className="font-mono text-xs">
490-
{format(timestamp, "PP pp z")}
484+
{format(new Date(log.timestamp), "PP pp z")}
491485
</div>
492486
</div>
493487
</div>

0 commit comments

Comments
 (0)