question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Parallax doesn't updating after change height block

See original GitHub issue

I have jQuery script which opened and closed block. After opening parallax doesn’t show, I read need use resize trigger but it not help me. There is my code $('.openmore').click(function () { $('.lightdiv').slideToggle(); if ($(this).html() == 'Show more') { $(this).html('Close'); } else { $(this).html('Show more'); } $(window).trigger('resize'); }); Thank. you.

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:5

github_iconTop GitHub Comments

1reaction
meverikxpcommented, Jun 1, 2016

I can answer On my question myself, I write $('.lightdiv').slideToggle(); slideToggle or any other similar function working with some delay so need run $(window).trigger(‘resize’); after this delay. Just need run with setTimeout example is $('.openmore').click(function () { $('.lightdiv').slideToggle(200); if ($(this).html() == 'Show more') { $(this).html('Close'); } else { $(this).html('Show more'); } setTimeout(function(){$(window).trigger('resize');},201) });

0reactions
wstoettingercommented, Oct 10, 2017

seems to be fixed with triggering resize. closing.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Parallax scrolling – decrease height of container to match ...
First I changed the way the event is triggered. Since it is a parallax I made it bound to the wheel event rather...
Read more >
Parallax Mapping (Height Map) not working anymore after ...
Hi there, I am currently facing a weird problem, that occured after updating from the 2020 LTS version of unity to the 2021...
Read more >
JS Animated. How to change the parallax block dimensions
The width and height of the parallax block are defined by the dimensions of the container it is added to. The dimensions can...
Read more >
“Parallax” not working on mobile after update | WordPress.org
Hello. I recently updated my SiteOrigin Builder plugin to the latest and noticed that the “Parallax” that i have for mobile views is...
Read more >
Parallax scrolling in version 7.0 - Squarespace Help Center
Because of this, cropping and focal point changes may not have a noticeable impact on a parallax scrolling image's position. Your site is ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found