Skip to content

Commit b412ef0

Browse files
chore(site): Fix chromatic errors (#6301)
1 parent d993a97 commit b412ef0

File tree

14 files changed

+1046
-1007
lines changed

14 files changed

+1046
-1007
lines changed

.github/workflows/ci.yaml

+6-2
Original file line numberDiff line numberDiff line change
@@ -506,7 +506,7 @@ jobs:
506506
507507
- uses: actions/setup-node@v3
508508
with:
509-
node-version: "14"
509+
node-version: "16.16.0"
510510

511511
- name: Install node_modules
512512
run: ./scripts/yarn_install.sh
@@ -555,7 +555,7 @@ jobs:
555555

556556
- uses: actions/setup-node@v3
557557
with:
558-
node-version: "14"
558+
node-version: "16.16.0"
559559

560560
- name: Echo Go Cache Paths
561561
id: go-cache-paths
@@ -609,6 +609,10 @@ jobs:
609609
# only get 1 commit on shallow checkout.
610610
fetch-depth: 0
611611

612+
- uses: actions/setup-node@v3
613+
with:
614+
node-version: "16.16.0"
615+
612616
- name: Install dependencies
613617
run: cd site && yarn
614618

site/package.json

+5-5
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
"@xstate/inspect": "0.6.5",
4545
"@xstate/react": "3.0.1",
4646
"axios": "0.26.1",
47-
"canvas": "^2.11.0",
47+
"canvas": "2.11.0",
4848
"chart.js": "3.9.1",
4949
"chartjs-adapter-date-fns": "3.0.0",
5050
"color-convert": "2.0.1",
@@ -61,12 +61,12 @@
6161
"jest-location-mock": "1.0.9",
6262
"just-debounce-it": "3.1.1",
6363
"lodash": "4.17.21",
64-
"playwright": "^1.29.2",
64+
"playwright": "1.29.2",
6565
"react": "18.2.0",
6666
"react-chartjs-2": "4.3.1",
6767
"react-color": "2.19.3",
6868
"react-dom": "18.2.0",
69-
"react-headless-tabs": "^6.0.3",
69+
"react-headless-tabs": "6.0.3",
7070
"react-helmet-async": "1.3.0",
7171
"react-i18next": "12.1.1",
7272
"react-markdown": "8.0.3",
@@ -121,10 +121,10 @@
121121
"eslint-plugin-unicorn": "44.0.0",
122122
"jest": "27.5.1",
123123
"jest-canvas-mock": "2.4.0",
124-
"jest-esm-transformer": "^1.0.0",
124+
"jest-esm-transformer": "1.0.0",
125125
"jest-runner-eslint": "1.1.0",
126126
"jest-websocket-mock": "2.4.0",
127-
"monaco-editor": "^0.34.1",
127+
"monaco-editor": "0.34.1",
128128
"msw": "0.47.0",
129129
"prettier": "2.8.1",
130130
"resize-observer": "1.0.4",

site/src/components/AppLink/AppLink.tsx

+5
Original file line numberDiff line numberDiff line change
@@ -130,6 +130,11 @@ const useStyles = makeStyles((theme) => ({
130130

131131
button: {
132132
whiteSpace: "nowrap",
133+
backgroundColor: theme.palette.background.default,
134+
135+
"&:hover": {
136+
backgroundColor: `${theme.palette.background.default} !important`,
137+
},
133138
},
134139

135140
unhealthyIcon: {

site/src/components/PaginationWidget/PageButton.tsx

+1
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ export const PageButton = ({
2121
const styles = useStyles()
2222
return (
2323
<Button
24+
variant="outlined"
2425
className={
2526
activePage === page
2627
? `${styles.pageButton} ${styles.activePageButton}`

site/src/components/PaginationWidget/PaginationWidget.tsx

+2
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ export const PaginationWidget = ({
4444
<Maybe condition={showWidget}>
4545
<div style={containerStyle} className={styles.defaultContainerStyles}>
4646
<Button
47+
variant="outlined"
4748
className={styles.prevLabelStyles}
4849
aria-label="Previous page"
4950
disabled={firstPageActive}
@@ -82,6 +83,7 @@ export const PaginationWidget = ({
8283
</Cond>
8384
</ChooseOne>
8485
<Button
86+
variant="outlined"
8587
aria-label="Next page"
8688
disabled={lastPageActive}
8789
onClick={() => send({ type: "NEXT_PAGE" })}

site/src/components/PortForwardButton/PortForwardButton.tsx

+10
Original file line numberDiff line numberDiff line change
@@ -149,6 +149,7 @@ export const PortForwardButton: React.FC<PortForwardButtonProps> = (props) => {
149149
return (
150150
<>
151151
<Button
152+
className={styles.button}
152153
startIcon={<OpenInNewOutlined />}
153154
size="small"
154155
ref={anchorRef}
@@ -208,4 +209,13 @@ const useStyles = makeStyles((theme) => ({
208209
form: {
209210
margin: theme.spacing(1.5, 0, 0),
210211
},
212+
213+
button: {
214+
whiteSpace: "nowrap",
215+
backgroundColor: theme.palette.background.default,
216+
217+
"&:hover": {
218+
backgroundColor: `${theme.palette.background.default} !important`,
219+
},
220+
},
211221
}))

site/src/components/SSHButton/SSHButton.tsx

+10
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ export const SSHButton: React.FC<React.PropsWithChildren<SSHButtonProps>> = ({
3434
return (
3535
<>
3636
<Button
37+
className={styles.button}
3738
startIcon={<CloudIcon />}
3839
size="small"
3940
ref={anchorRef}
@@ -122,4 +123,13 @@ const useStyles = makeStyles((theme) => ({
122123
textHelper: {
123124
fontWeight: 400,
124125
},
126+
127+
button: {
128+
whiteSpace: "nowrap",
129+
backgroundColor: theme.palette.background.default,
130+
131+
"&:hover": {
132+
backgroundColor: `${theme.palette.background.default} !important`,
133+
},
134+
},
125135
}))

site/src/components/SignInForm/OAuthSignInForm.tsx

+2-2
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ export const OAuthSignInForm: FC<OAuthSignInFormProps> = ({
4242
disabled={isLoading}
4343
fullWidth
4444
type="submit"
45-
variant="contained"
45+
variant="outlined"
4646
>
4747
{Language.githubSignIn}
4848
</Button>
@@ -71,7 +71,7 @@ export const OAuthSignInForm: FC<OAuthSignInFormProps> = ({
7171
disabled={isLoading}
7272
fullWidth
7373
type="submit"
74-
variant="contained"
74+
variant="outlined"
7575
>
7676
{authMethods.oidc.signInText || Language.oidcSignIn}
7777
</Button>

site/src/components/SignInForm/PasswordSignInForm.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ export const PasswordSignInForm: FC<PasswordSignInFormProps> = ({
8888
loading={isLoading}
8989
fullWidth
9090
type="submit"
91-
variant="contained"
91+
variant="outlined"
9292
>
9393
{isLoading ? "" : Language.passwordSignIn}
9494
</LoadingButton>

site/src/components/SignInForm/SignInForm.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ export const SignInForm: FC<React.PropsWithChildren<SignInFormProps>> = ({
150150
<Button
151151
fullWidth
152152
onClick={() => setShowPasswordAuth(true)}
153-
variant="contained"
153+
variant="outlined"
154154
startIcon={<EmailIcon className={styles.icon} />}
155155
>
156156
{loginPageTranslation.t("showPassword")}

site/src/components/TerminalLink/TerminalLink.tsx

+15-2
Original file line numberDiff line numberDiff line change
@@ -51,15 +51,28 @@ export const TerminalLink: FC<React.PropsWithChildren<TerminalLinkProps>> = ({
5151
)
5252
}}
5353
>
54-
<Button startIcon={<ComputerIcon />} size="small">
54+
<Button
55+
startIcon={<ComputerIcon />}
56+
size="small"
57+
className={styles.button}
58+
>
5559
{Language.linkText}
5660
</Button>
5761
</Link>
5862
)
5963
}
6064

61-
const useStyles = makeStyles(() => ({
65+
const useStyles = makeStyles((theme) => ({
6266
link: {
6367
textDecoration: "none !important",
6468
},
69+
70+
button: {
71+
whiteSpace: "nowrap",
72+
backgroundColor: theme.palette.background.default,
73+
74+
"&:hover": {
75+
backgroundColor: `${theme.palette.background.default} !important`,
76+
},
77+
},
6578
}))

site/src/components/VSCodeDesktopButton/VSCodeDesktopButton.tsx

+14
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import { makeStyles } from "@material-ui/core/styles"
12
import Button from "@material-ui/core/Button"
23
import { getApiKey } from "api/api"
34
import { VSCodeIcon } from "components/Icons/VSCodeIcon"
@@ -14,12 +15,14 @@ export const VSCodeDesktopButton: FC<
1415
PropsWithChildren<VSCodeDesktopButtonProps>
1516
> = ({ userName, workspaceName, agentName, folderPath }) => {
1617
const [loading, setLoading] = useState(false)
18+
const styles = useStyles()
1719

1820
return (
1921
<Button
2022
startIcon={<VSCodeIcon />}
2123
size="small"
2224
disabled={loading}
25+
className={styles.button}
2326
onClick={() => {
2427
setLoading(true)
2528
getApiKey()
@@ -51,3 +54,14 @@ export const VSCodeDesktopButton: FC<
5154
</Button>
5255
)
5356
}
57+
58+
const useStyles = makeStyles((theme) => ({
59+
button: {
60+
whiteSpace: "nowrap",
61+
backgroundColor: theme.palette.background.default,
62+
63+
"&:hover": {
64+
backgroundColor: `${theme.palette.background.default} !important`,
65+
},
66+
},
67+
}))

site/src/pages/SetupPage/SetupPageView.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ export const SetupPageView: React.FC<SetupPageViewProps> = ({
121121
</div>
122122
<LoadingButton
123123
fullWidth
124-
variant="contained"
124+
variant="outlined"
125125
loading={isLoading}
126126
type="submit"
127127
>

0 commit comments

Comments
 (0)