From 4e11051d9fccdbdd40abaa630afc130eafef6602 Mon Sep 17 00:00:00 2001 From: Sebastian Date: Tue, 10 Oct 2023 07:12:20 -0300 Subject: removing url from login --- .../merchant-backoffice-ui/src/Application.tsx | 32 +++++++--------------- 1 file changed, 10 insertions(+), 22 deletions(-) (limited to 'packages/merchant-backoffice-ui/src/Application.tsx') diff --git a/packages/merchant-backoffice-ui/src/Application.tsx b/packages/merchant-backoffice-ui/src/Application.tsx index c871b1633..82329974f 100644 --- a/packages/merchant-backoffice-ui/src/Application.tsx +++ b/packages/merchant-backoffice-ui/src/Application.tsx @@ -26,7 +26,6 @@ import { useTranslationContext, } from "@gnu-taler/web-util/browser"; import { Fragment, VNode, h } from "preact"; -import { route } from "preact-router"; import { useMemo } from "preact/hooks"; import { ApplicationReadyRoutes } from "./ApplicationReadyRoutes.js"; import { Loading } from "./components/exception/loading.js"; @@ -41,8 +40,7 @@ import { import { ConfigContextProvider } from "./context/config.js"; import { useBackendConfig } from "./hooks/backend.js"; import { strings } from "./i18n/strings.js"; -import { ConnectionPage, LoginPage } from "./paths/login/index.js"; -import { LoginToken } from "./declaration.js"; +import { LoginPage } from "./paths/login/index.js"; export function Application(): VNode { return ( @@ -60,7 +58,6 @@ export function Application(): VNode { * @returns */ function ApplicationStatusRoutes(): VNode { - const { changeBackend, selected: backendSelected } = useBackendContext(); const result = useBackendConfig(); const { i18n } = useTranslationContext(); @@ -69,15 +66,6 @@ function ApplicationStatusRoutes(): VNode { : { currency: "unknown", version: "unknown" }; const ctx = useMemo(() => ({ currency, version }), [currency, version]); - if (!backendSelected) { - return ( - - - - - ); - } - if (!result.ok) { if (result.loading) return ; if ( @@ -87,7 +75,13 @@ function ApplicationStatusRoutes(): VNode { return ( - + ); } @@ -100,12 +94,11 @@ function ApplicationStatusRoutes(): VNode { - ); } @@ -119,7 +112,6 @@ function ApplicationStatusRoutes(): VNode { description: i18n.str`Got message "${result.message}" from ${result.info?.url}`, }} /> - ; } if (result.type === ErrorType.UNREADABLE) { @@ -132,7 +124,6 @@ function ApplicationStatusRoutes(): VNode { description: i18n.str`Got message "${result.message}" from ${result.info?.url}`, }} /> - ; } return ( @@ -145,7 +136,6 @@ function ApplicationStatusRoutes(): VNode { description: i18n.str`Got message "${result.message}" from ${result.info?.url}`, }} /> - ); } @@ -164,9 +154,7 @@ function ApplicationStatusRoutes(): VNode { description: i18n.str`Merchant backend server version ${result.data.version} is not compatible with the supported version ${SUPPORTED_VERSION}`, }} /> - - } return ( -- cgit v1.2.3