@formio/js 5.1.0-dev.6048.569bfc1 → 5.1.0-dev.6049.6110ca0
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/Changelog.md +99 -310
- package/README.md +7 -0
- package/dist/formio.builder.css +1 -0
- package/dist/formio.builder.min.css +1 -1
- package/dist/formio.form.css +1 -0
- package/dist/formio.form.js +658 -669
- package/dist/formio.form.min.css +1 -1
- package/dist/formio.form.min.js +1 -1
- package/dist/formio.form.min.js.LICENSE.txt +3 -1
- package/dist/formio.full.css +1 -0
- package/dist/formio.full.js +685 -696
- package/dist/formio.full.min.css +1 -1
- package/dist/formio.full.min.js +1 -1
- package/dist/formio.full.min.js.LICENSE.txt +3 -1
- package/dist/formio.js +90 -68
- package/dist/formio.min.js +1 -1
- package/dist/formio.utils.js +103 -81
- package/dist/formio.utils.min.js +1 -1
- package/dist/formio.utils.min.js.LICENSE.txt +3 -1
- package/lib/cjs/Element.d.ts +2 -1
- package/lib/cjs/Element.js +18 -39
- package/lib/cjs/EventEmitter.js +2 -25
- package/lib/cjs/Form.js +2 -25
- package/lib/cjs/PDF.js +1 -1
- package/lib/cjs/PDFBuilder.d.ts +1 -0
- package/lib/cjs/PDFBuilder.js +10 -11
- package/lib/cjs/Webform.d.ts +2 -2
- package/lib/cjs/Webform.js +14 -15
- package/lib/cjs/WebformBuilder.d.ts +2 -1
- package/lib/cjs/WebformBuilder.js +62 -20
- package/lib/cjs/Wizard.d.ts +2 -2
- package/lib/cjs/Wizard.js +40 -26
- package/lib/cjs/WizardBuilder.js +1 -1
- package/lib/cjs/components/_classes/component/Component.d.ts +44 -13
- package/lib/cjs/components/_classes/component/Component.js +156 -95
- package/lib/cjs/components/_classes/component/editForm/Component.edit.conditional.js +1 -1
- package/lib/cjs/components/_classes/component/editForm/Component.edit.data.js +19 -0
- package/lib/cjs/components/_classes/component/editForm/Component.edit.logic.js +1 -1
- package/lib/cjs/components/_classes/component/editForm/utils.js +1 -1
- package/lib/cjs/components/_classes/componentModal/ComponentModal.js +1 -1
- package/lib/cjs/components/_classes/input/Input.js +1 -1
- package/lib/cjs/components/_classes/list/ListComponent.js +3 -3
- package/lib/cjs/components/_classes/nested/NestedComponent.form.js +13 -0
- package/lib/cjs/components/_classes/nested/NestedComponent.js +15 -8
- package/lib/cjs/components/_classes/nestedarray/NestedArrayComponent.js +1 -1
- package/lib/cjs/components/_classes/nesteddata/NestedDataComponent.d.ts +0 -2
- package/lib/cjs/components/_classes/nesteddata/NestedDataComponent.js +1 -12
- package/lib/cjs/components/address/Address.d.ts +8 -0
- package/lib/cjs/components/address/Address.js +32 -9
- package/lib/cjs/components/address/editForm/Address.edit.display.d.ts +4 -0
- package/lib/cjs/components/address/editForm/Address.edit.display.js +1 -0
- package/lib/cjs/components/address/editForm/Address.edit.provider.js +8 -8
- package/lib/cjs/components/alert/Alert.js +1 -1
- package/lib/cjs/components/button/Button.d.ts +1 -1
- package/lib/cjs/components/button/Button.js +7 -11
- package/lib/cjs/components/checkbox/Checkbox.js +1 -1
- package/lib/cjs/components/container/Container.js +1 -1
- package/lib/cjs/components/content/editForm/Content.edit.display.js +8 -0
- package/lib/cjs/components/currency/Currency.js +1 -1
- package/lib/cjs/components/currency/editForm/Currency.edit.display.js +12 -0
- package/lib/cjs/components/datagrid/DataGrid.js +5 -1
- package/lib/cjs/components/datetime/DateTime.d.ts +1 -1
- package/lib/cjs/components/datetime/DateTime.js +15 -13
- package/lib/cjs/components/datetime/editForm/DateTime.edit.validation.d.ts +66 -15
- package/lib/cjs/components/datetime/editForm/DateTime.edit.validation.js +68 -47
- package/lib/cjs/components/day/Day.js +2 -2
- package/lib/cjs/components/day/editForm/Day.edit.display.js +8 -0
- package/lib/cjs/components/editgrid/EditGrid.js +4 -2
- package/lib/cjs/components/editgrid/editForm/EditGrid.edit.display.js +1 -1
- package/lib/cjs/components/email/editForm/Email.edit.display.js +12 -0
- package/lib/cjs/components/fieldset/editForm/Fieldset.edit.display.js +8 -0
- package/lib/cjs/components/file/File.js +6 -2
- package/lib/cjs/components/file/editForm/File.edit.file.d.ts +13 -0
- package/lib/cjs/components/file/editForm/File.edit.file.js +1 -0
- package/lib/cjs/components/form/Form.d.ts +0 -1
- package/lib/cjs/components/form/Form.js +31 -23
- package/lib/cjs/components/form/editForm/Form.edit.form.js +4 -3
- package/lib/cjs/components/hidden/editForm/Hidden.edit.display.js +8 -0
- package/lib/cjs/components/html/editForm/HTML.edit.display.js +8 -0
- package/lib/cjs/components/number/Number.js +1 -1
- package/lib/cjs/components/number/editForm/Number.edit.display.js +12 -0
- package/lib/cjs/components/panel/Panel.js +1 -1
- package/lib/cjs/components/password/editForm/Password.edit.display.js +13 -1
- package/lib/cjs/components/phonenumber/PhoneNumber.form.js +9 -1
- package/lib/cjs/components/radio/Radio.d.ts +8 -0
- package/lib/cjs/components/radio/Radio.js +16 -6
- package/lib/cjs/components/recaptcha/editForm/ReCaptcha.edit.display.js +1 -1
- package/lib/cjs/components/select/Select.d.ts +1 -0
- package/lib/cjs/components/select/Select.js +21 -5
- package/lib/cjs/components/select/editForm/Select.edit.data.d.ts +68 -110
- package/lib/cjs/components/select/editForm/Select.edit.data.js +2 -37
- package/lib/cjs/components/selectboxes/SelectBoxes.d.ts +6 -0
- package/lib/cjs/components/selectboxes/SelectBoxes.js +7 -1
- package/lib/cjs/components/signature/Signature.js +1 -1
- package/lib/cjs/components/survey/Survey.js +2 -2
- package/lib/cjs/components/tabs/editForm/Tabs.edit.display.js +8 -0
- package/lib/cjs/components/tags/Tags.js +1 -1
- package/lib/cjs/components/textarea/TextArea.js +10 -2
- package/lib/cjs/components/textarea/editForm/TextArea.edit.display.js +12 -0
- package/lib/cjs/components/textfield/TextField.js +9 -32
- package/lib/cjs/components/time/Time.js +1 -1
- package/lib/cjs/components/unknown/Unknown.form.d.ts +2 -1
- package/lib/cjs/components/unknown/Unknown.form.js +13 -9
- package/lib/cjs/components/url/editForm/Url.edit.display.js +12 -0
- package/lib/cjs/components/well/editForm/Well.edit.display.js +8 -0
- package/lib/cjs/formio.form.js +5 -5
- package/lib/cjs/providers/storage/uploadAdapter.js +8 -6
- package/lib/cjs/translations/en.d.ts +1 -234
- package/lib/cjs/translations/en.js +4 -2
- package/lib/cjs/utils/Evaluator.d.ts +20 -6
- package/lib/cjs/utils/Evaluator.js +38 -15
- package/lib/cjs/utils/builder.js +5 -5
- package/lib/cjs/utils/conditionOperators/IsEqualTo.js +3 -3
- package/lib/cjs/utils/formUtils.d.ts +2 -2
- package/lib/cjs/utils/index.d.ts +169 -2
- package/lib/cjs/utils/index.js +22 -2
- package/lib/cjs/utils/utils.d.ts +31 -37
- package/lib/cjs/utils/utils.js +80 -135
- package/lib/cjs/widgets/CalendarWidget.d.ts +1 -8
- package/lib/cjs/widgets/CalendarWidget.js +19 -40
- package/lib/mjs/Element.d.ts +2 -1
- package/lib/mjs/Element.js +11 -9
- package/lib/mjs/EventEmitter.js +2 -2
- package/lib/mjs/Form.js +1 -1
- package/lib/mjs/PDF.js +1 -1
- package/lib/mjs/PDFBuilder.d.ts +1 -0
- package/lib/mjs/PDFBuilder.js +9 -10
- package/lib/mjs/Webform.d.ts +2 -2
- package/lib/mjs/Webform.js +12 -13
- package/lib/mjs/WebformBuilder.d.ts +2 -1
- package/lib/mjs/WebformBuilder.js +53 -13
- package/lib/mjs/Wizard.d.ts +2 -2
- package/lib/mjs/Wizard.js +38 -24
- package/lib/mjs/WizardBuilder.js +1 -1
- package/lib/mjs/components/_classes/component/Component.d.ts +44 -13
- package/lib/mjs/components/_classes/component/Component.js +129 -45
- package/lib/mjs/components/_classes/component/editForm/Component.edit.conditional.js +1 -1
- package/lib/mjs/components/_classes/component/editForm/Component.edit.data.js +19 -0
- package/lib/mjs/components/_classes/component/editForm/Component.edit.logic.js +1 -1
- package/lib/mjs/components/_classes/component/editForm/utils.js +1 -1
- package/lib/mjs/components/_classes/componentModal/ComponentModal.js +1 -1
- package/lib/mjs/components/_classes/input/Input.js +1 -1
- package/lib/mjs/components/_classes/list/ListComponent.js +3 -3
- package/lib/mjs/components/_classes/nested/NestedComponent.form.js +13 -0
- package/lib/mjs/components/_classes/nested/NestedComponent.js +15 -8
- package/lib/mjs/components/_classes/nestedarray/NestedArrayComponent.js +1 -1
- package/lib/mjs/components/_classes/nesteddata/NestedDataComponent.d.ts +0 -2
- package/lib/mjs/components/_classes/nesteddata/NestedDataComponent.js +1 -12
- package/lib/mjs/components/address/Address.d.ts +8 -0
- package/lib/mjs/components/address/Address.js +32 -9
- package/lib/mjs/components/address/editForm/Address.edit.display.d.ts +4 -0
- package/lib/mjs/components/address/editForm/Address.edit.display.js +1 -0
- package/lib/mjs/components/address/editForm/Address.edit.provider.js +8 -8
- package/lib/mjs/components/alert/Alert.js +1 -1
- package/lib/mjs/components/button/Button.d.ts +1 -1
- package/lib/mjs/components/button/Button.js +7 -10
- package/lib/mjs/components/checkbox/Checkbox.js +1 -1
- package/lib/mjs/components/container/Container.js +1 -1
- package/lib/mjs/components/content/editForm/Content.edit.display.js +8 -0
- package/lib/mjs/components/currency/Currency.js +1 -1
- package/lib/mjs/components/currency/editForm/Currency.edit.display.js +12 -0
- package/lib/mjs/components/datagrid/DataGrid.js +5 -1
- package/lib/mjs/components/datetime/DateTime.d.ts +1 -1
- package/lib/mjs/components/datetime/DateTime.js +15 -13
- package/lib/mjs/components/datetime/editForm/DateTime.edit.validation.d.ts +66 -15
- package/lib/mjs/components/datetime/editForm/DateTime.edit.validation.js +68 -47
- package/lib/mjs/components/day/Day.js +2 -2
- package/lib/mjs/components/day/editForm/Day.edit.display.js +8 -0
- package/lib/mjs/components/editgrid/EditGrid.js +4 -2
- package/lib/mjs/components/editgrid/editForm/EditGrid.edit.display.js +1 -1
- package/lib/mjs/components/email/editForm/Email.edit.display.js +12 -0
- package/lib/mjs/components/fieldset/editForm/Fieldset.edit.display.js +8 -0
- package/lib/mjs/components/file/File.js +6 -2
- package/lib/mjs/components/file/editForm/File.edit.file.d.ts +13 -0
- package/lib/mjs/components/file/editForm/File.edit.file.js +1 -0
- package/lib/mjs/components/form/Form.d.ts +0 -1
- package/lib/mjs/components/form/Form.js +30 -23
- package/lib/mjs/components/form/editForm/Form.edit.form.js +3 -2
- package/lib/mjs/components/hidden/editForm/Hidden.edit.display.js +8 -0
- package/lib/mjs/components/html/editForm/HTML.edit.display.js +8 -0
- package/lib/mjs/components/number/Number.js +1 -1
- package/lib/mjs/components/number/editForm/Number.edit.display.js +12 -0
- package/lib/mjs/components/panel/Panel.js +1 -1
- package/lib/mjs/components/password/editForm/Password.edit.display.js +13 -1
- package/lib/mjs/components/phonenumber/PhoneNumber.form.js +9 -1
- package/lib/mjs/components/radio/Radio.d.ts +8 -0
- package/lib/mjs/components/radio/Radio.js +16 -6
- package/lib/mjs/components/recaptcha/editForm/ReCaptcha.edit.display.js +1 -1
- package/lib/mjs/components/select/Select.d.ts +1 -0
- package/lib/mjs/components/select/Select.js +21 -5
- package/lib/mjs/components/select/editForm/Select.edit.data.d.ts +68 -110
- package/lib/mjs/components/select/editForm/Select.edit.data.js +2 -37
- package/lib/mjs/components/selectboxes/SelectBoxes.d.ts +6 -0
- package/lib/mjs/components/selectboxes/SelectBoxes.js +7 -1
- package/lib/mjs/components/signature/Signature.js +1 -1
- package/lib/mjs/components/survey/Survey.js +2 -2
- package/lib/mjs/components/tabs/editForm/Tabs.edit.display.js +8 -0
- package/lib/mjs/components/tags/Tags.js +1 -1
- package/lib/mjs/components/textarea/TextArea.js +10 -2
- package/lib/mjs/components/textarea/editForm/TextArea.edit.display.js +12 -0
- package/lib/mjs/components/textfield/TextField.js +3 -3
- package/lib/mjs/components/time/Time.js +1 -1
- package/lib/mjs/components/unknown/Unknown.form.d.ts +2 -1
- package/lib/mjs/components/unknown/Unknown.form.js +13 -9
- package/lib/mjs/components/url/editForm/Url.edit.display.js +12 -0
- package/lib/mjs/components/well/editForm/Well.edit.display.js +8 -0
- package/lib/mjs/formio.form.js +3 -3
- package/lib/mjs/providers/storage/uploadAdapter.js +8 -6
- package/lib/mjs/translations/en.d.ts +1 -234
- package/lib/mjs/translations/en.js +6 -47
- package/lib/mjs/utils/Evaluator.d.ts +20 -6
- package/lib/mjs/utils/Evaluator.js +31 -13
- package/lib/mjs/utils/builder.js +1 -1
- package/lib/mjs/utils/conditionOperators/IsEqualTo.js +1 -1
- package/lib/mjs/utils/formUtils.d.ts +2 -2
- package/lib/mjs/utils/index.d.ts +169 -2
- package/lib/mjs/utils/index.js +18 -1
- package/lib/mjs/utils/utils.d.ts +31 -37
- package/lib/mjs/utils/utils.js +72 -109
- package/lib/mjs/widgets/CalendarWidget.d.ts +1 -8
- package/lib/mjs/widgets/CalendarWidget.js +19 -40
- package/package.json +8 -6
- package/lib/cjs/i18n.d.ts +0 -13
- package/lib/cjs/i18n.js +0 -19
- package/lib/cjs/utils/i18n.d.ts +0 -19
- package/lib/cjs/utils/i18n.js +0 -120
- package/lib/mjs/i18n.d.ts +0 -13
- package/lib/mjs/i18n.js +0 -14
- package/lib/mjs/utils/i18n.d.ts +0 -19
- package/lib/mjs/utils/i18n.js +0 -112
@@ -1,4 +1,4 @@
|
|
1
|
-
import { uniqueName } from '../../utils
|
1
|
+
import { uniqueName } from '../../utils';
|
2
2
|
/**
|
3
3
|
* UploadAdapter for CKEditor https://ckeditor.com/docs/ckeditor5/latest/framework/guides/deep-dive/upload-adapter.html
|
4
4
|
*/
|
@@ -24,7 +24,7 @@ class FormioUploadAdapter {
|
|
24
24
|
null,
|
25
25
|
null
|
26
26
|
];
|
27
|
-
|
27
|
+
this.fileService.uploadFile(...uploadParams, () => this.component.emit('fileUploadingStart')).then((result) => {
|
28
28
|
return this.fileService.downloadFile(result);
|
29
29
|
}).then((result) => {
|
30
30
|
return resolve({
|
@@ -34,7 +34,7 @@ class FormioUploadAdapter {
|
|
34
34
|
console.warn('An Error occured while uploading file', err);
|
35
35
|
reject(err);
|
36
36
|
}).finally(() => {
|
37
|
-
this.component.emit('fileUploadingEnd'
|
37
|
+
this.component.emit('fileUploadingEnd');
|
38
38
|
});
|
39
39
|
}));
|
40
40
|
}
|
@@ -46,9 +46,11 @@ class FormioUploadAdapter {
|
|
46
46
|
}
|
47
47
|
}
|
48
48
|
}
|
49
|
-
const getFormioUploadAdapterPlugin = (fileService, component) =>
|
50
|
-
|
51
|
-
|
49
|
+
const getFormioUploadAdapterPlugin = (fileService, component) => {
|
50
|
+
return function (editor) {
|
51
|
+
editor.plugins.get('FileRepository').createUploadAdapter = (loader) => {
|
52
|
+
return new FormioUploadAdapter(loader, fileService, component);
|
53
|
+
};
|
52
54
|
};
|
53
55
|
};
|
54
56
|
export { getFormioUploadAdapterPlugin };
|
@@ -1,235 +1,2 @@
|
|
1
|
-
declare const _default:
|
2
|
-
unsavedRowsError: string;
|
3
|
-
invalidRowsError: string;
|
4
|
-
invalidRowError: string;
|
5
|
-
invalidOption: string;
|
6
|
-
invalidDay: string;
|
7
|
-
alertMessageWithLabel: string;
|
8
|
-
alertMessage: string;
|
9
|
-
complete: string;
|
10
|
-
error: string;
|
11
|
-
errorListHotkey: string;
|
12
|
-
errorsListNavigationMessage: string;
|
13
|
-
submitError: string;
|
14
|
-
required: string;
|
15
|
-
unique: string;
|
16
|
-
array: string;
|
17
|
-
array_nonempty: string;
|
18
|
-
nonarray: string;
|
19
|
-
select: string;
|
20
|
-
pattern: string;
|
21
|
-
minLength: string;
|
22
|
-
maxLength: string;
|
23
|
-
minWords: string;
|
24
|
-
maxWords: string;
|
25
|
-
min: string;
|
26
|
-
max: string;
|
27
|
-
maxDate: string;
|
28
|
-
minDate: string;
|
29
|
-
maxYear: string;
|
30
|
-
minYear: string;
|
31
|
-
minSelectedCount: string;
|
32
|
-
maxSelectedCount: string;
|
33
|
-
invalid_email: string;
|
34
|
-
invalid_url: string;
|
35
|
-
invalid_regex: string;
|
36
|
-
invalid_date: string;
|
37
|
-
invalid_day: string;
|
38
|
-
invalidValueProperty: string;
|
39
|
-
mask: string;
|
40
|
-
valueIsNotAvailable: string;
|
41
|
-
stripe: string;
|
42
|
-
month: string;
|
43
|
-
day: string;
|
44
|
-
year: string;
|
45
|
-
january: string;
|
46
|
-
february: string;
|
47
|
-
march: string;
|
48
|
-
april: string;
|
49
|
-
may: string;
|
50
|
-
june: string;
|
51
|
-
july: string;
|
52
|
-
august: string;
|
53
|
-
september: string;
|
54
|
-
october: string;
|
55
|
-
november: string;
|
56
|
-
december: string;
|
57
|
-
next: string;
|
58
|
-
previous: string;
|
59
|
-
cancel: string;
|
60
|
-
submit: string;
|
61
|
-
confirmCancel: string;
|
62
|
-
saveDraftInstanceError: string;
|
63
|
-
saveDraftAuthError: string;
|
64
|
-
restoreDraftInstanceError: string;
|
65
|
-
saveDraftError: string;
|
66
|
-
restoreDraftError: string;
|
67
|
-
time: string;
|
68
|
-
cancelButtonAriaLabel: string;
|
69
|
-
previousButtonAriaLabel: string;
|
70
|
-
nextButtonAriaLabel: string;
|
71
|
-
submitButtonAriaLabel: string;
|
72
|
-
reCaptchaTokenValidationError: string;
|
73
|
-
reCaptchaTokenNotSpecifiedError: string;
|
74
|
-
apiKey: string;
|
75
|
-
typeRemaining: string;
|
76
|
-
typeCount: string;
|
77
|
-
requiredDayField: string;
|
78
|
-
requiredDayEmpty: string;
|
79
|
-
requiredMonthField: string;
|
80
|
-
requiredYearField: string;
|
81
|
-
formNotReady: string;
|
82
|
-
noFormElement: string;
|
83
|
-
notUniqueKey: string;
|
84
|
-
newFormSchema: string;
|
85
|
-
missingUrl: string;
|
86
|
-
urlNotAttachedToBtn: string;
|
87
|
-
loadingProjectSettingsError: string;
|
88
|
-
sessionStorageSupportError: string;
|
89
|
-
builderUniqueError: string;
|
90
|
-
pageNotFound: string;
|
91
|
-
noDragInfoError: string;
|
92
|
-
addonSupportTypeError: string;
|
93
|
-
setPathError: string;
|
94
|
-
calculatedPathDeprecation: string;
|
95
|
-
unknownTemplate: string;
|
96
|
-
unknownComponent: string;
|
97
|
-
renderTemplateFunctionDeprecation: string;
|
98
|
-
whenReadyDeprecation: string;
|
99
|
-
loadResourcesError: string;
|
100
|
-
noSelectDataConfiguration: string;
|
101
|
-
indexedDBSupportError: string;
|
102
|
-
caretPositionSavingError: string;
|
103
|
-
iteratableRowsError: string;
|
104
|
-
checkRowDeprecation: string;
|
105
|
-
noOAuthBtn: string;
|
106
|
-
noOAuthConfiguration: string;
|
107
|
-
oAuthErrorsTitle: string;
|
108
|
-
noOAuthFormUrl: string;
|
109
|
-
oAuthStateError: string;
|
110
|
-
componentInvalidRowValidation: string;
|
111
|
-
videoPlayerNotFound: string;
|
112
|
-
synchronizationFailed: string;
|
113
|
-
fileWithDuplicatedNameInProgress: string;
|
114
|
-
fileWithDuplicatedNameLoaded: string;
|
115
|
-
nestedForm: string;
|
116
|
-
noDataProvided: string;
|
117
|
-
subformSubmissionLoadingError: string;
|
118
|
-
noDelimiterSet: string;
|
119
|
-
noSiteKey: string;
|
120
|
-
failedToNormalize: string;
|
121
|
-
failedToCompareItems: string;
|
122
|
-
editorFocusError: string;
|
123
|
-
quillImageUploadFailed: string;
|
124
|
-
noFilesSelected: string;
|
125
|
-
needConfigurationForQuill: string;
|
126
|
-
waitPdfConverting: string;
|
127
|
-
uploading: string;
|
128
|
-
pasteBelow: string;
|
129
|
-
copy: string;
|
130
|
-
move: string;
|
131
|
-
edit: string;
|
132
|
-
editJson: string;
|
133
|
-
remove: string;
|
134
|
-
clickToSetValue: string;
|
135
|
-
words: string;
|
136
|
-
characters: string;
|
137
|
-
addAnother: string;
|
138
|
-
yes: string;
|
139
|
-
no: string;
|
140
|
-
wantToClearData: string;
|
141
|
-
yesDelete: string;
|
142
|
-
waitFileProcessing: string;
|
143
|
-
wrongFileType: string;
|
144
|
-
fileTooSmall: string;
|
145
|
-
fileTooBig: string;
|
146
|
-
noFileService: string;
|
147
|
-
fileProcessingFailed: string;
|
148
|
-
readyForUpload: string;
|
149
|
-
readyForRemovingFromStorage: string;
|
150
|
-
preparingFileToRemove: string;
|
151
|
-
succefullyRemoved: string;
|
152
|
-
succefullyUploaded: string;
|
153
|
-
maxSelectItems: string;
|
154
|
-
minSelectItems: string;
|
155
|
-
clickToSign: string;
|
156
|
-
surveyQuestion: string;
|
157
|
-
surveyQuestionValue: string;
|
158
|
-
success: string;
|
159
|
-
noResultsFound: string;
|
160
|
-
noChoices: string;
|
161
|
-
typeToSearch: string;
|
162
|
-
loading: string;
|
163
|
-
help: string;
|
164
|
-
component: string;
|
165
|
-
save: string;
|
166
|
-
preview: string;
|
167
|
-
dragAndDropComponent: string;
|
168
|
-
searchFields: string;
|
169
|
-
noMatchesFound: string;
|
170
|
-
fileName: string;
|
171
|
-
size: string;
|
172
|
-
type: string;
|
173
|
-
gallery: string;
|
174
|
-
camera: string;
|
175
|
-
dropFilesToAttach: string;
|
176
|
-
useCamera: string;
|
177
|
-
browse: string;
|
178
|
-
takePicture: string;
|
179
|
-
switchToFileUpload: string;
|
180
|
-
completeStatus: string;
|
181
|
-
noStorageSet: string;
|
182
|
-
noFileApiSupport: string;
|
183
|
-
noFormDataSupport: string;
|
184
|
-
noProgressSupport: string;
|
185
|
-
close: string;
|
186
|
-
addResource: string;
|
187
|
-
autocomplete: string;
|
188
|
-
showPreview: string;
|
189
|
-
hidePreview: string;
|
190
|
-
createPage: string;
|
191
|
-
page: string;
|
192
|
-
closeBtnDescription: string;
|
193
|
-
cancelBtnDescription: string;
|
194
|
-
saveBtnDescription: string;
|
195
|
-
addOrRemove: string;
|
196
|
-
anyFileTypesAllowed: string;
|
197
|
-
allowedFileTypes: string;
|
198
|
-
syncing: string;
|
199
|
-
syncNow: string;
|
200
|
-
pressToOpen: string;
|
201
|
-
browseToAttachFileFor: string;
|
202
|
-
or: string;
|
203
|
-
numericOnly: string;
|
204
|
-
uploadPdfFile: string;
|
205
|
-
dropToStart: string;
|
206
|
-
expand: string;
|
207
|
-
collapse: string;
|
208
|
-
add: string;
|
209
|
-
delete: string;
|
210
|
-
revert: string;
|
211
|
-
removeBtnPressToRemove: string;
|
212
|
-
file: string;
|
213
|
-
captureVideo: string;
|
214
|
-
captureAudio: string;
|
215
|
-
captureImage: string;
|
216
|
-
browseFiles: string;
|
217
|
-
noComponentsSetInGrid: string;
|
218
|
-
sortAscending: string;
|
219
|
-
sortDescending: string;
|
220
|
-
filter: string;
|
221
|
-
clear: string;
|
222
|
-
showItemsWithValue: string;
|
223
|
-
gridItemsPerPage: string;
|
224
|
-
gridAllItems: string;
|
225
|
-
recordsSelectedOnPage: string;
|
226
|
-
recordsSelectedInTable: string;
|
227
|
-
gridSelectAll: string;
|
228
|
-
itemsInTable: string;
|
229
|
-
clearSelection: string;
|
230
|
-
editGridRow: string;
|
231
|
-
deleteGridRow: string;
|
232
|
-
selected: string;
|
233
|
-
actions: string;
|
234
|
-
};
|
1
|
+
declare const _default: any;
|
235
2
|
export default _default;
|
@@ -1,6 +1,11 @@
|
|
1
1
|
import bootstrap from '@formio/bootstrap';
|
2
|
+
import { coreEnTranslation } from '@formio/core';
|
3
|
+
import _ from 'lodash';
|
2
4
|
export default {
|
3
5
|
...(bootstrap?.translations?.en || {}),
|
6
|
+
// these keys contain a '-' to strip whitespace in core
|
7
|
+
// which is not handled correctly in the renderer, so we redefine them
|
8
|
+
..._.omit(coreEnTranslation, ['maxDate', 'minDate']),
|
4
9
|
unsavedRowsError: 'Please save all rows before proceeding.',
|
5
10
|
invalidRowsError: 'Please correct invalid rows before proceeding.',
|
6
11
|
invalidRowError: 'Invalid row. Please correct it or delete.',
|
@@ -13,49 +18,9 @@ export default {
|
|
13
18
|
errorListHotkey: 'Press Ctrl + Alt + X to go back to the error list.',
|
14
19
|
errorsListNavigationMessage: 'Click to navigate to the field with following error.',
|
15
20
|
submitError: 'Please check the form and correct all errors before submitting.',
|
16
|
-
required: '{{field}} is required',
|
17
|
-
unique: '{{field}} must be unique',
|
18
|
-
array: '{{field}} must be an array',
|
19
|
-
array_nonempty: '{{field}} must be a non-empty array', // eslint-disable-line camelcase
|
20
|
-
nonarray: '{{field}} must not be an array',
|
21
|
-
select: '{{field}} contains an invalid selection',
|
22
|
-
pattern: '{{field}} does not match the pattern {{pattern}}',
|
23
|
-
minLength: '{{field}} must have at least {{length}} characters.',
|
24
|
-
maxLength: '{{field}} must have no more than {{length}} characters.',
|
25
|
-
minWords: '{{field}} must have at least {{length}} words.',
|
26
|
-
maxWords: '{{field}} must have no more than {{length}} words.',
|
27
|
-
min: '{{field}} cannot be less than {{min}}.',
|
28
|
-
max: '{{field}} cannot be greater than {{max}}.',
|
29
21
|
maxDate: '{{field}} should not contain date after {{maxDate}}',
|
30
22
|
minDate: '{{field}} should not contain date before {{minDate}}',
|
31
|
-
maxYear: '{{field}} should not contain year greater than {{maxYear}}',
|
32
|
-
minYear: '{{field}} should not contain year less than {{minYear}}',
|
33
|
-
minSelectedCount: 'You must select at least {{minCount}} items',
|
34
|
-
maxSelectedCount: 'You may only select up to {{maxCount}} items',
|
35
|
-
invalid_email: '{{field}} must be a valid email.', // eslint-disable-line camelcase
|
36
|
-
invalid_url: '{{field}} must be a valid url.', // eslint-disable-line camelcase
|
37
|
-
invalid_regex: '{{field}} does not match the pattern {{regex}}.', // eslint-disable-line camelcase
|
38
|
-
invalid_date: '{{field}} is not a valid date.', // eslint-disable-line camelcase
|
39
|
-
invalid_day: '{{field}} is not a valid day.', // eslint-disable-line camelcase
|
40
|
-
invalidValueProperty: 'Invalid Value Property',
|
41
|
-
mask: '{{field}} does not match the mask.',
|
42
|
-
valueIsNotAvailable: '{{ field }} is an invalid value.',
|
43
23
|
stripe: '{{stripe}}',
|
44
|
-
month: 'Month',
|
45
|
-
day: 'Day',
|
46
|
-
year: 'Year',
|
47
|
-
january: 'January',
|
48
|
-
february: 'February',
|
49
|
-
march: 'March',
|
50
|
-
april: 'April',
|
51
|
-
may: 'May',
|
52
|
-
june: 'June',
|
53
|
-
july: 'July',
|
54
|
-
august: 'August',
|
55
|
-
september: 'September',
|
56
|
-
october: 'October',
|
57
|
-
november: 'November',
|
58
|
-
december: 'December',
|
59
24
|
next: 'Next',
|
60
25
|
previous: 'Previous',
|
61
26
|
cancel: 'Cancel',
|
@@ -74,12 +39,10 @@ export default {
|
|
74
39
|
reCaptchaTokenValidationError: 'ReCAPTCHA: Token validation error',
|
75
40
|
reCaptchaTokenNotSpecifiedError: 'ReCAPTCHA: Token is not specified in submission',
|
76
41
|
apiKey: 'API Key is not unique: {{key}}',
|
42
|
+
apiKeyNotValid: 'API Key is not valid: {{key}}',
|
77
43
|
typeRemaining: '{{ remaining }} {{ type }} remaining.',
|
78
44
|
typeCount: '{{ count }} {{ type }}',
|
79
|
-
requiredDayField: '{{ field }} is required',
|
80
45
|
requiredDayEmpty: '{{ field }} is required',
|
81
|
-
requiredMonthField: '{{ field }} is required',
|
82
|
-
requiredYearField: '{{ field }} is required',
|
83
46
|
formNotReady: 'Form not ready. Use form.ready promise',
|
84
47
|
noFormElement: 'No DOM element for form.',
|
85
48
|
notUniqueKey: 'API Key is not unique',
|
@@ -139,8 +102,6 @@ export default {
|
|
139
102
|
words: 'words',
|
140
103
|
characters: 'characters',
|
141
104
|
addAnother: 'Add Another',
|
142
|
-
yes: 'Yes',
|
143
|
-
no: 'No',
|
144
105
|
wantToClearData: 'Do you want to clear data?',
|
145
106
|
yesDelete: 'Yes, delete it',
|
146
107
|
waitFileProcessing: 'Processing file. Please wait...',
|
@@ -157,8 +118,6 @@ export default {
|
|
157
118
|
maxSelectItems: 'You may only select up to {{maxCount}} items',
|
158
119
|
minSelectItems: 'You must select at least {{minCount}} items',
|
159
120
|
clickToSign: 'Click to Sign',
|
160
|
-
surveyQuestion: 'Question',
|
161
|
-
surveyQuestionValue: 'Value',
|
162
121
|
success: 'Success',
|
163
122
|
noResultsFound: 'No results found',
|
164
123
|
noChoices: 'No choices to choose from',
|
@@ -1,7 +1,21 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
1
|
+
/**
|
2
|
+
* For backwards compatibility we a standalone interpolate function. This merely calls the
|
3
|
+
* global mutable Evaluator instance's interpolate function.
|
4
|
+
* @param {...any} args - interpolate arguments, typically "rawTemplate", "data", and "options"
|
5
|
+
* @returns {any} the interpolation result.
|
6
|
+
*/
|
7
|
+
export function interpolate(...args: any[]): any;
|
8
|
+
/**
|
9
|
+
* Set the evaluator to use for evaluating expressions.
|
10
|
+
* @param {CoreEvaluator} override - The new evaluator instance to use.
|
11
|
+
* @returns {void}
|
12
|
+
*/
|
13
|
+
export function registerEvaluator(override: CoreEvaluator): void;
|
14
|
+
export class DefaultEvaluator extends CoreEvaluator {
|
15
|
+
cache: {};
|
16
|
+
protectedEval: boolean;
|
17
|
+
template(template: any, hash: any): any;
|
18
|
+
interpolate(rawTemplate: any, data: any, _options: any): any;
|
7
19
|
}
|
20
|
+
export let Evaluator: DefaultEvaluator;
|
21
|
+
import { DefaultEvaluator as CoreEvaluator } from '@formio/core';
|
@@ -1,25 +1,24 @@
|
|
1
1
|
import _ from 'lodash';
|
2
2
|
import stringHash from 'string-hash';
|
3
|
-
import {
|
4
|
-
export class
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
static template(template, hash) {
|
3
|
+
import { DefaultEvaluator as CoreEvaluator } from '@formio/core';
|
4
|
+
export class DefaultEvaluator extends CoreEvaluator {
|
5
|
+
cache = {};
|
6
|
+
protectedEval = false;
|
7
|
+
template(template, hash) {
|
9
8
|
hash = hash || stringHash(template);
|
10
|
-
if (
|
11
|
-
return
|
9
|
+
if (this.cache[hash]) {
|
10
|
+
return this.cache[hash];
|
12
11
|
}
|
13
12
|
try {
|
14
13
|
// Ensure we handle copied templates from the ejs files.
|
15
14
|
template = template.replace(/ctx\./g, '');
|
16
|
-
return (
|
15
|
+
return (this.cache[hash] = _.template(template, this.templateSettings));
|
17
16
|
}
|
18
17
|
catch (err) {
|
19
18
|
console.warn('Error while processing template', err, template);
|
20
19
|
}
|
21
20
|
}
|
22
|
-
|
21
|
+
interpolate(rawTemplate, data, _options) {
|
23
22
|
// Ensure reverse compatability.
|
24
23
|
const options = _.isObject(_options) ? _options : { noeval: _options };
|
25
24
|
if (typeof rawTemplate === 'function') {
|
@@ -33,11 +32,11 @@ export class Evaluator extends CoreEvaluator {
|
|
33
32
|
}
|
34
33
|
rawTemplate = String(rawTemplate);
|
35
34
|
let template;
|
36
|
-
if (
|
37
|
-
return
|
35
|
+
if (this.noeval || options.noeval) {
|
36
|
+
return this.interpolateString(rawTemplate, data, _options);
|
38
37
|
}
|
39
38
|
else {
|
40
|
-
template =
|
39
|
+
template = this.template(rawTemplate);
|
41
40
|
}
|
42
41
|
if (typeof template === 'function') {
|
43
42
|
try {
|
@@ -51,3 +50,22 @@ export class Evaluator extends CoreEvaluator {
|
|
51
50
|
return template;
|
52
51
|
}
|
53
52
|
}
|
53
|
+
export let Evaluator = new DefaultEvaluator();
|
54
|
+
// preserve the standalone interpolate function for backwards compatibility
|
55
|
+
/**
|
56
|
+
* For backwards compatibility we a standalone interpolate function. This merely calls the
|
57
|
+
* global mutable Evaluator instance's interpolate function.
|
58
|
+
* @param {...any} args - interpolate arguments, typically "rawTemplate", "data", and "options"
|
59
|
+
* @returns {any} the interpolation result.
|
60
|
+
*/
|
61
|
+
export function interpolate(...args) {
|
62
|
+
return Evaluator.interpolate(...args);
|
63
|
+
}
|
64
|
+
/**
|
65
|
+
* Set the evaluator to use for evaluating expressions.
|
66
|
+
* @param {CoreEvaluator} override - The new evaluator instance to use.
|
67
|
+
* @returns {void}
|
68
|
+
*/
|
69
|
+
export function registerEvaluator(override) {
|
70
|
+
Evaluator = override;
|
71
|
+
}
|
package/lib/mjs/utils/builder.js
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
import ConditionOperator from './ConditionOperator';
|
2
2
|
import _ from 'lodash';
|
3
|
-
import { compareSelectResourceWithObjectTypeValues, isSelectResourceWithObjectValue } from '../
|
3
|
+
import { compareSelectResourceWithObjectTypeValues, isSelectResourceWithObjectValue } from '../';
|
4
4
|
export default class IsEqualTo extends ConditionOperator {
|
5
5
|
static get operatorKey() {
|
6
6
|
return 'isEqual';
|
@@ -26,8 +26,8 @@ export const getBestMatch: typeof Utils.getBestMatch;
|
|
26
26
|
export const getComponentFromPath: typeof Utils.getComponentFromPath;
|
27
27
|
export const getComponentValue: typeof Utils.getComponentValue;
|
28
28
|
export const findComponents: typeof Utils.findComponents;
|
29
|
-
export const eachComponentDataAsync: (components: Component[], data: DataObject, fn: EachComponentDataAsyncCallback, includeAll?: boolean | undefined, local?: boolean | undefined, parent?:
|
30
|
-
export const eachComponentData: (components: Component[], data: DataObject, fn: EachComponentDataCallback, includeAll?: boolean | undefined, local?: boolean | undefined, parent?:
|
29
|
+
export const eachComponentDataAsync: (components: import("@formio/core").Component[], data: import("@formio/core").DataObject, fn: import("@formio/core").EachComponentDataAsyncCallback, includeAll?: boolean | undefined, local?: boolean | undefined, parent?: import("@formio/core").Component | undefined, parentPaths?: import("@formio/core").ComponentPaths | undefined, noScopeReset?: boolean | undefined) => Promise<void>;
|
30
|
+
export const eachComponentData: (components: import("@formio/core").Component[], data: import("@formio/core").DataObject, fn: import("@formio/core").EachComponentDataCallback, includeAll?: boolean | undefined, local?: boolean | undefined, parent?: import("@formio/core").Component | undefined, parentPaths?: import("@formio/core").ComponentPaths | undefined, noScopeReset?: boolean | undefined) => void;
|
31
31
|
export const getComponentKey: typeof Utils.getComponentKey;
|
32
32
|
export const getContextualRowPath: typeof Utils.getContextualRowPath;
|
33
33
|
export const getContextualRowData: typeof Utils.getContextualRowData;
|
package/lib/mjs/utils/index.d.ts
CHANGED
@@ -1,3 +1,170 @@
|
|
1
|
-
export
|
1
|
+
export * from "./utils";
|
2
|
+
export * from "./formUtils";
|
2
3
|
export default FormioUtils;
|
3
|
-
|
4
|
+
declare const FormioUtils: {
|
5
|
+
Evaluator: import("./Evaluator").DefaultEvaluator;
|
6
|
+
interpolate: typeof interpolate;
|
7
|
+
ConditionOperators: {
|
8
|
+
[x: string]: typeof import("./conditionOperators/IsEqualTo").default | typeof import("./conditionOperators/DateGreaterThan").default;
|
9
|
+
};
|
10
|
+
_: any;
|
11
|
+
moment: typeof moment;
|
12
|
+
flattenComponents: typeof import("@formio/core/lib/utils/formUtil").flattenComponents;
|
13
|
+
guid: typeof import("@formio/core/lib/utils/formUtil").guid;
|
14
|
+
uniqueName: typeof import("@formio/core/lib/utils/formUtil").uniqueName;
|
15
|
+
MODEL_TYPES_OF_KNOWN_COMPONENTS: {
|
16
|
+
nestedArray: string[];
|
17
|
+
nestedDataArray: string[];
|
18
|
+
dataObject: string[];
|
19
|
+
object: string[];
|
20
|
+
map: string[];
|
21
|
+
content: string[];
|
22
|
+
string: string[];
|
23
|
+
number: string[];
|
24
|
+
boolean: string[];
|
25
|
+
none: string[];
|
26
|
+
any: string[];
|
27
|
+
};
|
28
|
+
getModelType: typeof import("@formio/core/lib/utils/formUtil").getModelType;
|
29
|
+
getComponentPath: any;
|
30
|
+
setComponentScope: typeof import("@formio/core/lib/utils/formUtil").setComponentScope;
|
31
|
+
resetComponentScope: typeof import("@formio/core/lib/utils/formUtil").resetComponentScope;
|
32
|
+
isComponentNestedDataType: typeof import("@formio/core/lib/utils/formUtil").isComponentNestedDataType;
|
33
|
+
componentPath: typeof import("@formio/core/lib/utils/formUtil").componentPath;
|
34
|
+
getComponentPaths: typeof import("@formio/core/lib/utils/formUtil").getComponentPaths;
|
35
|
+
componentMatches: typeof import("@formio/core/lib/utils/formUtil").componentMatches;
|
36
|
+
getBestMatch: typeof import("@formio/core/lib/utils/formUtil").getBestMatch;
|
37
|
+
getComponentFromPath: typeof import("@formio/core/lib/utils/formUtil").getComponentFromPath;
|
38
|
+
getComponentValue: typeof import("@formio/core/lib/utils/formUtil").getComponentValue;
|
39
|
+
findComponents: typeof import("@formio/core/lib/utils/formUtil").findComponents;
|
40
|
+
eachComponentDataAsync: (components: import("@formio/core").Component[], data: import("@formio/core").DataObject, fn: import("@formio/core").EachComponentDataAsyncCallback, includeAll?: boolean | undefined, local?: boolean | undefined, parent?: import("@formio/core").Component | undefined, parentPaths?: import("@formio/core").ComponentPaths | undefined, noScopeReset?: boolean | undefined) => Promise<void>;
|
41
|
+
eachComponentData: (components: import("@formio/core").Component[], data: import("@formio/core").DataObject, fn: import("@formio/core").EachComponentDataCallback, includeAll?: boolean | undefined, local?: boolean | undefined, parent?: import("@formio/core").Component | undefined, parentPaths?: import("@formio/core").ComponentPaths | undefined, noScopeReset?: boolean | undefined) => void;
|
42
|
+
getComponentKey: typeof import("@formio/core/lib/utils/formUtil").getComponentKey;
|
43
|
+
getContextualRowPath: typeof import("@formio/core/lib/utils/formUtil").getContextualRowPath;
|
44
|
+
getContextualRowData: typeof import("@formio/core/lib/utils/formUtil").getContextualRowData;
|
45
|
+
componentInfo: typeof import("@formio/core/lib/utils/formUtil").componentInfo;
|
46
|
+
eachComponent: typeof import("@formio/core/lib/utils/formUtil").eachComponent;
|
47
|
+
eachComponentAsync: typeof import("@formio/core/lib/utils/formUtil").eachComponentAsync;
|
48
|
+
getComponentData: typeof import("@formio/core/lib/utils/formUtil").getComponentData;
|
49
|
+
getComponentActualValue: any;
|
50
|
+
isLayoutComponent: typeof import("@formio/core/lib/utils/formUtil").isLayoutComponent;
|
51
|
+
matchComponent: typeof import("@formio/core/lib/utils/formUtil").matchComponent;
|
52
|
+
getComponent: typeof import("@formio/core/lib/utils/formUtil").getComponent;
|
53
|
+
searchComponents: typeof import("@formio/core/lib/utils/formUtil").searchComponents;
|
54
|
+
removeComponent: typeof import("@formio/core/lib/utils/formUtil").removeComponent;
|
55
|
+
hasCondition: typeof import("@formio/core/lib/utils/formUtil").hasCondition;
|
56
|
+
parseFloatExt: typeof import("@formio/core/lib/utils/formUtil").parseFloatExt;
|
57
|
+
formatAsCurrency: typeof import("@formio/core/lib/utils/formUtil").formatAsCurrency;
|
58
|
+
escapeRegExCharacters: typeof import("@formio/core/lib/utils/formUtil").escapeRegExCharacters;
|
59
|
+
getValue: typeof import("@formio/core/lib/utils/formUtil").getValue;
|
60
|
+
getStrings: typeof import("@formio/core/lib/utils/formUtil").getStrings;
|
61
|
+
generateFormChange: typeof import("@formio/core/lib/utils/formUtil").generateFormChange;
|
62
|
+
applyFormChanges: typeof import("@formio/core/lib/utils/formUtil").applyFormChanges;
|
63
|
+
findComponent: typeof import("@formio/core/lib/utils/formUtil").findComponent;
|
64
|
+
getEmptyValue: typeof import("@formio/core/lib/utils/formUtil").getEmptyValue;
|
65
|
+
isComponentDataEmpty: typeof import("@formio/core/lib/utils/formUtil").isComponentDataEmpty;
|
66
|
+
isSelectResourceWithObjectValue: typeof import("@formio/core/lib/utils/formUtil").isSelectResourceWithObjectValue;
|
67
|
+
compareSelectResourceWithObjectTypeValues: typeof import("@formio/core/lib/utils/formUtil").compareSelectResourceWithObjectTypeValues;
|
68
|
+
getItemTemplateKeys: typeof import("@formio/core/lib/utils/formUtil").getItemTemplateKeys;
|
69
|
+
evaluate(func: string | object | Function, args: any, ret: string, interpolate: boolean, options?: import("@formio/core").EvaluatorOptions): any;
|
70
|
+
getRandomComponentId(): string;
|
71
|
+
getPropertyValue(style: CSSStyleDeclaration, prop: string): number;
|
72
|
+
getElementRect(element: HTMLElement): {
|
73
|
+
x: number;
|
74
|
+
y: number;
|
75
|
+
width: number;
|
76
|
+
height: number;
|
77
|
+
};
|
78
|
+
getScriptPlugin(property: string): any;
|
79
|
+
boolValue(value: string | boolean): boolean;
|
80
|
+
isMongoId(text: string): boolean;
|
81
|
+
checkCalculated(component: import("@formio/core").Component, submission: import("@formio/core").Submission, rowData: any): void;
|
82
|
+
checkSimpleConditional(component: any, condition: any, row: any, data: any, instance: any): boolean;
|
83
|
+
checkCustomConditional(component: import("@formio/core").Component, custom: string, row: any, data: any, form: import("@formio/core").Form, variable: string, onError: any, instance: any): any;
|
84
|
+
checkJsonConditional(component: import("@formio/core").Component, json: import("@formio/core").JSONConditional, row: any, data: any, form: import("@formio/core").Form, onError: any): boolean;
|
85
|
+
checkCondition(component: import("@formio/core").Component, row: any, data: any, form: import("@formio/core").Form, instance: any): boolean;
|
86
|
+
checkTrigger(component: import("@formio/core").Component, trigger: any, row: import("@formio/core").DataObject, data: import("@formio/core").DataObject, form: import("@formio/core").Form, instance: any): boolean;
|
87
|
+
setActionProperty(component: import("@formio/core").Component, action: any, result: string, row: import("@formio/core").DataObject, data: import("@formio/core").DataObject, instance: any): import("@formio/core").Component;
|
88
|
+
removeHTML(str: string): string;
|
89
|
+
unescapeHTML(str: string): string;
|
90
|
+
convertStringToHTMLElement(str: string, selector: string): HTMLElement;
|
91
|
+
getDateSetting(date: string | Date): import("dayjs").Dayjs | null;
|
92
|
+
isValidDate(date: string | Date): boolean;
|
93
|
+
currentTimezone(): string;
|
94
|
+
offsetDate(date: Date, timezone: string): {
|
95
|
+
date: Date;
|
96
|
+
abbr: string;
|
97
|
+
};
|
98
|
+
shouldHandleTimezone(timezone: string): boolean;
|
99
|
+
dayjsDate(value: string | Date, format: string, timezone: string, options: object): import("dayjs").Dayjs;
|
100
|
+
formatDate(value: string | Date, format: string, timezone: string, flatPickrInputFormat: string): string;
|
101
|
+
formatOffset(formatFn: Function, date: string | Date, format: string, timezone: string): string;
|
102
|
+
getLocaleDateFormatInfo(locale: Intl.LocalesArgument): object;
|
103
|
+
convertFormatToFlatpickr(format: string): string;
|
104
|
+
convertFormatToDayjs(format: string): string;
|
105
|
+
convertFormatToMask(format: string): string;
|
106
|
+
getInputMask(mask: string, placeholderChar: string): any[];
|
107
|
+
unmaskValue(value: string, mask: string, placeholderChar: string): string;
|
108
|
+
matchInputMask(value: string, inputMask: string): boolean;
|
109
|
+
getNumberSeparators(lang?: string): {
|
110
|
+
delimiter: string;
|
111
|
+
decimalSeparator: string;
|
112
|
+
};
|
113
|
+
getNumberDecimalLimit(component: import("@formio/core").Component, defaultLimit: number): number;
|
114
|
+
getCurrencyAffixes({ currency, decimalLimit, decimalSeparator, lang, }: {
|
115
|
+
currency: string;
|
116
|
+
decimalLimit: number;
|
117
|
+
decimalSeparator: string;
|
118
|
+
lang: string;
|
119
|
+
}): {
|
120
|
+
prefix: string;
|
121
|
+
suffix: string;
|
122
|
+
};
|
123
|
+
fieldData(data: import("@formio/core").DataObject, component: import("@formio/core").Component): any;
|
124
|
+
delay(fn: Function, delay?: number, ...args: any[]): any;
|
125
|
+
iterateKey(key: string): string;
|
126
|
+
uniqueKey(map: Record<string, string>, base: string): string;
|
127
|
+
bootstrapVersion(options: {
|
128
|
+
bootstrap: string;
|
129
|
+
}): number;
|
130
|
+
unfold(e: any): any;
|
131
|
+
withSwitch(a: any, b: any): Functions[];
|
132
|
+
observeOverload(callback: Function, options?: {
|
133
|
+
limit: number;
|
134
|
+
delay: number;
|
135
|
+
}): Function;
|
136
|
+
getContextComponents(context: any, excludeNested: boolean, excludedTypes?: string[]): any[];
|
137
|
+
getContextButtons(context: any): any[];
|
138
|
+
translateHTMLTemplate(template: string, translate: Function): string;
|
139
|
+
sanitize(string: string, options: any): string;
|
140
|
+
fastCloneDeep(obj: any): any;
|
141
|
+
isInputComponent(componentJson: import("@formio/core").Component): boolean;
|
142
|
+
getArrayFromComponentPath(pathStr: string): string[];
|
143
|
+
isChildOf(child: any, parent: any): boolean;
|
144
|
+
getStringFromComponentPath(path: number[]): string;
|
145
|
+
round(number: number, precision: number): string;
|
146
|
+
getIEBrowserVersion(): number | null;
|
147
|
+
getBrowserInfo(): object;
|
148
|
+
getComponentPathWithoutIndicies(path?: string): string;
|
149
|
+
getDataParentComponent(componentInstance: Component): any;
|
150
|
+
isPromise(value: any): boolean;
|
151
|
+
getFocusableElements(element: HTMLElement): NodeList<HTMLElement>;
|
152
|
+
getComponentSavedTypes(fullSchema: import("@formio/core").Component): string[] | null;
|
153
|
+
hasEncodedTimezone(value: string): boolean;
|
154
|
+
firstNonNil: any;
|
155
|
+
componentValueTypes: {
|
156
|
+
number: string;
|
157
|
+
string: string;
|
158
|
+
boolean: string;
|
159
|
+
array: string;
|
160
|
+
object: string;
|
161
|
+
date: string;
|
162
|
+
any: string;
|
163
|
+
};
|
164
|
+
interpolateErrors: (component: Component, errors: FieldError[], interpolateFn: Function) => [];
|
165
|
+
};
|
166
|
+
import { Evaluator } from './Evaluator';
|
167
|
+
import { registerEvaluator } from './Evaluator';
|
168
|
+
import { interpolate } from './Evaluator';
|
169
|
+
import moment from 'moment';
|
170
|
+
export { FormioUtils as Utils, Evaluator, registerEvaluator };
|