ft: JsonSchema components are now ImmutableJS compliant (#5952)
bug: JsonSchema components should validate schema properties exists - schema - type - format - enum bug: fix a debounce error in JsonSchema_string if value is null ft: new simplified JsonSchemaArrayItemText component test: use immutableJS for `json-schema-form` test test: add dev scripts to run `cypress open` test: new cypress `schema-form` tests
This commit is contained in:
@@ -9,10 +9,11 @@ export default OAS3ComponentWrapFactory(({ Ori, ...props }) => {
|
||||
onChange
|
||||
} = props
|
||||
|
||||
const { type, format } = schema
|
||||
const format = schema && schema.get ? schema.get("format") : null
|
||||
const type = schema && schema.get ? schema.get("type") : null
|
||||
const Input = getComponent("Input")
|
||||
|
||||
if(type === "string" && (format === "binary" || format === "base64")) {
|
||||
if(type && type === "string" && (format && (format === "binary" || format === "base64"))) {
|
||||
return <Input type="file"
|
||||
className={ errors.length ? "invalid" : ""}
|
||||
title={ errors.length ? errors : ""}
|
||||
|
||||
@@ -100,7 +100,6 @@ const wrapRender = (component) => {
|
||||
return target
|
||||
}
|
||||
|
||||
|
||||
export const getComponent = (getSystem, getStore, getComponents, componentName, container, config = {}) => {
|
||||
|
||||
if(typeof componentName !== "string")
|
||||
|
||||
Reference in New Issue
Block a user