grid: fix treaty update time rendering

This commit is contained in:
Liam Fitzgerald 2021-09-13 15:37:20 +10:00
parent 10885ac57a
commit 10d474c38f
2 changed files with 4 additions and 4 deletions

View File

@ -1,5 +1,5 @@
import React from 'react';
import { Treaty } from '@urbit/api';
import { daToDate, Treaty } from '@urbit/api';
import moment from 'moment';
import { Attribute } from './Attribute';
@ -15,7 +15,7 @@ export function TreatyMeta(props: { treaty: Treaty }) {
{ship}/{desk}
</Attribute>
<Attribute title="Last Software Update" attr="case">
{moment(cass.da).format('YYYY.MM.DD')}
{moment(daToDate(cass.da)).format('YYYY.MM.DD')}
</Attribute>
{meta.map((d) => (
<Attribute key={d} attr={d}>

View File

@ -113,12 +113,12 @@ export interface Cass {
*/
ud: number;
/**
* Timestamp of revision, as unix timestamp
* Timestamp of revision, as stringifed `@da`
*
* @remarks
* If \@da is outside valid positive unix timestamp, value will be zero
*/
da: number;
da: string;
}
/**