Skip to content

Commit 916c388

Browse files
fix: Statuses breaking line in the UI (#3071)
* fix: Fix statuses breaking line in the UI * fix: AppLink stories
1 parent 82f159b commit 916c388

File tree

4 files changed

+19
-3
lines changed

4 files changed

+19
-3
lines changed

site/src/components/AppLink/AppLink.stories.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ WithIcon.args = {
1414
userName: "developer",
1515
workspaceName: MockWorkspace.name,
1616
appName: "code-server",
17-
appIcon: "/code.svg",
17+
appIcon: "/icon/code.svg",
1818
}
1919

2020
export const WithoutIcon = Template.bind({})

site/src/components/AppLink/AppLink.tsx

+5
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ export const AppLink: FC<AppLinkProps> = ({ userName, workspaceName, appName, ap
3838
<Button
3939
size="small"
4040
startIcon={appIcon ? <img alt={`${appName} Icon`} src={appIcon} /> : <ComputerIcon />}
41+
className={styles.button}
4142
>
4243
{appName}
4344
</Button>
@@ -49,4 +50,8 @@ const useStyles = makeStyles(() => ({
4950
link: {
5051
textDecoration: "none !important",
5152
},
53+
54+
button: {
55+
whiteSpace: "nowrap",
56+
},
5257
}))

site/src/components/BuildsTable/BuildsTable.tsx

+6-1
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,9 @@ export const BuildsTable: FC<BuildsTableProps> = ({ builds, className }) => {
7979
</span>
8080
</TableCellLink>
8181
<TableCellLink to={buildPageLink}>
82-
<span style={{ color: status.color }}>{status.status}</span>
82+
<span style={{ color: status.color }} className={styles.status}>
83+
{status.status}
84+
</span>
8385
</TableCellLink>
8486
<TableCellLink to={buildPageLink}>
8587
<div className={styles.arrowCell}>
@@ -126,4 +128,7 @@ const useStyles = makeStyles((theme) => ({
126128
arrowCell: {
127129
display: "flex",
128130
},
131+
status: {
132+
whiteSpace: "nowrap",
133+
},
129134
}))

site/src/components/Resources/Resources.tsx

+7-1
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,9 @@ export const Resources: FC<ResourcesProps> = ({
100100
{agent.name}
101101
<div className={styles.agentInfo}>
102102
<span className={styles.operatingSystem}>{agent.operating_system}</span>
103-
<span style={{ color: agentStatus.color }}>{agentStatus.status}</span>
103+
<span style={{ color: agentStatus.color }} className={styles.status}>
104+
{agentStatus.status}
105+
</span>
104106
</div>
105107
</TableCell>
106108
<TableCell>
@@ -182,4 +184,8 @@ const useStyles = makeStyles((theme) => ({
182184
flexWrap: "wrap",
183185
justifyContent: "flex-end",
184186
},
187+
188+
status: {
189+
whiteSpace: "nowrap",
190+
},
185191
}))

0 commit comments

Comments
 (0)