Kirby

Blueprint field hidden with default

Hallo,

there are no field properties in the reference of the hidden field. Is that correct? If so, is there a way to store a default value in the hidden field?

Lule

Yes, you can set a default value:

iamhidden:
  type: hidden
  default: blue

Note that defaults only work on page creation, they do not affect existing pages.

Thanks a lot. Solved.

I tried and I failed. Then I tested a little. There seems to be that true is saved as 1 and false is not saved or β€˜β€™ is saved.

I don’t know if this is a bug or a feature. But as long as true and false are saved as strings in other fields like toggle or radio there is a problem of data integrity at least IMHO.