Problem/Motivation
When using cookies_video in conjunction with ajax views placed via layout builder, the overlays of the iframes are not generated after ajax-content from drupals views is injected. Also, when consent was given, the iframes do not update their attributes to start working.
Steps to reproduce
* Configure cookies_video to block videos
* Create a view with video media, pagination and ajax enabled.
* Place it on a page with layout builder
* Use pagination
* The iframes will be broken on page 2 and on and no overlay will be generated for asking for consent.
Proposed resolution
Trigger the same event ("cookiesjsrUserConsent") as CookiesJSR manually with the current consent state, when drupal does inject ajax content.
Remaining tasks
Review issue and provided MR.
User interface changes
None.
API changes
None.
Data model changes
None.
Issue fork cookies-3444386
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #3
fisherman90Comment #4
fisherman90Comment #5
fisherman90Comment #6
tobiasbThe fix on production https://dgap.org/en/mediacenter -> change filter (media type) to video.
Comment #7
anybodyThanks for the report and the fix. I'm not super happy with the implementation above
document.dispatchEvent().I don't have much time currently to think about that. Any ideas for a more straight-forward solution?