Skip to content

armgit / ente

Public Imported from GitHub
0

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

Prevent layout shift

Manav Rathi228bf49eb33e
diff --git a/web/packages/accounts/components/PasswordStrength.tsx b/web/packages/accounts/components/PasswordStrength.tsx
index 0fb597a2ee..d543f5cd6e 100644
--- a/web/packages/accounts/components/PasswordStrength.tsx
+++ b/web/packages/accounts/components/PasswordStrength.tsx
@@ -19,8 +19,9 @@ export const PasswordStrengthHint: React.FC<PasswordStrengthHintProps> = ({
<Typography
variant="small"
sx={(theme) => ({
- marginBlock: "8px 4px",
+ mt: "8px",
alignSelf: "flex-start",
+ whiteSpace: "pre",
color:
passwordStrength == "weak"
? theme.colors.danger.A700
@@ -31,7 +32,8 @@ export const PasswordStrengthHint: React.FC<PasswordStrengthHintProps> = ({
>
{password
? t("passphrase_strength", { context: passwordStrength })
- : ""}
+ : /* empty space + white-space: pre to prevent layout shift. */
+ " "}
</Typography>
);
};