Skip to content
Grav 2.0 is officially stable. Read the announcement →

Community guidelines

Please keep discussions civil and on-topic. Repeated violations may lead to a temporary ban.

General

Theme inheritance Not Working Properly

Started by Duc 8 years ago · 7 replies · 1432 views
8 years ago

For some reason I can't get the theme inheritance to work. I have created all the necessary files and folders; however, it isn't pulling data from 'mytheme', but the original theme folder. I have setup the theme inheritance using a the Photography skeleton site and it works perfect. This current Ceevee site I am working on isn't working as it should.

How can I troubleshoot this and find where the fault is?

8 years ago

Hi,

First have you set your new theme as active in the admin panel ?

can you share your mytheme.yaml ? and your blueprints.yaml ? that should be in the '/user/themes/mytheme' folder.

Can you also share a screenshot of the /user/themes folder ?

Take care at the case sensitive .....

8 years ago

First have you set your new theme as active in the admin panel?
I have tried selecting the old and new theme again in admin panel. I also manually edited the system.yaml file to include the new theme.

YAML
pages:
  theme: ceevee_child

can you share your mytheme.yaml ? and your blueprints.yaml ? that should be in the ‘/user/themes/mytheme’ folder.

ceevee_child.yaml

YAML
streams:
 schemes:
   theme:
     type: ReadOnlyStream
     prefixes:
       '':
         - user/themes/ceevee_child
         - user/themes/ceevee

blueprints.yaml

YAML
name: ceevee_child
version: 1.0.0
description: "Extension of Ceevee theme"
icon: group
author:
 name: Duc Sue
 email: s[email protected]
 url: http://someurl.com

Can you also share a screenshot of the /user/themes folder?
folder structure

last edited 03/02/18
8 years ago

Did you create this child theme using the devtools plugin command line interface?

Please see https://github.com/getgrav/grav-plugin-devtools/issues/9 and its patch which has not been released to the official repo yet.

In the meantime or if that's not how you generated the child these, simply swicth the order of the themes in ceevee_child.yaml streams.schemes.theme.prefixes.''

8 years ago

I have added them all manually. Changing the order around doesn't seem to help either.

YAML
streams:
 schemes:
   theme:
     type: ReadOnlyStream
     prefixes:
       '':
         - user/themes/ceevee
         - user/themes/ceevee_child
8 years ago

Oops, you got it right the first time (can never remember the correct sequence!) so please switch back!

Which file(s) are you editing that tells you inheritance isn't working?

8 years ago

Switched back. I am using the images folder to test.

Just to make sure it is working on a totally different site I have theme inheritance setup, I have changed an image file and it does updates. So this particular theme, I am having issue with.

8 years ago

Well this is strange. It worked itself out. The site seems to be loading from the theme inheritance folder now and I didn't do anything to fix it. Ghost in the machine?

Suggested topics

Topic Participants Replies Views Activity
General · by Jerry Hunt, 4 days ago
2 74 6 hours ago
General · by pamtbaau, 12 hours ago
1 47 11 hours ago
General · by Andy Miller, 24 hours ago
0 44 24 hours ago
General · by Marcel, 12 months ago
6 346 5 days ago
General · by Duc , 5 days ago
3 39 5 days ago