- 🇬🇧United Kingdom lesleyfernandes
I am closing all very old tickets that have not received comments for a long time. If someone is still facing these issues, please reopen it. Feel free to contribute with more info or a patch.
The picture module provides a default breakpoint 'empty_srcset'. Changes to this breakpoint (for example, we add a modifier) can not be exported.
A work around is not using the default empty_srcset and defining a custom 'project_empty_srcset' one, which can be exported. I filed this issue to find out if there's a better way to achieve this.
One solution would be to allow exporting the default mapping, but this might be tough to implement (i.e. lots of modules have problems like this, like file_entity) and we're limited by the capabilities of ctools.
Another options would be to document how to override the defaults programatically. For example this hook works great in our case:
/**
* Implements hook_default_breakpoints_alter().
*
* Modify the default provided by picture.module. The modifiers can be
* configured in the UI, but we alter it because ctools defaults cannot be
* exported.
*/
function acme_default_breakpoints_alter(&$export) {
if (isset($export['module.picture.empty_srcset'])) {
$export['module.picture.empty_srcset']->multipliers['2x'] = '2x';
}
}
Closed: outdated
2.0
Code
Not all content is available!
It's likely this issue predates Contrib.social: some issue and comment data are missing.
I am closing all very old tickets that have not received comments for a long time. If someone is still facing these issues, please reopen it. Feel free to contribute with more info or a patch.