Options
All
  • Public
  • Public/Protected
  • All
Menu

JSON Forms Core

Index

Enumerations

Classes

Interfaces

Type aliases

Variables

Functions

Object literals

Type aliases

CombinatorKeyword

CombinatorKeyword: "anyOf" | "oneOf" | "allOf"

CombinatorProps

CoreActions

Dispatch

Dispatch<A>: function

A dispatching function (or simply dispatch function) is a function that accepts an action or an async action; it then may or may not dispatch one or more actions to the store.

We must distinguish between dispatching functions in general and the base dispatch function provided by the store instance without any middleware.

The base dispatch function always synchronously sends an action to the store's reducer, along with the previous state returned by the store, to calculate a new state. It expects actions to be plain objects ready to be consumed by the reducer.

Middleware wraps the base dispatch function. It allows the dispatch function to handle async actions in addition to actions. Middleware may transform, delay, ignore, or otherwise interpret actions or async actions before passing them to the next middleware.

template

A The type of things (actions or otherwise) which may be dispatched.

Type parameters

Type declaration

    • <T>(action: T): T
    • Type parameters

      • T: A

      Parameters

      • action: T

      Returns T

DispatchPropsOfCell

DispatchPropsOfCell: DispatchPropsOfControl

IterateCallback

IterateCallback: function

Type declaration

JsonFormsCellRendererRegistryState

JsonFormsCellRendererRegistryState: JsonFormsCellRendererRegistryEntry[]

JsonSchema

JsonSchema: JsonSchema4 | JsonSchema7

LocaleActions

Observable

Observable<T>: object

A minimal observable of state changes. For more information, see the observable proposal: https://github.com/tc39/proposal-observable

Type parameters

  • T

Type declaration

  • [Symbol.observable]: function
    • Returns Observable<T>

  • subscribe: function
    • subscribe(observer: Observer<T>): object
    • The minimal observable subscription method.

      Parameters

      • observer: Observer<T>

        Any object that can be used as an observer. The observer object should have a next method.

      Returns object

      An object with an unsubscribe method that can be used to unsubscribe the observable from the store, and prevent further emission of values from the observable.

Observer

Observer<T>: object

An Observer is used to receive data from an Observable, and is supplied as an argument to subscribe.

Type parameters

  • T

Type declaration

  • next: function
    • next(value: T): void
    • Parameters

      • value: T

      Returns void

Properties

Properties: object

Type declaration

RankedTester

RankedTester: function

A ranked tester associates a tester with a number.

Type declaration

Reducer

Reducer<S, A>: function

A reducer (also called a reducing function) is a function that accepts an accumulation and a value and returns a new accumulation. They are used to reduce a collection of values down to a single value

Reducers are not unique to Redux—they are a fundamental concept in functional programming. Even most non-functional languages, like JavaScript, have a built-in API for reducing. In JavaScript, it's Array.prototype.reduce().

In Redux, the accumulated value is the state object, and the values being accumulated are actions. Reducers calculate a new state given the previous state and an action. They must be pure functions—functions that return the exact same output for given inputs. They should also be free of side-effects. This is what enables exciting features like hot reloading and time travel.

Reducers are the most important concept in Redux.

Do not put API calls into reducers.

template

S The type of state consumed and produced by this reducer.

template

A The type of actions the reducer can potentially respond to.

Type parameters

Type declaration

    • (state: S | undefined, action: A): S
    • Parameters

      • state: S | undefined
      • action: A

      Returns S

RefResolver

RefResolver: function

Type declaration

Tester

Tester: function

A tester is a function that receives an UI schema and a JSON schema and returns a boolean.

Type declaration

UISchemaActions

UISchemaTester

UISchemaTester: function

Type declaration

    • (schema: JsonSchema, schemaPath: string, path: string): number
    • Parameters

      • schema: JsonSchema
      • schemaPath: string
      • path: string

      Returns number

Unsubscribe

Unsubscribe: function

Function to remove listener added by Store.subscribe().

Type declaration

    • (): void
    • Returns void

ValidCellReducerActions

ValidDefaultDataActions

ValidRendererReducerActions

ValidRendererReducerActions: AddRendererAction | RemoveRendererAction

ValidationMode

ValidationMode: "ValidateAndShow" | "ValidateAndHide" | "NoValidation"

Variables

Const ADDITIONAL_PROPERTIES

ADDITIONAL_PROPERTIES: "additionalProperties" = "additionalProperties"

Const ADD_CELL

ADD_CELL: "jsonforms/ADD_CELL" = "jsonforms/ADD_CELL"

Const ADD_DEFAULT_DATA

ADD_DEFAULT_DATA: "jsonforms/ADD_DEFAULT_DATA" = `jsonforms/ADD_DEFAULT_DATA`

Const ADD_RENDERER

ADD_RENDERER: "jsonforms/ADD_RENDERER" = "jsonforms/ADD_RENDERER"

Const ADD_UI_SCHEMA

ADD_UI_SCHEMA: "jsonforms/ADD_UI_SCHEMA" = `jsonforms/ADD_UI_SCHEMA`

Const INIT

INIT: "jsonforms/INIT" = "jsonforms/INIT"

Const NOT_APPLICABLE

NOT_APPLICABLE: -1 = -1

Constant that indicates that a tester is not capable of handling a combination of schema/data.

type

{number}

Const REMOVE_CELL

REMOVE_CELL: "jsonforms/REMOVE_CELL" = "jsonforms/REMOVE_CELL"

Const REMOVE_DEFAULT_DATA

REMOVE_DEFAULT_DATA: "jsonforms/REMOVE_DEFAULT_DATA" = `jsonforms/REMOVE_DEFAULT_DATA`

Const REMOVE_RENDERER

REMOVE_RENDERER: "jsonforms/REMOVE_RENDERER" = "jsonforms/REMOVE_RENDERER"

Const REMOVE_UI_SCHEMA

REMOVE_UI_SCHEMA: "jsonforms/REMOVE_UI_SCHEMA" = `jsonforms/REMOVE_UI_SCHEMA`

Const REQUIRED_PROPERTIES

REQUIRED_PROPERTIES: "required" = "required"

Const SET_AJV

SET_AJV: "jsonforms/SET_AJV" = "jsonforms/SET_AJV"

Const SET_CONFIG

SET_CONFIG: "jsonforms/SET_CONFIG" = "jsonforms/SET_CONFIG"

Const SET_LOCALE

SET_LOCALE: "jsonforms/SET_LOCALE" = `jsonforms/SET_LOCALE`

Const SET_LOCALIZED_SCHEMAS

SET_LOCALIZED_SCHEMAS: "jsonforms/SET_LOCALIZED_SCHEMAS" = "jsonforms/SET_LOCALIZED_SCHEMAS"

Const SET_LOCALIZED_UISCHEMAS

SET_LOCALIZED_UISCHEMAS: "jsonforms/SET_LOCALIZED_UISCHEMAS" = "jsonforms/SET_LOCALIZED_UISCHEMAS"

Const SET_SCHEMA

SET_SCHEMA: "jsonforms/SET_SCHEMA" = `jsonforms/SET_SCHEMA`

Const SET_UISCHEMA

SET_UISCHEMA: "jsonforms/SET_UISCHEMA" = `jsonforms/SET_UISCHEMA`

Const SET_VALIDATION_MODE

SET_VALIDATION_MODE: "jsonforms/SET_VALIDATION_MODE" = "jsonforms/SET_VALIDATION_MODE"

Const UPDATE_CORE

UPDATE_CORE: "jsonforms/UPDATE_CORE" = `jsonforms/UPDATE_CORE`

Const UPDATE_DATA

UPDATE_DATA: "jsonforms/UPDATE" = "jsonforms/UPDATE"

Const UPDATE_ERRORS

UPDATE_ERRORS: "jsonforms/UPDATE_ERRORS" = "jsonforms/UPDATE_ERRORS"

Const VALIDATE

VALIDATE: "jsonforms/VALIDATE" = "jsonforms/VALIDATE"

Const badPtrTokenRegex

badPtrTokenRegex: RegExp = /~(?:[^01]|$)/g

Const isAllOfControl

isAllOfControl: function = and(uiTypeIs('Control'),schemaMatches(schema => schema.hasOwnProperty('allOf')))

Type declaration

Const isAnyOfControl

isAnyOfControl: function = and(uiTypeIs('Control'),schemaMatches(schema => schema.hasOwnProperty('anyOf')))

Type declaration

Const isArrayObjectControl

isArrayObjectControl: function = isObjectArrayControl

Synonym for isObjectArrayControl

Type declaration

Const isBooleanControl

isBooleanControl: function = and(uiTypeIs('Control'),schemaTypeIs('boolean'))

Default tester for boolean.

type

{RankedTester}

Type declaration

Const isDateControl

isDateControl: function = and(uiTypeIs('Control'), formatIs('date'))

Tests whether the given UI schema is of type Control and if the schema has a 'date' format.

type

{Tester}

Type declaration

Const isDateTimeControl

isDateTimeControl: function = and(uiTypeIs('Control'),formatIs('date-time'))

Tests whether the given UI schema is of type Control and if the schema has a 'date-time' format.

type

{Tester}

Type declaration

Const isEnumControl

isEnumControl: function = and(uiTypeIs('Control'),or(schemaMatches(schema => schema.hasOwnProperty('enum')),schemaMatches(schema => schema.hasOwnProperty('const'))))

Tests whether the given UI schema is of type Control and if the schema has an enum.

type

{Tester}

Type declaration

Const isIntegerControl

isIntegerControl: function = and(uiTypeIs('Control'),schemaTypeIs('integer'))

Tests whether the given UI schema is of type Control and if the schema is of type integer

type

{Tester}

Type declaration

Const isMultiLineControl

isMultiLineControl: function = and(uiTypeIs('Control'),optionIs('multi', true))

Tests whether the given UI schema is of type Control and if is has a 'multi' option.

type

{Tester}

Type declaration

Const isNumberControl

isNumberControl: function = and(uiTypeIs('Control'), schemaTypeIs('number'))

Tests whether the given UI schema is of type Control and if the schema is of type number

type

{Tester}

Type declaration

Const isNumberFormatControl

isNumberFormatControl: function = and(uiTypeIs('Control'),schemaTypeIs('integer'),optionIs('format', true))

Tests whether the given UI schema is of type Control, if the schema is of type string and has option format

type

{Tester}

Type declaration

Const isObjectArray

isObjectArray: function = and(schemaMatches(schema => hasType(schema, 'array') && !Array.isArray(schema.items) // we don't care about tuples),schemaSubPathMatches('items', schema => hasType(schema, 'object')))

Tests whether the given schema is an array of objects.

type

{Tester}

Type declaration

Const isObjectArrayControl

isObjectArrayControl: function = and(uiTypeIs('Control'), isObjectArray)

Tests whether the given UI schema is of type Control and if the schema is an array of objects.

type

{Tester}

Type declaration

Const isObjectControl

isObjectControl: function = and(uiTypeIs('Control'), schemaTypeIs('object'))

Type declaration

Const isOneOfControl

isOneOfControl: function = and(uiTypeIs('Control'),schemaMatches(schema => schema.hasOwnProperty('oneOf')))

Type declaration

Const isOneOfEnumControl

isOneOfEnumControl: function = and(uiTypeIs('Control'),schemaMatches(schema =>schema.hasOwnProperty('oneOf') &&(schema.oneOf as JsonSchema[]).every(s => s.const !== undefined)))

Tests whether the given UI schema is of type Control and if the schema has an enum based on oneOf.

type

{Tester}

Type declaration

Const isPrimitiveArrayControl

isPrimitiveArrayControl: function = and(uiTypeIs('Control'),schemaMatches(schema => deriveTypes(schema).length !== 0 && !Array.isArray(schema.items) // we don't care about tuples),schemaSubPathMatches('items', schema => {const types = deriveTypes(schema);return (types.length === 1 &&includes(['integer', 'number', 'boolean', 'string'], types[0]));}))

Tests whether the given UI schema is of type Control and if the schema is an array of a primitive type.

type

{Tester}

Type declaration

Const isRangeControl

isRangeControl: function = and(uiTypeIs('Control'),or(schemaTypeIs('number'), schemaTypeIs('integer')),schemaMatches(schema =>schema.hasOwnProperty('maximum') &&schema.hasOwnProperty('minimum') &&schema.hasOwnProperty('default')),optionIs('slider', true))

Tests whether a given UI schema is of type Control, if the schema is of type number or integer and whether the schema defines a numerical range with a default value.

type

{Tester}

Type declaration

Const isStringControl

isStringControl: function = and(uiTypeIs('Control'), schemaTypeIs('string'))

Tests whether the given UI schema is of type Control and if the schema is of type string

type

{Tester}

Type declaration

Const isTimeControl

isTimeControl: function = and(uiTypeIs('Control'), formatIs('time'))

Tests whether the given UI schema is of type Control and if the schema has a 'time' format.

type

{Tester}

Type declaration

Const mapDispatchToCellProps

mapDispatchToCellProps: function = mapDispatchToControlProps

Synonym for mapDispatchToControlProps.

type

{(dispatch) => {handleChange(path, value): void}}

Type declaration

Const uriDetailsCache

uriDetailsCache: any = {} as any

Const usedIds

usedIds: Set<string> = new Set<string>()

Functions

Const addLabel

  • addLabel(layout: Layout, labelName: string): void
  • Adds the given {@code labelName} to the {@code layout} if it exists

    Parameters

    • layout: Layout
       The layout which is to receive the label
    • labelName: string
       The name of the schema

    Returns void

Const alwaysValid

  • alwaysValid(): true
  • Returns true

Const and

  • A tester that allow composing other testers by && them.

    Parameters

    • Rest ...testers: Tester[]

      the testers to be composed

    Returns Tester

Const applyDefaultConfiguration

  • applyDefaultConfiguration(config?: any): any
  • Parameters

    • Default value config: any = {}

    Returns any

Const categorizationHasCategory

  • Parameters

    Returns boolean

Const cellReducer

Const clearAllIds

  • clearAllIds(): void
  • Returns void

Const compose

  • compose(path1: string, path2: string): string
  • Parameters

    • path1: string
    • path2: string

    Returns string

Const composeWithUi

  • composeWithUi(scopableUi: Scopable, path: string): string
  • Parameters

    Returns string

Const computeLabel

  • computeLabel(label: string, required: boolean, hideRequiredAsterisk: boolean): string
  • Adds an asterisk to the given label string based on the required parameter.

    Parameters

    • label: string

      the label string

    • required: boolean

      whether the label belongs to a control which is required

    • hideRequiredAsterisk: boolean

    Returns string

    the label string

Const configReducer

  • Parameters

    • Default value state: any = applyDefaultConfiguration()
    • action: SetConfigAction

    Returns any

Const convertToValidClassName

  • convertToValidClassName(s: string): string
  • Escape the given string such that it can be used as a class name, i.e. hashes and slashes will be replaced.

    Parameters

    • s: string

      the string that should be converted to a valid class name

    Returns string

    the escaped string

Const coreReducer

Const createAjv

  • createAjv(options?: Options): Ajv
  • Parameters

    • Optional options: Options

    Returns Ajv

Const createCleanLabel

  • createCleanLabel(label: string): string
  • Parameters

    • label: string

    Returns string

Const createCombinatorRenderInfos

Const createControlElement

  • Creates a IControlObject with the given label referencing the given ref

    Parameters

    • ref: string

    Returns ControlElement

Const createDefaultValue

  • Create a default value based on the given scheam.

    Parameters

    • schema: JsonSchema

      the schema for which to create a default value.

    Returns object

Const createId

  • createId(proposedId: string): string
  • Parameters

    • proposedId: string

    Returns string

Const createLabel

  • Parameters

    Returns string

Const createLabelDescriptionFrom

  • Return a label object based on the given control and schema element.

    Parameters

    • withLabel: ControlElement

      the UI schema to obtain a label object for

    • Optional schema: JsonSchema

      optional: the corresponding schema element

    Returns LabelDescription

Const createLayout

  • createLayout(layoutType: string): Layout
  • Creates a new ILayout.

    Parameters

    • layoutType: string

      The type of the laoyut

    Returns Layout

    the new ILayout

Const defaultDataReducer

Const defaultMapDispatchToControlProps

  • Default dispatch to control props which can be customized to set handleChange action

    Parameters

    Returns DispatchPropsOfControl

Const defaultMapStateToEnumCellProps

Const deriveLabel

  • Parameters

    Returns string

Const deriveTypes

  • Derives the type of the jsonSchema element

    Parameters

    Returns string[]

Const distinct

  • distinct(properties: any[], discriminator: function): JsonSchema4[]
  • Parameters

    • properties: any[]
    • discriminator: function
        • (item: any): string
        • Parameters

          • item: any

          Returns string

    Returns JsonSchema4[]

Const encodePath

  • encodePath(path: any): any[]
  • Parameters

    • path: any

    Returns any[]

Const enumToEnumOptionMapper

  • Parameters

    • e: any

    Returns EnumOption

Const errorAt

  • errorAt(instancePath: string, schema: JsonSchema): (Anonymous function)
  • Parameters

    Returns (Anonymous function)

Const errorsAt

  • errorsAt(instancePath: string, schema: JsonSchema, matchPath: function): (Anonymous function)
  • Parameters

    • instancePath: string
    • schema: JsonSchema
    • matchPath: function
        • (path: string): boolean
        • Parameters

          • path: string

          Returns boolean

    Returns (Anonymous function)

Const evalEnablement

  • evalEnablement(uischema: UISchemaElement, data: any, path?: string, ajv: Ajv): boolean
  • Parameters

    • uischema: UISchemaElement
    • data: any
    • Default value path: string = undefined
    • ajv: Ajv

    Returns boolean

Const evalVisibility

  • evalVisibility(uischema: UISchemaElement, data: any, path?: string, ajv: Ajv): boolean
  • Parameters

    • uischema: UISchemaElement
    • data: any
    • Default value path: string = undefined
    • ajv: Ajv

    Returns boolean

Const evaluateCondition

  • evaluateCondition(data: any, condition: Condition, path: string, ajv: Ajv): boolean
  • Parameters

    • data: any
    • condition: Condition
    • path: string
    • ajv: Ajv

    Returns boolean

Const extractAjv

  • Parameters

    Returns Ajv

Const extractData

  • Parameters

    Returns any

Const extractDefaultData

Const extractRefParserOptions

  • Parameters

    Returns object

    • Optional dereference?: object

      The dereference options control how JSON Schema $Ref Parser will dereference $ref pointers within the JSON schema.

      • Optional circular?: boolean | "ignore"

        Determines whether circular $ref pointers are handled.

        If set to false, then a ReferenceError will be thrown if the schema contains any circular references.

        If set to "ignore", then circular references will simply be ignored. No error will be thrown, but the $Refs.circular property will still be set to true.

    • Optional parse?: object

      The parse options determine how different types of files will be parsed.

      JSON Schema $Ref Parser comes with built-in JSON, YAML, plain-text, and binary parsers, any of which you can configure or disable. You can also add your own custom parsers if you want.

      • [key: string]: ParserOptions | boolean | undefined
      • Optional json?: ParserOptions | boolean
      • Optional text?: ParserOptions & object | boolean
      • Optional yaml?: ParserOptions | boolean
    • Optional resolve?: object

      The resolve options control how JSON Schema $Ref Parser will resolve file paths and URLs, and how those files will be read/downloaded.

      JSON Schema $Ref Parser comes with built-in support for HTTP and HTTPS, as well as support for local files (when running in Node.js). You can configure or disable either of these built-in resolvers. You can also add your own custom resolvers if you want.

      • Optional external?: boolean

        Determines whether external $ref pointers will be resolved. If this option is disabled, then external $ref pointers will simply be ignored.

      • Optional file?: Partial<ResolverOptions> | boolean
      • Optional http?: HTTPResolverOptions | boolean

Const extractSchema

Const extractUiSchema

Const fetchLocale

  • Parameters

    Returns string

Const findAllRefs

  • Finds all references inside the given schema.

    Parameters

    • schema: JsonSchema

      The JsonSchema to find the references in

    • Default value result: ReferenceSchemaMap = {}

      The initial result map, default: empty map (this parameter is used for recursion inside the function)

    • Default value resolveTuples: boolean = false

      Whether arrays of tuples should be considered; default: false

    Returns ReferenceSchemaMap

Const findLocalizedSchema

  • findLocalizedSchema(locale: string): (Anonymous function)
  • Parameters

    • locale: string

    Returns (Anonymous function)

Const findLocalizedUISchema

  • findLocalizedUISchema(locale: string): (Anonymous function)
  • Parameters

    • locale: string

    Returns (Anonymous function)

Const findMatchingUISchema

Const findRefs

Const findUISchema

  • Finds a registered UI schema to use, if any.

    Parameters

    • uischemas: JsonFormsUISchemaRegistryEntry[]
    • schema: JsonSchema

      the JSON schema describing the data to be rendered

    • schemaPath: string

      the according schema path

    • path: string

      the instance path

    • Default value fallbackLayoutType: string = "VerticalLayout"

      the type of the layout to use

    • Optional control: ControlElement

      may be checked for embedded inline uischema options

    • Optional rootSchema: JsonSchema

    Returns UISchemaElement

Const formatErrorMessage

  • formatErrorMessage(errors: string[]): string
  • Parameters

    • errors: string[]

    Returns string

Const formatIs

  • formatIs(expectedFormat: string): Tester
  • Only applicable for Controls.

    This function checks whether the given UI schema is of type Control and if so, resolves the sub-schema referenced by the control and checks whether the format of the sub-schema matches the expected one.

    Parameters

    • expectedFormat: string

      the expected format of the resolved sub-schema

    Returns Tester

Const fromScopable

  • fromScopable(scopable: Scopable): string
  • Parameters

    Returns string

Const generateDefaultUISchema

  • Generate a default UI schema.

    Parameters

    • jsonSchema: JsonSchema

      the JSON schema to generated a UI schema for

    • Default value layoutType: string = "VerticalLayout"

      the desired layout type for the root layout of the generated UI schema

    • Default value prefix: string = "#"
    • Default value rootSchema: JsonSchema4 | JsonSchema7 = jsonSchema

    Returns UISchemaElement

Const generateJsonSchema

  • generateJsonSchema(instance: Object, options?: any): JsonSchema4
  • Generate a JSON schema based on the given data and any additional options.

    Parameters

    • instance: Object

      the data to create a JSON schema for

    • Default value options: any = {}

      any additional options that may alter the generated JSON schema

    Returns JsonSchema4

    the generated schema

Const generateUISchema

Const getAjv

  • Parameters

    Returns Ajv

Const getCells

Const getConditionScope

  • getConditionScope(condition: Scopable, path: string): string
  • Parameters

    Returns string

Const getConfig

  • Parameters

    Returns any

Const getData

  • Parameters

    Returns any

Const getDefaultData

Const getErrorAt

  • getErrorAt(instancePath: string, schema: JsonSchema): (Anonymous function)
  • Parameters

    Returns (Anonymous function)

Const getErrorsAt

  • getErrorsAt(instancePath: string, schema: JsonSchema, matchPath: function): (Anonymous function)
  • Parameters

    • instancePath: string
    • schema: JsonSchema
    • matchPath: function
        • (path: string): boolean
        • Parameters

          • path: string

          Returns boolean

    Returns (Anonymous function)

Const getExtraRefKeys

  • getExtraRefKeys(ref: any): string[]
  • Parameters

    • ref: any

    Returns string[]

Const getLocale

  • Parameters

    Returns string

Const getLocalizedSchema

  • getLocalizedSchema(locale: string): (Anonymous function)
  • Parameters

    • locale: string

    Returns (Anonymous function)

Const getLocalizedUISchema

  • getLocalizedUISchema(locale: string): (Anonymous function)
  • Parameters

    • locale: string

    Returns (Anonymous function)

Const getOrCreateAjv

Const getRefDetails

  • getRefDetails(obj: any): any
  • Parameters

    • obj: any

    Returns any

Const getRefParserOptions

  • Parameters

    Returns RefParser.Options

  • Parameters

    Returns RefParser.Options

Const getRefType

  • getRefType(refDetails: any): any
  • Parameters

    • refDetails: any

    Returns any

Const getRenderers

Const getSchema

Const getSubErrorsAt

  • getSubErrorsAt(instancePath: string, schema: JsonSchema): (Anonymous function)
  • Parameters

    Returns (Anonymous function)

Const getUISchemas

Const getUiSchema

Const getValidationMode

Const hasAjvOption

  • hasAjvOption(option: any): option is InitActionOptions
  • Parameters

    • option: any

    Returns option is InitActionOptions

Const hasCategory

  • Parameters

    Returns boolean

Const hasEnableRule

  • Parameters

    Returns boolean

Const hasRefParserOption

  • hasRefParserOption(option: any): option is InitActionOptions
  • Parameters

    • option: any

    Returns option is InitActionOptions

Const hasShowRule

  • Parameters

    Returns boolean

Const hasType

  • hasType(jsonSchema: JsonSchema, expected: string): boolean
  • Parameters

    Returns boolean

Const hasValidationModeOption

  • hasValidationModeOption(option: any): option is InitActionOptions
  • Parameters

    • option: any

    Returns option is InitActionOptions

Const i18nReducer

  • i18nReducer(state?: any, action: any): any
  • Parameters

    • Default value state: any = initState
    • action: any

    Returns any

Const init

Const isAndCondition

  • isAndCondition(condition: Condition): condition is AndCondition
  • Parameters

    Returns condition is AndCondition

Const isArraySchema

  • Parameters

    Returns boolean

Const isCategorization

  • Parameters

    Returns category is Categorization

Const isCategory

  • Parameters

    Returns boolean

Const isCombinator

  • Returns whether the given {@code jsonSchema} is a combinator ({@code oneOf}, {@code anyOf}, {@code allOf}) at the root level

    Parameters

    Returns boolean

Const isControl

  • isControl(uischema: any): uischema is ControlElement
  • Parameters

    • uischema: any

    Returns uischema is ControlElement

Const isDescriptionHidden

  • isDescriptionHidden(visible: boolean, description: string, isFocused: boolean, showUnfocusedDescription: boolean): boolean
  • Whether an element's description should be hidden.

    Parameters

    • visible: boolean

      whether an element is visible

    • description: string

      the element's description

    • isFocused: boolean

      whether the element is focused

    • showUnfocusedDescription: boolean

    Returns boolean

    true, if the description is to be hidden, false otherwise

Const isEnabled

  • isEnabled(uischema: UISchemaElement, data: any, path?: string, ajv: Ajv): boolean
  • Parameters

    • uischema: UISchemaElement
    • data: any
    • Default value path: string = undefined
    • ajv: Ajv

    Returns boolean

Const isGroup

  • isGroup(layout: Layout): layout is GroupLayout
  • Parameters

    Returns layout is GroupLayout

Const isLayout

  • Parameters

    Returns uischema is Layout

Const isLeafCondition

  • isLeafCondition(condition: Condition): condition is LeafCondition
  • Parameters

    Returns condition is LeafCondition

Const isObjectArrayWithNesting

Const isObjectSchema

  • Parameters

    Returns boolean

Const isOrCondition

  • isOrCondition(condition: Condition): condition is OrCondition
  • Parameters

    Returns condition is OrCondition

Const isPlainLabel

  • isPlainLabel(label: string | Labels): label is string
  • Parameters

    Returns label is string

Const isPtr

  • isPtr(ptr: any, throwWithDetails: boolean): boolean
  • Parameters

    • ptr: any
    • throwWithDetails: boolean

    Returns boolean

Const isRefLike

  • isRefLike(obj: any, throwWithDetails: boolean): boolean
  • Parameters

    • obj: any
    • throwWithDetails: boolean

    Returns boolean

Const isRequired

  • Parameters

    Returns boolean

Const isRuleFulfilled

  • isRuleFulfilled(uischema: UISchemaElement, data: any, path: string, ajv: Ajv): boolean
  • Parameters

    Returns boolean

Const isSchemaCondition

  • isSchemaCondition(condition: Condition): condition is SchemaBasedCondition
  • Parameters

    Returns condition is SchemaBasedCondition

Const isUniqueId

  • isUniqueId(idBase: string, iteration: number): boolean
  • Parameters

    • idBase: string
    • iteration: number

    Returns boolean

Const isVisible

  • isVisible(uischema: UISchemaElement, data: any, path?: string, ajv: Ajv): boolean
  • Parameters

    • uischema: UISchemaElement
    • data: any
    • Default value path: string = undefined
    • ajv: Ajv

    Returns boolean

Const iterateSchema

Const labelDescription

  • Parameters

    • text: string
    • show: boolean

    Returns LabelDescription

Const makeId

  • makeId(idBase: string, iteration: number): string
  • Parameters

    • idBase: string
    • iteration: number

    Returns string

Const mapDispatchToArrayControlProps

  • Maps state to dispatch properties of an array control.

    Parameters

    Returns DispatchPropsOfArrayControl

    dispatch props of an array control

Const mapDispatchToControlProps

  • Map dispatch to control props.

    Parameters

    Returns DispatchPropsOfControl

    dispatch props for a control

Const mapStateToAllOfProps

Const mapStateToAnyOfProps

Const mapStateToArrayControlProps

Const mapStateToArrayLayoutProps

Const mapStateToCellProps

Const mapStateToCombinatorRendererProps

Const mapStateToControlProps

Const mapStateToControlWithDetailProps

Const mapStateToDispatchCellProps

Const mapStateToEnumControlProps

Const mapStateToJsonFormsRendererProps

Const mapStateToLayoutProps

Const mapStateToMasterListItemProps

Const mapStateToOneOfEnumControlProps

Const mapStateToOneOfProps

Const move

  • move(array: any[], index: number, delta: number): void
  • Parameters

    • array: any[]
    • index: number
    • delta: number

    Returns void

Const moveDown

  • moveDown(array: any[], toMove: number): void
  • Parameters

    • array: any[]
    • toMove: number

    Returns void

Const moveUp

  • moveUp(array: any[], toMove: number): void
  • Parameters

    • array: any[]
    • toMove: number

    Returns void

Const not

  • Parameters

    Returns Tester

Const optionIs

  • optionIs(optionName: string, optionValue: any): Tester
  • Checks whether the given UI schema has an option with the given name and whether it has the expected value. If no options property is set, returns false.

    Parameters

    • optionName: string

      the name of the option to check

    • optionValue: any

      the expected value of the option

    Returns Tester

Const or

  • A tester that allow composing other testers by || them.

    Parameters

    • Rest ...testers: Tester[]

      the testers to be composed

    Returns Tester

Const parseURI

  • parseURI(uri: string): URIComponents
  • Parameters

    • uri: string

    Returns URIComponents

Const pathToPtr

  • pathToPtr(path: any, hashPrefix: any): string
  • Parameters

    • path: any
    • hashPrefix: any

    Returns string

Const rankWith

  • rankWith(rank: number, tester: Tester): (Anonymous function)
  • Create a ranked tester that will associate a number with a given tester, if the latter returns true.

    Parameters

    • rank: number

      the rank to be returned in case the tester returns true

    • tester: Tester

      a tester

    Returns (Anonymous function)

Const registerCell

Const registerDefaultData

  • registerDefaultData(schemaPath: string, data: any): object
  • Parameters

    • schemaPath: string
    • data: any

    Returns object

    • data: any
    • schemaPath: string
    • type: "jsonforms/ADD_DEFAULT_DATA"

Const registerRenderer

  • registerRenderer(tester: RankedTester, renderer: any): object

Const registerUISchema

Const removeId

  • removeId(id: string): boolean
  • Parameters

    • id: string

    Returns boolean

Const rendererReducer

Const resolveData

  • resolveData(instance: any, dataPath: string): any
  • Parameters

    • instance: any
    • dataPath: string

    Returns any

Const resolveSchema

  • Resolve the given schema path in order to obtain a subschema.

    Parameters

    • schema: JsonSchema

      the root schema from which to start

    • schemaPath: string

      the schema path to be resolved

    • Optional rootSchema: JsonSchema

      the actual root schema

    Returns JsonSchema

    the resolved sub-schema

Const resolveSubSchemas

retrieveResolvableSchema

  • Normalizes the schema and resolves the given ref.

    Parameters

    • full: JsonSchema

      the JSON schema to resolved the reference against

    • reference: string

      the reference to be resolved

    Returns JsonSchema

    the resolved sub-schema

Const reuseAjvForSchema

  • reuseAjvForSchema(ajv: Ajv, schema: JsonSchema): Ajv
  • Parameters

    Returns Ajv

Const sanitizeErrors

  • sanitizeErrors(validator: ValidateFunction, data: any): ErrorObject[]
  • Parameters

    • validator: ValidateFunction
    • data: any

    Returns ErrorObject[]

Const schemaMatches

  • schemaMatches(predicate: function): Tester
  • Only applicable for Controls.

    This function checks whether the given UI schema is of type Control and if so, resolves the sub-schema referenced by the control and applies the given predicate

    Parameters

    • predicate: function

      the predicate that should be applied to the resolved sub-schema

    Returns Tester

Const schemaSubPathMatches

  • schemaSubPathMatches(subPath: string, predicate: function): Tester
  • Parameters

    • subPath: string
    • predicate: function

    Returns Tester

Const schemaTypeIs

  • schemaTypeIs(expectedType: string): Tester
  • Only applicable for Controls.

    This function checks whether the given UI schema is of type Control and if so, resolves the sub-schema referenced by the control and checks whether the type of the sub-schema matches the expected one.

    Parameters

    • expectedType: string

      the expected type of the resolved sub-schema

    Returns Tester

Const scopeEndIs

  • scopeEndIs(expected: string): Tester
  • Only applicable for Controls.

    Checks whether the last segment of the scope matches the expected string.

    Parameters

    • expected: string

      the expected ending of the reference

    Returns Tester

Const scopeEndsWith

  • scopeEndsWith(expected: string): Tester
  • Only applicable for Controls.

    Checks whether the scope of a control ends with the expected string.

    Parameters

    • expected: string

      the expected ending of the reference

    Returns Tester

Const setAjv

  • setAjv(ajv: AJV.Ajv): object
  • Parameters

    • ajv: AJV.Ajv

    Returns object

    • ajv: Ajv
    • type: "jsonforms/SET_AJV"

Const setConfig

  • Parameters

    • config: any

    Returns SetConfigAction

Const setLocale

  • Parameters

    • locale: string

    Returns SetLocaleAction

Const setLocalizedSchemas

Const setLocalizedUISchemas

Const setReadonly

  • Parameters

    Returns void

Const setReadonlyPropertyValue

  • Parameters

    • value: boolean

    Returns IterateCallback

Const setSchema

Const setUISchema

Const setValidationMode

Const subErrorsAt

  • subErrorsAt(instancePath: string, schema: JsonSchema): (Anonymous function)
  • Parameters

    Returns (Anonymous function)

Const toDataPath

  • toDataPath(schemaPath: string): string
  • Remove all schema-specific keywords (e.g. 'properties') from a given path.

    Parameters

    • schemaPath: string

      the schema path to be converted

    Returns string

    the path without schema-specific keywords

Const toDataPathSegments

  • toDataPathSegments(schemaPath: string): string[]
  • Convert a schema path (i.e. JSON pointer) to an array by splitting at the '/' character and removing all schema-specific keywords.

    The returned value can be used to de-reference a root object by folding over it and de-referencing the single segments to obtain a new object.

    Parameters

    • schemaPath: string

      the schema path to be converted

    Returns string[]

    an array containing only non-schema-specific segments

Const traverse

Const uiTypeIs

  • uiTypeIs(expected: string): Tester
  • Checks whether the given UI schema has the expected type.

    Parameters

    • expected: string

      the expected UI schema type

    Returns Tester

Const uischemaRegistryReducer

Const unregisterCell

Const unregisterDefaultData

  • unregisterDefaultData(schemaPath: string): object
  • Parameters

    • schemaPath: string

    Returns object

    • schemaPath: string
    • type: "jsonforms/REMOVE_DEFAULT_DATA"

Const unregisterRenderer

  • unregisterRenderer(tester: RankedTester, renderer: any): object

Const unregisterUISchema

Const unsetReadonly

  • Parameters

    Returns void

Const update

  • Parameters

    • path: string
    • updater: function
        • (existingData: any): any
        • Parameters

          • existingData: any

          Returns any

    Returns UpdateAction

Const updateCore

Const updateErrors

  • Parameters

    • errors: ErrorObject[]

    Returns UpdateErrorsAction

Const validate

  • validate(validator: ValidateFunction, data: any): ErrorObject[]
  • Parameters

    • validator: ValidateFunction
    • data: any

    Returns ErrorObject[]

Const walk

  • walk(ancestors: any, node: any, path: any, fn: any): void
  • Parameters

    • ancestors: any
    • node: any
    • path: any
    • fn: any

    Returns void

Const withIncreasedRank

  • withIncreasedRank(by: number, rankedTester: RankedTester): (Anonymous function)
  • Parameters

    Returns (Anonymous function)

Const wrapInLayoutIfNecessary

  • Wraps the given {@code uiSchema} in a Layout if there is none already.

    Parameters

    • uischema: UISchemaElement

      The ui schema to wrap in a layout.

    • layoutType: string

      The type of the layout to create.

    Returns Layout

    the wrapped uiSchema.

Object literals

Const Draft4

Draft4: object

$schema

$schema: string = "http://json-schema.org/draft-04/schema#"

default

default: object

Type declaration

description

description: string = "Core schema meta-schema"

id

id: string = "http://json-schema.org/draft-04/schema#"

type

type: string = "object"

definitions

definitions: object

positiveInteger

positiveInteger: object

minimum

minimum: number = 0

type

type: string = "integer"

positiveIntegerDefault0

positiveIntegerDefault0: object

allOf

allOf: (object | object)[] = [{ $ref: '#/definitions/positiveInteger' }, { default: 0 }]

schemaArray

schemaArray: object

minItems

minItems: number = 1

type

type: string = "array"

items

items: object

$ref

$ref: string = "#"

simpleTypes

simpleTypes: object

enum

enum: string[] = ['array','boolean','integer','null','number','object','string']

stringArray

stringArray: object

minItems

minItems: number = 1

type

type: string = "array"

uniqueItems

uniqueItems: boolean = true

items

items: object

type

type: string = "string"

dependencies

dependencies: object

exclusiveMaximum

exclusiveMaximum: string[] = ['maximum']

exclusiveMinimum

exclusiveMinimum: string[] = ['minimum']

properties

properties: object

default

default: object

Type declaration

$schema

$schema: object

format

format: string = "uri"

type

type: string = "string"

additionalItems

additionalItems: object

anyOf

anyOf: (object | object)[] = [{ type: 'boolean' }, { $ref: '#' }]

default

default: object

Type declaration

additionalProperties

additionalProperties: object

anyOf

anyOf: (object | object)[] = [{ type: 'boolean' }, { $ref: '#' }]

default

default: object

Type declaration

allOf

allOf: object

$ref

$ref: string = "#/definitions/schemaArray"

anyOf

anyOf: object

$ref

$ref: string = "#/definitions/schemaArray"

definitions

definitions: object

default

default: object

Type declaration

type

type: string = "object"

additionalProperties

additionalProperties: object

$ref

$ref: string = "#"

dependencies

dependencies: object

type

type: string = "object"

additionalProperties

additionalProperties: object

anyOf

anyOf: object[] = [{ $ref: '#' }, { $ref: '#/definitions/stringArray' }]

description

description: object

type

type: string = "string"

enum

enum: object

minItems

minItems: number = 1

type

type: string = "array"

uniqueItems

uniqueItems: boolean = true

exclusiveMaximum

exclusiveMaximum: object

default

default: boolean = false

type

type: string = "boolean"

exclusiveMinimum

exclusiveMinimum: object

default

default: boolean = false

type

type: string = "boolean"

id

id: object

format

format: string = "uri"

type

type: string = "string"

items

items: object

anyOf

anyOf: object[] = [{ $ref: '#' }, { $ref: '#/definitions/schemaArray' }]

default

default: object

Type declaration

maxItems

maxItems: object

$ref

$ref: string = "#/definitions/positiveInteger"

maxLength

maxLength: object

$ref

$ref: string = "#/definitions/positiveInteger"

maxProperties

maxProperties: object

$ref

$ref: string = "#/definitions/positiveInteger"

maximum

maximum: object

type

type: string = "number"

minItems

minItems: object

$ref

$ref: string = "#/definitions/positiveIntegerDefault0"

minLength

minLength: object

$ref

$ref: string = "#/definitions/positiveIntegerDefault0"

minProperties

minProperties: object

$ref

$ref: string = "#/definitions/positiveIntegerDefault0"

minimum

minimum: object

type

type: string = "number"

multipleOf

multipleOf: object

exclusiveMinimum

exclusiveMinimum: boolean = true

minimum

minimum: number = 0

type

type: string = "number"

not

not: object

$ref

$ref: string = "#"

oneOf

oneOf: object

$ref

$ref: string = "#/definitions/schemaArray"

pattern

pattern: object

format

format: string = "regex"

type

type: string = "string"

patternProperties

patternProperties: object

default

default: object

Type declaration

type

type: string = "object"

additionalProperties

additionalProperties: object

$ref

$ref: string = "#"

properties

properties: object

default

default: object

Type declaration

type

type: string = "object"

additionalProperties

additionalProperties: object

$ref

$ref: string = "#"

required

required: object

$ref

$ref: string = "#/definitions/stringArray"

title

title: object

type

type: string = "string"

type

type: object

anyOf

anyOf: (object | object)[] = [{ $ref: '#/definitions/simpleTypes' },{type: 'array',items: { $ref: '#/definitions/simpleTypes' },minItems: 1,uniqueItems: true}]

uniqueItems

uniqueItems: object

default

default: boolean = false

type

type: string = "boolean"

Const Generate

Generate: object

controlElement

controlElement: createControlElement = createControlElement

jsonSchema

jsonSchema: generateJsonSchema = generateJsonSchema

uiSchema

uiSchema: generateDefaultUISchema = generateDefaultUISchema

Const Helpers

Helpers: object

convertToValidClassName

convertToValidClassName: convertToValidClassName

createLabelDescriptionFrom

createLabelDescriptionFrom: createLabelDescriptionFrom

Const Paths

Paths: object

compose

compose: compose = composePaths

fromScopable

fromScopable: fromScopable

Const Resolve

Resolve: object

Convenience wrapper around resolveData and resolveSchema.

data

data: resolveData = resolveData

schema

schema: resolveSchema = resolveSchema

Const Runtime

Runtime: object

isEnabled

  • Parameters

    Returns boolean

isVisible

  • Parameters

    Returns boolean

Const configDefault

configDefault: object

hideRequiredAsterisk

hideRequiredAsterisk: boolean = false

restrict

restrict: boolean = false

showUnfocusedDescription

showUnfocusedDescription: boolean = false

trim

trim: boolean = false

Const controlDefaultProps

controlDefaultProps: object

errors

errors: string[] = [] as string[]

Const initState

initState: object

ajv

ajv: undefined = undefined

data

data: object

Type declaration

errors

errors: undefined[] = []

locale

locale: undefined = undefined

localizedSchemas

localizedSchemas: Map<any, any> = new Map()

localizedUISchemas

localizedUISchemas: Map<any, any> = new Map()

refParserOptions

refParserOptions: undefined = undefined

schema

schema: object

Type declaration

uischema

uischema: undefined = undefined

validationMode

validationMode: "ValidateAndShow" = "ValidateAndShow"

validator

validator: ValidateFunction = alwaysValid

Const jsonFormsReducerConfig

jsonFormsReducerConfig: object

cells

cells: function = cellReducer

Type declaration

    • (state: S | undefined, action: A): S
    • Parameters

      • state: S | undefined
      • action: A

      Returns S

config

config: function = configReducer

Type declaration

    • (state: S | undefined, action: A): S
    • Parameters

      • state: S | undefined
      • action: A

      Returns S

core

core: function = coreReducer

Type declaration

    • (state: S | undefined, action: A): S
    • Parameters

      • state: S | undefined
      • action: A

      Returns S

defaultData

defaultData: function = defaultDataReducer

Type declaration

    • (state: S | undefined, action: A): S
    • Parameters

      • state: S | undefined
      • action: A

      Returns S

i18n

i18n: function = i18nReducer

Type declaration

    • (state: S | undefined, action: A): S
    • Parameters

      • state: S | undefined
      • action: A

      Returns S

renderers

renderers: function = rendererReducer

Type declaration

    • (state: S | undefined, action: A): S
    • Parameters

      • state: S | undefined
      • action: A

      Returns S

uischemas

uischemas: function = uischemaRegistryReducer

Type declaration

    • (state: S | undefined, action: A): S
    • Parameters

      • state: S | undefined
      • action: A

      Returns S

Const layoutDefaultProps

layoutDefaultProps: object

direction

direction: "column" = "column"

enabled

enabled: true = true

path

path: string = ""

visible

visible: true = true

Generated using TypeDoc