Skip to content
● Meet Grav Guard: keep every Grav site you run secure and up to date, all from one place. Free for up to 3 sites. Read more →

How to override the default page blueprint?

Started by Muut Archive 10 years ago · 4 replies · 1285 views
10 years ago

I'd like to override the default page blueprint from a theme. I tried to add the following to themes/mytheme/blueprints/default.yaml:

---yaml
'@extends':
type: default
context: blueprints://pages

form:
fields:
tabs:
type: tabs
fields:
customtab:
type: tab
title: Custom

[...]

TXT


However the tab doesn't show up. Do I need to create a blueprint for every page type to inherit from my modified default blueprint?
---yaml
'@extends':
10 years ago

Thanks, I tried this but it didn't work. It might be that the default.yml in my theme is not part of Grav\Common\Page\Types::systemBlueprints and does not get picked up as a fallback in scanTemplates() later on.

10 years ago

Make sure you call it default.yaml, not default.yml

10 years ago

Oh, I meant to write default.yaml (the file was named correctly).

Suggested topics

Topic Participants Replies Views Activity
Archive · by Muut Archive, 10 years ago
1 672 1 week ago
Archive · by Deleted User, 9 years ago
0 3043 9 years ago
Archive · by Muut Archive, 9 years ago
2 1983 9 years ago
Archive · by Muut Archive, 9 years ago
2 5336 9 years ago
Archive · by Muut Archive, 9 years ago
1 4134 9 years ago