Make sure Protostar is your default template, and loads modal library.
You can do this by adding a line of code to templates/protostar/index.php
(or to a duplicated template based on protostar):
JHtml::_('behavior.modal');
In a module or an article insert a link pointing to a big image (ideally wider than high) and with modal class:
<a class="modal" href="path/to/image.jpg">Modal link</a>
In mobile devices, when you click the link to open the image, it should load fine keeping the aspect ratio.
The image loads with 100% height and width, losing the proportions (the image is stretched):
Firefox 50.0.2
MacOS Sierra
Labels |
Added:
?
|
I don't see why this should be fixed personally. JHtml::_('behavior.modal');
is deprecated.
Instead, you should use JHtml::_('bootstrap.renderModal');
@htmgarcia is this Issue resolved?
@franz-wohlkoenig please see @C-Lodder reply.
Regards
Status | New | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2017-02-02 23:13:54 |
Closed_By | ⇒ | htmgarcia |
This seems to be the code involved: https://github.com/joomla/joomla-cms/blob/staging/media/system/css/modal.css#L74
Changing to
height: auto;
may partially solve the issue.