@@ -8,6 +8,15 @@ import { CardRadius, MONOSPACE_FONT_FAMILY } from "../../theme/constants"
8
8
import { combineClasses } from "../../util/combineClasses"
9
9
import { getDisplayStatus } from "../../util/workspace"
10
10
11
+ const Language = {
12
+ templateLabel : "Template" ,
13
+ statusLabel : "Status" ,
14
+ versionLabel : "Version" ,
15
+ lastBuiltLabel : "Last Built" ,
16
+ outdated : "Outdated" ,
17
+ upToDate : "Up to date" ,
18
+ }
19
+
11
20
export interface WorkspaceStatsProps {
12
21
workspace : Workspace
13
22
}
@@ -20,7 +29,7 @@ export const WorkspaceStats: React.FC<WorkspaceStatsProps> = ({ workspace }) =>
20
29
return (
21
30
< div className = { styles . stats } >
22
31
< div className = { styles . statItem } >
23
- < span className = { styles . statsLabel } > Workspace </ span >
32
+ < span className = { styles . statsLabel } > { Language . templateLabel } </ span >
24
33
< Link
25
34
component = { RouterLink }
26
35
to = { `/templates/${ workspace . template_name } ` }
@@ -31,7 +40,7 @@ export const WorkspaceStats: React.FC<WorkspaceStatsProps> = ({ workspace }) =>
31
40
</ div >
32
41
< div className = { styles . statsDivider } />
33
42
< div className = { styles . statItem } >
34
- < span className = { styles . statsLabel } > Status </ span >
43
+ < span className = { styles . statsLabel } > { Language . statusLabel } </ span >
35
44
< span className = { styles . statsValue } >
36
45
< span style = { { color : status . color } } role = "status" >
37
46
{ status . status }
@@ -40,18 +49,18 @@ export const WorkspaceStats: React.FC<WorkspaceStatsProps> = ({ workspace }) =>
40
49
</ div >
41
50
< div className = { styles . statsDivider } />
42
51
< div className = { styles . statItem } >
43
- < span className = { styles . statsLabel } > Version </ span >
52
+ < span className = { styles . statsLabel } > { Language . versionLabel } </ span >
44
53
< span className = { styles . statsValue } >
45
54
{ workspace . outdated ? (
46
- < span style = { { color : theme . palette . error . main } } > Outdated </ span >
55
+ < span style = { { color : theme . palette . error . main } } > { Language . outdated } </ span >
47
56
) : (
48
- < span style = { { color : theme . palette . text . secondary } } > Up to date </ span >
57
+ < span style = { { color : theme . palette . text . secondary } } > { Language . upToDate } </ span >
49
58
) }
50
59
</ span >
51
60
</ div >
52
61
< div className = { styles . statsDivider } />
53
62
< div className = { styles . statItem } >
54
- < span className = { styles . statsLabel } > Last built </ span >
63
+ < span className = { styles . statsLabel } > { Language . lastBuiltLabel } </ span >
55
64
< span className = { styles . statsValue } data-chromatic = "ignore" >
56
65
{ dayjs ( ) . to ( dayjs ( workspace . latest_build . created_at ) ) }
57
66
</ span >
0 commit comments