mirror of
https://github.com/RoboSats/robosats.git
synced 2025-01-18 20:21:35 +00:00
parent
534e4c0fee
commit
dd2292f8d0
@ -36,6 +36,12 @@ interface Props {
|
|||||||
const StatsDialog = ({ open = false, onClose, info }: Props): JSX.Element => {
|
const StatsDialog = ({ open = false, onClose, info }: Props): JSX.Element => {
|
||||||
const { t } = useTranslation();
|
const { t } = useTranslation();
|
||||||
|
|
||||||
|
const isOnionAccess = window.location.hostname.endsWith('.onion');
|
||||||
|
|
||||||
|
const ambossURL = isOnionAccess
|
||||||
|
? `http://amboss5jfdzzblty5dr5zaig5twvkgsla6y5xuy6s5c5ogpjfcqgltid.onion/node/${info.node_id}`
|
||||||
|
: `https://amboss.space/node/${info.node_id}`;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Dialog open={open} onClose={onClose}>
|
<Dialog open={open} onClose={onClose}>
|
||||||
<div style={info.loading ? {} : { display: 'none' }}>
|
<div style={info.loading ? {} : { display: 'none' }}>
|
||||||
@ -107,11 +113,7 @@ const StatsDialog = ({ open = false, onClose, info }: Props): JSX.Element => {
|
|||||||
<AmbossIcon />
|
<AmbossIcon />
|
||||||
</ListItemIcon>
|
</ListItemIcon>
|
||||||
<ListItemText secondary={info.node_alias}>
|
<ListItemText secondary={info.node_alias}>
|
||||||
<Link
|
<Link target='_blank' href={ambossURL} rel='noreferrer'>
|
||||||
target='_blank'
|
|
||||||
href={`https://amboss.space/node/${info.node_id}`}
|
|
||||||
rel='noreferrer'
|
|
||||||
>
|
|
||||||
{`${info.node_id.slice(0, 12)}... (AMBOSS)`}
|
{`${info.node_id.slice(0, 12)}... (AMBOSS)`}
|
||||||
</Link>
|
</Link>
|
||||||
</ListItemText>
|
</ListItemText>
|
||||||
|
Loading…
Reference in New Issue
Block a user