Page 1 of 2

Error msg too far to the right

Posted: Sun May 17, 2020 8:25 pm
by Martin
Hi,

The messagebox is displayed too far to the right, outside the visible area. Only if you scroll to the right, you will see the error message.

Re: Error msg too far to the right

Posted: Fri May 22, 2020 7:07 pm
by Martin
Is anyone experiencing the same issue or is my installation corrupt?

Re: Error msg too far to the right

Posted: Fri May 22, 2020 10:13 pm
by Janusz
Hi,
If you refer to the nuMessage you can change default location for example in the following way:
in ./nuform.js
find the line and disable it:

Code: Select all

//$('body', par).append("<div id='nuMessageDiv' class='nuMessage' style='overflow:hidden;width:" + widest + "px;left:" + l + "px' ></div>")
and add/replace with:

Code: Select all

$('body', par).append("<div id='nuMessageDiv' class='nuMessage' style='position:fixed; overflow:hidden;width:" + widest + "px;top:55px; left:10px' ></div>")

Re: Error msg too far to the right

Posted: Wed Aug 05, 2020 9:07 am
by kev1n
Hi guys,

You could try my fix. It centers the message over the current window/iFrame/popup. It also takes into account the current horizontal scrolling position to ensure visibility.

https://github.com/smalos/nuBuilder4-Bu ... osition.md

Re: Error msg too far to the right

Posted: Tue Aug 11, 2020 5:07 am
by admin
Janusz,

I have added your changes to Github.

Thanks

(Please test it.)


Steven

Re: Error msg too far to the right

Posted: Tue Aug 11, 2020 6:42 am
by kev1n
Hi Steven

The Patch doesn't work well for me in all situations. E.g. if the scrollbar position > 0 .

Apart from that, I find a centered message box more aesthetic (IMHO) and it's standard to do so.

BTW, Janusz confirmed that my Patch works well for him too.
numessage.png

Re: Error msg too far to the right

Posted: Tue Aug 11, 2020 7:26 am
by Janusz
Hi Steven,

To confirm - the implemented patch works well - it position the message on the left - so it's always visible.

And to confirm as well that I tested with Kevin his proposal - which works fine - and centers the message in the middle of the active window/iframe - if the message is wider than the window and goes to much on left (so it would be partially not readable) then it's placed on the left as in my proposal.

Re: Error msg too far to the right

Posted: Thu Aug 13, 2020 1:28 am
by admin
Thanks to both of you.

Steven

Re: Error msg too far to the right

Posted: Thu Aug 13, 2020 4:35 am
by kev1n
Steven,

In other words, the message is too far to the left now. Can you use my code or is there an issue with it? Please let me know. Thanks.

Re: Error msg too far to the right

Posted: Thu Aug 13, 2020 8:31 am
by admin
kev1n,

I've added your bit too now, thanks.

Steven