From d439c3e1bc743f2aa47de4457953dba6ecb0e20f Mon Sep 17 00:00:00 2001
From: Sebastian <sebasjm@gmail.com>
Date: Sun, 4 Sep 2022 23:08:45 -0300
Subject: adding version and commit into the setting section

---
 .../taler-wallet-webextension/src/wallet/Settings.tsx    | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

(limited to 'packages/taler-wallet-webextension/src/wallet/Settings.tsx')

diff --git a/packages/taler-wallet-webextension/src/wallet/Settings.tsx b/packages/taler-wallet-webextension/src/wallet/Settings.tsx
index 90e8518ae..1b75ee6c9 100644
--- a/packages/taler-wallet-webextension/src/wallet/Settings.tsx
+++ b/packages/taler-wallet-webextension/src/wallet/Settings.tsx
@@ -19,6 +19,7 @@ import { Fragment, h, VNode } from "preact";
 import { Checkbox } from "../components/Checkbox.js";
 import { ErrorTalerOperation } from "../components/ErrorTalerOperation.js";
 import { JustInDevMode } from "../components/JustInDevMode.js";
+import { Part } from "../components/Part.js";
 import { SelectList } from "../components/SelectList.js";
 import {
   DestructiveText,
@@ -69,6 +70,8 @@ export interface ViewProps {
   toggleDeveloperMode: () => Promise<void>;
   knownExchanges: Array<ExchangeListItem>;
 }
+const VERSION = typeof __VERSION__ !== "undefined" ? __VERSION__ : "dev";
+const GIT_HASH = typeof __GIT_HASH__ !== "undefined" ? __GIT_HASH__ : undefined;
 
 export function SettingsView({
   knownExchanges,
@@ -210,6 +213,19 @@ export function SettingsView({
             />
           </Input>
         </JustInDevMode>
+        <SubTitle>
+          <i18n.Translate>Version</i18n.Translate>
+        </SubTitle>
+        <Part
+          title={<i18n.Translate>Release</i18n.Translate>}
+          text={<span>{VERSION}</span>}
+        />
+        {GIT_HASH && (
+          <Part
+            title={<i18n.Translate>Hash</i18n.Translate>}
+            text={<span>{GIT_HASH}</span>}
+          />
+        )}
       </section>
     </Fragment>
   );
-- 
cgit v1.2.3

