fix(components): add support for oneOf/anyOf JSON Schema keywords in parameter-row rendering (#9934)
Refs #7912
This commit is contained in:
@@ -9,6 +9,7 @@ import ParameterRow from "core/components/parameter-row"
|
||||
import {
|
||||
memoizedSampleFromSchema,
|
||||
memoizedCreateXMLExample,
|
||||
mergeJsonSchema,
|
||||
} from "core/plugins/json-schema-5-samples/fn/index"
|
||||
import makeGetSampleSchema from "core/plugins/json-schema-5-samples/fn/get-sample-schema"
|
||||
import makeGetJsonSampleSchema from "core/plugins/json-schema-5-samples/fn/get-json-sample-schema"
|
||||
@@ -103,6 +104,7 @@ describe("bug #4557: default parameter values", function () {
|
||||
getYamlSampleSchema: makeGetYamlSampleSchema(getSystem),
|
||||
getXmlSampleSchema: makeGetXmlSampleSchema(getSystem),
|
||||
getSampleSchema: makeGetSampleSchema(getSystem),
|
||||
mergeJsonSchema,
|
||||
},
|
||||
})
|
||||
const props = {
|
||||
|
||||
@@ -9,6 +9,7 @@ import ParameterRow from "core/components/parameter-row"
|
||||
import {
|
||||
memoizedSampleFromSchema,
|
||||
memoizedCreateXMLExample,
|
||||
mergeJsonSchema,
|
||||
} from "core/plugins/json-schema-5-samples/fn/index"
|
||||
import makeGetSampleSchema from "core/plugins/json-schema-5-samples/fn/get-sample-schema"
|
||||
import makeGetJsonSampleSchema from "core/plugins/json-schema-5-samples/fn/get-json-sample-schema"
|
||||
@@ -31,6 +32,7 @@ describe("<ParameterRow/>", () => {
|
||||
getYamlSampleSchema: makeGetYamlSampleSchema(getSystem),
|
||||
getXmlSampleSchema: makeGetXmlSampleSchema(getSystem),
|
||||
getSampleSchema: makeGetSampleSchema(getSystem),
|
||||
mergeJsonSchema,
|
||||
},
|
||||
oas3Selectors: { activeExamplesMember: () => {} },
|
||||
getConfigs: () => ({}),
|
||||
@@ -276,6 +278,7 @@ describe("bug #5573: zero default and example values", function () {
|
||||
getYamlSampleSchema: makeGetYamlSampleSchema(getSystem),
|
||||
getXmlSampleSchema: makeGetXmlSampleSchema(getSystem),
|
||||
getSampleSchema: makeGetSampleSchema(getSystem),
|
||||
mergeJsonSchema,
|
||||
},
|
||||
})
|
||||
const props = {
|
||||
@@ -329,6 +332,7 @@ describe("bug #5573: zero default and example values", function () {
|
||||
getYamlSampleSchema: makeGetYamlSampleSchema(getSystem),
|
||||
getXmlSampleSchema: makeGetXmlSampleSchema(getSystem),
|
||||
getSampleSchema: makeGetSampleSchema(getSystem),
|
||||
mergeJsonSchema,
|
||||
},
|
||||
})
|
||||
const props = {
|
||||
|
||||
Reference in New Issue
Block a user