+
{t(translations.termsOfService)}
-
+
{t(translations.privacyPolicy)}
-
+
{t(translations.contactUs)}
{
Date: Wed, 28 Jun 2023 13:51:49 +0800
Subject: [PATCH 07/10] style(PasswordTextField): remove visibility hint
---
.../core/fields/PasswordTextField.tsx | 27 ++-----------------
client/app/lib/translations/messages.ts | 5 ----
2 files changed, 2 insertions(+), 30 deletions(-)
diff --git a/client/app/lib/components/core/fields/PasswordTextField.tsx b/client/app/lib/components/core/fields/PasswordTextField.tsx
index 73ac0d20f69..f5841ad3b8d 100644
--- a/client/app/lib/components/core/fields/PasswordTextField.tsx
+++ b/client/app/lib/components/core/fields/PasswordTextField.tsx
@@ -1,15 +1,11 @@
import { ComponentProps, forwardRef, useState } from 'react';
import { Visibility, VisibilityOff } from '@mui/icons-material';
-import { IconButton, InputAdornment, Typography } from '@mui/material';
-
-import useTranslation from 'lib/hooks/useTranslation';
-import messagesTranslations from 'lib/translations/messages';
+import { IconButton, InputAdornment } from '@mui/material';
import TextField from './TextField';
type PasswordTextFieldProps = ComponentProps
& {
onChangePasswordVisibility?: (visibility: boolean) => void;
- showPasswordVisibilityHint?: boolean;
disablePasswordVisibilitySwitch?: boolean;
};
@@ -17,12 +13,10 @@ const PasswordTextField = forwardRef(
(props, ref): JSX.Element => {
const {
onChangePasswordVisibility,
- showPasswordVisibilityHint,
disablePasswordVisibilitySwitch,
...textFieldProps
} = props;
- const { t } = useTranslation();
const [showPassword, setShowPassword] = useState(false);
const handleChangePasswordVisibility = (): void =>
@@ -31,7 +25,7 @@ const PasswordTextField = forwardRef(
return !state;
});
- const textField = (
+ return (
(
})}
/>
);
-
- if (showPasswordVisibilityHint && showPassword)
- return (
-
- {textField}
-
-
-
-
-
- {t(messagesTranslations.passwordIsVisible)}
-
-
-
- );
-
- return textField;
},
);
diff --git a/client/app/lib/translations/messages.ts b/client/app/lib/translations/messages.ts
index 06a234c912a..fe53fa38b4d 100644
--- a/client/app/lib/translations/messages.ts
+++ b/client/app/lib/translations/messages.ts
@@ -16,11 +16,6 @@ const messagesTranslations = defineMessages({
defaultMessage:
'An error occurred when saving your changes. You may reload and try again.',
},
- passwordIsVisible: {
- id: 'lib.translations.messages.passwordIsVisible',
- defaultMessage:
- 'Your password is visible! Watch out for eyes behind you...',
- },
});
export default messagesTranslations;
From 06bbe14e6d62a31d42ab7c1d926ea16b9148262d Mon Sep 17 00:00:00 2001
From: Phillmont Muktar <51525686+purfectliterature@users.noreply.github.com>
Date: Wed, 28 Jun 2023 13:52:43 +0800
Subject: [PATCH 08/10] fix(AccountSettings): p/w confirmation still appear
after showing p/w
---
.../bundles/user/AccountSettings/AccountSettingsForm.tsx | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/client/app/bundles/user/AccountSettings/AccountSettingsForm.tsx b/client/app/bundles/user/AccountSettings/AccountSettingsForm.tsx
index 5a22e6dea25..1538625a1c1 100644
--- a/client/app/bundles/user/AccountSettings/AccountSettingsForm.tsx
+++ b/client/app/bundles/user/AccountSettings/AccountSettingsForm.tsx
@@ -262,7 +262,6 @@ const AccountSettingsForm = (props: AccountSettingsFormProps): JSX.Element => {
fullWidth
inputProps={{ autoComplete: 'off' }}
label={t(translations.currentPassword)}
- showPasswordVisibilityHint
type="password"
variant="filled"
/>
@@ -284,8 +283,9 @@ const AccountSettingsForm = (props: AccountSettingsFormProps): JSX.Element => {
fullWidth
inputProps={{ autoComplete: 'new-password' }}
label={t(translations.newPassword)}
- onChangePasswordVisibility={setRequirePasswordConfirmation}
- showPasswordVisibilityHint
+ onChangePasswordVisibility={(visible): void =>
+ setRequirePasswordConfirmation(!visible)
+ }
type="password"
variant="filled"
/>
From def93f0c7b0e69563e77ff6f993a63d7696695fd Mon Sep 17 00:00:00 2001
From: Phillmont Muktar <51525686+purfectliterature@users.noreply.github.com>
Date: Wed, 28 Jun 2023 13:53:14 +0800
Subject: [PATCH 09/10] fix(Checkbox): properly support `small` size
---
client/app/lib/components/core/buttons/Checkbox.tsx | 11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/client/app/lib/components/core/buttons/Checkbox.tsx b/client/app/lib/components/core/buttons/Checkbox.tsx
index 55d316b9d6b..643af4f5533 100644
--- a/client/app/lib/components/core/buttons/Checkbox.tsx
+++ b/client/app/lib/components/core/buttons/Checkbox.tsx
@@ -69,11 +69,18 @@ const Checkbox = forwardRef(
}
/>
-
+
{description && (
{description}
From b0aef5eef8fafa974ad9d2884a9a7443033162d9 Mon Sep 17 00:00:00 2001
From: Phillmont Muktar <51525686+purfectliterature@users.noreply.github.com>
Date: Wed, 28 Jun 2023 14:05:16 +0800
Subject: [PATCH 10/10] fix(rack_mini_profiler): move to top right temporarily
It covers the menu button on the React course pages.
---
config/initializers/rack_mini_profiler.rb | 3 +++
1 file changed, 3 insertions(+)
create mode 100644 config/initializers/rack_mini_profiler.rb
diff --git a/config/initializers/rack_mini_profiler.rb b/config/initializers/rack_mini_profiler.rb
new file mode 100644
index 00000000000..f8f27e8950e
--- /dev/null
+++ b/config/initializers/rack_mini_profiler.rb
@@ -0,0 +1,3 @@
+# frozen_string_literal: true
+# TODO: Remove this once fully SPA
+Rack::MiniProfiler.config.position = 'top-right'