Skip to content

chore: use emotion for styling (pt. 4) #10149

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 25 commits into from
Oct 10, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
emotion: ExternalAuth
  • Loading branch information
aslilac committed Oct 9, 2023
commit 65cf2a5897ab5e65a37b6b20fe84143ff932cd96
15 changes: 2 additions & 13 deletions site/src/pages/CreateWorkspacePage/ExternalAuth.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,9 @@ import ReplayIcon from "@mui/icons-material/Replay";
import Button from "@mui/material/Button";
import FormHelperText from "@mui/material/FormHelperText";
import Tooltip from "@mui/material/Tooltip";
import { makeStyles } from "@mui/styles";
import { type FC } from "react";
import { LoadingButton } from "components/LoadingButton/LoadingButton";
import { Stack } from "components/Stack/Stack";
import { FC } from "react";
import { type ExternalAuthPollingState } from "./CreateWorkspacePage";

export interface ExternalAuthProps {
Expand All @@ -29,10 +28,6 @@ export const ExternalAuth: FC<ExternalAuthProps> = (props) => {
error,
} = props;

const styles = useStyles({
error: typeof error !== "undefined",
});

return (
<Tooltip
title={authenticated && `${displayName} has already been connected.`}
Expand All @@ -52,7 +47,7 @@ export const ExternalAuth: FC<ExternalAuthProps> = (props) => {
/>
}
disabled={authenticated}
className={styles.button}
css={{ height: 52 }}
color={error ? "error" : undefined}
fullWidth
onClick={(event) => {
Expand Down Expand Up @@ -80,9 +75,3 @@ export const ExternalAuth: FC<ExternalAuthProps> = (props) => {
</Tooltip>
);
};

const useStyles = makeStyles(() => ({
button: {
height: 52,
},
}));