Add dnslink entry for Rococo (#3343)
This commit is contained in:
parent
eafba6df38
commit
bb9bdc690a
@ -94,6 +94,7 @@ function createTest (t: TFunction): LinkOption[] {
|
||||
value: 'wss://westend-rpc.polkadot.io'
|
||||
},
|
||||
{
|
||||
dnslink: 'rococo',
|
||||
info: 'rococo',
|
||||
text: t<string>('rpc.rococo', 'Rococo (Polkadot Testnet, hosted by Parity)', { ns: 'apps-config' }),
|
||||
value: 'wss://rococo-rpc.polkadot.io'
|
||||
|
||||
@ -37,10 +37,12 @@ function ChainInfo ({ className = '', isToggled, onClick }: Props): React.ReactE
|
||||
)}
|
||||
<BestNumber label='#' />
|
||||
</div>
|
||||
<Icon
|
||||
className='dropdown'
|
||||
icon={isToggled ? 'caret-right' : 'caret-down'}
|
||||
/>
|
||||
{onClick && (
|
||||
<Icon
|
||||
className='dropdown'
|
||||
icon={isToggled ? 'caret-right' : 'caret-down'}
|
||||
/>
|
||||
)}
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
|
||||
@ -8,6 +8,7 @@ import React, { useCallback, useMemo, useState } from 'react';
|
||||
import styled from 'styled-components';
|
||||
import createRoutes from '@polkadot/apps-routing';
|
||||
import { Button, ChainImg, Icon, Menu, media } from '@polkadot/react-components';
|
||||
import { useIpfs } from '@polkadot/react-hooks';
|
||||
|
||||
import { SIDEBAR_MENU_THRESHOLD } from '../constants';
|
||||
import { useTranslation } from '../translate';
|
||||
@ -31,6 +32,7 @@ const MENU_WIDTH_EXPANDED = '12rem';
|
||||
|
||||
function AppsSidebar ({ className = '', collapse, handleResize, isCollapsed, isMenuOpen, toggleMenu }: Props): React.ReactElement<Props> {
|
||||
const { t } = useTranslation();
|
||||
const { ipnsChain } = useIpfs();
|
||||
const [modals, setModals] = useState<Record<string, boolean>>(
|
||||
createRoutes(t).reduce((result: Record<string, boolean>, route): Record<string, boolean> => {
|
||||
if (route && route.Modal) {
|
||||
@ -87,7 +89,11 @@ function AppsSidebar ({ className = '', collapse, handleResize, isCollapsed, isM
|
||||
<div className='apps--SideBar-Scroll'>
|
||||
<ChainInfo
|
||||
isToggled={modals.network}
|
||||
onClick={_toggleModal('network')}
|
||||
onClick={
|
||||
ipnsChain
|
||||
? undefined
|
||||
: _toggleModal('network')
|
||||
}
|
||||
/>
|
||||
{routing.map((route, index): React.ReactNode => (
|
||||
route
|
||||
|
||||
Loading…
Reference in New Issue
Block a user