Zenit Design - Themes
Buy themeThemesSupport
EN
EN
  • First steps
  • Start Guides
    • Atmos - Demo 1
    • Atmos - Demo 2
    • Atmos - Demo 3
    • Atmos - Demo 4
    • Gravity - Demo 1
    • Gravity - Demo 2
    • Horizon - Demo 1
    • Horizon - Demo 2
    • Sphere - Demo 1
    • Sphere - Demo 2
    • Stratus - Demo 1
    • Stratus - Demo 2
    • Stratus - Demo 3
    • Stratus - Demo 4
  • Tips
    • Dashboard
    • Theme configuration
    • Dictionary
    • Multiple sales channels
  • Configuration sets
  • Support
    • Read errors
    • Find cause
  • 🎨Styling
    • General
      • Basic layout
      • Product images
      • Produkt Layout-Typ
      • Global background
      • Preloader
      • Accent line
      • Scroll animation
    • Typo & Colors
      • Theme colors
      • Status messages
      • Fonts
      • Typography
      • E-Commerce
      • Buttons
    • Logos
    • Header
      • Header
      • Search
      • Top bar
      • Shop navigation
      • Main navigation
      • Flyout navigation
      • Dropdown navigation
    • Footer
      • Footer
      • Content
      • Columns
      • Columns styling
      • Footer bottom
    • Components
      • Sidebar
      • Sidebar navigation
      • Forms
      • Image & gallery slider
      • Produkt slider
      • Category Listing Slider
      • Pagination
      • Breadcrumbs
      • Cookie banner
      • Offcanvas
      • Backdrop
      • Scroll-Up button
    • Category
      • Category header
      • Hero section
      • Filter
      • Listing actions
      • Product boxes
      • Quickview
    • Product
      • Detail
      • Gallery
      • Description
      • Description navigation
      • Description content
    • Checkout
      • Cart
      • Checkout
  • ⚙️SETTINGS
    • Basic settings
    • Custom field assignment
      • Custom fields for product page details
      • Custom fields for product datasheets
    • Social media icons
    • Marketing text slider
    • Custom tab details page
    • Custom footer columns
    • Custom code
  • 📂Contents
    • Shopping experiences
      • Sections
      • Blocks
        • Elements
          • Image text slider
          • Search banner
          • Text banner
          • Teaser
          • Features
          • Breadcrumbs
          • Code
          • Divider
          • Category-navigation
          • Footer navigation
          • Placeholder
        • Commerce
          • Image gallery and buy box with product name & manufacturer logo
          • Image gallery and buy box with product name & manufacturer logo & description
          • Image gallery and buy box with description
          • Image gallery with description and buy box with product name & manufacturer logo
        • Category
          • Category listing
        • Columns
        • Layouts
      • Block inner spacings
      • Block outer spacings
      • Animations
      • CSS Variables
    • Category
      • Hero section
      • Category header
      • CSS classes
      • Category badges
      • Category Icons
      • Products per row
    • Product page
      • Layouts
      • Default layout
      • Gallery mode
      • Custom tabs
      • Videos tab
      • Datasheets
    • Product images
      • Image sizes
      • Aspect ratio
      • File format
      • Product image background
    • Layout type
    • Responsive tables
    • Multilingualism
  • 🎓Tutorials
    • Demodata import
    • Demo theme configuration import
    • Duplicate Child-Theme
    • Customizations
    • Configuration export/import
    • Custom Fields export/import
    • Embed fonts locally
    • Embed fonts locally with child-theme
  • 🛠️Update Guides
    • Child theme update
    • Shopware 6.6.9.0
    • Shopware 6.6.0.0
    • Shopware 6.5.0.0
    • Theme 3.5.3
    • Theme 2.11.0
  • ❓FAQ
    • Overview
    • Accessibility
      • Typography
      • Colors
      • Images
      • Video
      • Accessibility checker and resources
    • General
      • Copyright notice
      • Wishlist
    • Product layout
    • Licenses
      • Trial version vs full version
      • Changing the licence domain
    • Derivations
      • Child theme
      • Theme duplicate
      • Child theme vs theme duplicate
    • Updates
      • Theme is displayed as incompatible
      • Update is not displayed
    • Known issues
      • Could not assign child-theme
      • Text modules show technical name
      • Theme save error
      • SVG logo is not displayed
      • Search / Input mobile zoom
      • Text is not visible / readable
Powered by GitBook
On this page
  • 1. Download configuration set
  • 2. Unzip the zip file
  • 3. Make adjustments
  • 4. Ready

Was this helpful?

  1. Tutorials

Duplicate Child-Theme

If you want to use one child theme for multiple sales channels, you can duplicate and rename the child theme. Below we will show you how this works.

Last updated 6 months ago

Was this helpful?

Duration: 5-10 minutes Difficulty level: Easy Programming knowledge: No Programs: Code editor or Notepad

Since theme version 4.4.0, you have the option to generate a personalized child theme using our free child theme generator plugin and then import the desired demo template.

1. Download configuration set

Navigate to demos (1) and filter (2) on the name of the theme you purchased. Via the Download Set (3) link you can download the installable zip file of the child-theme.

Please note that the images and demo data shown in the demos are not part of the theme and templates.

For this example we will use Horizon Demo 2

2. Unzip the zip file

Unzip the zip file on your computer. You will receive the following files:

Unzipped zip zenitPlatformHorizonSet2
└──  (1)
    ├──  (2)
    └── src
        ├──  (3)
        └── Resources
            ├──  (4)
            ├── app
            │   └── storefront
            │       ├── dist
            │       │   ├── assets
            │       │   │   └── ...
            │       │   └── storefront
            │       │       └── js
            │       │           ├──  (5)
            │       │           │   └──  (5)
            │       │           └──  (5)
            │       └── src
            │           └── scss
            │               ├── base.scss
            │               └── overrides.scss
            └── config
                └── ...

3. Make adjustments

Small name changes are necessary in 5 places. We have labeled the individual files with numbers in the image above.

Folder name zenitPlatformHorizonSet2 (1)

Change the folder name to the desired technical name of the new theme. The easiest way is to replace Set2 with any string. In our example, from zenitPlatformHorizonSet2 => zenitPlatformHorizonSetBeispiel

Rewrites in composer.json (2)

Open the file in a code editor or Notepad.

  • Line 1: zenit/horizon-set-2 → zenit/horizon-set-beispiel

  • Line 20: zenit\\PlatformHorizonSet2\\zenitPlatformHorizonSet2 →zenit\\PlatformHorizonSetBeispiel\\zenitPlatformHorizonSetBeispiel

  • Line 24-25: Give your child theme a name

  • Line 28-29: Give your child theme a description

  • Line 42: zenit\\PlatformHorizonSet2\\→ zenit\\PlatformHorizonSetBeispiel\\

composer.json
{
    "name": "zenit/horizon-set-2",
    "description": "Theme Horizon by Zenit Design",
    "version": "3.6.5",
    "type": "shopware-platform-plugin",
    "license": "proprietary",
    "authors": [
        {
            "name": "Zenit Design",
            "homepage": "https://zenit.design",
            "role": "Manufacturer"
        }
    ],
    "require": {
        "shopware/core": "^6.5",
        "shopware/storefront": "^6.5",
        "zenit/horizon": ">=3.0.0"
    },
    "extra": {
        "shopware-plugin-class": "zenit\\PlatformHorizonSet2\\zenitPlatformHorizonSet2",
        "plugin-icon": "src/Resources/config/plugin.png",
        "copyright": "(c) by Zenit Design",
        "label": {
            "de-DE": "Theme HORIZON | Pro - Set 2",
            "en-GB": "Theme HORIZON | Pro - Set 2"
        },
        "description": {
            "de-DE": "Theme HORIZON | Pro - Set 2",
            "en-GB": "Theme HORIZON | Pro - Set 2"
        },
        "manufacturerLink": {
            "de-DE": "https://store.shopware.com/zenit-design.html",
            "en-GB": "https://store.shopware.com/en/zenit-design.html"
        },
        "supportLink": {
            "de-DE": "https://help.zenit.design",
            "en-GB": "https://help.zenit.design"
        }
    },
    "autoload": {
        "psr-4": {
            "zenit\\PlatformHorizonSet2\\": "src/"
        }
    }
}

Changes in the zenitPlatformHorizonSet2.php (3)

Apart from the file name, two places in the file also need to be adjusted.

  1. Adjust the file name to the new name: zenitPlatformHorizonSet2.php → zenitPlatformHorizonSetBeispiel.php

  2. Rewrite the names in the file, open the file in an editor or Notepad.

    Line 3: zenit\PlatformHorizonSet2 → zenit\PlatformHorizonSetBeispiel

    Line 8: zenitPlatformHorizonSet2 → zenitPlatformHorizonSetBeispiel

zenitPlatformHorizonSetBeispiel.php
<?php declare(strict_types=1);

namespace zenit\PlatformHorizonSet2;

use Shopware\Storefront\Framework\ThemeInterface;
use Shopware\Core\Framework\Plugin;

class zenitPlatformHorizonSet2 extends Plugin implements ThemeInterface
{
    public function getThemeConfigPath(): string
    {
        return 'theme.json';
    }
}

Changes in the theme.json (4)

Open the file in a code editor or Notepad.

  • Line 2: Give your child theme any name you want

  • Line 9: @zenitPlatformHorizonSet2 → @zenitPlatformHorizonSetBeispiel

  • Line 19: app/storefront/dist/storefront/js/zenit-platform-horizon-set2.js → app/storefront/dist/storefront/js/zenit-platform-horizon-set-beispiel.js

  • Line 20 (from version 4.0.0): app/storefront/dist/storefront/js/zenit-platform-horizon-set2/zenit-platform-horizon-set2.js

    → app/storefront/dist/storefront/js/zenit-platform-horizon-set-beispiel/zenit-platform-horizon-set-beispiel.js

theme.json
{
    "name": "Theme HORIZON | Pro - Set 2",
    "author": "Zenit Design",
    "previewMedia": "config/horizon-set-2-preview.png",
    "views": [
        "@Storefront",
        "@zenitPlatformHorizon",
        "@Plugins",
        "@zenitPlatformHorizonSet2"
    ],
    "style": [
        "app/storefront/src/scss/overrides.scss",
        "@zenitPlatformHorizon",
        "app/storefront/src/scss/base.scss"
    ],
    "script": [
        "@Storefront",
        "@zenitPlatformHorizon",
        "app/storefront/dist/storefront/js/zenit-platform-horizon-set2.js"
        "app/storefront/dist/storefront/js/zenit-platform-horizon-set2/zenit-platform-horizon-set2.js"
    ],
    "asset": [
        "@Storefront",
        "@zenitPlatformHorizon",
        "app/storefront/dist/assets"
    ],
    "configInheritance": [
        "@Storefront",
        "@zenitPlatformHorizon"
    ],
    "config": {
        ...
    }

Rename the file zenit-platform-horizon-set2.js (5)

Finally, all you have to do is change the file name of the Javascript file to the name from theme.json (line 19) that was changed in the previous step.

zenit-platform-horizon-set2.js → zenit-platform-horizon-set-beispiel.js

If you are using a Child Theme version 4.0.0 or higher, an additional folder and another JavaScript file need to be renamed at this location.

Folder: zenit-platform-horizon-set2 → zenit-platform-horizon-set-beispiel Javascript file: zenit-platform-horizon-set2.js → zenit-platform-horizon-set-beispiel.js

4. Ready

Now zip the folder again and upload the file manually to your shop. You can now install the duplicate child theme as usual.

Download the desired template as a zip file on our for free.

🎓
webseite
Child theme generator for Zenit Design themesShopware Store
Logo