From bca60cf81c22d0dd5b946565fc54bfc700eaf583 Mon Sep 17 00:00:00 2001 From: filzrev <103790468+filzrev@users.noreply.github.com> Date: Fri, 5 Jul 2024 10:42:19 +0900 Subject: [PATCH] chore: Fix json schemas (#10064) chore: fix json schemas --- schemas/docfx.schema.json | 5 +++++ schemas/filterconfig.schema.json | 36 +++++++++++++++++--------------- 2 files changed, 24 insertions(+), 17 deletions(-) diff --git a/schemas/docfx.schema.json b/schemas/docfx.schema.json index f06d712e042..b296b331a8f 100644 --- a/schemas/docfx.schema.json +++ b/schemas/docfx.schema.json @@ -399,6 +399,7 @@ "sitemap": { "type": "object", "description": "Specifies the options for the sitemap.xml file.", + "additionalProperties": false, "properties": { "baseUrl": { "type": "string", @@ -465,6 +466,7 @@ "markdownEngineProperties": { "description": "Set the parameters for markdown engine, value should be a JSON string.", "type": "object", + "additionalProperties": false, "properties": { "enableSourceInfo": { "type": "boolean", @@ -520,6 +522,7 @@ "plantUmlOptions": { "type": "object", "description": "PlantUml extension configuration parameters", + "additionalProperties": false, "properties": { "javaPath": { "type": "string", @@ -572,6 +575,7 @@ "type": "array", "items": { "type": "object", + "additionalProperties": false, "properties": { "src": { "$ref": "#/$defs/srcFileMapping" @@ -742,6 +746,7 @@ "type": "array", "items": { "type": "object", + "additionalProperties": false, "properties": { "content": { "$ref": "#/$defs/contentFileMapping" diff --git a/schemas/filterconfig.schema.json b/schemas/filterconfig.schema.json index 10e362ffdc1..271942dddf0 100644 --- a/schemas/filterconfig.schema.json +++ b/schemas/filterconfig.schema.json @@ -27,28 +27,30 @@ "properties": { "include": { "type": "object", + "additionalProperties": false, "properties": { "uidRegex": { "type": "string" }, - "kind": { + "type": { "$ref": "#/$defs/extendedSymbolKind" }, - "attribute": { + "hasAttribute": { "$ref": "#/$defs/attributeFilterInfo" } } }, "exclude": { "type": "object", + "additionalProperties": false, "properties": { "uidRegex": { "type": "string" }, - "kind": { + "type": { "$ref": "#/$defs/extendedSymbolKind" }, - "attribute": { + "hasAttribute": { "$ref": "#/$defs/attributeFilterInfo" } } @@ -57,19 +59,19 @@ }, "extendedSymbolKind": { "enum": [ - "assembly", - "namespace", - "class", - "struct", - "enum", - "interface", - "delegate", - "type", - "event", - "field", - "method", - "property", - "member" + "Assembly", + "Namespace", + "Class", + "Struct", + "Enum", + "Interface", + "Delegate", + "Type", + "Event", + "Field", + "Method", + "Property", + "Member" ] }, "attributeFilterInfo": {