fix(javascript): lightbox wasn't shown when generated from ajax view.

It also fixes page owner in core/edit_comment ajax view, needed for a consistent
experience with embed plugin.

Fixes #6304