mirror of
https://github.com/sergeyyarkov/educt-client.git
synced 2026-10-11 10:19:22 +03:00
fix: video lesson layout
This commit is contained in:
parent
d366c05d55
commit
7d9a9f7d19
@ -152,11 +152,17 @@ const LessonPage: React.FC<IPageProps> = () => {
|
|||||||
<Page.Content>
|
<Page.Content>
|
||||||
<Grid templateColumns={{ base: '1fr', xl: '3fr 1fr' }}>
|
<Grid templateColumns={{ base: '1fr', xl: '3fr 1fr' }}>
|
||||||
<GridItem>
|
<GridItem>
|
||||||
<Box>
|
<Box overflowY='hidden'>
|
||||||
{lesson.video ? (
|
{lesson.video ? (
|
||||||
<ReactPlayer width={'100%'} height={'100%'} controls url={constants.BACKEND_URL + lesson.video.url} />
|
<ReactPlayer
|
||||||
|
style={{ backgroundColor: '#000' }}
|
||||||
|
width={'100%'}
|
||||||
|
height={'547px'}
|
||||||
|
controls
|
||||||
|
url={constants.BACKEND_URL + lesson.video.url}
|
||||||
|
/>
|
||||||
) : (
|
) : (
|
||||||
<Flex h='500px' justifyContent={'center'} alignItems={'center'}>
|
<Flex h='547px' justifyContent={'center'} alignItems={'center'}>
|
||||||
<Text color='gray.500' userSelect={'none'}>
|
<Text color='gray.500' userSelect={'none'}>
|
||||||
Video has not been uploaded yet.
|
Video has not been uploaded yet.
|
||||||
</Text>
|
</Text>
|
||||||
@ -192,7 +198,7 @@ const LessonPage: React.FC<IPageProps> = () => {
|
|||||||
</GridItem>
|
</GridItem>
|
||||||
<GridItem minWidth={'250px'}>
|
<GridItem minWidth={'250px'}>
|
||||||
<Box>
|
<Box>
|
||||||
<Stack maxH={'500px'} overflowY={'scroll'} spacing={'0'}>
|
<Stack maxH={'547px'} minH={'547px'} overflowY={'scroll'} spacing={'0'}>
|
||||||
{lessons.map((lesson, i) => (
|
{lessons.map((lesson, i) => (
|
||||||
<LinkBox
|
<LinkBox
|
||||||
ref={lesson.id === id ? currentLessonRef : undefined}
|
ref={lesson.id === id ? currentLessonRef : undefined}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user