Move wallet status
This commit is contained in:
parent
7be94dcfed
commit
e401c6f277
@ -3,12 +3,12 @@ import styles from '@/styles/wallet.module.css'
|
||||
import Plug from '@/svgs/plug.svg'
|
||||
import Gear from '@/svgs/settings-5-fill.svg'
|
||||
import Link from 'next/link'
|
||||
import { Status, isConfigured } from '@/wallets/common'
|
||||
import { isConfigured } from '@/wallets/common'
|
||||
import DraggableIcon from '@/svgs/draggable.svg'
|
||||
import RecvIcon from '@/svgs/arrow-left-down-line.svg'
|
||||
import SendIcon from '@/svgs/arrow-right-up-line.svg'
|
||||
import { useWalletImage } from '@/wallets/image'
|
||||
import { useWalletStatus, statusToClass } from '@/wallets/status'
|
||||
import { useWalletStatus, statusToClass, Status } from '@/wallets/status'
|
||||
import { useWalletSupport } from '@/wallets/support'
|
||||
|
||||
export default function WalletCard ({ wallet, draggable, onDragStart, onDragEnter, onDragEnd, onTouchStart, sourceIndex, targetIndex, index }) {
|
||||
|
@ -1,12 +1,5 @@
|
||||
import walletDefs from '@/wallets/client'
|
||||
|
||||
export const Status = {
|
||||
Enabled: 'Enabled',
|
||||
Disabled: 'Disabled',
|
||||
Error: 'Error',
|
||||
Warning: 'Warning'
|
||||
}
|
||||
|
||||
export function getWalletByName (name) {
|
||||
return walletDefs.find(def => def.name === name)
|
||||
}
|
||||
|
@ -1,7 +1,14 @@
|
||||
import { canReceive, canSend, isConfigured, Status } from '@/wallets/common'
|
||||
import { canReceive, canSend, isConfigured } from '@/wallets/common'
|
||||
import { useWalletLogs } from '@/wallets/logger'
|
||||
import styles from '@/styles/wallet.module.css'
|
||||
|
||||
export const Status = {
|
||||
Enabled: 'Enabled',
|
||||
Disabled: 'Disabled',
|
||||
Error: 'Error',
|
||||
Warning: 'Warning'
|
||||
}
|
||||
|
||||
export function useWalletStatus (wallet) {
|
||||
const { logs } = useWalletLogs(wallet)
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user