import {CurrencyPair} from "./types";
// import * as Icon from 'react-cryptocoins'
import {Btc, Eth, Xmr} from 'react-cryptocoins';
export function symbolToPair(symbol: string): CurrencyPair {
const symbol_regex = "t(?[a-zA-Z]{3})(?[a-zA-Z]{3})"
const match = symbol.match(symbol_regex)
return {
base: match.groups.base,
quote: match.groups.quote
}
}
export type SymbolAccesory = {
name: string,
icon: React.Component,
color: string
}
export const SymbolAccessories: Array = [
{
name: "BTC",
icon: Btc,
color: "yellow"
},
{
name: "XMR",
icon: Xmr,
color: "yellow"
},
{
name: "ETH",
icon: Eth,
color: "yellow"
}
];