You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I like the idea of creating a mixin to accomplish this. There is already a ratio percent function in Sparkle, but I think a mixin that accomplishes this would be versatile to fit a custom class.
What would be best for this is if we can pass in ratio percentage, but default to the widescreen 56.25% value. Then the iframe should be customizeable/expandable as well.
For usage this is what I think this is what this should look like:
I’m open to discussing the name of this function. The ratio(4, 3) is in number value, so it can use percentages or calc(), or the ratio() function. The second portion of the mixing '.iframe' would allow for passing in a string of selectors, because we may want iframe and video and some other class value.
We copy/paste this code from project to project, it would be nice to have here! The 56.25% creates the 16:9 aspect ratio.
The text was updated successfully, but these errors were encountered: