The only thing I can think of here is to create media queries in the temaplate.css to match the breakpoints I set in econa image
In /plugins/content/econa/tmpl/list.php there is a small amount of code that handles the display of image intros
You use
Right now the way I am handling this is through media queries, but it would be nice if this was set as a function of choosing the sizes in the interface. Frankly I can't think of a way this can be done other than media queries because we are providing a list of sizes that the browser can choose from. How would we know that in advance?
In /plugins/content/econa/tmpl/list.php there is a small amount of code that handles the display of image intros
<?php /** * @author Lefteris Kavadas * @copyright Copyright (c) 2016 - 2018 Lefteris Kavadas / firecoders.com * @license GNU General Public License version 3 or later */ defined('_JEXEC') or die; ?> <?php if ($this->params->get('list_image', 1) && $image->src): ?> <div class="econaListImageBlock"> <div class="econaImage"> <a href="https://www.firecoders.com/<?php echo JRoute::_(ContentHelperRoute::getArticleRoute($article->slug, $article->catid, $article->language)); ?>" itemprop="url"> <img src="https://www.firecoders.com/<?php echo $image->src; ?>" alt="<?php echo htmlspecialchars($alt, ENT_QUOTES, 'UTF-8'); ?>" <?php if($image->srcset): ?> srcset="https://www.firecoders.com/<?php /echo /$image->srcset; /?>" <?php endif; ?> <?php if($image->srcset): ?> sizes="<?php echo $image->sizes; ?>" <?php endif; ?> /> </a> </div> <?php if ($this->params->get('list_caption', 0) && $caption): ?> <span class="econaImageCaption"><?php echo $caption; ?></span> <?php endif; ?> <?php if ($this->params->get('list_credits', 0) && $credits): ?> <span class="econaImageCredits"><?php echo $credits; ?></span> <?php endif; ?> </div> <?php endif; ?>
You use
<?php if($image->srcset): ?> srcset="https://www.firecoders.com/<?php /echo /$image->srcset; /?>" <?php endif; ?> <?php if($image->srcset): ?> sizes="<?php echo $image->sizes; ?>" <?php endif; ?>to create the list of srcset images sizes available and what I was wondering, is there was a way to set the size of the container div
<div class="econaImage" style="width:>in the same way.
Right now the way I am handling this is through media queries, but it would be nice if this was set as a function of choosing the sizes in the interface. Frankly I can't think of a way this can be done other than media queries because we are providing a list of sizes that the browser can choose from. How would we know that in advance?