diff --git a/.github/workflows/electron.yml b/.github/workflows/electron.yml index 5061cf35..d9f73cd9 100644 --- a/.github/workflows/electron.yml +++ b/.github/workflows/electron.yml @@ -11,7 +11,7 @@ jobs: strategy: matrix: - os: [ubuntu-18.04, macos-latest, windows-latest] + os: [ubuntu-20.04, macos-latest, windows-latest] steps: - name: Context @@ -21,10 +21,10 @@ jobs: - uses: actions/checkout@v1 with: fetch-depth: 1 - - name: Use Node.js 14.x + - name: Use Node.js 16.x uses: actions/setup-node@v1 with: - node-version: 14.x + node-version: 16.x - name: yarn install run: | yarn install @@ -42,7 +42,7 @@ jobs: if: contains(matrix.os, 'macos') uses: apple-actions/import-codesign-certs@v1 with: - p12-filepath: 'cert.p12' + p12-filepath: "cert.p12" p12-password: ${{ secrets.p12certpassword }} - name: Build and Package@Mac if: contains(matrix.os, 'macos') diff --git a/src/components/Sidebar.tsx b/src/components/Sidebar.tsx index 264c7737..fe33bbbd 100644 --- a/src/components/Sidebar.tsx +++ b/src/components/Sidebar.tsx @@ -16,7 +16,11 @@ type ExportPrivKeyModalProps = { exportedPrivKeys: string[] | null; closeModal: () => void; }; -const ExportPrivKeyModal = ({ modalIsOpen, exportedPrivKeys, closeModal }: ExportPrivKeyModalProps) => { +const ExportPrivKeyModal = ({ + modalIsOpen, + exportedPrivKeys, + closeModal, +}: ExportPrivKeyModalProps) => { return (
-
+
Your Wallet Private Keys
- These are all the private keys in your wallet. Please store them carefully! + These are all the private keys in your wallet. Please store them + carefully!
{exportedPrivKeys && ( - + )}
-
@@ -69,12 +85,16 @@ const ImportPrivKeyModal = ({ overlayClassName={cstyles.modalOverlay} >
-
+
Import Private Keys
- Please paste your private or viewing keys here (transparent address or shielded address), one line per key. + Please paste your private or viewing keys here (transparent address or + shielded address), one line per key.
@@ -98,7 +118,11 @@ const ImportPrivKeyModal = ({ > Import -
@@ -132,7 +156,10 @@ const PayURIModal = ({ overlayClassName={cstyles.modalOverlay} >
-
+
{modalTitle}
@@ -163,7 +190,11 @@ const PayURIModal = ({ )} -
@@ -176,7 +207,11 @@ type SidebarMenuItemProps = { routeName: string; iconname: string; }; -const SidebarMenuItem = ({ name, routeName, iconname }: SidebarMenuItemProps) => { +const SidebarMenuItem = ({ + name, + routeName, + iconname, +}: SidebarMenuItemProps) => { const activeColorClass = styles.sidebarmenuitemactive; return ( @@ -240,28 +275,37 @@ class Sidebar extends PureComponent { openErrorModal( "Zecwallet Fullnode",
-
Zecwallet Fullnode v1.8.5
-
Built with Electron. Copyright (c) 2018-2021, Aditya Kulkarni.
- The MIT License (MIT) Copyright (c) 2018-2021 Zecwallet + Zecwallet Fullnode v1.8.5 +
+
+ Built with Electron. Copyright (c) 2018-2022, Aditya Kulkarni. +
+
+ The MIT License (MIT) Copyright (c) 2018-2022 Zecwallet

- Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated - documentation files (the "Software"), to deal in the Software without restriction, including - without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the - following conditions: + Permission is hereby granted, free of charge, to any person + obtaining a copy of this software and associated documentation files + (the "Software"), to deal in the Software without + restriction, including without limitation the rights to use, copy, + modify, merge, publish, distribute, sublicense, and/or sell copies + of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions:

- The above copyright notice and this permission notice shall be included in all copies or substantial - portions of the Software. + The above copyright notice and this permission notice shall be + included in all copies or substantial portions of the Software.

- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT - NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN - NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER - IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE - USE OR OTHER DEALINGS IN THE SOFTWARE. + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY + KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE + WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND + NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS + BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN + ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN + CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + SOFTWARE.
); @@ -305,11 +349,16 @@ class Sidebar extends PureComponent { const rows = transactions.flatMap((t) => { if (t.detailedTxns) { return t.detailedTxns.map((dt) => { - const normaldate = dateformat(t.time * 1000, "mmm dd yyyy hh::MM tt"); + const normaldate = dateformat( + t.time * 1000, + "mmm dd yyyy hh::MM tt" + ); // Add a single quote "'" into the memo field to force interpretation as a string, rather than as a // formula from a rogue memo - const escapedMemo = dt.memo ? `'${dt.memo.replace(/"/g, '""')}'` : ""; + const escapedMemo = dt.memo + ? `'${dt.memo.replace(/"/g, '""')}'` + : ""; return `${t.time},"${normaldate}","${t.txid}","${t.type}",${dt.amount},"${dt.address}","${escapedMemo}"`; }); @@ -321,7 +370,10 @@ class Sidebar extends PureComponent { const header = [`UnixTime, Date, Txid, Type, Amount, Address, Memo`]; try { - await window.zecwallet.writeFile(save.filePath, header.concat(rows).join("\n")); + await window.zecwallet.writeFile( + save.filePath, + header.concat(rows).join("\n") + ); } catch (err) { openErrorModal("Error Exporting Transactions", `${err}`); } @@ -403,12 +455,17 @@ class Sidebar extends PureComponent { // eslint-disable-next-line no-control-regex let keys = privKeyInputValue.split(new RegExp("[\n\r]+")); if (!keys || keys.length === 0) { - openErrorModal("No Keys Imported", "No keys were specified, so none were imported"); + openErrorModal( + "No Keys Imported", + "No keys were specified, so none were imported" + ); return; } // Filter out empty lines and clean up the private keys - keys = keys.filter((k) => !(k.trim().startsWith("#") || k.trim().length === 0)); + keys = keys.filter( + (k) => !(k.trim().startsWith("#") || k.trim().length === 0) + ); // Special case. // Sometimes, when importing from a paperwallet or such, the key is split by newlines, and might have @@ -514,22 +571,54 @@ class Sidebar extends PureComponent {
- - - - - + + + + +
{state === "CONNECTED" && ( -
+
  Connected
)} {state === "SYNCING" && ( -
+
  Syncing @@ -538,8 +627,16 @@ class Sidebar extends PureComponent {
)} {state === "DISCONNECTED" && ( -
- +
+   Connected
)}