Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
devchenyan committed Dec 24, 2023
1 parent 4cd62e0 commit 8d4cd13
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ const DetectDuplicateWalletDialog = ({ onClose }: { onClose: () => void }) => {
}, [wallets])

const handleGroupChange = useCallback(
value => {
const [extendedKey, id] = value.split('_')
(checked: string | number) => {
const [extendedKey, id] = (checked as string).split('_')
const list: string[] = []
wallets.forEach(item => {
if (item.extendedKey === extendedKey) {
Expand Down Expand Up @@ -98,7 +98,7 @@ const DetectDuplicateWalletDialog = ({ onClose }: { onClose: () => void }) => {
<div className={styles.groupWrap}>
{groups.map(group => (
<RadioGroup
inputIdPrefix="detect-dupliacte-wallet"
inputIdPrefix="detect-duplicate-wallet"
key={group[0].extendedKey}
defaultValue=""
onChange={handleGroupChange}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,8 +71,8 @@ const ReplaceDuplicateWalletDialog = ({
const group = useMemo(() => wallets.filter(item => item.extendedKey === extendedKey), [wallets, extendedKey])

const handleGroupChange = useCallback(
value => {
setSelectedId(value)
(checked: string | number) => {
setSelectedId(checked as string)
},
[setSelectedId]
)
Expand Down Expand Up @@ -107,7 +107,7 @@ const ReplaceDuplicateWalletDialog = ({
<p className={styles.detail}>{t('settings.wallet-manager.importing-existing.detail')}</p>
<div className={styles.groupWrap}>
<RadioGroup
inputIdPrefix="replace-dupliacte-wallet"
inputIdPrefix="replace-duplicate-wallet"
defaultValue=""
onChange={handleGroupChange}
itemClassName={styles.radioItem}
Expand Down
4 changes: 2 additions & 2 deletions packages/neuron-ui/src/components/WalletSetting/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ const WalletSetting = ({
const [notice, setNotice] = useState('')
const [showDetectDialog, setShowDetectDialog] = useState(false)

const hasDupliacteWallets = useMemo(() => {
const hasDuplicateWallets = useMemo(() => {
const extendedKeys = wallets.map(item => item.extendedKey)
const extendedKeySet = new Set(extendedKeys)
return extendedKeys.length > extendedKeySet.size
Expand Down Expand Up @@ -192,7 +192,7 @@ const WalletSetting = ({
</button>
</Tooltip>

{hasDupliacteWallets ? (
{hasDuplicateWallets ? (
<button type="button" className={styles.actionBtn} onClick={handleDetect}>
<Detect /> {t('wizard.detect-duplicate-wallets')}
</button>
Expand Down

1 comment on commit 8d4cd13

@github-actions
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Packaging for test is done in 7312039838

Please sign in to comment.