Flyer53 / jsPanel

A jQuery Plugin to create highly configurable floating panels, modals, tooltips and hints/notifiers for use in a backend solution and other web applications.
http://v2.jspanel.de/
Other
163 stars 56 forks source link

Position #47

Closed andreschardong closed 9 years ago

andreschardong commented 9 years ago

First of all, awesome plugin! Thanks!! I was having issues with position: { top: "auto", rigth: "auto" }. When top = 0, the position object, panelpos was returning {bottom: NaN, right: NaN}, instead of {top: 0, right: 0}

Looking the code, two changes solve my issue:

everything works fine now. is this correct? Or am I missing something.

Flyer53 commented 9 years ago

Hi there ... and thanks for the praise :)

Thank you very much for your report. And yes, there is an issue with using position: { top: "auto", rigth: "auto" }. Noticed this myself a few days ago but didn't have time to investigate it ... working to much on jsPanel version 3 ;)

Your solution seems to work fine but instead of adding 2 lines of code I would just change the two lines to:

panelpos.top = this.calcPos('top', jsP);

and

panelpos.left = this.calcPos('left', jsP);

respectively.

But this needs some more testing before I release a fixed version. If your time permits maybe you can make some tests as well. Would appreciate that and some feedback very much.

Thanks again, Stefan

Flyer53 commented 9 years ago

This issue is fixed with version 2.5.4

andreschardong commented 9 years ago

Dear Stefan, I see you released the fix. Thank you so much. Everything is working fine!

Flyer53 commented 9 years ago

@andreschardong I have to thank you! Not only for reporting, but also for providing the solution as well :)