-
Notifications
You must be signed in to change notification settings - Fork 711
Proposal for a background-video property #6732
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
This wouldn't be appropriate as a separate property - it implies that you can have both an image and a video on a given background layer, which doesn't seem necessary - but a |
I like it from the standpoint of how using background images allows you to easily make an image responsive. BUT Keep in mind that for video:
|
Yup, but these are all considerations that apply equally to animated gifs or other animated image formats. |
not following why a I guess it depends on how a poster image equivalent for the video is dealt with? |
background-color is not a fallback for background-image, tho - it's a completely separate color displayed in addition to any background images. |
thanks tab, i get it now. The My only other general thought is how many folks are going to feel so odd about writing:
that they would default to just use |
would this fall into [css-images-5] because it's on |
+1 for a |
It would probably be part of css-images-5. Therefore I added the label now. @tabatkins @LeaVerou Feel free to disagree. And just to be clear, Tab's idea means that videos could be used everywhere where an Sebastian |
Has any serious consideration yet been given to adding a CSS
background-video
property?There are already tons of articles explaining how to reposition the
<video>
tag for this. Since folks are doing it anyway seems that CSSbackground-video
could save developers some work. Could also help discourage the use of bloated animated image types for this?Seperation of concerns thinking would go: HTML for content video and CSS for background video. We have html
and css
background-image
why notI vaguely remember something about Safari considering allowing the use of video formats in
background-image
and treating them like animated GIFs by default (muted with auto repeat). But wouldn't there be special consideration for video that would require a separatebackground-video
property (like playback speed, etc)?background-video
likebackground-image
would need to work with (where possible) existingbackground-
properties (-size, -position, etc..).The text was updated successfully, but these errors were encountered: