Closed OscarValerock closed 1 year ago
I've prototyped something for the schema that would ship with the May release. Here's the schema generated, please let me know if you see an issue with it!
"image": {
"type": "object",
"additionalProperties": false,
"properties": {
"*": {
"type": "object",
"allOf": [
{
"$ref": "#/definitions/commonCards"
},
{
"properties": {
"*": {
"type": "array",
"items": {
"type": "object",
"properties": {
"imageUrl": {
"type": "string"
},
"imageScalingType": {
"type": "string",
"oneOf": [
{
"const": "Normal",
"title": "Normal"
},
{
"const": "Fit",
"title": "Fit"
},
{
"const": "Fill",
"title": "Fill"
}
],
"title": "Scaling"
}
}
}
},
"general": {
"type": "array",
"items": {
"type": "object",
"properties": {
"imageUrl": {
"type": "string"
}
}
}
},
"imageScaling": {
"type": "array",
"items": {
"type": "object",
"properties": {
"imageScalingType": {
"type": "string",
"oneOf": [
{
"const": "Normal",
"title": "Normal"
},
{
"const": "Fit",
"title": "Fit"
},
{
"const": "Fill",
"title": "Fill"
}
],
"title": "Scaling"
}
}
},
"title": "Scaling"
}
}
}
]
}
}
},
Seems to be working great, looking forward to the next release. Thanks!
Hi @yelper !
The "image" visual style is missing from the schema.
But this can be used in a theme without problems.