title | issue |
---|---|
Fix twig source path for icons |
NEXT-23464 |
- Changed
Shopware\Core\Framework\DependencyInjection\CompilerPass\TwigLoaderConfigCompilerPass
to add pathBUNDLE/Resources/app/storefront/dist
to the TwigFileLoader.
- Changed
storefront/utilities/icon.html.twig
to only usedist
directory for icons - Changed
Shopware\Storefront\Framework\Routing\StorefrontSubscriber::addIconSetConfig
to add pathBUNDLE/Resources/app/storefront/dist
to the TwigFileLoader.
We changed the base paths to the icons in the template Storefront/Resources/views/storefront/utilities/icon.html.twig
If you have overwritten the block utilities_icon
please change it as follows:
Before:
...
{% set icon = source('@' ~ themeIconConfig[pack].namespace ~ '/../' ~ themeIconConfig[pack].path ~'/'~ name ~ '.svg', ignore_missing = true) %}
...
{% set icon = source('@' ~ namespace ~ '/../app/storefront/dist/assets/icon/'~ pack ~'/'~ name ~'.svg', ignore_missing = true) %}
...
After:
...
{% set icon = source('@' ~ themeIconConfig[pack].namespace ~ '/' ~ themeIconConfig[pack].path ~'/'~ name ~ '.svg', ignore_missing = true) %}
...
{% set icon = source('@' ~ namespace ~ '/assets/icon/'~ pack ~'/'~ name ~'.svg', ignore_missing = true) %}
...