gnunet-svn
[Top][All Lists]
Advanced

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

[taler-merchant-backoffice] branch master updated: edit strings


From: gnunet
Subject: [taler-merchant-backoffice] branch master updated: edit strings
Date: Wed, 09 Jun 2021 16:50:19 +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 352e23d  edit strings
352e23d is described below

commit 352e23dbbc9a83b522964f3ba7fb06295d38c835
Author: Christian Grothoff <christian@grothoff.org>
AuthorDate: Wed Jun 9 16:50:17 2021 +0200

    edit strings
---
 packages/frontend/src/InstanceRoutes.tsx           | 17 ++++++++---------
 .../frontend/src/paths/admin/create/CreatePage.tsx | 22 +++++++++++-----------
 packages/frontend/src/paths/admin/create/index.tsx |  5 ++---
 .../paths/instance/orders/create/CreatePage.tsx    |  4 ++--
 .../orders/create/InventoryProductForm.tsx         |  8 ++++----
 .../src/paths/instance/orders/list/Table.tsx       |  3 +--
 .../src/paths/instance/orders/list/index.tsx       |  6 +++---
 7 files changed, 31 insertions(+), 34 deletions(-)

diff --git a/packages/frontend/src/InstanceRoutes.tsx 
b/packages/frontend/src/InstanceRoutes.tsx
index a7e4227..5c04275 100644
--- a/packages/frontend/src/InstanceRoutes.tsx
+++ b/packages/frontend/src/InstanceRoutes.tsx
@@ -112,8 +112,8 @@ export function InstanceRoutes({ id, admin }: Props): VNode 
{
 
   const ServerErrorRedirectTo = (to: InstancePaths | AdminPaths) => (error: 
HttpError) => {
     setGlobalNotification({
-      message: i18n`HTTP status #${error.status}: Server reported a problem`,
-      description: i18n`Got message: "${error.message}" from: 
${error.info?.url}`,
+      message: i18n`The backend reported a problem: HTTP status 
#${error.status}`,
+      description: i18n`Diagnostic from ${error.info?.url} is 
"${error.message}"`,
       type: 'ERROR',
       to
     })
@@ -121,7 +121,7 @@ export function InstanceRoutes({ id, admin }: Props): VNode 
{
   }
 
   const LoginPageAccessDenied = () => <Fragment>
-    <NotificationCard notification={{ message: i18n`Access denied`, 
description: i18n`Check your token is valid`, type: 'ERROR', }} />
+    <NotificationCard notification={{ message: i18n`Access denied`, 
description: i18n`The access token provided is invalid.`, type: 'ERROR', }} />
     <LoginPage onConfirm={updateLoginStatus} />
   </Fragment>
 
@@ -130,8 +130,8 @@ export function InstanceRoutes({ id, admin }: Props): VNode 
{
       if (admin && id === 'default') {
         return <Fragment>
           <NotificationCard notification={{
-            message: i18n`No default instance`,
-            description: i18n`in order to use merchant backoffice, you should 
create the default instance`,
+            message: i18n`No 'default' instance configured yet.`,
+            description: i18n`Create a 'default' instance to begin using the 
merchant backoffice.`,
             type: 'INFO'
           }} />
           <InstanceCreatePage forceId="default" onConfirm={() => {
@@ -314,8 +314,8 @@ function AdminInstanceUpdatePage({ id, ...rest }: { id: 
string } & InstanceUpdat
       onLoadError={(error: HttpError) => {
         return <Fragment>
           <NotificationCard notification={{
-            message: i18n`Server reported a problem: HTTP status 
#${error.status}`,
-            description: i18n`Got message: ${error.message} from: 
${error.info?.url}`,
+            message: i18n`The backend reported a problem: HTTP status 
#${error.status}`,
+            description: i18n`Diagnostic from ${error.info?.url} is 
"${error.message}"`,
             type: 'ERROR'
           }} />
           <LoginPage onConfirm={updateLoginStatus} />
@@ -326,7 +326,7 @@ function AdminInstanceUpdatePage({ id, ...rest }: { id: 
string } & InstanceUpdat
         return <Fragment>
           <NotificationCard notification={{
             message: i18n`Access denied`,
-            description: i18n`Check your token is valid`,
+            description: i18n`The access token provided is invalid`,
             type: 'ERROR',
           }} />
           <LoginPage onConfirm={updateLoginStatus} />
@@ -336,4 +336,3 @@ function AdminInstanceUpdatePage({ id, ...rest }: { id: 
string } & InstanceUpdat
     />
   </InstanceContextProvider>
 }
-
diff --git a/packages/frontend/src/paths/admin/create/CreatePage.tsx 
b/packages/frontend/src/paths/admin/create/CreatePage.tsx
index e1803c6..488d137 100644
--- a/packages/frontend/src/paths/admin/create/CreatePage.tsx
+++ b/packages/frontend/src/paths/admin/create/CreatePage.tsx
@@ -79,7 +79,7 @@ export function CreatePage({ onCreate, onBack, forceId }: 
Props): VNode {
     return onCreate(schema.cast(value) as Entity);
   }
   const backend = useBackendContext()
-  
+
   function updateToken(token: string | null) {
     valueHandler(old => ({ ...old, auth_token: token === null ? undefined : 
token }))
   }
@@ -114,29 +114,29 @@ export function CreatePage({ onCreate, onBack, forceId }: 
Props): VNode {
         <div class="column is-two-thirds">
           <FormProvider<Entity> errors={errors} object={value} 
valueHandler={valueHandler} >
 
-            <InputWithAddon<Entity> name="id" label={i18n`ID`} 
addonBefore={`${backend.url}/private/instances/`} readonly={!!forceId} 
tooltip={i18n`display name identification`} />
+            <InputWithAddon<Entity> name="id" label={i18n`Identifier`} 
addonBefore={`${backend.url}/private/instances/`} readonly={!!forceId} 
tooltip={i18n`Name of the instance in URLs. The 'default' instance is special 
in that it is used to administer other instances.`} />
 
-            <Input<Entity> name="name" label={i18n`Name`} 
tooltip={i18n`descriptive name`} />
+            <Input<Entity> name="name" label={i18n`Business name`} 
tooltip={i18n`Legal name of the business represented by this instance.`} />
 
-            <InputPayto<Entity> name="payto_uris" label={i18n`Account 
address`} help="x-taler-bank/bank.taler:5882/blogger" tooltip={i18n`where the 
money will be sent`} />
+            <InputPayto<Entity> name="payto_uris" label={i18n`Bank account 
URI`} help="x-taler-bank/bank.taler:5882/blogger" tooltip={i18n`URI specifying 
bank account for crediting revenue.`} />
 
-            <InputCurrency<Entity> name="default_max_deposit_fee" 
label={i18n`Default max deposit fee`} tooltip={i18n`max deposit fee when an 
order has not overridden it`} />
+            <InputCurrency<Entity> name="default_max_deposit_fee" 
label={i18n`Default max deposit fee`} tooltip={i18n`Maximum deposit fees this 
merchant is willing to pay per order by default.`} />
 
-            <InputCurrency<Entity> name="default_max_wire_fee" 
label={i18n`Default max wire fee`} tooltip={i18n`max wire fee when the order 
has not overridden it`} />
+            <InputCurrency<Entity> name="default_max_wire_fee" 
label={i18n`Default max wire fee`} tooltip={i18n`Maximum wire fees this 
merchant is willing to pay per wire transfer by default.`} />
 
-            <Input<Entity> name="default_wire_fee_amortization" 
label={i18n`Default wire fee amortization`} tooltip={i18n`max wire fee 
amortization when the order has not overridden it`} />
+            <Input<Entity> name="default_wire_fee_amortization" 
label={i18n`Default wire fee amortization`} tooltip={i18n`Number of orders 
excess wire transfer fees will be divided by to compute per order surcharge.`} 
/>
 
-            <InputGroup name="address" label={i18n`Address`} 
tooltip={i18n`physical location of merchant`}>
+            <InputGroup name="address" label={i18n`Address`} 
tooltip={i18n`Physical location of the merchant.`}>
               <InputLocation name="address" />
             </InputGroup>
 
-            <InputGroup name="jurisdiction" label={i18n`Jurisdiction`} 
tooltip={i18n`legal location of merchant`}>
+            <InputGroup name="jurisdiction" label={i18n`Jurisdiction`} 
tooltip={i18n`Jurisdiction for legal disputes with the merchant.`}>
               <InputLocation name="jurisdiction" />
             </InputGroup>
 
-            <InputDuration<Entity> name="default_pay_delay" 
label={i18n`Default payment delay`} tooltip={i18n`max time to pay if the order 
does not override it`} />
+            <InputDuration<Entity> name="default_pay_delay" 
label={i18n`Default payment delay`} tooltip={i18n`Time customers have to pay an 
order before the offer expires by default.`} />
 
-            <InputDuration<Entity> name="default_wire_transfer_delay" 
label={i18n`Default wire transfer delay`} tooltip={i18n`min time to wait the 
transfer if the merchant does not override it`} />
+            <InputDuration<Entity> name="default_wire_transfer_delay" 
label={i18n`Default wire transfer delay`} tooltip={i18n`Maximum time an 
exchange is allowed to delay wiring funds to the merchant, enabling it to 
aggregate smaller payments into larger wire transfers and reducing wire fees.`} 
/>
 
           </FormProvider>
 
diff --git a/packages/frontend/src/paths/admin/create/index.tsx 
b/packages/frontend/src/paths/admin/create/index.tsx
index 8789b45..e240bb6 100644
--- a/packages/frontend/src/paths/admin/create/index.tsx
+++ b/packages/frontend/src/paths/admin/create/index.tsx
@@ -55,13 +55,12 @@ export default function Create({ onBack, onConfirm, forceId 
}: Props): VNode {
           setCreatedOk(d)
         }).catch((error) => {
           setNotif({
-            message: i18n`could not create instance`,
+            message: i18n`Failed to create instance`,
             type: "ERROR",
             description: error.message
           })
         })
       }} />
   </Fragment>
-  
-}
 
+}
diff --git a/packages/frontend/src/paths/instance/orders/create/CreatePage.tsx 
b/packages/frontend/src/paths/instance/orders/create/CreatePage.tsx
index ef25500..1b47564 100644
--- a/packages/frontend/src/paths/instance/orders/create/CreatePage.tsx
+++ b/packages/frontend/src/paths/instance/orders/create/CreatePage.tsx
@@ -235,7 +235,7 @@ export function CreatePage({ onCreate, onBack }: Props): 
VNode {
               in {inventoryList.reduce((prev, cur) => cur.quantity + prev, 0)} 
units,
               with a total price of {totalPriceInventory}
             </p>
-          } tooltip={i18n`add products to the order that already exist in the 
inventory`}>
+          } tooltip={i18n`Add products from managed inventory to the order.`}>
             <InventoryProductForm
               currentProducts={value.inventoryProducts || {}}
               onAddProduct={addProductToTheInventoryList}
@@ -256,7 +256,7 @@ export function CreatePage({ onCreate, onBack }: Props): 
VNode {
               in {productList.reduce((prev, cur) => cur.quantity + prev, 0)} 
units,
               with a total price of {totalPriceProducts}
             </p>
-          } tooltip={i18n`add products to the order`}>
+          } tooltip={i18n`Add products without inventory management to the 
order.`}>
             <NonInventoryProductFrom value={editingProduct} onAddProduct={(p) 
=> {
               setEditingProduct(undefined)
               return addNewProduct(p)
diff --git 
a/packages/frontend/src/paths/instance/orders/create/InventoryProductForm.tsx 
b/packages/frontend/src/paths/instance/orders/create/InventoryProductForm.tsx
index 5bb69f1..6cf48f8 100644
--- 
a/packages/frontend/src/paths/instance/orders/create/InventoryProductForm.tsx
+++ 
b/packages/frontend/src/paths/instance/orders/create/InventoryProductForm.tsx
@@ -41,27 +41,27 @@ export function InventoryProductForm({ currentProducts, 
onAddProduct }: Props):
 
   const submit = (): void => {
     if (!state.product) {
-      setErrors({ product: i18n`select a product first` });
+      setErrors({ product: i18n`You must enter a valid product identifier.` });
       return;
     }
     if (state.product.total_stock === -1) {
       onAddProduct(state.product, 1)
     } else {
       if (!state.quantity || state.quantity <= 0) {
-        setErrors({ quantity: i18n`should be greater than 0` });
+        setErrors({ quantity: i18n`Quantity must be greater than 0!` });
         return;
       }
       const currentStock = state.product.total_stock - 
state.product.total_lost - state.product.total_sold
       const p = currentProducts[state.product.id]
       if (p) {
         if (state.quantity + p.quantity > currentStock) {
-          setErrors({ quantity: i18n`cannot be greater than current stock and 
quantity previously added. max: ${currentStock - p.quantity}` });
+          setErrors({ quantity: i18n`This quantity exceeds remaining stock. 
The current maximum value is ${currentStock - p.quantity}.` });
           return;
         }
         onAddProduct(state.product, state.quantity + p.quantity)
       } else {
         if (state.quantity > currentStock) {
-          setErrors({ quantity: i18n`cannot be greater than current stock 
${currentStock}` });
+          setErrors({ quantity: i18n`This quantity exceeds remaining stock. 
The current maximum value is ${currentStock}.` });
           return;
         }
         onAddProduct(state.product, state.quantity)
diff --git a/packages/frontend/src/paths/instance/orders/list/Table.tsx 
b/packages/frontend/src/paths/instance/orders/list/Table.tsx
index fb97346..4057ca2 100644
--- a/packages/frontend/src/paths/instance/orders/list/Table.tsx
+++ b/packages/frontend/src/paths/instance/orders/list/Table.tsx
@@ -151,7 +151,7 @@ function EmptyTable(): VNode {
     <p>
       <span class="icon is-large"><i class="mdi mdi-emoticon-sad mdi-48px" 
/></span>
     </p>
-    <p><Translate>No orders has been found</Translate></p>
+    <p><Translate>No orders have been found matching your 
query!</Translate></p>
   </div>
 }
 
@@ -229,4 +229,3 @@ export function RefundModal({ id, onCancel, onConfirm }: 
RefundModalProps): VNod
 
   </ConfirmModal>
 }
-
diff --git a/packages/frontend/src/paths/instance/orders/list/index.tsx 
b/packages/frontend/src/paths/instance/orders/list/index.tsx
index 60d9428..c85db0b 100644
--- a/packages/frontend/src/paths/instance/orders/list/index.tsx
+++ b/packages/frontend/src/paths/instance/orders/list/index.tsx
@@ -66,7 +66,7 @@ export default function ({ onUnauthorized, onLoadError, 
onCreate, onSelect, onNo
 
   async function testIfOrderExistAndSelect() {
     if (!orderId) {
-      setErrorOrderId('place an order id here')
+      setErrorOrderId('Enter an order id')
       return;
     }
     try {
@@ -88,7 +88,7 @@ export default function ({ onUnauthorized, onLoadError, 
onCreate, onSelect, onNo
         <div class="level-item">
           <div class="field has-addons">
             <div class="control">
-              <input class={errorOrderId ? "input is-danger" : "input"} 
type="text" value={orderId} onChange={e => setOrderId(e.currentTarget.value)} 
placeholder={i18n`go to order id`} />
+              <input class={errorOrderId ? "input is-danger" : "input"} 
type="text" value={orderId} onChange={e => setOrderId(e.currentTarget.value)} 
placeholder={i18n`order id`} />
               {errorOrderId && <p class="help is-danger">{errorOrderId}</p>}
             </div>
             <div class="control">
@@ -120,7 +120,7 @@ export default function ({ onUnauthorized, onLoadError, 
onCreate, onSelect, onNo
               </a>
             </div>}
             <div class="control">
-              <input class="input" type="text" readonly value={!filter.date ? 
'' : format(filter.date, 'yyyy/MM/dd')} placeholder={i18n`pick a date`} />
+              <input class="input" type="text" readonly value={!filter.date ? 
'' : format(filter.date, 'yyyy/MM/dd')} placeholder={i18n`date (YYYY/MM/DD)`} />
             </div>
             <div class="control">
               <a class="button" onClick={() => { setPickDate(true) }}>

-- 
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]