iframes broken on some browsers, show link url

This commit is contained in:
Martti Malmi
2024-02-16 10:44:08 +02:00
parent 86906682f9
commit e5f8bebb53
11 changed files with 104 additions and 60 deletions

View File

@ -53,8 +53,18 @@ const TidalEmbed = ({ link }: { link: string }) => {
</a>
);
}
// eslint-disable-next-line react/no-unknown-property
return <iframe src={source} style={extraStyles} width="100%" title="TIDAL Embed" frameBorder={0} credentialless="" />;
const iframe = (
// eslint-disable-next-line react/no-unknown-property
<iframe src={source} style={extraStyles} width="100%" title="TIDAL Embed" frameBorder={0} credentialless="" />
);
return (
<>
{iframe}
<a href={link} target="_blank" rel="noreferrer" onClick={e => e.stopPropagation()} className="ext">
{link}
</a>
</>
);
};
export default TidalEmbed;