Add subsquare external links for referenda (#8385)

This commit is contained in:
Yongfeng LI 2022-11-22 01:06:01 +08:00 committed by GitHub
parent feb4936f92
commit bfbb6cdc27
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 1 deletions

View File

@ -35,6 +35,7 @@ export default {
council: 'council/motion',
external: 'democracy/external',
proposal: 'democracy/proposal',
referenda: 'referenda/referendum',
referendum: 'democracy/referendum',
tip: 'treasury/tip',
treasury: 'treasury/proposal'

View File

@ -10,7 +10,7 @@ import type { Referendum, ReferendumProps as Props } from '../types';
import React, { useMemo } from 'react';
import usePreimage, { getPreimageHash } from '@polkadot/app-preimages/usePreimage';
import { CallExpander, Progress } from '@polkadot/react-components';
import { CallExpander, LinkExternal, Progress } from '@polkadot/react-components';
import { useTranslation } from '../translate';
import Deposits from './Deposits';
@ -135,6 +135,12 @@ function Ongoing ({ isMember, members, palletReferenda, palletVote, value: { id,
preimage={preimage}
/>
</td>
<td className='links media--1000'>
<LinkExternal
data={id}
type='referenda'
/>
</td>
</>
);
}