Skip to content

Commit

Permalink
feat(tokens): create tokens.js file to show pretty names or hide from…
Browse files Browse the repository at this point in the history
… suggestions
  • Loading branch information
shrpne committed Oct 21, 2022
1 parent 0d9131e commit 3d6a07f
Show file tree
Hide file tree
Showing 7 changed files with 28 additions and 5 deletions.
2 changes: 1 addition & 1 deletion components/Action.vue
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { waitUntil } from 'async-wait-until';
import getTitle from '~/assets/get-title.js';
import hashColor from '~/assets/hash-color.js';
import {isCoinId as isId} from 'minter-js-sdk/src/utils.js';
import {flatCardList} from '~/content/card-list.js';
import {flatCardList} from '~/data/cards.js';
import {translateCardField} from '~/components/Card.vue';
import HubBuyForm from '~/components/HubBuyForm.vue';
import Swap from '~/components/Swap.vue';
Expand Down
2 changes: 1 addition & 1 deletion components/InvestmentList.vue
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<script>
import {getAddressLockList, getPremiumLevel} from '~/api/staking.js';
import {fillCardWithCoin, flatCardList} from '~/content/card-list.js';
import {fillCardWithCoin, flatCardList} from '~/data/cards.js';
import {getErrorText} from '~/assets/server-error.js';
import {PREMIUM_STAKE_PROGRAM_ID} from '~/assets/variables.js';
import {pretty} from '~/assets/utils.js';
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion content/card-list.js → data/cards.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import cardList from '~/content/card-list-data.js';
import cardList from '~/data/cards-raw.js';

/**
* Fill omitted card properties (title, icon, tags) with data from 'coin' property
Expand Down
23 changes: 23 additions & 0 deletions data/tokens.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
export default {
USDCE: {
name: 'USDC',
network: 'ETH',
},
USDCBSC: {
name: 'USDC',
network: 'BSC',
},
PAXE: {
// optional if hide: true
name: 'PAX',
network: 'ETH',
// hide from list
hide: true,
},
TUSD: {
hide: true,
},
HUSD: {
hide: true,
},
};
2 changes: 1 addition & 1 deletion pages/index.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<script>
import cardList from '~/content/card-list.js';
import cardList from '~/data/cards.js';
import Card from '~/components/Card.vue';
import AddressAssets from '~/components/AddressAssets.vue';
import InvestmentList from '~/components/InvestmentList.vue';
Expand Down
2 changes: 1 addition & 1 deletion pages/onboarding/index.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<script>
import {flatCardList} from '~/content/card-list.js';
import {flatCardList} from '~/data/cards.js';
import {pretty} from '~/assets/utils.js';
import {BASE_COIN} from '~/assets/variables.js';
import {clearActionQuery} from '~/components/Action.vue';
Expand Down

0 comments on commit 3d6a07f

Please sign in to comment.