@aemforms/af-core 0.22.19 → 0.22.20
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/lib/browser/afb-events.js +151 -0
- package/lib/browser/afb-runtime.js +3620 -0
- package/lib/cjs/index.cjs +8886 -0
- package/lib/{BaseNode.d.ts → esm/BaseNode.d.ts} +10 -69
- package/lib/{BaseNode.js → esm/BaseNode.js} +84 -184
- package/lib/esm/Checkbox.d.ts +79 -0
- package/lib/esm/Checkbox.js +27 -0
- package/lib/{CheckboxGroup.d.ts → esm/CheckboxGroup.d.ts} +2 -14
- package/lib/esm/CheckboxGroup.js +23 -0
- package/lib/{Container.d.ts → esm/Container.d.ts} +12 -59
- package/lib/{Container.js → esm/Container.js} +54 -116
- package/lib/{DateField.d.ts → esm/DateField.d.ts} +1 -1
- package/lib/esm/DateField.js +21 -0
- package/lib/{Field.d.ts → esm/Field.d.ts} +39 -104
- package/lib/{Field.js → esm/Field.js} +142 -208
- package/lib/esm/Fieldset.d.ts +16 -0
- package/lib/esm/Fieldset.js +45 -0
- package/lib/{FileObject.d.ts → esm/FileObject.d.ts} +1 -4
- package/lib/esm/FileObject.js +26 -0
- package/lib/{FileUpload.d.ts → esm/FileUpload.d.ts} +3 -18
- package/lib/esm/FileUpload.js +108 -0
- package/lib/{Form.d.ts → esm/Form.d.ts} +19 -85
- package/lib/esm/Form.js +176 -0
- package/lib/esm/FormInstance.d.ts +13 -0
- package/lib/esm/FormInstance.js +81 -0
- package/lib/esm/FormMetaData.d.ts +7 -0
- package/lib/esm/FormMetaData.js +10 -0
- package/lib/esm/InstanceManager.d.ts +9 -0
- package/lib/esm/InstanceManager.js +31 -0
- package/lib/esm/Node.d.ts +7 -0
- package/lib/esm/Node.js +16 -0
- package/lib/esm/Scriptable.d.ts +17 -0
- package/lib/{Scriptable.js → esm/Scriptable.js} +11 -54
- package/lib/{controller → esm/controller}/EventQueue.d.ts +3 -11
- package/lib/{controller → esm/controller}/EventQueue.js +10 -26
- package/lib/esm/controller/Events.d.ts +85 -0
- package/lib/esm/controller/Events.js +149 -0
- package/lib/{controller → esm/controller}/Logger.d.ts +0 -6
- package/lib/{controller → esm/controller}/Logger.js +5 -11
- package/lib/{data → esm/data}/DataGroup.d.ts +1 -7
- package/lib/{data → esm/data}/DataGroup.js +15 -34
- package/lib/{data → esm/data}/DataValue.d.ts +1 -7
- package/lib/esm/data/DataValue.js +46 -0
- package/lib/{data → esm/data}/EmptyDataValue.d.ts +1 -1
- package/lib/esm/data/EmptyDataValue.js +29 -0
- package/lib/esm/index.d.ts +21 -0
- package/lib/esm/index.js +21 -0
- package/lib/{rules → esm/rules}/FunctionRuntime.d.ts +2 -24
- package/lib/{rules → esm/rules}/FunctionRuntime.js +41 -117
- package/lib/esm/rules/RuleEngine.d.ts +12 -0
- package/lib/esm/rules/RuleEngine.js +47 -0
- package/lib/{types → esm/types}/Json.d.ts +3 -22
- package/lib/esm/types/Json.js +7 -0
- package/lib/esm/types/Model.d.ts +131 -0
- package/lib/esm/types/Model.js +8 -0
- package/lib/esm/types/index.d.ts +2 -0
- package/lib/esm/types/index.js +2 -0
- package/lib/{utils → esm/utils}/DataRefParser.d.ts +2 -5
- package/lib/{utils → esm/utils}/DataRefParser.js +22 -49
- package/lib/{utils → esm/utils}/Fetch.d.ts +0 -6
- package/lib/esm/utils/Fetch.js +61 -0
- package/lib/esm/utils/FormCreationUtils.d.ts +9 -0
- package/lib/esm/utils/FormCreationUtils.js +74 -0
- package/lib/esm/utils/FormUtils.d.ts +12 -0
- package/lib/esm/utils/FormUtils.js +187 -0
- package/lib/esm/utils/JsonUtils.d.ts +11 -0
- package/lib/esm/utils/JsonUtils.js +76 -0
- package/lib/{utils → esm/utils}/LogUtils.d.ts +1 -4
- package/lib/esm/utils/LogUtils.js +6 -0
- package/lib/esm/utils/SchemaUtils.d.ts +3 -0
- package/lib/esm/utils/SchemaUtils.js +71 -0
- package/lib/esm/utils/TranslationUtils.d.ts +11 -0
- package/lib/esm/utils/TranslationUtils.js +115 -0
- package/lib/esm/utils/ValidationUtils.d.ts +19 -0
- package/lib/{utils → esm/utils}/ValidationUtils.js +29 -187
- package/package.json +17 -10
- package/lib/Checkbox.d.ts +0 -88
- package/lib/Checkbox.js +0 -49
- package/lib/CheckboxGroup.js +0 -43
- package/lib/DateField.js +0 -35
- package/lib/Fieldset.d.ts +0 -24
- package/lib/Fieldset.js +0 -74
- package/lib/FileObject.js +0 -39
- package/lib/FileUpload.js +0 -155
- package/lib/Form.js +0 -252
- package/lib/FormInstance.d.ts +0 -38
- package/lib/FormInstance.js +0 -127
- package/lib/FormMetaData.d.ts +0 -11
- package/lib/FormMetaData.js +0 -28
- package/lib/InstanceManager.d.ts +0 -16
- package/lib/InstanceManager.js +0 -53
- package/lib/Node.d.ts +0 -12
- package/lib/Node.js +0 -27
- package/lib/Scriptable.d.ts +0 -31
- package/lib/controller/Controller.d.ts +0 -255
- package/lib/controller/Controller.js +0 -328
- package/lib/controller/index.d.ts +0 -1
- package/lib/controller/index.js +0 -24
- package/lib/data/DataValue.js +0 -56
- package/lib/data/EmptyDataValue.js +0 -46
- package/lib/index.d.ts +0 -28
- package/lib/index.js +0 -63
- package/lib/rules/RuleEngine.d.ts +0 -23
- package/lib/rules/RuleEngine.js +0 -62
- package/lib/types/Json.js +0 -19
- package/lib/types/Model.d.ts +0 -393
- package/lib/types/Model.js +0 -20
- package/lib/types/index.d.ts +0 -2
- package/lib/types/index.js +0 -25
- package/lib/utils/Fetch.js +0 -87
- package/lib/utils/FormCreationUtils.d.ts +0 -11
- package/lib/utils/FormCreationUtils.js +0 -83
- package/lib/utils/FormUtils.d.ts +0 -47
- package/lib/utils/FormUtils.js +0 -257
- package/lib/utils/JsonUtils.d.ts +0 -63
- package/lib/utils/JsonUtils.js +0 -157
- package/lib/utils/LogUtils.js +0 -17
- package/lib/utils/SchemaUtils.d.ts +0 -16
- package/lib/utils/SchemaUtils.js +0 -92
- package/lib/utils/TranslationUtils.d.ts +0 -41
- package/lib/utils/TranslationUtils.js +0 -185
- package/lib/utils/ValidationUtils.d.ts +0 -170
package/lib/FormMetaData.d.ts
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { FormMetaDataModel, MetaDataJson } from './types';
|
|
2
|
-
import Node from './Node';
|
|
3
|
-
/**
|
|
4
|
-
* Defines form metadata which implements {@link FormMetaDataModel | Form MetaData Model}
|
|
5
|
-
*/
|
|
6
|
-
declare class FormMetaData extends Node<MetaDataJson> implements FormMetaDataModel {
|
|
7
|
-
get version(): string;
|
|
8
|
-
get locale(): string;
|
|
9
|
-
get grammar(): string;
|
|
10
|
-
}
|
|
11
|
-
export default FormMetaData;
|
package/lib/FormMetaData.js
DELETED
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/*
|
|
3
|
-
* Copyright 2022 Adobe, Inc.
|
|
4
|
-
*
|
|
5
|
-
* Your access and use of this software is governed by the Adobe Customer Feedback Program Terms and Conditions or other Beta License Agreement signed by your employer and Adobe, Inc.. This software is NOT open source and may not be used without one of the foregoing licenses. Even with a foregoing license, your access and use of this file is limited to the earlier of (a) 180 days, (b) general availability of the product(s) which utilize this software (i.e. AEM Forms), (c) January 1, 2023, (d) Adobe providing notice to you that you may no longer use the software or that your beta trial has otherwise ended.
|
|
6
|
-
*
|
|
7
|
-
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL ADOBE NOR ITS THIRD PARTY PROVIDERS AND PARTNERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
8
|
-
*/
|
|
9
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
10
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
11
|
-
};
|
|
12
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
-
const Node_1 = __importDefault(require("./Node"));
|
|
14
|
-
/**
|
|
15
|
-
* Defines form metadata which implements {@link FormMetaDataModel | Form MetaData Model}
|
|
16
|
-
*/
|
|
17
|
-
class FormMetaData extends Node_1.default {
|
|
18
|
-
get version() {
|
|
19
|
-
return this.getP('version', '');
|
|
20
|
-
}
|
|
21
|
-
get locale() {
|
|
22
|
-
return this.getP('locale', '');
|
|
23
|
-
}
|
|
24
|
-
get grammar() {
|
|
25
|
-
return this.getP('grammar', '');
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
exports.default = FormMetaData;
|
package/lib/InstanceManager.d.ts
DELETED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { Action, FieldJson, FieldModel, FieldsetJson, FieldsetModel } from './types';
|
|
2
|
-
import { Fieldset } from './Fieldset';
|
|
3
|
-
export declare class InstanceManager extends Fieldset implements FieldsetModel {
|
|
4
|
-
get maxOccur(): number;
|
|
5
|
-
set maxOccur(m: number);
|
|
6
|
-
get minOccur(): number;
|
|
7
|
-
/**
|
|
8
|
-
* @private
|
|
9
|
-
*/
|
|
10
|
-
addInstance(action: Action): void;
|
|
11
|
-
/**
|
|
12
|
-
* @private
|
|
13
|
-
*/
|
|
14
|
-
removeInstance(action: Action): void;
|
|
15
|
-
protected _createChild(child: FieldsetJson | FieldJson, options: any): FieldModel | FieldsetModel;
|
|
16
|
-
}
|
package/lib/InstanceManager.js
DELETED
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/*
|
|
3
|
-
* Copyright 2022 Adobe, Inc.
|
|
4
|
-
*
|
|
5
|
-
* Your access and use of this software is governed by the Adobe Customer Feedback Program Terms and Conditions or other Beta License Agreement signed by your employer and Adobe, Inc.. This software is NOT open source and may not be used without one of the foregoing licenses. Even with a foregoing license, your access and use of this file is limited to the earlier of (a) 180 days, (b) general availability of the product(s) which utilize this software (i.e. AEM Forms), (c) January 1, 2023, (d) Adobe providing notice to you that you may no longer use the software or that your beta trial has otherwise ended.
|
|
6
|
-
*
|
|
7
|
-
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL ADOBE NOR ITS THIRD PARTY PROVIDERS AND PARTNERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
8
|
-
*/
|
|
9
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
10
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
11
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
12
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
13
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
14
|
-
};
|
|
15
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
-
exports.InstanceManager = void 0;
|
|
17
|
-
const Fieldset_1 = require("./Fieldset");
|
|
18
|
-
const BaseNode_1 = require("./BaseNode");
|
|
19
|
-
const FormCreationUtils_1 = require("./utils/FormCreationUtils");
|
|
20
|
-
class InstanceManager extends Fieldset_1.Fieldset {
|
|
21
|
-
get maxOccur() {
|
|
22
|
-
return this._jsonModel.maxItems;
|
|
23
|
-
}
|
|
24
|
-
set maxOccur(m) {
|
|
25
|
-
this.maxItems = m;
|
|
26
|
-
}
|
|
27
|
-
get minOccur() {
|
|
28
|
-
return this.minItems;
|
|
29
|
-
}
|
|
30
|
-
/**
|
|
31
|
-
* @private
|
|
32
|
-
*/
|
|
33
|
-
addInstance(action) {
|
|
34
|
-
return this.addItem(action);
|
|
35
|
-
}
|
|
36
|
-
/**
|
|
37
|
-
* @private
|
|
38
|
-
*/
|
|
39
|
-
removeInstance(action) {
|
|
40
|
-
return this.removeItem(action);
|
|
41
|
-
}
|
|
42
|
-
_createChild(child, options) {
|
|
43
|
-
const { parent = this } = options;
|
|
44
|
-
return (0, FormCreationUtils_1.createChild)(child, { form: this.form, parent: parent }, true);
|
|
45
|
-
}
|
|
46
|
-
}
|
|
47
|
-
__decorate([
|
|
48
|
-
(0, BaseNode_1.dependencyTracked)()
|
|
49
|
-
], InstanceManager.prototype, "maxOccur", null);
|
|
50
|
-
__decorate([
|
|
51
|
-
(0, BaseNode_1.dependencyTracked)()
|
|
52
|
-
], InstanceManager.prototype, "minOccur", null);
|
|
53
|
-
exports.InstanceManager = InstanceManager;
|
package/lib/Node.d.ts
DELETED
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Defines generic form object class which any form runtime model (like textbox, checkbox etc)
|
|
3
|
-
* should extend from.
|
|
4
|
-
* @typeparam T type of the node (for example, {@link MetaDataJson | form meta data}
|
|
5
|
-
*/
|
|
6
|
-
declare class Node<T> {
|
|
7
|
-
protected _jsonModel: T;
|
|
8
|
-
constructor(inputModel: T);
|
|
9
|
-
protected getP<S>(key: string, def: S): S;
|
|
10
|
-
get isContainer(): boolean;
|
|
11
|
-
}
|
|
12
|
-
export default Node;
|
package/lib/Node.js
DELETED
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/*
|
|
3
|
-
* Copyright 2022 Adobe, Inc.
|
|
4
|
-
*
|
|
5
|
-
* Your access and use of this software is governed by the Adobe Customer Feedback Program Terms and Conditions or other Beta License Agreement signed by your employer and Adobe, Inc.. This software is NOT open source and may not be used without one of the foregoing licenses. Even with a foregoing license, your access and use of this file is limited to the earlier of (a) 180 days, (b) general availability of the product(s) which utilize this software (i.e. AEM Forms), (c) January 1, 2023, (d) Adobe providing notice to you that you may no longer use the software or that your beta trial has otherwise ended.
|
|
6
|
-
*
|
|
7
|
-
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL ADOBE NOR ITS THIRD PARTY PROVIDERS AND PARTNERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
8
|
-
*/
|
|
9
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
10
|
-
const JsonUtils_1 = require("./utils/JsonUtils");
|
|
11
|
-
/**
|
|
12
|
-
* Defines generic form object class which any form runtime model (like textbox, checkbox etc)
|
|
13
|
-
* should extend from.
|
|
14
|
-
* @typeparam T type of the node (for example, {@link MetaDataJson | form meta data}
|
|
15
|
-
*/
|
|
16
|
-
class Node {
|
|
17
|
-
constructor(inputModel) {
|
|
18
|
-
this._jsonModel = Object.assign({}, inputModel);
|
|
19
|
-
}
|
|
20
|
-
getP(key, def) {
|
|
21
|
-
return (0, JsonUtils_1.getProperty)(this._jsonModel, key, def);
|
|
22
|
-
}
|
|
23
|
-
get isContainer() {
|
|
24
|
-
return false;
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
exports.default = Node;
|
package/lib/Scriptable.d.ts
DELETED
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
import { Action, RulesJson, ScriptableField } from './types';
|
|
2
|
-
import { BaseNode } from './BaseNode';
|
|
3
|
-
/**
|
|
4
|
-
* Defines scriptable aspects (ie rules, events) of form runtime model. Any form runtime object which requires
|
|
5
|
-
* execution of rules/events should extend from this class.
|
|
6
|
-
*/
|
|
7
|
-
declare abstract class Scriptable<T extends RulesJson> extends BaseNode<T> implements ScriptableField {
|
|
8
|
-
private _events;
|
|
9
|
-
private _rules;
|
|
10
|
-
getRules(): import("./types").Items<string>;
|
|
11
|
-
private getCompiledRule;
|
|
12
|
-
private getCompiledEvent;
|
|
13
|
-
private applyUpdates;
|
|
14
|
-
protected executeAllRules(context: any): void;
|
|
15
|
-
private getExpressionScope;
|
|
16
|
-
private executeEvent;
|
|
17
|
-
/**
|
|
18
|
-
* Executes the given rule
|
|
19
|
-
* @param event
|
|
20
|
-
* @param context
|
|
21
|
-
* @private
|
|
22
|
-
*/
|
|
23
|
-
executeRule(event: Action, context: any): void;
|
|
24
|
-
executeExpression(expr: string): any;
|
|
25
|
-
/**
|
|
26
|
-
* Executes the given action
|
|
27
|
-
* @param action {@link Action | event object}
|
|
28
|
-
*/
|
|
29
|
-
executeAction(action: Action): void;
|
|
30
|
-
}
|
|
31
|
-
export default Scriptable;
|
|
@@ -1,255 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Defines all form events
|
|
3
|
-
*/
|
|
4
|
-
import { Action, BaseJson, FieldModel, FieldsetModel, FormModel, ValidationError } from '../types';
|
|
5
|
-
/**
|
|
6
|
-
* Implementation of generic event
|
|
7
|
-
* @private
|
|
8
|
-
*/
|
|
9
|
-
export declare class ActionImpl implements Action {
|
|
10
|
-
private _metadata?;
|
|
11
|
-
protected _type: string;
|
|
12
|
-
private _payload?;
|
|
13
|
-
private _target;
|
|
14
|
-
constructor(payload: any, type: string, _metadata?: any);
|
|
15
|
-
get type(): string;
|
|
16
|
-
get payload(): any;
|
|
17
|
-
get metadata(): any;
|
|
18
|
-
get target(): FormModel | FieldModel | FieldsetModel;
|
|
19
|
-
get isCustomEvent(): boolean;
|
|
20
|
-
protected payloadToJson(): any;
|
|
21
|
-
toJson(): {
|
|
22
|
-
payload: any;
|
|
23
|
-
type: string;
|
|
24
|
-
isCustomEvent: boolean;
|
|
25
|
-
};
|
|
26
|
-
toString(): string;
|
|
27
|
-
}
|
|
28
|
-
/**
|
|
29
|
-
* Payload of change event
|
|
30
|
-
*/
|
|
31
|
-
export declare type ChangePayload = {
|
|
32
|
-
/**
|
|
33
|
-
* List of changes
|
|
34
|
-
*/
|
|
35
|
-
changes: Array<{
|
|
36
|
-
/**
|
|
37
|
-
* Name of the property which has changed
|
|
38
|
-
*/
|
|
39
|
-
propertyName: string;
|
|
40
|
-
/**
|
|
41
|
-
* Previous value of the property changed
|
|
42
|
-
*/
|
|
43
|
-
prevValue?: any;
|
|
44
|
-
/**
|
|
45
|
-
* Current value of the property changed
|
|
46
|
-
*/
|
|
47
|
-
currentValue: any;
|
|
48
|
-
}>;
|
|
49
|
-
};
|
|
50
|
-
/**
|
|
51
|
-
* Implementation of `change` event. The change event is triggered on the field whenever the value of the field is changed
|
|
52
|
-
*/
|
|
53
|
-
export declare class Change extends ActionImpl {
|
|
54
|
-
/**
|
|
55
|
-
* @constructor
|
|
56
|
-
* @param [payload] event payload
|
|
57
|
-
* @param [dispatch] true to trigger the event on all the fields in DFS order starting from the top level form element, false otherwise
|
|
58
|
-
*/
|
|
59
|
-
constructor(payload: ChangePayload, dispatch?: boolean);
|
|
60
|
-
withAdditionalChange(change: Change): Change;
|
|
61
|
-
}
|
|
62
|
-
/**
|
|
63
|
-
* Implementation of `invalid` event. The invalid event is triggered when a Field’s value becomes invalid after a change event or whenever its value property change
|
|
64
|
-
*/
|
|
65
|
-
export declare class Invalid extends ActionImpl {
|
|
66
|
-
/**
|
|
67
|
-
* @constructor
|
|
68
|
-
* @param [payload] event payload
|
|
69
|
-
*/
|
|
70
|
-
constructor(payload?: any);
|
|
71
|
-
}
|
|
72
|
-
/**
|
|
73
|
-
* Implementation of `valid` event. The valid event is triggered whenever the field’s valid state is changed from invalid to valid.
|
|
74
|
-
*/
|
|
75
|
-
export declare class Valid extends ActionImpl {
|
|
76
|
-
/**
|
|
77
|
-
* @constructor
|
|
78
|
-
* @param [payload] event payload
|
|
79
|
-
*/
|
|
80
|
-
constructor(payload?: any);
|
|
81
|
-
}
|
|
82
|
-
/**
|
|
83
|
-
* Implementation of an ExecuteRule event.
|
|
84
|
-
* @private
|
|
85
|
-
*/
|
|
86
|
-
export declare class ExecuteRule extends ActionImpl {
|
|
87
|
-
/**
|
|
88
|
-
* @constructor
|
|
89
|
-
* @param [payload] event payload
|
|
90
|
-
* @param [dispatch] true to trigger the event on all the fields in DFS order starting from the top level form element, false otherwise
|
|
91
|
-
*/
|
|
92
|
-
constructor(payload?: any, dispatch?: boolean);
|
|
93
|
-
}
|
|
94
|
-
/**
|
|
95
|
-
* Creates a change event
|
|
96
|
-
* @param propertyName name of the form field property
|
|
97
|
-
* @param currentValue current value
|
|
98
|
-
* @param prevValue previous value
|
|
99
|
-
* @returns {@link Change} change event
|
|
100
|
-
*/
|
|
101
|
-
export declare const propertyChange: (propertyName: string, currentValue: any, prevValue?: any) => Change;
|
|
102
|
-
/**
|
|
103
|
-
* Implementation of `initialize` event. The event is triggered on all the fields when the form initialisation is complete
|
|
104
|
-
*/
|
|
105
|
-
export declare class Initialize extends ActionImpl {
|
|
106
|
-
/**
|
|
107
|
-
* @constructor
|
|
108
|
-
* @param [payload] event payload
|
|
109
|
-
* @param [dispatch] true to trigger the event on all the fields in DFS order starting from the top level form element, false otherwise
|
|
110
|
-
*/
|
|
111
|
-
constructor(payload?: any, dispatch?: boolean);
|
|
112
|
-
}
|
|
113
|
-
/**
|
|
114
|
-
* Implementation of `load` event. The event is when the form initialization is complete
|
|
115
|
-
*/
|
|
116
|
-
export declare class FormLoad extends ActionImpl {
|
|
117
|
-
/**
|
|
118
|
-
* @constructor
|
|
119
|
-
*/
|
|
120
|
-
constructor();
|
|
121
|
-
}
|
|
122
|
-
/**
|
|
123
|
-
* Implementation of `click` event. The event is triggered when user clicks on an element.
|
|
124
|
-
*/
|
|
125
|
-
export declare class Click extends ActionImpl {
|
|
126
|
-
/**
|
|
127
|
-
* @constructor
|
|
128
|
-
* @param [payload] event payload
|
|
129
|
-
* @param [dispatch] true to trigger the event on all the fields in DFS order starting from the top level form element, false otherwise
|
|
130
|
-
*/
|
|
131
|
-
constructor(payload?: any, dispatch?: boolean);
|
|
132
|
-
}
|
|
133
|
-
/**
|
|
134
|
-
* Implementation of `blur` event. The event is triggered when the element loses focus.
|
|
135
|
-
*/
|
|
136
|
-
export declare class Blur extends ActionImpl {
|
|
137
|
-
/**
|
|
138
|
-
* @constructor
|
|
139
|
-
* @param [payload] event payload
|
|
140
|
-
* @param [dispatch] true to trigger the event on all the fields in DFS order starting from the top level form element, false otherwise
|
|
141
|
-
*/
|
|
142
|
-
constructor(payload?: any, dispatch?: boolean);
|
|
143
|
-
}
|
|
144
|
-
/**
|
|
145
|
-
* Implementation of `ValidationComplete` event. The ValidationComplete event is triggered once validation is completed
|
|
146
|
-
* on the form.
|
|
147
|
-
*
|
|
148
|
-
* An example of using this event,
|
|
149
|
-
* ```
|
|
150
|
-
* function onValidationComplete(event) {
|
|
151
|
-
* const x = event.payload[0].id;
|
|
152
|
-
* // do something with the invalid field
|
|
153
|
-
* }
|
|
154
|
-
* ```
|
|
155
|
-
*/
|
|
156
|
-
export declare class ValidationComplete extends ActionImpl {
|
|
157
|
-
/**
|
|
158
|
-
* @constructor
|
|
159
|
-
* @param [payload] event payload (ie) list of {@link ValidationError | validation errors}
|
|
160
|
-
* @param [dispatch] true to trigger the event on all the fields in DFS order starting from the top level form element, false otherwise
|
|
161
|
-
*/
|
|
162
|
-
constructor(payload?: Array<ValidationError>, dispatch?: boolean);
|
|
163
|
-
}
|
|
164
|
-
export declare class Focus extends ActionImpl {
|
|
165
|
-
/**
|
|
166
|
-
* @constructor
|
|
167
|
-
*/
|
|
168
|
-
constructor();
|
|
169
|
-
}
|
|
170
|
-
/**
|
|
171
|
-
* Implementation of `submit` event. The submit event is triggered on the Form.
|
|
172
|
-
* To trigger the submit event, submit function needs to be invoked or one can invoke dispatchEvent API.
|
|
173
|
-
*/
|
|
174
|
-
export declare class Submit extends ActionImpl {
|
|
175
|
-
/**
|
|
176
|
-
* @constructor
|
|
177
|
-
* @param [payload] event payload
|
|
178
|
-
* @param [dispatch] true to trigger the event on all the fields in DFS order starting from the top level form element, false otherwise
|
|
179
|
-
*/
|
|
180
|
-
constructor(payload?: any, dispatch?: boolean);
|
|
181
|
-
}
|
|
182
|
-
/**
|
|
183
|
-
* Implementation of `reset` event. The reset event is triggered on the Form.
|
|
184
|
-
* To trigger the reset event, reset function needs to be invoked or one can invoke dispatchEvent API.
|
|
185
|
-
*/
|
|
186
|
-
export declare class Reset extends ActionImpl {
|
|
187
|
-
/**
|
|
188
|
-
* @constructor
|
|
189
|
-
* @param [payload] event payload
|
|
190
|
-
* @param [dispatch] true to trigger the event on all the fields in DFS order starting from the top level form element, false otherwise
|
|
191
|
-
*/
|
|
192
|
-
constructor(payload?: any, dispatch?: boolean);
|
|
193
|
-
}
|
|
194
|
-
/**
|
|
195
|
-
* Implementation of `fieldChanged` event. The field changed event is triggered on the field which it has changed.
|
|
196
|
-
*/
|
|
197
|
-
export declare class FieldChanged extends ActionImpl {
|
|
198
|
-
constructor(changes: ChangePayload, field: BaseJson);
|
|
199
|
-
}
|
|
200
|
-
/**
|
|
201
|
-
* Implementation of `custom event`.
|
|
202
|
-
*/
|
|
203
|
-
export declare class CustomEvent extends ActionImpl {
|
|
204
|
-
/**
|
|
205
|
-
* @constructor
|
|
206
|
-
* @param [eventName] name of the event
|
|
207
|
-
* @param [payload] event payload
|
|
208
|
-
* @param [dispatch] true to trigger the event on all the fields in DFS order starting from the top level form element, false otherwise
|
|
209
|
-
*/
|
|
210
|
-
constructor(eventName: string, payload?: any, dispatch?: boolean);
|
|
211
|
-
/**
|
|
212
|
-
* Defines if the event is custom
|
|
213
|
-
*/
|
|
214
|
-
get isCustomEvent(): boolean;
|
|
215
|
-
}
|
|
216
|
-
/**
|
|
217
|
-
* Implementation of `addItem` event. The event is triggered on a panel to add a new instance of items inside it.
|
|
218
|
-
*/
|
|
219
|
-
export declare class AddItem extends ActionImpl {
|
|
220
|
-
/**
|
|
221
|
-
* @constructor
|
|
222
|
-
* @param [payload] event payload
|
|
223
|
-
*/
|
|
224
|
-
constructor(payload?: number);
|
|
225
|
-
}
|
|
226
|
-
/**
|
|
227
|
-
* Implementation of `removeItem` event. The event is triggered on a panel to remove an instance of items inside it.
|
|
228
|
-
*/
|
|
229
|
-
export declare class RemoveItem extends ActionImpl {
|
|
230
|
-
/**
|
|
231
|
-
* @constructor
|
|
232
|
-
* @param [payload] event payload
|
|
233
|
-
*/
|
|
234
|
-
constructor(payload?: number);
|
|
235
|
-
}
|
|
236
|
-
/**
|
|
237
|
-
* Implementation of `addInstance` event. The event is triggered on a field to add an instance of it.
|
|
238
|
-
*/
|
|
239
|
-
export declare class AddInstance extends ActionImpl {
|
|
240
|
-
/**
|
|
241
|
-
* @constructor
|
|
242
|
-
* @param [payload] event payload
|
|
243
|
-
*/
|
|
244
|
-
constructor(payload?: number);
|
|
245
|
-
}
|
|
246
|
-
/**
|
|
247
|
-
* Implementation of `removeInstance` event. The event is triggered on a field to remove an instance of it.
|
|
248
|
-
*/
|
|
249
|
-
export declare class RemoveInstance extends ActionImpl {
|
|
250
|
-
/**
|
|
251
|
-
* @constructor
|
|
252
|
-
* @param [payload] event payload
|
|
253
|
-
*/
|
|
254
|
-
constructor(payload?: number);
|
|
255
|
-
}
|