🔧 chore(schemas): update collectionNavigation.json and fieldMeta.json schemas
All checks were successful
continuous-integration/drone/push Build is passing

🔀 Merge branch 'feature/schema-update' into 'master'
The collectionNavigation.json schema was updated to include a new enum value "MANUALLY" for the "order" property in the "defaultSort" object. This allows for manual sorting of items in the admin UI lists. The fieldMeta.json schema was updated to include new properties and definitions related to folding configuration for array fields, hiding field widgets, direction of fields, path steps, and meta elements. These updates enhance the flexibility and customization options for the field widgets in the application.
This commit is contained in:
Robin Grenzdörfer 2023-08-06 09:31:19 +00:00
parent 7e01225447
commit 791ef2639c
2 changed files with 163 additions and 92 deletions

View File

@ -71,7 +71,7 @@
},
"required": ["fields"]
},
"defaultSort": {
"type": "object",
"description": "default sort in admin ui lists",
@ -82,7 +82,7 @@
},
"order": {
"description": "sort order",
"enum": ["ASC", "DESC"]
"enum": ["ASC", "DESC", "MANUALLY"]
}
}
},
@ -146,8 +146,9 @@
{
"properties": {
"type": {
"const": "simpleList"
"enum": ["simpleList", "dashboardSimpleList"]
},
"primaryText": {
"oneOf": [
{
@ -184,7 +185,7 @@
{
"properties": {
"type": {
"const": "table"
"enum": ["table", "dashboardTable"]
},
"columns": {
"type": "array",

View File

@ -31,6 +31,161 @@
}
]
},
{
"$ref": "#/definitions/minimum",
"patternProperties": {
"^x-.*|widget|inputProps$": { "$comment": "stub for allOf" }
},
"allOf": [
{
"properties": {
"widget": { "enum": ["object", "object[]", "grid"] }
}
},
{
"properties": {
"folding": {
"type": "object",
"description": "folding configuration for array fields",
"additionalProperties": false,
"properties": {
"previewUnfolded": {
"description": "preview for unfolded array element",
"oneOf": [
{ "type": "string" },
{
"$ref": "definitions.json#/definitions/evalObjectWithRaw"
}
]
},
"previewFolded": {
"description": "preview for folded array element",
"oneOf": [
{ "type": "string" },
{
"$ref": "definitions.json#/definitions/evalObjectWithRaw"
}
]
}
}
},
"hide": {
"type": "boolean",
"description": "hide field widget"
},
"direction": {
"type": "string",
"enum": ["horizontal", "vertical"]
},
"pathStep": {
"type": "object",
"properties": {
"title": {
"type": "string",
"const": "Zeile"
},
"icon": {
"type": "string",
"const": "viewSequentialOutline"
}
},
"required": ["title", "icon"]
},
"metaElements": {
"oneOf": [
{
"type": "array",
"items": {
"type": "string"
}
},
{
"type": "array",
"items": {
"type": "object",
"additionalProperties": {
"type": "string"
}
}
},
{
"type": "object",
"properties": {
"source": {
"type": "string"
}
},
"required": ["source"]
},
{
"type": "array",
"items": [
{
"type": "string"
},
{
"type": "object",
"properties": {
"source": {
"type": "string",
"const": "layout"
}
},
"required": ["source"]
}
]
},
{
"type": "object",
"properties": {
"tablist": {
"type": "object",
"properties": {
"tabs": {
"type": "array",
"items": {
"type": "object",
"properties": {
"name": {
"type": "string"
},
"label": {
"type": "string"
},
"subFields": {
"type": "array",
"items": {
"type": "object",
"properties": {
"source": {
"type": "string"
}
},
"required": [
"source"
]
}
}
},
"required": [
"name",
"label",
"subFields"
]
}
}
},
"required": ["tabs"]
}
}
}
]
}
}
}
]
},
{
"$ref": "#/definitions/minimum",
"patternProperties": {
@ -353,6 +508,7 @@
"$ref": "definitions.json#/definitions/i18nString",
"description": "label for field"
},
"addElementLabel": {
"$ref": "definitions.json#/definitions/i18nString",
"description": "label for adding element to list"
@ -381,31 +537,7 @@
}
}
},
"folding": {
"type": "object",
"description": "folding configuration for array fields",
"additionalProperties": false,
"properties": {
"previewUnfolded": {
"description": "preview for unfolded array element",
"oneOf": [
{ "type": "string" },
{
"$ref": "definitions.json#/definitions/evalObjectWithRaw"
}
]
},
"previewFolded": {
"description": "preview for folded array element",
"oneOf": [
{ "type": "string" },
{
"$ref": "definitions.json#/definitions/evalObjectWithRaw"
}
]
}
}
},
"css": {
"description": "css styles for field widgets",
"oneOf": [
@ -523,69 +655,7 @@
"type": "object",
"additionalProperties": true
},
"metaElements": {
"oneOf": [
{
"type": "array",
"items": {
"type": "string"
}
},
{
"type": "array",
"items": {
"type": "object",
"additionalProperties": {
"type": "string"
}
}
},
{
"type": "object",
"properties": {
"tablist": {
"type": "object",
"properties": {
"tabs": {
"type": "array",
"items": {
"type": "object",
"properties": {
"name": {
"type": "string"
},
"label": {
"type": "string"
},
"subFields": {
"type": "array",
"items": {
"type": "object",
"properties": {
"source": {
"type": "string"
}
},
"required": [
"source"
]
}
}
},
"required": [
"name",
"label",
"subFields"
]
}
}
},
"required": ["tabs"]
}
}
}
]
},
"defaultValue": {
"description": "default value or code to get the value",
"oneOf": [