Skip to content
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

CSS overlap issue with flickr embeds #245

Open
dieseltravis opened this issue Jun 21, 2017 · 4 comments
Open

CSS overlap issue with flickr embeds #245

dieseltravis opened this issue Jun 21, 2017 · 4 comments
Labels
bug Something isn't working

Comments

@dieseltravis
Copy link
Member

See screenshot:

image

Incoming link:
https://mltshp.com/incoming/before/1BQQ8

@spaceninja
Copy link
Member

Looks like our logic that tries to force embedded iframes to 16:9 isn't working for flickr for some reason.

@bradchoate
Copy link

Not all videos are 16:9?

The markup for this Flickr video:

<div class="image-content">
    <div class="the-image">
        <div class="data-wrapper">
            <iframe frameborder="0" allowfullscreen=""
                class="flickr-embed-frame"
                webkitallowfullscreen="" mozallowfullscreen=""
                oallowfullscreen="" msallowfullscreen=""
                width="450" height="800"
                data-natural-width="450" data-natural-height="800"
                style="overflow: hidden; padding: 0px; margin: 0px; width: 450px; height: 800px; max-width: 100%;"
                data-loaded="true"></iframe>
            <script async="" src="https://embedr.flickr.com/assets/client-code.js" charset="utf-8"></script>
        </div>
    </div>
    <div id="image-content-footer-1BQQ6" class="image-content-footer">
        <!-- ... -->
        <div class="clear"> </div>
    </div>
</div>

@onezerodigits
Copy link

A more bulletproof solution might include measuring the embed dimensions, like how fitvids does:
https://github.com/davatron5000/FitVids.js/blob/master/jquery.fitvids.js

Thanks for giving this attention!

@ardgedee
Copy link

ardgedee commented Dec 14, 2017

This should be fixable entirely in CSS, without having to process loading content.

The culprit has two parts. Commenting both of the following assignments fixes the problem on the example page, although a committed fix should be more thorough than this:
in admin.scss:136, .data-wrapper>iframe is assigned absolute position.
in core.scss:8, .data-wrapper is given a padding-top value of 56.25%.

@spaceninja spaceninja transferred this issue from MLTSHP/mltshp Oct 5, 2020
@spaceninja spaceninja added the bug Something isn't working label Oct 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

5 participants