I have created a custom theme. And I want a preview of the theme to be displayed automatically when it have been installed (just like the default Shopware theme).
Created a image with the same size as the one for the default theme. Also, added it to:
myThemePlugin > src > Resources >app > storfront > src > assets
The name is „aliceThemePreview.jpg“
Zipped the custom theme „myThemePlugin“ folder and installed on another Shopware store (locally). But no theme preview…
How is this done?
I also followed the manual on how to Add custom assets, but that did not seems to work either.
Thanks @Max_Shop
But I don’t get it how this will work. Do you mean this config folder (see image). But when I zip my plugin, it will not contain the preview file.
I have the development version of Shopware installed, and trying to „reverse engineer“ how Shopware have done it…
@Max_Shop I have solved it!
And, if anyone else wonder how to do it:
Add your theme preview file in the folder „YourPlugInFolder > src > Resources > app > storefront > src > assets“
Add this line to your theme.json file:
„previewMedia“: „app/storefront/src/assets/alicered22-preview.jpg“,
after the description block. Change the file name to your file.