Merge pull request #1704 from RafaelTaranto/chore/alchemy-labels-on-infura
LAM-1106 chore: add Alchemy label and remove extra fields
This commit is contained in:
commit
b8b3c374ee
3 changed files with 4 additions and 26 deletions
|
|
@ -31,7 +31,7 @@ const ALL_ACCOUNTS = [
|
||||||
{ code: 'mock-ticker', display: 'Mock (Caution!)', class: TICKER, cryptos: ALL_CRYPTOS, dev: true },
|
{ code: 'mock-ticker', display: 'Mock (Caution!)', class: TICKER, cryptos: ALL_CRYPTOS, dev: true },
|
||||||
{ code: 'bitcoind', display: 'bitcoind', class: WALLET, cryptos: [BTC] },
|
{ code: 'bitcoind', display: 'bitcoind', class: WALLET, cryptos: [BTC] },
|
||||||
{ code: 'no-layer2', display: 'No Layer 2', class: LAYER_2, cryptos: ALL_CRYPTOS },
|
{ code: 'no-layer2', display: 'No Layer 2', class: LAYER_2, cryptos: ALL_CRYPTOS },
|
||||||
{ code: 'infura', display: 'Infura', class: WALLET, cryptos: [ETH, USDT] },
|
{ code: 'infura', display: 'Infura/Alchemy', class: WALLET, cryptos: [ETH, USDT] },
|
||||||
{ code: 'trongrid', display: 'Trongrid', class: WALLET, cryptos: [TRX, USDT_TRON] },
|
{ code: 'trongrid', display: 'Trongrid', class: WALLET, cryptos: [TRX, USDT_TRON] },
|
||||||
{ code: 'geth', display: 'geth (deprecated)', class: WALLET, cryptos: [ETH, USDT] },
|
{ code: 'geth', display: 'geth (deprecated)', class: WALLET, cryptos: [ETH, USDT] },
|
||||||
{ code: 'zcashd', display: 'zcashd', class: WALLET, cryptos: [ZEC] },
|
{ code: 'zcashd', display: 'zcashd', class: WALLET, cryptos: [ZEC] },
|
||||||
|
|
|
||||||
|
|
@ -17,7 +17,6 @@ const SECRET_FIELDS = [
|
||||||
'bitgo.BCHWalletPassphrase',
|
'bitgo.BCHWalletPassphrase',
|
||||||
'bitgo.DASHWalletPassphrase',
|
'bitgo.DASHWalletPassphrase',
|
||||||
'bitstamp.secret',
|
'bitstamp.secret',
|
||||||
'infura.apiSecret',
|
|
||||||
'itbit.clientSecret',
|
'itbit.clientSecret',
|
||||||
'kraken.privateKey',
|
'kraken.privateKey',
|
||||||
'binanceus.privateKey',
|
'binanceus.privateKey',
|
||||||
|
|
|
||||||
|
|
@ -1,27 +1,12 @@
|
||||||
import * as Yup from 'yup'
|
import * as Yup from 'yup'
|
||||||
|
|
||||||
import SecretInputFormik from 'src/components/inputs/formik/SecretInput'
|
|
||||||
import TextInputFormik from 'src/components/inputs/formik/TextInput'
|
import TextInputFormik from 'src/components/inputs/formik/TextInput'
|
||||||
|
|
||||||
import { secretTest } from './helper'
|
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
code: 'infura',
|
code: 'infura',
|
||||||
name: 'Infura',
|
name: 'Infura/Alchemy',
|
||||||
title: 'Infura (Wallet)',
|
title: 'Infura/Alchemy (Wallet)',
|
||||||
elements: [
|
elements: [
|
||||||
{
|
|
||||||
code: 'apiKey',
|
|
||||||
display: 'Project ID',
|
|
||||||
component: TextInputFormik,
|
|
||||||
face: true,
|
|
||||||
long: true
|
|
||||||
},
|
|
||||||
{
|
|
||||||
code: 'apiSecret',
|
|
||||||
display: 'Project Secret',
|
|
||||||
component: SecretInputFormik
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
code: 'endpoint',
|
code: 'endpoint',
|
||||||
display: 'Endpoint',
|
display: 'Endpoint',
|
||||||
|
|
@ -29,14 +14,8 @@ export default {
|
||||||
face: true
|
face: true
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
getValidationSchema: account => {
|
getValidationSchema: () => {
|
||||||
return Yup.object().shape({
|
return Yup.object().shape({
|
||||||
apiKey: Yup.string('The project ID must be a string')
|
|
||||||
.max(100, 'The project ID is too long')
|
|
||||||
.required('The project ID is required'),
|
|
||||||
apiSecret: Yup.string('The project secret must be a string')
|
|
||||||
.max(100, 'The project secret is too long')
|
|
||||||
.test(secretTest(account?.apiSecret, 'project secret')),
|
|
||||||
endpoint: Yup.string('The endpoint must be a string')
|
endpoint: Yup.string('The endpoint must be a string')
|
||||||
.max(100, 'The endpoint is too long')
|
.max(100, 'The endpoint is too long')
|
||||||
.required('The endpoint is required')
|
.required('The endpoint is required')
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue