@elyx-code/project-logic-tree 0.0.6228 → 0.0.6230
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/definitions/types/index.d.ts +7 -6
- package/dist/index.js +609 -587
- package/dist/index.umd.cjs +44 -44
- package/dist/tree/built-in/built-in-base-entities/endpoint/entity.d.ts +2 -2
- package/dist/tree/state/base.d.ts +1 -1
- package/dist/tree/state/types/state.d.ts +1 -1
- package/dist/tree/utils/index.d.ts +1 -0
- package/dist/tree/utils/values-validations.d.ts +3 -3
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { BaseEntityNames, EntityType, EntityVersion, IBuiltInBaseEntity, IBuiltInBaseEntityTransfer, LiteralValueType } from '../../../../definitions';
|
|
2
|
-
import { BuiltInBaseEntityState, FunctionDeclarationState, IValueValidationResult,
|
|
2
|
+
import { BuiltInBaseEntityState, FunctionDeclarationState, IValueValidationResult, PrimitiveEntityState, ProjectState, PropertyState } from '../../../state';
|
|
3
3
|
import { ActionDescriptorState } from '../../../state/action-descriptor';
|
|
4
4
|
import { EntityError } from '../../../state/error';
|
|
5
5
|
|
|
@@ -7,7 +7,7 @@ export declare enum HTTPStatucCodeValidationErrorCodes {
|
|
|
7
7
|
StatusCodeMustBeNumber = "status-code-must-be-number",
|
|
8
8
|
StatusCodeMustBeBetween100And599 = "status-code-must-be-between-100-and-599"
|
|
9
9
|
}
|
|
10
|
-
export declare function httpStatusCodeValueValidation(self: ActionDescriptorState, value:
|
|
10
|
+
export declare function httpStatusCodeValueValidation(self: ActionDescriptorState, value: LiteralValueType): IValueValidationResult<LiteralValueType, HTTPStatucCodeValidationErrorCodes>;
|
|
11
11
|
export declare class EndpointEntity extends BuiltInBaseEntityState {
|
|
12
12
|
initialData: IBuiltInBaseEntity | IBuiltInBaseEntityTransfer;
|
|
13
13
|
readonly id: BaseEntityNames;
|
|
@@ -147,7 +147,7 @@ export interface IValueValidationResult<T = LiteralValueType, TCode = SharedEnti
|
|
|
147
147
|
errors: EntityError<TCode>[];
|
|
148
148
|
override: T;
|
|
149
149
|
}
|
|
150
|
-
export type ValueValidationCallback<T = LiteralValueType> = (self: EntityWithValueState, value:
|
|
150
|
+
export type ValueValidationCallback<T = LiteralValueType> = (self: EntityWithValueState, value: T) => IValueValidationResult<T>;
|
|
151
151
|
export declare abstract class EntityWithValueClass {
|
|
152
152
|
abstract getDefaultValue(): LiteralValueState | null;
|
|
153
153
|
abstract codeNativeValueValidation: ValueValidationCallback | null;
|
|
@@ -29,7 +29,7 @@ import { LiteralValuePayloadUnion, LiteralValueState } from '../literal-value';
|
|
|
29
29
|
export type VariableState = VariableDeclarationState | VariableInstanceState;
|
|
30
30
|
export type ValueReadingEntityState = VariableState | InputMapState | ReturnDeclarationState;
|
|
31
31
|
export type ValueWritingEntityState = VariableState | ArgumentDeclarationState | OutputMapState;
|
|
32
|
-
export type EntityWithValueState =
|
|
32
|
+
export type EntityWithValueState = ValueWritingEntityState | ValueReadingEntityState | PropertyState | ValueDescriptorState;
|
|
33
33
|
export type EventEntityState = GlobalEventState;
|
|
34
34
|
export type PassThroughCallableEntityState = OperationState | FunctionCallState | ConditionState | SearchState | VariableState | InternalCallState | LoopState;
|
|
35
35
|
export type PassThroughCallableEntityWithOutputsState = OperationState | FunctionCallState | SearchState | VariableState | InternalCallState | LoopState;
|
|
@@ -24,6 +24,7 @@ export * from './uuid';
|
|
|
24
24
|
export * from './variables';
|
|
25
25
|
export * from './shared-data-structure-entity';
|
|
26
26
|
export * from './string';
|
|
27
|
+
export * from './values-validations';
|
|
27
28
|
export declare function flattenCanvasAncestorsUntil(entity: CanvasEntityState, until: CanvasEntityState): {
|
|
28
29
|
list: CanvasEntityState[];
|
|
29
30
|
last: CanvasEntityState | null;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { LiteralValueType } from '../../definitions';
|
|
2
|
-
import { EntityWithValueState, IValueValidationResult
|
|
2
|
+
import { EntityWithValueState, IValueValidationResult } from '../state';
|
|
3
3
|
|
|
4
4
|
export declare enum CommonStringValidationErrorCodes {
|
|
5
5
|
StringValueMustNotHaveSpaces = "string-value-must-not-have-spaces",
|
|
6
6
|
StringValueMustNotHaveDashes = "string-value-must-not-have-dashes"
|
|
7
7
|
}
|
|
8
|
-
export declare function noSpacesValueValidation(self: EntityWithValueState, value:
|
|
9
|
-
export declare function noSpacesOrDashesValueValidation(self: EntityWithValueState, value:
|
|
8
|
+
export declare function noSpacesValueValidation(self: EntityWithValueState, value: LiteralValueType): IValueValidationResult<LiteralValueType, CommonStringValidationErrorCodes>;
|
|
9
|
+
export declare function noSpacesOrDashesValueValidation(self: EntityWithValueState, value: LiteralValueType): IValueValidationResult<LiteralValueType, CommonStringValidationErrorCodes>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@elyx-code/project-logic-tree",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.6230",
|
|
4
4
|
"author": "Sergio Herrero",
|
|
5
5
|
"license": "UNLICENSED",
|
|
6
6
|
"description": "An installable module which contains the type definitions and ephemeral state management for a projects' logic tree data structure",
|