This forum is for assistance with theme development.

seeking guidance on git(hub) repo structure for themes and sub-themes

I'm seeking some advice on what others would think would be best practices or things to consider while making themes and sub-themes as git repositories hosted on GitHub.

design not changing

Hi,

My first project on drupal 8 and my problem is that i cant make custom code to the bartik theme nothing changes. Clear cache not working not doing anything

[SOLVED]Seven subtheme problem

There was no problems with the yml or any of that stuff.  I needed to go into the block editor and duplicate the same blocks that seven had!

-----------

Hi all!

It looks like I've successfully setup a seven subtheme except the header seems to be odd.  Check out the screenshots below.  Hopefully it's an easy fix?

Just as a reference, seven theme (working and unchanged): Working theme

Rendering TWIG in content

I neeed some conditionals and some fields in content and want to use TWIG syntax for that purpose.
I made a very small (nearly empty) Theme for outputting my fields. But I don't know how to render content.

I have a similar website on WP where I use compile_string in PHP Template.

How to do that in Drupal without writing a Module?
Would it be possible to use template_from_string() to include content as template?
How do I enable the StringLoader?

Thanks for any help

Birger

USWDS Subtheme: Parent theme styles are not inherited from parent theme

Our team has individually followed the README file and instructions for creating a subtheme of USWDS (https://www.drupal.org/project/uswds) but it seems that this theme is not setup to inherit styles from the parent theme. 

The way they describe it on the project page, it looks as if they are assuming that the USWDS styles will live in your subtheme folder and all of the directions they give have those base theme styles running in your subtheme rather than in your parent theme.

themename.libraries.yml - can it have links to cdn sources libraries or only local?

I'm getting familiar with theming in drupal 8, i'm on part of adding libraries to custom theme. In documentation and example themes i see libraries added in form of path to a file located in theme's structure but is it possible to add link to library located on cdn?

For example, that's how it is in themes:

global-styling:
  version: VERSION
  css:
    base:
      ...
    component:
      css/components/admin-list.css: {}

But can i make it like this and would it work the way i want it to work?

Pages

Subscribe with RSS Subscribe to RSS - Theme development