• 0

jPopup v2.0.1


Question

http://jpopup.seapip.com/

 

Finally finished with v2.0.0 release of my popup plugin, since there wasn't any proper jQuery plugin for popups that just worked I decided to make my own. Now I've made a complete rewrite which is more advanced then ever before :D

 

The demo button doesn't work yet on the website, thinking of a nice demo at this moment, all the other documentation demos work though.

  • Like 3
Link to comment
https://www.neowin.net/forum/topic/1307752-jpopup-v201/
Share on other sites

13 answers to this question

Recommended Posts

  • 0
3 hours ago, Mur said:

Should change the download link to always pull from the GitHub master branch.

 

https://github.com/seahorsepip/jPopup/archive/master.zip

 

I look forward to seeing the Demo :)

Nah the download link is generated using the github api to always pull the latest release. So it will never show a download link for a work in progress version.

 

I also plan to include sass css in the next update. Also a lightbox plugin is in the works. And a width and height option will be added later.

Link to comment
https://www.neowin.net/forum/topic/1307752-jpopup-v201/#findComment-597571006
Share on other sites

  • 0
On 9/4/2016 at 1:43 PM, Seahorsepip said:

Nah the download link is generated using the github api to always pull the latest release. So it will never show a download link for a work in progress version.

Typically you'd handle that with branches in the Git Repo? I don't really follow how you generated one with the GitHub API either :wacko:

 

For code documentation as well, you might be able to leverage what Slate has to offer

Link to comment
https://www.neowin.net/forum/topic/1307752-jpopup-v201/#findComment-597572294
Share on other sites

  • 0
17 minutes ago, Mur said:

Typically you'd handle that with branches in the Git Repo? I don't really follow how you generated one with the GitHub API either :wacko:

 

For code documentation as well, you might be able to leverage what Slate has to offer

There's a releases option for release versions in github.

And I generate a download button for the latest release by using the json api:

$.get("https://api.github.com/repos/seahorsepip/jPopup/releases/latest", function(data) {
	$("#download").append(data.tag_name); //Add version number to download button string
	$("#download").attr("href", data.zipball_url); //Get url for latest version zip
});

 

Link to comment
https://www.neowin.net/forum/topic/1307752-jpopup-v201/#findComment-597572304
Share on other sites

  • 0
6 hours ago, Seahorsepip said:

There's a releases option for release versions in github.

And I generate a download button for the latest release by using the json api:


$.get("https://api.github.com/repos/seahorsepip/jPopup/releases/latest", function(data) {
	$("#download").append(data.tag_name); //Add version number to download button string
	$("#download").attr("href", data.zipball_url); //Get url for latest version zip
});

 

Fair enough.

Link to comment
https://www.neowin.net/forum/topic/1307752-jpopup-v201/#findComment-597572604
Share on other sites

  • 0
3 hours ago, game_over said:

Demo button doesn't work.

 

[edit] The try it yourself buttons work, but the 'Demo' button doesn't do anything.

 

When a button is clicked the page scrolls back to the top, is this intended?

The demo button is work in progress as stated in the OP. The page scroll up issue is a bug when a popup button is clicked more then once(double click), I've just fixed that and create a bug fix release (v2.0.1) in a moment. Also what browser did you use? I had issues with scroll positions in the past with a few browsers.

 

Edit:

 

Bugs should be fixed in version 2.0.1

Link to comment
https://www.neowin.net/forum/topic/1307752-jpopup-v201/#findComment-597573228
Share on other sites

  • 0
3 hours ago, Seahorsepip said:

The demo button is work in progress as stated in the OP. The page scroll up issue is a bug when a popup button is clicked more then once(double click), I've just fixed that and create a bug fix release (v2.0.1) in a moment. Also what browser did you use? I had issues with scroll positions in the past with a few browsers.

 

Edit:

 

Bugs should be fixed in version 2.0.1

Maybe I should read properly :)

 

I tested it in Safari and Chrome.

Link to comment
https://www.neowin.net/forum/topic/1307752-jpopup-v201/#findComment-597573530
Share on other sites

  • 0
3 hours ago, Mur said:

What was the solution for the scrolling issue in the 1.0 version? You never pushed that update.

The freeze function is the following:

_freeze: function() {
	var top = $(document).scrollTop();
	var left = $(document).scrollLeft();
	if(window.innerWidth > document.documentElement.clientWidth) {
		$("html").css("overflow-y", "scroll");
	}
	$("html").css({"width": "100%", "height": "100%", "position": "fixed", "top": -top, "left": -left});
}

In the past var top was:

var top = $("html").scrollTop();

But sadly some browsers returned 0 instead of the actual scrollTop.

 

So I fixed it by changing it to:

var top = $("html").scrollTop() || $("body").scrollTop();

 

Later on (during v2 development) I changed it to:

var top = $(window).scrollTop();

Since that seems to work on even more devices (Hello IE6).

 

But it seems that didn't work in some browsers on some systems as reported today so in v2.0.1 that's changed yet again to:

var top = $(document).scrollTop();

 

The top variable will be later used in the unfreeze function to set the scrollTop back again and guess what when the top variableis 0 instead of the value it should be... the page jump to the top.

 

 

And yes it's absurd and crazy that such a simple thing reports different values in all browsers lol.

 

Also the IE6+ support plugin even makes sure that the animations work smoothly in IE6 which is kinda absurd too but I thought if I were to add IE support I should at least support all versions :p

 

And excerpt from the IE6+ plugin:

//Insane code for an insane browser
this._vars.fakeScrollbar = $("<div>");
this._vars.fakeScrollbar.html("<div style=\"position:absolute;top:expression(document.documentElement.scrollTop);right:0;bottom:0;margin-left:-200px;width:0;overflow-y:scroll;height:expression(document.documentElement.clientHeight);z-index:9999999;\"></div>");
this._vars.fakeScrollbar = this._vars.fakeScrollbar.children();

It has so much horror in the code, firstly the following didn't work in IE6 so I had to use above sort of 'hack':

this._vars.fakeScrollbar = $("<div style=\"position:absolute;top:expression(document.documentElement.scrollTop);right:0;bottom:0;margin-left:-200px;width:0;overflow-y:scroll;height:expression(document.documentElement.clientHeight);z-index:9999999;\"></div>");

Then secondly, css expressions :cry:...

 

And at last,

Q: why a fake scrollbar in the first place?!

A: The original freeze function doesn't work since IE6 doesn't support position: fixed; so to freeze the page I used the rather simple overflow: hidden; instead. But then it doesn't show the disabled scrollbar and the page content jumps horizontally, so that's fixed by adding padding-right: *scrollbarwidth*; and a fake scrollbar.

 

This way it looks exactly the same to the user in IE6 and the latest chrome release.

Link to comment
https://www.neowin.net/forum/topic/1307752-jpopup-v201/#findComment-597573760
Share on other sites

This topic is now closed to further replies.
  • Posts

    • Microsoft confirms Windows 11 26H2, urges IT admins to prepare for release by Usama Jawad Windows 11 typically follows an annual update cycle, but Microsoft recently broke that tradition a bit by releasing a "26H1" version in the first half of this year as a "scoped" build for select new silicon PCs only. This version was not available for customers using 24H2 and 25H2 builds, as Microsoft is busy preparing version 26H2 for them, confirmed officially for the first time. In a Windows IT Pro blog, Microsoft has urged IT admins to prepare for the upcoming release of Windows 11 version 26H2. The company has confirmed that this will be a small enablement package (eKB) that will simply light up certain disabled features that are already present in the operating system's code base. This means that the "refined" Windows update and deployment experience will be simpler and quicker, with minimal disruptions, as the feature update will simply toggle a few flags rather than performing a complete replacement. Microsoft has explained that this is all possible because the standard Windows 11 releases share the same servicing branch and hence, the same source code. However, this also means that Windows 11 26H1 users won't be able to upgrade to 26H2 as that is a different branch, but this is something we have known for a while now. Similar to previous annual feature updates, Windows 11 26H2 will offer the following support cycles: 24 months of support for Home, Pro, Pro EDU, and Pro for Workstations editions 36 months of support for Enterprise, Education, IoT Enterprise, and Enterprise Multi-session editions Microsoft has not confirmed a concrete release date for Windows 11 26H2, but noted that it is "coming soon". If we go by the ongoing release cadence, we can expect it to begin rolling out in early October 2026. As such, IT admins have been encouraged to begin validating Windows Insider releases in the Experimental Channel, plan rollout rings, and strategize the utilization of their existing deployment tools.
    • Windows 11 gets new audio improvements in the latest builds by Taras Buria Today's Experimental builds (26H1 and Future Platforms, formerly Canary) pack several audio-related improvements. If your device is enrolled in the Experimental Channel (26H1), you can download build 28120.2315, while those in the Future Platforms version have build 29613.1000 to try. Here is what is new in build 29613.1000: [Audio] Following up on our previous improvements, we’re making some more adjustments to Settings > System > Sounds based on your feedback. Namely, we’ve updated the “All sound devices” page so: You now have the ability to change default devices from this page. Each of the devices displayed on this page now has a little volume meter next to it to show if there is audio actively playing. We’ve adjusted the page design slightly so now you can filter whether you’re viewing input or output devices. We’ve added toggles so you can choose if you want to hide or show disabled, disconnected, and unplugged devices on this page. We’ve also updated the input and output audio properties page for devices in Settings to now include jack information for those that need it. And here is the changelog for build 28120.2315: This update includes a small number of minor bug fixes and improvements. [Accessibility] This update improves caption style responsiveness by redrawing captions immediately for caption style changes. If no current caption is visible, a sample caption string is displayed. [Audio] This update improves the reliability of the inbox HD Audio driver. You can find the official release notes for build 28120.2315 here and for build 29613.1000 here.
    • I agree with what I think you are saying, just not in the way you are saying it. Like any tool, the amount it represents your work is perorational to the effort you put into it. It is similar to why 2nd grade math students learning to add and subtract are not allowed to use calculators, but a high-school calculous student is. For the 2nd grader, that tool would completely replace the work they are doing, for the calculous student the same tool allows them to work far more effectively while in no way replacing their effort or knowable. If you spend 30 seconds writing a prompt, then the image that comes out is no more "yours" than if you found the same image with a Google Image search. However, many of these generative tools also support highly iterative processes that allow back and forth, and merging generated images with photos or human created images. I am sure you would agree that a human spending hours of time working on a project, even if AI was involved in the process, still reflects that human's work.
    • Windows 11 version 26H2 is now available for testing in the latest preview build by Taras Buria Friday Windows 11 preview builds are here. Insiders in the Experimental (formerly Dev) and Beta Channel can download builds 26300.8697 and 26220.8690. There are no new features, but Microsoft is officially moving the Experimental Channel to version 26H2. In addition, Microsoft is improving the copy dialog in File Explorer, the Start menu reliability, and fixing virtualization issues. Here is the changelog: [General] With today’s build, Windows Insiders in the Experimental channel will see the versioning updated under Settings > System > About (and winver) to version 26H2. For more information, see the Windows Insiders blog. [File Explorer] We’ve improved the visual consistency and reliability of the Copy dialog in Dark mode, including its launch experience and the expanded progress view. [Start menu] - Also available in Beta Improved reliability of Start menu reflecting newly installed or removed apps without requiring sign-out or restart. [Taskbar] Fixed an issue for Insiders using the new smaller taskbar option, where the system tray might get cut off or pushed off screen. [Settings] - Also available in Beta Improved reliability of Settings > Apps > Startup. [Virtualization] - Also available in Beta This update addresses an issue that could result in bugchecks citing HYPERVISOR_ERROR (0x20001) and KMODE_EXCEPTION_NOT_HANDLED (0x1E) errors after installing the latest flights on some devices during system restarts, virtual machine operations, or while running some gaming applications. You can find the official changelog for the Experimental build here and for the Beta build here.
    • I've always preferred this possibility. There is something that feels good about the idea that all matter in the universe will eventually come back together and maybe even result in another big bang. The idea that the universe would fizzle out over the eons and forever drift apart is a little depressing. I realize it is not logical to let a basic human desire for life to have a grand everlasting meaning change the way I feel about a scientific theory, but I am human, so that is how I feel :-).
  • Recent Achievements

    • Collaborator
      ryansurfer98 went up a rank
      Collaborator
    • Week One Done
      Eurosoft10 earned a badge
      Week One Done
    • One Month Later
      Eurosoft10 earned a badge
      One Month Later
    • One Year In
      Skeet Campbell earned a badge
      One Year In
    • One Month Later
      Sharbel earned a badge
      One Month Later
  • Popular Contributors

    1. 1
      +primortal
      574
    2. 2
      +Edouard
      188
    3. 3
      Michael Scrip
      77
    4. 4
      PsYcHoKiLLa
      76
    5. 5
      neufuse
      71
  • Tell a friend

    Love Neowin? Tell a friend!