New games every week!
BBCode Button Saga Continues
4th August 2020  
The popup is working well, now.. Except..


Why can't I just say "Under the mouse"?
Why is that not a thing, without having to faff about tracking the mouse/touch positions in ways that look decidedly dodgy!?

Yesterday I spent ages looking into ways of locating the position of the "Open popup box" link, so that I can position the popup over the top of THAT, instead of tracking the mouse.
It "almost" works.

I can access the "OffsetTop" and "OffsetLeft" of the link, but unfortunately, SoCoder's a cavalcade of boxes, divs, tables and more, and by the time I get to the link in question, its "offset" is 0,0, because it's counting the offset from the myriad of parent elements, and not the top left of the site.

So, looks like the mouse position is probably the best way to do it.
Today I'll be finding the least hacky way of doing that, that I can, and hopefully not breaking the entire site as I do it.

Sure is a pretty popup, though!

Views 40, Upvotes 1
Daily Blog , Socoder
New games every week!
Site credits : Jayenkai
(c) Jayenkai 2017 and onwards, site design Rychan. RSS feed
Blog - BBCode Button Saga Continues - AGameAWeek