mirror of
https://github.com/wavetermdev/docusaurus-og.git
synced 2026-08-05 13:46:35 -07:00
fix: hero video max-width
This commit is contained in:
@@ -43,7 +43,7 @@
|
|||||||
object-position: top;
|
object-position: top;
|
||||||
|
|
||||||
height: 100%;
|
height: 100%;
|
||||||
max-width: var(--container-max-width);
|
max-width: calc(var(--container-max-width) / var(--hero-video-scale));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -69,6 +69,9 @@
|
|||||||
video {
|
video {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
transform: scale(var(--hero-video-scale-mobile));
|
transform: scale(var(--hero-video-scale-mobile));
|
||||||
|
max-width: calc(
|
||||||
|
var(--container-max-width) / var(--hero-video-scale-mobile)
|
||||||
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -69,9 +69,9 @@ export const HeroVideo: React.FC<HeroVideoProps> = ({
|
|||||||
style={makeStyle(
|
style={makeStyle(
|
||||||
{ ...style },
|
{ ...style },
|
||||||
{
|
{
|
||||||
'hero-video-scale': desktop?.scale ?? '151.5%',
|
'hero-video-scale': desktop?.scale ?? '1.515',
|
||||||
'hero-video-offset-y': desktop?.offsetY ?? '-120px',
|
'hero-video-offset-y': desktop?.offsetY ?? '-120px',
|
||||||
'hero-video-scale-mobile': mobile?.scale ?? '140%',
|
'hero-video-scale-mobile': mobile?.scale ?? '1.40',
|
||||||
'hero-video-offset-y-mobile': mobile?.offsetY ?? '-10%',
|
'hero-video-offset-y-mobile': mobile?.offsetY ?? '-10%',
|
||||||
},
|
},
|
||||||
)}
|
)}
|
||||||
|
|||||||
Reference in New Issue
Block a user