Skip to content

Commit 9d9d7ef

Browse files
committed
Provide missing data to ROFL apps list
1 parent 97249a0 commit 9d9d7ef

File tree

4 files changed

+13
-8
lines changed

4 files changed

+13
-8
lines changed

.changelog/1842.trivial.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Provide missing data to ROFL apps list

src/app/components/Rofl/RoflAppsList.tsx

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import { RoflApp } from '../../../oasis-nexus/api'
44
import { Table, TableCellAlign, TableColProps } from '..//Table'
55
import { TablePaginationProps } from '../Table/TablePagination'
66
import { TableHeaderAge } from '../TableHeaderAge'
7+
import { TableCellAge } from '../TableCellAge'
78
import { RoflAppStatusBadge } from './RoflAppStatusBadge'
89
import { RoflAppLink } from './RoflAppLink'
910

@@ -24,8 +25,8 @@ export const RoflAppsList: FC<RoflAppsListProps> = ({ isLoading, limit, paginati
2425
{ key: 'instances', content: t('rofl.instances'), align: TableCellAlign.Right },
2526
{ key: 'created', content: t('rofl.created'), align: TableCellAlign.Right },
2627
{
27-
key: 'lastActvity',
28-
content: <TableHeaderAge label={t('rofl.lastActvity')} />,
28+
key: 'lastActivity',
29+
content: <TableHeaderAge label={t('rofl.lastActivity')} />,
2930
align: TableCellAlign.Right,
3031
},
3132
]
@@ -73,13 +74,16 @@ export const RoflAppsList: FC<RoflAppsListProps> = ({ isLoading, limit, paginati
7374
} satisfies Intl.DateTimeFormatOptions,
7475
},
7576
}),
76-
key: 'firstActivity',
77+
key: 'created',
7778
},
7879
{
7980
align: TableCellAlign.Right,
80-
// TODO: Replace with last activity when available
81-
content: t('common.missing'),
82-
key: 'timestamp',
81+
content: app.last_activity ? (
82+
<TableCellAge sinceTimestamp={app.last_activity} />
83+
) : (
84+
t('common.missing')
85+
),
86+
key: 'lastActivity',
8387
},
8488
],
8589
}

src/app/pages/RoflAppDetailsPage/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ export const RoflAppDetailsView: FC<{
5151
},
5252
})}
5353
</dd>
54-
<dt>{t('rofl.lastActvity')}</dt>
54+
<dt>{t('rofl.lastActivity')}</dt>
5555
<dd>{t('common.missing')}</dd>
5656
</StyledDescriptionList>
5757
)

src/locales/en/translation.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -660,7 +660,7 @@
660660
"rakAbbreviation": "RAK",
661661
"rak": "Runtime Attestation Key",
662662
"removed": "Removed",
663-
"lastActvity": "Last activity",
663+
"lastActivity": "Last activity",
664664
"appId": "App ID",
665665
"emptyRoflAppsList": "No ROFL apps found.",
666666
"created": "Date created",

0 commit comments

Comments
 (0)