aboutsummaryrefslogtreecommitdiffstats
path: root/packages/website/ts/pages/instant
diff options
context:
space:
mode:
authorfragosti <francesco.agosti93@gmail.com>2018-12-04 09:52:35 +0800
committerfragosti <francesco.agosti93@gmail.com>2018-12-04 09:52:35 +0800
commit1498e013d083ed3815f5d5ea2de93a848161ed07 (patch)
treef04122f4e3bfe35a30c61fcee7348f877f714fa8 /packages/website/ts/pages/instant
parentcd44dc7beb1697ec76dccba4711b3ce8057ba6e4 (diff)
downloaddexon-sol-tools-1498e013d083ed3815f5d5ea2de93a848161ed07.tar.gz
dexon-sol-tools-1498e013d083ed3815f5d5ea2de93a848161ed07.tar.zst
dexon-sol-tools-1498e013d083ed3815f5d5ea2de93a848161ed07.zip
feat: update relayer list
Diffstat (limited to 'packages/website/ts/pages/instant')
-rw-r--r--packages/website/ts/pages/instant/config_generator.tsx20
1 files changed, 19 insertions, 1 deletions
diff --git a/packages/website/ts/pages/instant/config_generator.tsx b/packages/website/ts/pages/instant/config_generator.tsx
index 671b1f6df..4e25e3437 100644
--- a/packages/website/ts/pages/instant/config_generator.tsx
+++ b/packages/website/ts/pages/instant/config_generator.tsx
@@ -32,7 +32,11 @@ export interface ConfigGeneratorState {
availableTokens?: ObjectMap<ERC20AssetMetaData>;
}
-const SRA_ENDPOINTS = ['https://api.radarrelay.com/0x/v2/', 'https://api.openrelay.xyz/v2/'];
+const SRA_ENDPOINTS = [
+ 'https://api.radarrelay.com/0x/v2/',
+ 'https://api.sharkrelay.com/sra/v2/',
+ 'https://sra.bamboorelay.com/0x/v2/',
+];
export class ConfigGenerator extends React.Component<ConfigGeneratorProps, ConfigGeneratorState> {
public state: ConfigGeneratorState = {
@@ -212,6 +216,20 @@ export class ConfigGenerator extends React.Component<ConfigGeneratorProps, Confi
</Container>
);
}
+ const availableAssetDatas = _.keys(availableTokens);
+ if (availableAssetDatas.length === 0) {
+ return (
+ <Container
+ className="flex flex-column items-center justify-center"
+ height={multiSelectHeight}
+ backgroundColor={colors.white}
+ borderRadius="4px"
+ width="100%"
+ >
+ <Text fontSize="16px">No tokens available. Try another endpoint?</Text>
+ </Container>
+ );
+ }
const items = _.map(_.keys(availableTokens), assetData => {
const metaData = availableTokens[assetData];
return {