craftcms-thearchitect
craftcms-thearchitect copied to clipboard
I think Relabel may not be supported on Neo blocks that aren't top-level accessible
Weird issue:
- Neo field had two blocks: Top and Child.
- Both blocks had fields using Relabel.
- Top imported fields to block and relabeled properly.
- Child did not import fields to block, and thus didn't have anything to relabel.
Either the Child type is throwing an issue, or the null
(code below) is causing an issue.
{
"group": "Page Content",
"name": "Column Builder",
"handle": "columnBuilder",
"instructions": "Build out a three-column layout using this field.",
"required": false,
"type": "Neo",
"typesettings": {
"maxBlocks": "4",
"groups": {
"name": [],
"sortOrder": []
},
"blockTypes": {
"new0": {
"sortOrder": "1",
"name": "Section",
"handle": "builderSection",
"maxBlocks": "1",
"childBlocks": [
"column"
],
"maxChildBlocks": null,
"topLevel": "1",
"fieldLayout": {
"Content": [
"featuredImage"
]
},
"relabel": [
{
"field": "featuredImage",
"name": "Background Image",
"instructions": "The background for this section. The photo will be behind every column in this section."
}
]
},
"new1": {
"sortOrder": "2",
"name": "Column",
"handle": "column",
"maxBlocks": "3",
"childBlocks": "",
"maxChildBlocks": null,
"topLevel": "0",
"fieldLayout": {
"Content": [
"columnHeadline",
"copy",
"blockButton"
]
},
"relabel": [
{
"field": "columnHeadline",
"name": "Headline",
"instructions": "Use the Bold function to change the text from black to blue."
},
{
"field": "blockButton",
"name": "Button",
"instructions": null
}
]
}
}
}
},
Update: I filled in the null
value and reimported this Neo field. The error still occurred.