Skip to content
Snippets Groups Projects
Verified Commit 1a2b06f4 authored by Dorian Koch's avatar Dorian Koch
Browse files

Work around third-party cookie restrictions, closes #41

parent 266843eb
No related branches found
No related tags found
No related merge requests found
Pipeline #6424 failed
...@@ -749,18 +749,28 @@ export function EmbeddedPlayer({ playerData }: { playerData: ResourceType<Player ...@@ -749,18 +749,28 @@ export function EmbeddedPlayer({ playerData }: { playerData: ResourceType<Player
); );
} }
let pageContent = ( if (!perms.is_lecture_authenticated) {
<AuthorizeHelper // Show link to page
lecture={lecture} return (
course={course} <div className="h-100 w-100 d-flex flex-column justify-content-center">
authed_methods={perms.authenticated_methods} <div className="text-center">
/> <img alt="VideoAG" src={`${basePath}/static/logo.png`} width={44} height={44} />
</div>
<div className="alert alert-warning m-2" role="alert">
Dieses Video ist nicht öffentlich verfügbar. Bitte{" "}
<a
href={`https://video.fsmpi.rwth-aachen.de/${course.id_string}/${lecture.id}`}
>
öffnen Sie die Seite
</a>{" "}
um das Video zu sehen.
</div>
</div>
); );
if (perms.is_lecture_authenticated) {
pageContent = <VideoPlayer lecture={lecture} className="h-100" />;
} }
return <>{pageContent} </>; return <VideoPlayer lecture={lecture} className="h-100" />;
} }
export default function Player({ playerData }: { playerData: ResourceType<PlayerData> }) { export default function Player({ playerData }: { playerData: ResourceType<PlayerData> }) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment