diff --git a/lemmy-translations b/lemmy-translations
index 21b8e8d9..6fe83fe9 160000
--- a/lemmy-translations
+++ b/lemmy-translations
@@ -1 +1 @@
-Subproject commit 21b8e8d9d380bef6c39b6b06fc9563d3fedf2ab6
+Subproject commit 6fe83fe9c0bfdf8bcee6e2528e4420fabd582b8b
diff --git a/src/shared/components/common/totp-modal.tsx b/src/shared/components/common/totp-modal.tsx
index b07b4b86..8a9eabc3 100644
--- a/src/shared/components/common/totp-modal.tsx
+++ b/src/shared/components/common/totp-modal.tsx
@@ -21,12 +21,15 @@ interface TotpModalProps {
interface TotpModalState {
totp: string;
qrCode?: string;
+ pending: boolean;
}
const TOTP_LENGTH = 6;
async function handleSubmit(i: TotpModal, totp: string) {
+ i.setState({ pending: true });
const successful = await i.props.onSubmit(totp);
+ i.setState({ pending: false });
if (!successful) {
i.setState({ totp: "" });
@@ -74,6 +77,7 @@ export default class TotpModal extends Component<
modal: Modal;
state: TotpModalState = {
totp: "",
+ pending: false,
};
constructor(props: TotpModalProps, context: any) {
@@ -131,7 +135,7 @@ export default class TotpModal extends Component<
render() {
const { type, secretUrl, onClose } = this.props;
- const { totp } = this.state;
+ const { totp, pending } = this.state;
return (