Remove link tooltips (#3424)

* Remove link tooltips

* Convert to a title
This commit is contained in:
Jaco Greeff 2020-08-15 16:37:25 +02:00 committed by GitHub
parent bb77207a56
commit 44055cbcde
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -11,7 +11,6 @@ import linked from '@polkadot/apps-config/links';
import { useApi } from '@polkadot/react-hooks';
import { useTranslation } from './translate';
import Tooltip from './Tooltip';
interface Props {
className?: string;
@ -36,27 +35,18 @@ function genLinks (systemChain: string, { data, hash, type, withShort }: Props):
return null;
}
const trigger = `${name}-${type}-${data.toString()}`;
const link = create(extChain, extPath, data, hash);
return (
<a
data-for={trigger}
data-tip
href={link}
href={create(extChain, extPath, data, hash)}
key={name}
rel='noopener noreferrer'
target='_blank'
title={`${name}, ${url}`}
>
{withShort
? shortName(name)
: name
}
<Tooltip
place='top'
text={<>{name}<br />{url}</>}
trigger={trigger}
/>
</a>
);
})