Projects

Create a content entity with properties to store HTML, CSS, and JS values.

Updated: | #Entity

Mantra started as a black and white theme - let's add color for the background, text, and links.

First we need to know how to set variables and use them in css.

Updated: | #Theming

Themes can include config for default block placement.

Will the starter kit include this in setup?

Updated: | #Development, #Theming

I set up a new text filter to use CKEditor 5 called Content.

I added a few buttons for lists, tables, blockquotes. Also replaced the image button with media library, and added code block and source buttons.

Updated: | #Content, #Text Format
name: Mantra
description: Mantra theme.
type: theme
core_version_requirement: ">=8"
base theme: false

 

Updated: | #Theming

layout.css

Updated: | #Layout

messages.css

Updated: | #Messages

Copy menu.html.twig from Classy.

Add attach_library('mantra_theme/menu').

 

mantra_theme.libraries.yml

Updated:

Drupal themes inherit libraries from core modules and base themes.

Inherited libraries can be extended or overridden in the theme info file.

mantra_theme.info.yml

Updated: | #Theming, #Libraries

CKEditor 5 is now loaded without an iFrame, so it inherits the styles from the current theme.

mantra_theme.info.yml

ckeditor5-stylesheets:
  - css/drupal/ckeditor5.css

 

Updated: | #CKEditor 5