@json-layout/core
Advanced tools
Comparing version 0.34.1 to 0.35.0
{ | ||
"name": "@json-layout/core", | ||
"version": "0.34.1", | ||
"version": "0.35.0", | ||
"description": "Compilation and state management utilities for JSON Layout.", | ||
@@ -5,0 +5,0 @@ "type": "module", |
@@ -88,4 +88,4 @@ // compileStatic is meant to produce a serializable result | ||
const expressionsParams = expression.pure | ||
? ['data', expression.dataAlias, 'options', 'context', 'display', 'layout', 'validates'] | ||
: ['data', expression.dataAlias, 'options', 'context', 'display', 'layout', 'validates', 'rootData', 'parent'] | ||
? ['data', expression.dataAlias, 'options', 'context', 'display', 'layout', 'readOnly', 'summary', 'validates'] | ||
: ['data', expression.dataAlias, 'options', 'context', 'display', 'layout', 'readOnly', 'summary', 'validates', 'rootData', 'parent'] | ||
/* if (expression.type === 'expr-eval') { | ||
@@ -92,0 +92,0 @@ expressions.push(exprEvalParser.parse(expression.expr).toJSFunction(expressionsParams.join(','))) |
@@ -20,2 +20,4 @@ import type ajvModule from 'ajv/dist/2019.js' | ||
layout: BaseCompObject, | ||
readOnly: boolean, | ||
summary: boolean, | ||
validates: Record<string, ValidateFunction>, | ||
@@ -22,0 +24,0 @@ rootData?: unknown, |
@@ -226,5 +226,5 @@ import { isSwitchStruct, childIsCompObject, isCompositeLayout, isFocusableLayout, isItemsLayout, isGetItemsExpression, isGetItemsFetch, isListLayout } from '@json-layout/vocabulary' | ||
if (expression.pure) { | ||
return compiledExpression(data, data, options, options.context, display, layout, validates) | ||
return compiledExpression(data, data, options, options.context, display, layout, options.readOnly, options.summary, validates) | ||
} else { | ||
return compiledExpression(data, data, options, options.context, display, layout, validates, rootData, parentContext) | ||
return compiledExpression(data, data, options, options.context, display, layout, options.readOnly, options.summary, validates, rootData, parentContext) | ||
} | ||
@@ -231,0 +231,0 @@ } catch (err) { |
@@ -11,3 +11,3 @@ import type ajvModule from 'ajv/dist/2019.js'; | ||
} | ||
export type CompiledExpression = (data: any, dataAlias: any, options: StateNodeOptionsBase, context: object, display: Display, layout: BaseCompObject, validates: Record<string, ValidateFunction>, rootData?: unknown, parent?: ParentContextExpression | null) => any; | ||
export type CompiledExpression = (data: any, dataAlias: any, options: StateNodeOptionsBase, context: object, display: Display, layout: BaseCompObject, readOnly: boolean, summary: boolean, validates: Record<string, ValidateFunction>, rootData?: unknown, parent?: ParentContextExpression | null) => any; | ||
export interface CompileOptions { | ||
@@ -14,0 +14,0 @@ ajv: ajvModule.default; |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
177188
3978