Closed apod42 closed 8 years ago
So you want the popup to display with the black background, but the regular page to be scrollable as well?
I don't want any overlay (black background) to be displayed over the page. And yes, the regular page should be scrollable. Any way to do this please?
Do you also want the alert to be movable?
Shane, no, I don't want the alert to be movable. Just to keep centered on page resize, as it does now.
Emil
I'm just trying to fully understand what you're looking for so that I can decide if it's a useful feature to add for everyone, or too specific of a use-case. I could see it being a desired feature to say "Ok, I want a popup that doesn't cover any content. One that people can move around to see what's underneath" (for instance, this could contain an editable field and maybe you need to refer to the page's content to fill it in), but to just have one that sits in the middle over stuff while you scroll sounds too specific for most people to want..so instead of making that a feature of the plugin, I'll just tell you how to do it for your implementation. One moment.
Comment out line 280 of jAlert-v3.js //$('body').css('overflow', 'hidden');
That might be all you need to do. I can't test right now, but let me know if that works. Since you didn't ask about the background, I'm assuming you already removed that on your own?
Thank you, works great! Now I just need to get rid of the background, please do tell :)
2 Options:
1: Comment out line 131 of jAlert //backgroundClasses.push('jawrap'+thisAlert.options.backgroundColor);
2: Pass a bunk background color like pink $.jAlert({ 'title':'Hi', 'content':'Sup?', 'backgroundColor':'pink' });
Scrap that. The second one won't work because it validates the background color. You'd have to also add it to the backgroundColors array.
Just comment out line 131 of jAlert.js. lol.
Thank you! Great success :)
No problem :)
Hello! When an alert pops-up, the vertical scrollbar is hidden and page body is no longer scrollable. Any way to prevent this behaviour? In the plugin options have found nothing related... Thank you!