-
Notifications
You must be signed in to change notification settings - Fork 986
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
Dynamically prioritize video height or width #252
Comments
Hi thanks for trying it out. I would actually consider not using this plugin for what you want to do. You could maybe use regular old CSS `position: fixed` to do what you’re describing. This plugin is for when you want the aspect ratio to be maintained.
Hope that helps. Good luck.
…________________________________
From: Michelle Kirby <[email protected]>
Sent: Saturday, October 7, 2017 5:34:15 PM
To: davatron5000/FitVids.js
Cc: Subscribed
Subject: [davatron5000/FitVids.js] Dynamically prioritize video height or width (#252)
Hello,
This plugin is fantastic. I'm working on an app site with no scrolling and want to fit the video to fill as much of the screen space as possible. Some videos are vertical and are being cut off. Do you have any suggestions on how to approach calculating which is longer and scaling to the maximum without growing taller than the screen?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub<#252>, or mute the thread<https://github.com/notifications/unsubscribe-auth/AACk6ibTW88YYYp0QE160NaE2BJPQPBxks5sp_xngaJpZM4PxhKE>.
|
It does a bit, thanks for the quick response. To clarify a bit, I would like the aspect ratio to be maintained, let me try and better explain what I'm trying to accomplish. I want to be able to put any video, vertical or horizontal, and the video would resize to fill the container in whatever direction without going off the page. So if I have a vertical video, it would resize the video to the fullest length it can be without going off the page in either direction, and then set the width proportionally based on that calculated maximum height. And vise versa if it is a horizontal video. Could I do this with css classes and switch em up depending on the orientation of the video? |
Hello,
This plugin is fantastic. I'm working on an app site with no scrolling and want to fit the video to fill as much of the screen space as possible. Some videos are vertical and are being cut off. Do you have any suggestions on how to approach calculating which is longer and scaling to the maximum without growing taller than the screen?
The text was updated successfully, but these errors were encountered: