fix: 提交视频
This commit is contained in:
parent
28c72a36fa
commit
4a0d4ff1c9
@ -10,6 +10,7 @@ import { redirect } from 'next/navigation';
|
|||||||
import FooterCopyright from '@/components/main/FooterCopyright';
|
import FooterCopyright from '@/components/main/FooterCopyright';
|
||||||
import FullScreenVideoBackground from '@/components/main/FullScreenVideoBackground';
|
import FullScreenVideoBackground from '@/components/main/FullScreenVideoBackground';
|
||||||
import HomeContent from '@/components/main/HomeContent';
|
import HomeContent from '@/components/main/HomeContent';
|
||||||
|
import Image from 'next/image';
|
||||||
|
|
||||||
export default async function Home() {
|
export default async function Home() {
|
||||||
const Authorization = (await cookies()).get('Authorization')?.value;
|
const Authorization = (await cookies()).get('Authorization')?.value;
|
||||||
@ -38,6 +39,14 @@ export default async function Home() {
|
|||||||
<HomeContent />
|
<HomeContent />
|
||||||
</main>
|
</main>
|
||||||
<FooterCopyright />
|
<FooterCopyright />
|
||||||
|
<Image
|
||||||
|
src={'./logo.png'}
|
||||||
|
height={37}
|
||||||
|
width={28}
|
||||||
|
className={'fixed bottom-8 left-1/2 -translate-x-1/2'}
|
||||||
|
alt='logo'
|
||||||
|
unoptimized
|
||||||
|
></Image>
|
||||||
</>
|
</>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -2,35 +2,21 @@
|
|||||||
|
|
||||||
const FullScreenVideoBackground = ({}: {}) => {
|
const FullScreenVideoBackground = ({}: {}) => {
|
||||||
return (
|
return (
|
||||||
<div
|
<div className='fixed inset-0 h-full w-full overflow-hidden'>
|
||||||
style={{
|
|
||||||
position: 'relative',
|
|
||||||
width: '100vw',
|
|
||||||
height: '100vh',
|
|
||||||
margin: 0,
|
|
||||||
padding: 0,
|
|
||||||
overflow: 'hidden',
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
<video
|
<video
|
||||||
autoPlay
|
autoPlay
|
||||||
muted
|
muted
|
||||||
loop
|
loop
|
||||||
playsInline
|
playsInline
|
||||||
|
className='absolute inset-0 h-full w-full object-cover'
|
||||||
style={{
|
style={{
|
||||||
position: 'fixed',
|
|
||||||
top: '50%',
|
|
||||||
left: '50%',
|
|
||||||
minWidth: '100%',
|
minWidth: '100%',
|
||||||
minHeight: '100%',
|
minHeight: '100%',
|
||||||
width: 'auto',
|
width: 'auto',
|
||||||
height: 'auto',
|
height: 'auto',
|
||||||
transform: 'translate(-50%, -50%)',
|
|
||||||
zIndex: -1,
|
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<source src={'/video.mp4'} type='video/mp4' /> {/* 传入本地视频路径,如 '/video.mp4' */}
|
<source src='/video.mp4' type='video/mp4' />
|
||||||
Your browser does not support the video tag.
|
|
||||||
</video>
|
</video>
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
|
|||||||
BIN
apps/user/public/logo.png
Normal file
BIN
apps/user/public/logo.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.9 KiB |
Loading…
x
Reference in New Issue
Block a user