Web/CSS

[CSS] How to change a height of a video in html css?

brightlightkim 2022. 5. 20. 06:13

HTML:

<video autoplay muted loop id="myVideo">
    <source src="videos/Raindrops.mp4" type="video/MP4">
</video>

CSS:

#myVideo {
    width: 100%;
    height: 600px;
    object-fit: cover;
    z-index: -100;
}

 

'Web > CSS' 카테고리의 다른 글

Tailwind CSS Intro  (0) 2022.12.06
[CSS] Font scaling based on width of container  (0) 2022.06.04
HTML5 Video 7 Tips  (0) 2022.05.20