Fix fetching of gravatar images getting blocked by COEP

This commit is contained in:
Florian Scholdei
2025-09-02 15:19:04 +02:00
committed by René Pfeuffer
parent d5096cf025
commit b0629c20ef
4 changed files with 13 additions and 6 deletions

View File

@@ -0,0 +1,2 @@
- type: fixed
description: Fetching of gravatar images getting blocked by Cross-Origin-Embedder-Policy

View File

@@ -20389,7 +20389,7 @@ exports[`Storyshots Repositories/Changesets Co-Authors with avatar 1`] = `
className="media-left mt-2 mr-2" className="media-left mt-2 mr-2"
> >
<div <div
className="SingleChangeset__FixedSizedAvatar-sc-ytpqp9-0 dLAXC image" className="SingleChangeset__FixedSizedAvatar-sc-ytpqp9-0 gwbxYG image"
> >
<img <img
alt="SCM Administrator" alt="SCM Administrator"
@@ -20448,6 +20448,7 @@ exports[`Storyshots Repositories/Changesets Co-Authors with avatar 1`] = `
<img <img
alt="Ford Prefect" alt="Ford Prefect"
className="ContributorAvatar-sc-1yz8zn-0 lhgGHS" className="ContributorAvatar-sc-1yz8zn-0 lhgGHS"
crossOrigin="anonymous"
src="https://robohash.org/ford.prefect@hitchhiker.com" src="https://robohash.org/ford.prefect@hitchhiker.com"
/> />
</a> </a>
@@ -20458,6 +20459,7 @@ exports[`Storyshots Repositories/Changesets Co-Authors with avatar 1`] = `
<img <img
alt="Zaphod Beeblebrox" alt="Zaphod Beeblebrox"
className="ContributorAvatar-sc-1yz8zn-0 lhgGHS" className="ContributorAvatar-sc-1yz8zn-0 lhgGHS"
crossOrigin="anonymous"
src="https://robohash.org/zaphod.beeblebrox@hitchhiker.cm" src="https://robohash.org/zaphod.beeblebrox@hitchhiker.cm"
/> />
</a> </a>
@@ -20468,6 +20470,7 @@ exports[`Storyshots Repositories/Changesets Co-Authors with avatar 1`] = `
<img <img
alt="Tricia Marie McMillan" alt="Tricia Marie McMillan"
className="ContributorAvatar-sc-1yz8zn-0 lhgGHS" className="ContributorAvatar-sc-1yz8zn-0 lhgGHS"
crossOrigin="anonymous"
src="https://robohash.org/trillian@hitchhiker.cm" src="https://robohash.org/trillian@hitchhiker.cm"
/> />
</a> </a>
@@ -20564,7 +20567,7 @@ exports[`Storyshots Repositories/Changesets Commiter and Co-Authors with avatar
className="media-left mt-2 mr-2" className="media-left mt-2 mr-2"
> >
<div <div
className="SingleChangeset__FixedSizedAvatar-sc-ytpqp9-0 dLAXC image" className="SingleChangeset__FixedSizedAvatar-sc-ytpqp9-0 gwbxYG image"
> >
<img <img
alt="SCM Administrator" alt="SCM Administrator"
@@ -20618,6 +20621,7 @@ exports[`Storyshots Repositories/Changesets Commiter and Co-Authors with avatar
<img <img
alt="Zaphod Beeblebrox" alt="Zaphod Beeblebrox"
className="ContributorAvatar-sc-1yz8zn-0 lhgGHS" className="ContributorAvatar-sc-1yz8zn-0 lhgGHS"
crossOrigin="anonymous"
src="https://robohash.org/zaphod.beeblebrox@hitchhiker.cm" src="https://robohash.org/zaphod.beeblebrox@hitchhiker.cm"
/> />
</a> </a>
@@ -20633,6 +20637,7 @@ exports[`Storyshots Repositories/Changesets Commiter and Co-Authors with avatar
<img <img
alt="Ford Prefect" alt="Ford Prefect"
className="ContributorAvatar-sc-1yz8zn-0 lhgGHS" className="ContributorAvatar-sc-1yz8zn-0 lhgGHS"
crossOrigin="anonymous"
src="https://robohash.org/ford.prefect@hitchhiker.com" src="https://robohash.org/ford.prefect@hitchhiker.com"
/> />
</a> </a>
@@ -21637,7 +21642,7 @@ exports[`Storyshots Repositories/Changesets With avatar 1`] = `
className="media-left mt-2 mr-2" className="media-left mt-2 mr-2"
> >
<div <div
className="SingleChangeset__FixedSizedAvatar-sc-ytpqp9-0 dLAXC image" className="SingleChangeset__FixedSizedAvatar-sc-ytpqp9-0 gwbxYG image"
> >
<img <img
alt="SCM Administrator" alt="SCM Administrator"

View File

@@ -57,11 +57,11 @@ const ContributorWithAvatar: FC<PersonAvatarProps> = ({ person, avatar }) => {
if (person.mail) { if (person.mail) {
return ( return (
<a href={"mailto:" + person.mail} title={t("changeset.contributors.mailto") + " " + person.mail}> <a href={"mailto:" + person.mail} title={t("changeset.contributors.mailto") + " " + person.mail}>
<ContributorAvatar src={avatar} alt={person.name} /> <ContributorAvatar src={avatar} alt={person.name} crossOrigin="anonymous" />
</a> </a>
); );
} }
return <ContributorAvatar src={avatar} alt={person.name} title={person.name} />; return <ContributorAvatar src={avatar} alt={person.name} title={person.name} crossOrigin="anonymous" />;
}; };
export const SingleContributor: FC<PersonProps> = ({ person, className, displayTextOnly }) => { export const SingleContributor: FC<PersonProps> = ({ person, className, displayTextOnly }) => {

View File

@@ -37,7 +37,7 @@ type Props = {
const FixedSizedAvatar = styled.div` const FixedSizedAvatar = styled.div`
width: 35px; width: 35px;
height: 35px; height: 35px;
min-width: fit-content; overflow: hidden;
`; `;
const FullWidthDiv = styled.div` const FullWidthDiv = styled.div`