with the new blueprint snippet feature since kirby version 2.2 blueprint fields can be extended. I’ve tried to extend global field sets but this seems to be not possible:
# site/blueprints/fields/field.set.yml
title:
label: Titel
type: text
description:
label: Description
type: text
# site/blueprints/default.yml
fields:
extends: field.set
additional_field:
label: Additional field
type: text
So instead of importing field snippets, it would also be handy to extend the blueprint of a parent/base template. This would mean, that, for example, page.yml would inherit all fields from default.yml and so on. »Child«-blueprints then could override the parent’s fields as well.
That is indeed a cool idea, but I think it is a bit to unflexible because of the nameing convention. Existing kirby sites have to rename their page content files to use that feature.
I also prefer to use my own nameing convention. For examle i have a device page (device.yml) and a device datasheet (device.datasheet.yml). In the datasheet i don´t want to have all fields of the device page. A description field in a datasheet is not useful.
But the inheriting idea is great. What about a new line at the top of a yml file:
# site/blueprint/page.yml
inherit: default
fields:
additional_field:
label: Title
type: text
The inherit function could also inherit the page and file settings. They could be overitten if needed.