From 1a8618e27c2e1176dd617582d1769ea0e0c6aad3 Mon Sep 17 00:00:00 2001 From: Tom Beckenham <34339192+tombeckenham@users.noreply.github.com> Date: Thu, 12 Dec 2024 09:50:38 +1100 Subject: [PATCH] Added switchunlock as well Closes #259 --- .vscode/settings.json | 3 ++- src/ui/views/SwitchUnlock/index.tsx | 5 ++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/.vscode/settings.json b/.vscode/settings.json index 16e06291..cd384a8c 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -20,5 +20,6 @@ "javascript.updateImportsOnFileMove.enabled": "always", "typescript.updateImportsOnFileMove.enabled": "always", "eslint.useFlatConfig": true, - "githubPullRequests.overrideDefaultBranch": "dev" + "githubPullRequests.overrideDefaultBranch": "dev", + "githubIssues.issueBranchTitle": "${issueNumber}-${sanitizedIssueTitle}" } diff --git a/src/ui/views/SwitchUnlock/index.tsx b/src/ui/views/SwitchUnlock/index.tsx index 80497e4d..a89e30c6 100644 --- a/src/ui/views/SwitchUnlock/index.tsx +++ b/src/ui/views/SwitchUnlock/index.tsx @@ -35,6 +35,9 @@ const useStyles = makeStyles(() => ({ }, })); +const DEFAULT_PASSWORD = + process.env.NODE_ENV === 'development' ? process.env.DEV_PASSWORD || '' : ''; + const SwitchUnlock = () => { const wallet = useWallet(); const classes = useStyles(); @@ -43,7 +46,7 @@ const SwitchUnlock = () => { // const { t } = useTranslation(); const [showError, setShowError] = useState(false); const [isLoading, setLoading] = useState(false); - const [password, setPassword] = useState(''); + const [password, setPassword] = useState(DEFAULT_PASSWORD); const [resetPop, setResetPop] = useState(false); useEffect(() => {