gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[taler-merchant-backoffice] branch master updated: -fix spa


From: gnunet
Subject: [taler-merchant-backoffice] branch master updated: -fix spa
Date: Mon, 26 Sep 2022 22:16:58 +0200

This is an automated email from the git hooks/post-receive script.

grothoff pushed a commit to branch master
in repository merchant-backoffice.

The following commit(s) were added to refs/heads/master by this push:
     new f31b0a4  -fix spa
f31b0a4 is described below

commit f31b0a4b422d8e419cd011ced04b35ced68e5e01
Author: Christian Grothoff <christian@grothoff.org>
AuthorDate: Mon Sep 26 22:16:56 2022 +0200

    -fix spa
---
 packages/bank/src/pages/home/index.tsx | 25 ++++++++++++-------------
 1 file changed, 12 insertions(+), 13 deletions(-)

diff --git a/packages/bank/src/pages/home/index.tsx 
b/packages/bank/src/pages/home/index.tsx
index 90e044f..f74b3b3 100644
--- a/packages/bank/src/pages/home/index.tsx
+++ b/packages/bank/src/pages/home/index.tsx
@@ -12,11 +12,11 @@ import talerLogo from '../../assets/logo-white.svg';
 import { LangSelectorLikePy as LangSelector } from 
'../../components/menu/LangSelector';
 
 // @ts-ignore
-const __LIBEUFIN_UI_ALLOW_REGISTRATIONS__ = 
window.__LIBEUFIN_UI_ALLOW_REGISTRATIONS__ ?? 1;
+const UI_ALLOW_REGISTRATIONS = ('__LIBEUFIN_UI_ALLOW_REGISTRATIONS__') ?? 1;
 // @ts-ignore
-const __LIBEUFIN_UI_IS_DEMO__ = window.__LIBEUFIN_UI_IS_DEMO__ ?? 0;
+const UI_IS_DEMO = ('__LIBEUFIN_UI_IS_DEMO__') ?? 0;
 // @ts-ignore
-const __LIBEUFIN_UI_BANK_NAME__ = window.__LIBEUFIN_UI_BANK_NAME__ ?? 'Taler 
Bank';
+const UI_BANK_NAME = ('__LIBEUFIN_UI_BANK_NAME__') ?? 'Taler Bank';
 
 /**
  * FIXME:
@@ -133,7 +133,7 @@ interface AccountStateType {
  ***********/
 
 function maybeDemoContent(content: VNode) {
-  if (__LIBEUFIN_UI_IS_DEMO__) return content;
+  if (UI_IS_DEMO) return content;
 }
 
 async function fetcher(url: string) {
@@ -865,7 +865,7 @@ function BankFrame(Props: any): VNode {
           <h1>
             <span class="it">
               <a href="/">{
-                 __LIBEUFIN_UI_BANK_NAME__
+                 UI_BANK_NAME
               }
               </a>
             </span>
@@ -1284,7 +1284,7 @@ function TalerWithdrawal(Props: any): VNode {
 function RegistrationButton(Props: any): VNode {
   const { backendStateSetter, pageStateSetter } = Props;
   const i18n = useTranslator();
-  if (__LIBEUFIN_UI_ALLOW_REGISTRATIONS__)
+  if (UI_ALLOW_REGISTRATIONS)
   {
      return (<button
               autofocus
@@ -1360,9 +1360,8 @@ function LoginForm(Props: any): VNode {
           );
           submitDataSetter(undefined);
         }}>{i18n`Login`}
-      </button>)
-      + RegistrationButton(props) +
-    (
+      </button>
+      {RegistrationButton(Props)}
     </div>
   </form>);
 }
@@ -1380,7 +1379,7 @@ function RegistrationForm(Props: any): VNode {
     <Fragment>
       <h1 class="nav">
       {
-        i18n`Welcome to ${__LIBEUFIN_UI_BANK_NAME__}!`
+        i18n`Welcome to ${UI_BANK_NAME}!`
       }
       </h1>
       <aside class="sidebar" id="left" />
@@ -1890,8 +1889,8 @@ export function BankHome(): VNode {
     </SWRWithoutCredentials>);
 
   if (pageState.tryRegister) {
-    console.log('allow registrations?', __LIBEUFIN_UI_ALLOW_REGISTRATIONS__);
-    if (__LIBEUFIN_UI_ALLOW_REGISTRATIONS__)
+    console.log('allow registrations?', UI_ALLOW_REGISTRATIONS);
+    if (UI_ALLOW_REGISTRATIONS)
       return (
         <PageContext.Provider value={[pageState, pageStateSetter]}>
           <BankFrame>
@@ -1936,7 +1935,7 @@ export function BankHome(): VNode {
       <BankFrame>
         <h1 class="nav">
         {
-          i18n`Welcome to ${__LIBEUFIN_UI_BANK_NAME__}!`
+          i18n`Welcome to ${UI_BANK_NAME}!`
         }
         </h1>
         <LoginForm

-- 
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]