Pagelist sitemap selector bug (?)

Permalink
This post is mainly directed at the Concrete5 team, I hope this is the place to post it.

I have a block in the marketplace that uses a button to select pages from the sitemap and add them to a list (PagePicker block). The selecting from the sitemap part is Javascript and uses some Concrete Javascript event listeners to get the job done.

Now this is the problem :
The block works fine but if you edit a pagelist-block on the same page as a pagepicker block and use the select-page option of the pagelist block to pick a parent page from the sitemap dialog, this creates a problem : if I now edit the pagepicker block again and select a page from the sitemap, the sitemap dialog will automatically close when I select a page. This is a problem because my code already takes care of closing that dialog ($.fn.dialog.closeTop()). It seems to me the pagelist-block still has eventlisteners attached to the sitemap dialog and is closing it before I can. This causes my code to close the next dialog box which is the edit-form of my block. So this appears to be a bug in Concrete5 Javascript : some eventlisteners haven't been removed after the pagelist edit form has closed.

The Javascript in Concrete5 is not documented and hard to find or get my head around because it's tucked away in all kinds of places and has been minified. However, it is hard to build an extension for Concrete5 without using Javascript and if that script depends on Concrete5 Javascript you're basically in a bad position.

If these is indeed a Concrete5 Javascript bug as I think it is, do I post this to the bug tracker? Because it could be my code. And could you point me in any kind of direction concerning documentation on the Concrete5 Javascript libraries?

Justin1978
 
HardOne replied on at Permalink Reply
HardOne
As far as I know there are no written rules according to what belongs into the bugtracker and what should be a github issue. But that has recently been discussed at github, so a documentation about that might come soon.

If you believe it's a bug, then post it to the bugtracker. Even if it's not a bug it won't harm anyone. If you are sure it is a bug and even know the cause and maybe a solution, then open an issue at github. That's what I would do and what I believe is common practice here.

By the way github is also a good resource for non minified files, if beautifying every file manually is not an option.

I'm sorry for not beiing able to help you with your actual problem.
Justin1978 replied on at Permalink Reply
Justin1978
Thanks for your reply, I think it is in fact a Concrete Javascript bug so I will probably submit it to the bug tracker. Some other process is closing the sitemap dialog box. I created a workaround as a patch for my block so the problem is solved momentarily