=> {
await mockSleep(SLEEP_MS);
mockDelegations = mockDelegations.map((d) => {
if (d.mix_id === mix_id) {
@@ -193,7 +181,7 @@ export const MockDelegationContextProvider: FCWithChildren = ({ children }) => {
};
};
- const undelegateVesting = async (_: number, _fee?: FeeDetails) => ({
+ const undelegateVesting = async () => ({
logs_json: '',
data_json: '',
transaction_hash: '',
diff --git a/wallet/src/context/mocks/utils.ts b/wallet/src/context/mocks/utils.ts
index f4b13fff36..ffe1c40d72 100644
--- a/wallet/src/context/mocks/utils.ts
+++ b/wallet/src/context/mocks/utils.ts
@@ -1,3 +1,2 @@
export const mockSleep = (delayMilliseconds: number) =>
- // eslint-disable-next-line no-promise-executor-return
new Promise((resolve) => setTimeout(resolve, delayMilliseconds));
diff --git a/wallet/src/hooks/useCheckOwnership.ts b/wallet/src/hooks/useCheckOwnership.ts
index adb62d915f..81e3d0ff82 100644
--- a/wallet/src/hooks/useCheckOwnership.ts
+++ b/wallet/src/hooks/useCheckOwnership.ts
@@ -22,20 +22,20 @@ export const useCheckOwnership = () => {
try {
const [ownsMixnode, ownsGateway] = await Promise.all([checkMixnodeOwnership(), checkGatewayOwnership()]);
- if (ownsMixnode) {
+ if (ownsMixnode && clientDetails?.client_address) {
status.hasOwnership = true;
status.nodeType = EnumNodeType.mixnode;
status.vestingPledge = await getVestingPledgeInfo({
- address: clientDetails?.client_address!,
+ address: clientDetails.client_address,
type: EnumNodeType.mixnode,
});
}
- if (ownsGateway) {
+ if (ownsGateway && clientDetails?.client_address) {
status.hasOwnership = true;
status.nodeType = EnumNodeType.gateway;
status.vestingPledge = await getVestingPledgeInfo({
- address: clientDetails?.client_address!,
+ address: clientDetails.client_address,
type: EnumNodeType.gateway,
});
}
diff --git a/wallet/src/log.tsx b/wallet/src/log.tsx
index 73ce6925f2..a58d385d25 100644
--- a/wallet/src/log.tsx
+++ b/wallet/src/log.tsx
@@ -4,17 +4,15 @@ import { LogViewer } from './components/LogViewer';
import { ErrorFallback } from './components';
import { NymWalletTheme } from './theme';
-const Log = () => (
-
-
-
-
-
-);
-
const elem = document.getElementById('root-log');
if (elem) {
const root = createRoot(elem);
- root.render();
+ root.render(
+
+
+
+
+ ,
+ );
}
diff --git a/wallet/src/pages/auth/components/password-strength.tsx b/wallet/src/pages/auth/components/password-strength.tsx
index 3845ba9348..a7ae31f219 100644
--- a/wallet/src/pages/auth/components/password-strength.tsx
+++ b/wallet/src/pages/auth/components/password-strength.tsx
@@ -1,5 +1,3 @@
-/* eslint-disable no-nested-ternary */
-
import zxcvbn, { ZXCVBNScore } from 'zxcvbn';
import { LockOutlined } from '@mui/icons-material';
import { LinearProgress, Stack, Typography, Box } from '@mui/material';
diff --git a/wallet/src/pages/auth/pages/existing-account.tsx b/wallet/src/pages/auth/pages/existing-account.tsx
index 09dc98eeab..4f9405c44b 100644
--- a/wallet/src/pages/auth/pages/existing-account.tsx
+++ b/wallet/src/pages/auth/pages/existing-account.tsx
@@ -1,5 +1,3 @@
-/* eslint-disable react/no-unused-prop-types */
-
import { useNavigate } from 'react-router-dom';
import { Box, Button, Stack, Typography } from '@mui/material';
import { SubtitleSlick, Title } from '../components';
diff --git a/wallet/src/pages/auth/pages/forgot-password.tsx b/wallet/src/pages/auth/pages/forgot-password.tsx
index 38f227dd2e..09731d59b0 100644
--- a/wallet/src/pages/auth/pages/forgot-password.tsx
+++ b/wallet/src/pages/auth/pages/forgot-password.tsx
@@ -1,5 +1,3 @@
-/* eslint-disable react/no-unused-prop-types */
-
import { useNavigate } from 'react-router-dom';
import { Button, Stack, Typography } from '@mui/material';
import { Subtitle } from '../components';
diff --git a/wallet/src/pages/bonding/node-settings/apy-playground/index.tsx b/wallet/src/pages/bonding/node-settings/apy-playground/index.tsx
index c95faabb1c..c81826d73f 100644
--- a/wallet/src/pages/bonding/node-settings/apy-playground/index.tsx
+++ b/wallet/src/pages/bonding/node-settings/apy-playground/index.tsx
@@ -76,7 +76,6 @@ export const ApyPlayground = ({ bondedNode }: { bondedNode: TBondedMixnode }) =>
const handleCalculateEstimate = async ({ bond, delegations, uptime, profitMargin, operatorCost }: CalculateArgs) => {
try {
- // eslint-disable-next-line @typescript-eslint/naming-convention
const { estimation, reward_params } = await computeEstimate({
mixId: bondedNode.mixId,
uptime,
diff --git a/wallet/src/pages/delegation/index.tsx b/wallet/src/pages/delegation/index.tsx
index 4e81d53fa5..b66acdda59 100644
--- a/wallet/src/pages/delegation/index.tsx
+++ b/wallet/src/pages/delegation/index.tsx
@@ -120,7 +120,6 @@ export const Delegation: FC<{ isStorybook?: boolean }> = ({ isStorybook }) => {
}
setCurrentDelegationListActionItem(item);
- // eslint-disable-next-line default-case
switch (action) {
case 'delegate':
setShowDelegateMoreModal(true);
diff --git a/wallet/src/pages/node-settings/system-variables.tsx b/wallet/src/pages/node-settings/system-variables.tsx
index b61d0a5e4c..0085007f2f 100644
--- a/wallet/src/pages/node-settings/system-variables.tsx
+++ b/wallet/src/pages/node-settings/system-variables.tsx
@@ -1,4 +1,3 @@
-/* eslint-disable no-nested-ternary */
import { useContext, useState } from 'react';
import { useForm } from 'react-hook-form';
import { Box, Button, Chip, CircularProgress, Grid, LinearProgress, Stack, TextField, Typography } from '@mui/material';
diff --git a/wallet/src/pages/node-settings/useSettingsState.ts b/wallet/src/pages/node-settings/useSettingsState.ts
index 736fabad13..8c09103643 100644
--- a/wallet/src/pages/node-settings/useSettingsState.ts
+++ b/wallet/src/pages/node-settings/useSettingsState.ts
@@ -30,7 +30,6 @@ export const useSettingsState = () => {
const getMixnodeInclusionProbability = async (mixId: number) => {
const probability = await getInclusionProbability(mixId);
if (probability) {
- // eslint-disable-next-line @typescript-eslint/naming-convention
setInclusionProbability({ in_active: probability.in_active, in_reserve: probability.in_reserve });
}
};
diff --git a/wallet/src/theme/mui-theme.d.ts b/wallet/src/theme/mui-theme.d.ts
index e1e98ca7c0..4c91d6c152 100644
--- a/wallet/src/theme/mui-theme.d.ts
+++ b/wallet/src/theme/mui-theme.d.ts
@@ -1,5 +1,3 @@
-/* eslint-disable no-shadow,@typescript-eslint/no-unused-vars,@typescript-eslint/no-empty-interface */
-import { Theme, ThemeOptions, Palette, PaletteOptions } from '@mui/material/styles';
import { PaletteMode } from '@mui/material';
/**
diff --git a/wallet/src/typings/FC.d.ts b/wallet/src/typings/FC.d.ts
index 08ebdfa298..d179e92a79 100644
--- a/wallet/src/typings/FC.d.ts
+++ b/wallet/src/typings/FC.d.ts
@@ -1 +1 @@
-declare type FCWithChildren = React.FC>;
+declare type FCWithChildren = React.FC>;
diff --git a/wallet/src/utils/console.ts b/wallet/src/utils/console.ts
index 6506c76d2a..2c2e4cffa7 100644
--- a/wallet/src/utils/console.ts
+++ b/wallet/src/utils/console.ts
@@ -1,4 +1,3 @@
-/* eslint-disable no-console */
import { config } from '../config';
export const Console = {
diff --git a/wallet/src/utils/fireRequests.ts b/wallet/src/utils/fireRequests.ts
index 23117e13eb..d4c2c49ba4 100644
--- a/wallet/src/utils/fireRequests.ts
+++ b/wallet/src/utils/fireRequests.ts
@@ -1,7 +1,7 @@
import { Console } from 'src/utils/console';
-export type TauriReq Promise)> = {
- name: Req['name'];
+export type TauriReq Promise> = {
+ name: Req extends { name: infer N } ? N : never;
request: () => ReturnType;
onFulfilled: (value: Awaited>) => void;
};
diff --git a/wallet/src/utils/sleep.ts b/wallet/src/utils/sleep.ts
index 4f1d101103..9127886ee1 100644
--- a/wallet/src/utils/sleep.ts
+++ b/wallet/src/utils/sleep.ts
@@ -1,3 +1 @@
-export const sleep = (delayMilliseconds: number) =>
- // eslint-disable-next-line no-promise-executor-return
- new Promise((resolve) => setTimeout(resolve, delayMilliseconds));
+export const sleep = (delayMilliseconds: number) => new Promise((resolve) => setTimeout(resolve, delayMilliseconds));