Support » Plugin: WP YouTube Lyte » thumbnail does not load if scrolling from bottom to top

  • I have CSS smooth scroll set. So if I click a link to a page from the bottom of the current page, it will load that new page at the bottom and then scroll up to the top. The YouTube is at the top of the page, and it stays grey because perhaps it was out of the viewport and then we are moving from the bottom to top rather than top to the bottom
    At this point it is impossible to get the preview to load up. I have to reload the page

Viewing 2 replies - 1 through 2 (of 2 total)
  • html{
    scroll-behavior:smooth;
    }

    Plugin Author Optimizing Matters

    (@optimizingmatters)

    LYTE does not take viewport into account @funsail, so that’s not it. also scroll-behavior is meant to apply to in-page scrolling, not transitions between different pages.

    Based on your description of the problem I think you might be using some JS-based page loading mechanism, which loads a HTML snippet and injects that in the page in which case the onload even (which LYTE hooks into) would likely not trigger, in which case you’ll have to call ly.te() after the HTML was loaded somehow. You can test that in the browser console by typing ly.te() there and monitor if any error pops up before or after that.

    hope this helps,
    frank

Viewing 2 replies - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.