diff options
author | Sebastian <sebasjm@gmail.com> | 2023-09-21 13:54:02 -0300 |
---|---|---|
committer | Sebastian <sebasjm@gmail.com> | 2023-09-25 14:50:41 -0300 |
commit | af623f5096138631383719bf737f5ff21660e052 (patch) | |
tree | 06077e6e938d29381d03a85e4b9cd21b43258d0d /packages/demobank-ui/src/pages/LoginForm.tsx | |
parent | 0b7bbed99d155ba030a1328e357ab6751bdbb835 (diff) | |
download | wallet-core-af623f5096138631383719bf737f5ff21660e052.tar.xz |
preparing for the new token api
Diffstat (limited to 'packages/demobank-ui/src/pages/LoginForm.tsx')
-rw-r--r-- | packages/demobank-ui/src/pages/LoginForm.tsx | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/packages/demobank-ui/src/pages/LoginForm.tsx b/packages/demobank-ui/src/pages/LoginForm.tsx index 46039005a..f6ea0e1d1 100644 --- a/packages/demobank-ui/src/pages/LoginForm.tsx +++ b/packages/demobank-ui/src/pages/LoginForm.tsx @@ -19,11 +19,12 @@ import { ErrorType, notifyError, useTranslationContext } from "@gnu-taler/web-ut import { Fragment, VNode, h } from "preact"; import { useEffect, useRef, useState } from "preact/hooks"; import { useBackendContext } from "../context/backend.js"; -import { useCredentialsChecker } from "../hooks/backend.js"; import { bankUiSettings } from "../settings.js"; import { undefinedIfEmpty } from "../utils.js"; import { USERNAME_REGEX } from "./RegistrationPage.js"; import { ShowInputErrorLabel } from "../components/ShowInputErrorLabel.js"; +import { AccessToken, useCredentialsChecker } from "../hooks/useCredentialsChecker.js"; +import { useCredentialsCheckerOld } from "../hooks/backend.js"; /** * Collect and submit login data. @@ -33,7 +34,9 @@ export function LoginForm({ onRegister }: { onRegister?: () => void }): VNode { const [username, setUsername] = useState<string | undefined>(); const [password, setPassword] = useState<string | undefined>(); const { i18n } = useTranslationContext(); - const testLogin = useCredentialsChecker(); + // const { requestNewLoginToken, refreshLoginToken } = useCredentialsChecker(); + + const testLogin = useCredentialsCheckerOld(); const ref = useRef<HTMLInputElement>(null); useEffect(function focusInput() { ref.current?.focus(); |