Skip to content

armgit / ente

Public Imported from GitHub
0

πŸ’š End-to-end encrypted cloud for everything.

Manual cleanup after npx @mui/codemod@latest v6.0.0/system-props

Manav Rathi4ce934a0f960
diff --git a/web/packages/accounts/components/Login.tsx b/web/packages/accounts/components/Login.tsx
index 82784844bd..af7d5462ac 100644
--- a/web/packages/accounts/components/Login.tsx
+++ b/web/packages/accounts/components/Login.tsx
@@ -67,15 +67,13 @@ export const Login: React.FC<LoginProps> = ({ signUp, host }) => {
<Input sx={{ display: "none" }} type="password" value="" />
}
/>
-
<FormPaperFooter>
- <Stack gap={4}>
+ <Stack sx={{ gap: 4 }}>
<LinkButton onClick={signUp}>{t("NO_ACCOUNT")}</LinkButton>
<Typography
variant="mini"
- color="text.faint"
- minHeight={"32px"}
+ sx={{ color: "text.faint", minHeight: "32px" }}
>
{host ?? "" /* prevent layout shift with a minHeight */}
</Typography>
diff --git a/web/packages/accounts/components/LoginComponents.tsx b/web/packages/accounts/components/LoginComponents.tsx
index eb20cd2dc6..df8cd045f9 100644
--- a/web/packages/accounts/components/LoginComponents.tsx
+++ b/web/packages/accounts/components/LoginComponents.tsx
@@ -23,7 +23,7 @@ export const PasswordHeader: React.FC<React.PropsWithChildren> = ({
return (
<Header_>
<Typography variant="h2">{t("password")}</Typography>
- <Typography color="text.faint">{children}</Typography>
+ <Typography sx={{ color: "text.faint" }}>{children}</Typography>
</Header_>
);
};
@@ -32,7 +32,7 @@ const PasskeyHeader: React.FC<React.PropsWithChildren> = ({ children }) => {
return (
<Header_>
<Typography variant="h3">{"Passkey"}</Typography>
- <Typography color="text.faint">{children}</Typography>
+ <Typography sx={{ color: "text.faint" }}>{children}</Typography>
</Header_>
);
};
@@ -53,11 +53,17 @@ export const LoginFlowFormFooter: React.FC<React.PropsWithChildren> = ({
return (
<FormPaperFooter>
- <Stack gap="16px" width="100%" textAlign="start">
+ <Stack
+ sx={{
+ gap: "16px",
+ width: "100%",
+ textAlign: "start",
+ }}
+ >
{children}
{host && (
- <Typography variant="small" color="text.faint">
+ <Typography variant="small" sx={{ color: "text.faint" }}>
{host}
</Typography>
)}
@@ -131,7 +137,7 @@ export const VerifyingPasskey: React.FC<VerifyingPasskeyProps> = ({
<CircularProgress color="accent" size="1.5em" />
</Typography>
) : (
- <Typography color="text.muted">
+ <Typography sx={{ color: "text.muted" }}>
{verificationStatus == "waiting"
? t("waiting_for_verification")
: t("verification_still_pending")}
@@ -159,7 +165,10 @@ export const VerifyingPasskey: React.FC<VerifyingPasskeyProps> = ({
</VerifyingPasskeyMiddle>
<LoginFlowFormFooter>
- <Stack direction="row" justifyContent="space-between">
+ <Stack
+ direction="row"
+ sx={{ justifyContent: "space-between" }}
+ >
<LinkButton onClick={handleRecover}>
{t("RECOVER_ACCOUNT")}
</LinkButton>
diff --git a/web/packages/accounts/components/RecoveryKey.tsx b/web/packages/accounts/components/RecoveryKey.tsx
index 854c787f7a..010ddcbc5c 100644
--- a/web/packages/accounts/components/RecoveryKey.tsx
+++ b/web/packages/accounts/components/RecoveryKey.tsx
@@ -81,12 +81,15 @@ export const RecoveryKey: React.FC<RecoveryKeyProps> = ({
</DialogTitle>
<DialogCloseIconButton {...{ onClose }} />
</SpaceBetweenFlex>
-
<DialogContent>
- <Typography mb={3}>{t("recovery_key_description")}</Typography>
+ <Typography sx={{ mb: 3 }}>
+ {t("recovery_key_description")}
+ </Typography>
<DashedBorderWrapper>
<CodeBlock code={recoveryKey} />
- <Typography m={2}>{t("key_not_stored_note")}</Typography>
+ <Typography sx={{ m: 2 }}>
+ {t("key_not_stored_note")}
+ </Typography>
</DashedBorderWrapper>
</DialogContent>
<DialogActions>
diff --git a/web/packages/accounts/components/SetPasswordForm.tsx b/web/packages/accounts/components/SetPasswordForm.tsx
index 43bcc9d653..4c9dfd165c 100644
--- a/web/packages/accounts/components/SetPasswordForm.tsx
+++ b/web/packages/accounts/components/SetPasswordForm.tsx
@@ -80,7 +80,10 @@ function SetPasswordForm(props: SetPasswordFormProps) {
>
{({ values, errors, handleChange, handleSubmit }) => (
<form noValidate onSubmit={handleSubmit}>
- <Typography mb={2} color="text.muted" variant="small">
+ <Typography
+ variant="small"
+ sx={{ mb: 2, color: "text.muted" }}
+ >
{t("ENTER_ENC_PASSPHRASE")}
</Typography>
@@ -136,11 +139,11 @@ function SetPasswordForm(props: SetPasswordFormProps) {
/>
<PasswordStrengthHint password={values.passphrase} />
- <Typography my={2} variant="small">
+ <Typography variant="small" sx={{ my: 2 }}>
<Trans i18nKey={"PASSPHRASE_DISCLAIMER"} />
</Typography>
- <Box my={4}>
+ <Box sx={{ my: 4 }}>
<LoadingButton
fullWidth
color="accent"
@@ -152,10 +155,12 @@ function SetPasswordForm(props: SetPasswordFormProps) {
</LoadingButton>
{loading && (
<Typography
- textAlign="center"
- mt={1}
- color="text.muted"
variant="small"
+ sx={{
+ textAlign: "center",
+ mt: 1,
+ color: "text.muted",
+ }}
>
{t("key_generation_in_progress")}
</Typography>
diff --git a/web/packages/accounts/components/SignUp.tsx b/web/packages/accounts/components/SignUp.tsx
index cccaf2b379..39f68f2a13 100644
--- a/web/packages/accounts/components/SignUp.tsx
+++ b/web/packages/accounts/components/SignUp.tsx
@@ -216,9 +216,11 @@ export const SignUp: React.FC<SignUpProps> = ({ router, login, host }) => {
<Box sx={{ width: "100%" }}>
<Typography
- textAlign={"left"}
- color="text.secondary"
- mt={"24px"}
+ sx={{
+ textAlign: "left",
+ color: "text.secondary",
+ mt: "24px",
+ }}
>
{t("REFERRAL_CODE_HINT")}
</Typography>
@@ -297,7 +299,7 @@ export const SignUp: React.FC<SignUpProps> = ({ router, login, host }) => {
/>
</FormGroup>
</VerticallyCentered>
- <Box mb={4}>
+ <Box sx={{ mb: 4 }}>
<LoadingButton
fullWidth
color="accent"
@@ -312,10 +314,12 @@ export const SignUp: React.FC<SignUpProps> = ({ router, login, host }) => {
</LoadingButton>
{loading && (
<Typography
- mt={1}
- textAlign={"center"}
- color="text.muted"
variant="small"
+ sx={{
+ mt: 1,
+ textAlign: "center",
+ color: "text.muted",
+ }}
>
{t("key_generation_in_progress")}
</Typography>
@@ -325,15 +329,14 @@ export const SignUp: React.FC<SignUpProps> = ({ router, login, host }) => {
)}
</Formik>
<FormPaperFooter>
- <Stack gap={4}>
+ <Stack sx={{ gap: 4 }}>
<LinkButton onClick={login}>
{t("ACCOUNT_EXISTS")}
</LinkButton>
<Typography
variant="mini"
- color="text.faint"
- minHeight={"32px"}
+ sx={{ color: "text.faint", minHeight: "32px" }}
>
{host ?? "" /* prevent layout shift with a minHeight */}
</Typography>
diff --git a/web/packages/accounts/components/two-factor/VerifyTwoFactor.tsx b/web/packages/accounts/components/two-factor/VerifyTwoFactor.tsx
index e21601f151..457234ad76 100644
--- a/web/packages/accounts/components/two-factor/VerifyTwoFactor.tsx
+++ b/web/packages/accounts/components/two-factor/VerifyTwoFactor.tsx
@@ -66,10 +66,13 @@ export function VerifyTwoFactor(props: Props) {
{({ values, errors, handleChange, handleSubmit, submitForm }) => (
<VerticallyCentered>
<form noValidate onSubmit={handleSubmit}>
- <Typography mb={2} variant="small" color="text.muted">
+ <Typography
+ variant="small"
+ sx={{ mb: 2, color: "text.muted" }}
+ >
{t("ENTER_TWO_FACTOR_OTP")}
</Typography>
- <Box my={2}>
+ <Box sx={{ my: 2 }}>
<OtpInput
shouldAutoFocus={shouldAutoFocus}
value={values.otp}
diff --git a/web/packages/accounts/pages/change-email.tsx b/web/packages/accounts/pages/change-email.tsx
index 4abe7d6988..158ab98031 100644
--- a/web/packages/accounts/pages/change-email.tsx
+++ b/web/packages/accounts/pages/change-email.tsx
@@ -134,8 +134,8 @@ const ChangeEmailForm: React.FC = () => {
components={{
a: (
<Box
- color="text.muted"
component={"span"}
+ sx={{ color: "text.muted" }}
/>
),
}}
diff --git a/web/packages/accounts/pages/credentials.tsx b/web/packages/accounts/pages/credentials.tsx
index c8565557a6..df5e42e220 100644
--- a/web/packages/accounts/pages/credentials.tsx
+++ b/web/packages/accounts/pages/credentials.tsx
@@ -390,7 +390,10 @@ const Page: React.FC<PageProps> = ({ appContext }) => {
/>
<LoginFlowFormFooter>
- <Stack direction="row" justifyContent="space-between">
+ <Stack
+ direction="row"
+ sx={{ justifyContent: "space-between" }}
+ >
<LinkButton onClick={() => router.push(PAGES.RECOVER)}>
{t("FORGOT_PASSWORD")}
</LinkButton>
@@ -400,7 +403,6 @@ const Page: React.FC<PageProps> = ({ appContext }) => {
</Stack>
</LoginFlowFormFooter>
</FormPaper>
-
<SecondFactorChoice {...secondFactorChoiceProps} />
</VerticallyCentered>
);
diff --git a/web/packages/accounts/pages/two-factor/setup.tsx b/web/packages/accounts/pages/two-factor/setup.tsx
index c91365e2bd..9dc1a5c4e6 100644
--- a/web/packages/accounts/pages/two-factor/setup.tsx
+++ b/web/packages/accounts/pages/two-factor/setup.tsx
@@ -63,7 +63,7 @@ const Page: React.FC<PageProps> = () => {
<Card>
<CardContent>
<VerticallyCentered sx={{ p: 3 }}>
- <Box mb={4}>
+ <Box sx={{ mb: 4 }}>
<Typography variant="h2">
{t("two_factor")}
</Typography>
diff --git a/web/packages/accounts/pages/verify.tsx b/web/packages/accounts/pages/verify.tsx
index 0aa53f5e6e..ead8824e83 100644
--- a/web/packages/accounts/pages/verify.tsx
+++ b/web/packages/accounts/pages/verify.tsx
@@ -225,12 +225,17 @@ const Page: React.FC<PageProps> = ({ appContext }) => {
<Trans
i18nKey="EMAIL_SENT"
components={{
- a: <Box color="text.muted" component={"span"} />,
+ a: (
+ <Box
+ component={"span"}
+ sx={{ color: "text.muted" }}
+ />
+ ),
}}
values={{ email }}
/>
</FormPaperTitle>
- <Typography color={"text.muted"} mb={2} variant="small">
+ <Typography variant="small" sx={{ color: "text.muted", mb: 2 }}>
{t("CHECK_INBOX")}
</Typography>
<SingleInputForm
@@ -242,7 +247,10 @@ const Page: React.FC<PageProps> = ({ appContext }) => {
/>
<LoginFlowFormFooter>
- <Stack direction="row" justifyContent="space-between">
+ <Stack
+ direction="row"
+ sx={{ justifyContent: "space-between" }}
+ >
{resend === 0 && (
<LinkButton onClick={resendEmail}>
{t("RESEND_MAIL")}
@@ -256,7 +264,6 @@ const Page: React.FC<PageProps> = ({ appContext }) => {
</Stack>
</LoginFlowFormFooter>
</FormPaper>
-
<SecondFactorChoice {...secondFactorChoiceProps} />
</VerticallyCentered>
);