Add json schema files for the layout-config.json
This commit is contained in:
parent
bb283b59a4
commit
e15ec387a2
25 changed files with 7340 additions and 0 deletions
80
Docs/Schemas/FilterConfigJsonJSC.ts
Normal file
80
Docs/Schemas/FilterConfigJsonJSC.ts
Normal file
|
@ -0,0 +1,80 @@
|
|||
export default {
|
||||
"$schema": "http://json-schema.org/draft-07/schema#",
|
||||
"$ref": "#/definitions/FilterConfigJson",
|
||||
"definitions": {
|
||||
"FilterConfigJson": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": "string",
|
||||
"description": "An id/name for this filter, used to set the URL parameters"
|
||||
},
|
||||
"options": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"question": {
|
||||
"anyOf": [
|
||||
{
|
||||
"type": "string"
|
||||
},
|
||||
{}
|
||||
]
|
||||
},
|
||||
"osmTags": {
|
||||
"anyOf": [
|
||||
{
|
||||
"$ref": "#/definitions/AndOrTagConfigJson"
|
||||
},
|
||||
{
|
||||
"type": "string"
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"question"
|
||||
]
|
||||
},
|
||||
"description": "The options for a filter If there are multiple options these will be a list of radio buttons If there is only one option this will be a checkbox Filtering is done based on the given osmTags that are compared to the objects in that layer."
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"id",
|
||||
"options"
|
||||
]
|
||||
},
|
||||
"AndOrTagConfigJson": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"and": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"anyOf": [
|
||||
{
|
||||
"type": "string"
|
||||
},
|
||||
{
|
||||
"$ref": "#/definitions/AndOrTagConfigJson"
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"or": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"anyOf": [
|
||||
{
|
||||
"type": "string"
|
||||
},
|
||||
{
|
||||
"$ref": "#/definitions/AndOrTagConfigJson"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue