Problem/Motivation
The existing Ratio setting has no effect because the module passes it as plyr.ratio, while the GLightbox library expects plyr.config.ratio. This affects both explicitly configured ratios and leaving the setting blank for automatic sizing.
Steps to reproduce
- Go to
/admin/config/media/glightbox. - Set Ratio to
4:3, save and clear caches. - Open a video in GLightbox.
Expected: the configured ratio is used. Actual: the setting is ignored and the library retains its default configuration.
Proposed resolution
Correct the configuration path in GLightboxAttachment::attach(). Add a Kernel regression test covering blank, landscape and portrait settings.
Remaining tasks
Review the merge request.
User interface changes
The existing Ratio setting works as described. No new settings.
API changes
The attached JavaScript setting moves from plyr.ratio to plyr.config.ratio.
Data model changes
None.
AI-Generated: Yes (Used Codex to help investigate and prepare the change.)
Issue fork glightbox-3630937
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
nick hope commentedComment #4
nick hope commentedComment #6
levmyshkinThank you, merged!
Comment #7
levmyshkinComment #9
levmyshkin