@arquimedes.co/eureka-forms 1.9.134 → 2.0.1-test
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/@Types/Form.d.ts +1 -1
- package/dist/@Types/FormStep.d.ts +2 -2
- package/dist/@Types/GenericFormSteps.d.ts +1 -0
- package/dist/App/App.css +6 -0
- package/dist/{App.d.ts → App/App.d.ts} +13 -21
- package/dist/App/App.js +76 -0
- package/dist/App/AppFunctions.d.ts +17 -0
- package/dist/App/AppFunctions.js +210 -0
- package/dist/App/AppHooks.d.ts +10 -0
- package/dist/App/AppHooks.js +235 -0
- package/dist/Contexts/CustomContext.d.ts +11 -0
- package/dist/Contexts/CustomContext.js +6 -0
- package/dist/Contexts/FormContext.d.ts +4 -0
- package/dist/Contexts/FormContext.js +19 -0
- package/dist/Contexts/SectionContext.d.ts +3 -0
- package/dist/Contexts/SectionContext.js +3 -0
- package/dist/Form/ConfirmationDialog/ConfirmationDialog.d.ts +2 -4
- package/dist/Form/ConfirmationDialog/ConfirmationDialog.js +3 -1
- package/dist/Form/Form.d.ts +17 -34
- package/dist/Form/Form.js +73 -124
- package/dist/Form/FormFunctions.d.ts +5 -4
- package/dist/Form/FormFunctions.js +24 -25
- package/dist/Form/FormTypes/ColumnForm/ColumnForm.d.ts +1 -1
- package/dist/Form/FormTypes/ColumnForm/ColumnForm.js +34 -58
- package/dist/Form/FormTypes/ColumnForm/ColumnForm.module.css +0 -4
- package/dist/Form/FormTypes/StepperForm/StepperForm.d.ts +1 -1
- package/dist/Form/FormTypes/StepperForm/StepperForm.js +122 -3
- package/dist/Form/FormTypes/StepperForm/StepperForm.module.css +53 -0
- package/dist/Form/Hooks.d.ts +9 -0
- package/dist/Form/Hooks.js +7 -0
- package/dist/Form/Section/MaterialSection/MaterialSection.d.ts +1 -1
- package/dist/Form/Section/MaterialSection/MaterialSection.js +15 -16
- package/dist/Form/Section/Section.d.ts +2 -34
- package/dist/Form/Section/Section.js +11 -5
- package/dist/Form/Terms/Term/MaterialTerm/MaterialTerm.d.ts +1 -1
- package/dist/Form/Terms/Term/MaterialTerm/MaterialTerm.js +19 -14
- package/dist/Form/Terms/Term/Term.d.ts +1 -8
- package/dist/Form/Terms/Term/Term.js +3 -1
- package/dist/Form/Terms/Terms.d.ts +1 -2
- package/dist/Form/Terms/Terms.js +17 -8
- package/dist/Form/Terms/Terms.module.css +3 -0
- package/dist/FormSteps/@Construction/CBRElementStep/CBRElementStep.d.ts +3 -3
- package/dist/FormSteps/@Construction/CBRElementStep/CBRElementStep.js +49 -38
- package/dist/FormSteps/@Construction/CBRIncidentsStep/CBRIncidentsStep.js +3 -1
- package/dist/FormSteps/@Construction/CBRIncidentsStep/MaterialCBRIncidentsStep/Incident/Incident.d.ts +2 -2
- package/dist/FormSteps/@Construction/CBRIncidentsStep/MaterialCBRIncidentsStep/Incident/Incident.js +11 -5
- package/dist/FormSteps/@Construction/CBRIncidentsStep/MaterialCBRIncidentsStep/MaterialCBRIncidentsStep.js +29 -27
- package/dist/FormSteps/@Construction/CBRIncidentsStep/MaterialCBRIncidentsStep/MaterialCBRIncidentsStep.module.css +0 -6
- package/dist/FormSteps/@Construction/CBRPropertyStep/CBRPropertyStep.js +39 -31
- package/dist/FormSteps/AYFStepMapper.js +42 -43
- package/dist/FormSteps/ApiSelectorStep/ApiSelectorStep.d.ts +1 -1
- package/dist/FormSteps/ApiSelectorStep/ApiSelectorStep.js +4 -14
- package/dist/FormSteps/ApiSelectorStep/MaterialApiSelectorStep/MaterialApiSelectorStep.js +84 -97
- package/dist/FormSteps/ApiSelectorStep/MaterialApiSelectorStep/MaterialApiSelectorStep.module.css +0 -9
- package/dist/FormSteps/CBRStepMapper.js +78 -74
- package/dist/FormSteps/CheckBoxStep/CheckBoxStep.d.ts +1 -1
- package/dist/FormSteps/CheckBoxStep/CheckBoxStep.js +4 -14
- package/dist/FormSteps/CheckBoxStep/MaterialCheckBoxStep/MaterialCheckBoxStep.js +33 -26
- package/dist/FormSteps/CheckBoxStep/MaterialCheckBoxStep/MaterialCheckBoxStep.module.css +17 -0
- package/dist/FormSteps/ClassifierSelectorStep/ClassifierSelectorStep.d.ts +1 -1
- package/dist/FormSteps/ClassifierSelectorStep/ClassifierSelectorStep.js +4 -14
- package/dist/FormSteps/ClassifierSelectorStep/MaterialClassifierSelectorStep/MaterialClassifierSelectorStep.js +34 -27
- package/dist/FormSteps/CollapsibleStep/CollapsibleStep.d.ts +1 -1
- package/dist/FormSteps/CollapsibleStep/CollapsibleStep.js +4 -2
- package/dist/FormSteps/CollapsibleStep/MaterialTitleStep/MaterialCollapsibleStep.js +16 -11
- package/dist/FormSteps/CustomStep.d.ts +22 -0
- package/dist/FormSteps/CustomStep.js +37 -0
- package/dist/FormSteps/DatePickerStep/DatePickerStep.js +3 -1
- package/dist/FormSteps/DatePickerStep/MaterialDatePickerStep/MaterialDatePickerStep.d.ts +1 -1
- package/dist/FormSteps/DatePickerStep/MaterialDatePickerStep/MaterialDatePickerStep.js +26 -14
- package/dist/FormSteps/EntityValueStep/EntityValuePickerStep.d.ts +1 -1
- package/dist/FormSteps/EntityValueStep/EntityValuePickerStep.js +4 -14
- package/dist/FormSteps/EntityValueStep/MaterialEntityValuePickerStep/MaterialEntityValuePickerStep.js +93 -112
- package/dist/FormSteps/EntityValueStep/MaterialEntityValuePickerStep/MaterialEntityValuePickerStep.module.css +0 -9
- package/dist/FormSteps/FileUploadStep/FileUploadStep.js +3 -1
- package/dist/FormSteps/FileUploadStep/MaterialFileUploadStep/FileComponent/FileComponent.d.ts +1 -1
- package/dist/FormSteps/FileUploadStep/MaterialFileUploadStep/FileComponent/FileComponent.js +1 -1
- package/dist/FormSteps/FileUploadStep/MaterialFileUploadStep/FileComponent/FileComponent.module.css +0 -7
- package/dist/FormSteps/FileUploadStep/MaterialFileUploadStep/MaterialFileUploadStep.js +32 -18
- package/dist/FormSteps/FileUploadStep/MaterialFileUploadStep/MaterialFileUploadStep.module.css +0 -7
- package/dist/FormSteps/MapperStep/MapperStep.d.ts +2 -2
- package/dist/FormSteps/MapperStep/MapperStep.js +4 -14
- package/dist/FormSteps/MapperStep/MaterialMapperStep/Element/ListMapperElement/ListMapperElement.d.ts +1 -9
- package/dist/FormSteps/MapperStep/MaterialMapperStep/Element/ListMapperElement/ListMapperElement.js +7 -2
- package/dist/FormSteps/MapperStep/MaterialMapperStep/Element/MapperElement.d.ts +3 -2
- package/dist/FormSteps/MapperStep/MaterialMapperStep/Element/MapperElement.js +18 -10
- package/dist/FormSteps/MapperStep/MaterialMapperStep/Element/PillMapperElement/PillMapperElement.d.ts +1 -9
- package/dist/FormSteps/MapperStep/MaterialMapperStep/Element/PillMapperElement/PillMapperElement.js +7 -2
- package/dist/FormSteps/MapperStep/MaterialMapperStep/MaterialMapperStep.d.ts +1 -1
- package/dist/FormSteps/MapperStep/MaterialMapperStep/MaterialMapperStep.js +44 -228
- package/dist/FormSteps/MapperStep/MaterialMapperStep/MaterialMapperStep.module.css +0 -7
- package/dist/FormSteps/RatingStep/MaterialRatingStep/MaterialRatingStep.js +30 -14
- package/dist/FormSteps/RatingStep/RatingStep.js +3 -1
- package/dist/FormSteps/SelectorStep/MaterialSelectorStep/MaterialSelectorStep.js +36 -26
- package/dist/FormSteps/SelectorStep/SelectorStep.d.ts +1 -1
- package/dist/FormSteps/SelectorStep/SelectorStep.js +4 -14
- package/dist/FormSteps/SeparatorStep/MaterialSeparatorStep/MaterialSeparatorStep.d.ts +1 -1
- package/dist/FormSteps/SeparatorStep/MaterialSeparatorStep/MaterialSeparatorStep.js +3 -1
- package/dist/FormSteps/SeparatorStep/SeparatorStep.d.ts +1 -1
- package/dist/FormSteps/SeparatorStep/SeparatorStep.js +4 -14
- package/dist/FormSteps/SmartSelectStep/MaterialSmartSelectStep/MaterialSmartSelectStep.d.ts +5 -2
- package/dist/FormSteps/SmartSelectStep/MaterialSmartSelectStep/MaterialSmartSelectStep.js +119 -199
- package/dist/FormSteps/SmartSelectStep/SmartSelectStep.d.ts +9 -10
- package/dist/FormSteps/SmartSelectStep/SmartSelectStep.js +3 -1
- package/dist/FormSteps/Step.d.ts +3 -4
- package/dist/FormSteps/Step.js +12 -8
- package/dist/FormSteps/StepFunctions.d.ts +10 -0
- package/dist/FormSteps/StepFunctions.js +156 -1
- package/dist/FormSteps/StepHooks.d.ts +23 -0
- package/dist/FormSteps/StepHooks.js +87 -0
- package/dist/FormSteps/TextAreaStep/MaterialTextAreaStep/MaterialTextAreaEditorStep.d.ts +10 -0
- package/dist/FormSteps/TextAreaStep/MaterialTextAreaStep/MaterialTextAreaEditorStep.js +148 -0
- package/dist/FormSteps/TextAreaStep/MaterialTextAreaStep/MaterialTextAreaStep.d.ts +1 -6
- package/dist/FormSteps/TextAreaStep/MaterialTextAreaStep/MaterialTextAreaStep.js +40 -186
- package/dist/FormSteps/TextAreaStep/MaterialTextAreaStep/MaterialTextAreaStep.module.css +0 -9
- package/dist/FormSteps/TextAreaStep/TextAreaStep.js +8 -2
- package/dist/FormSteps/TextInputStep/MaterialTextInputStep/MaterialTextInputStep.d.ts +1 -1
- package/dist/FormSteps/TextInputStep/MaterialTextInputStep/MaterialTextInputStep.js +43 -42
- package/dist/FormSteps/TextInputStep/TextInputStep.js +3 -1
- package/dist/FormSteps/TitleStep/MaterialTitleStep/MaterialTitleStep.js +11 -6
- package/dist/FormSteps/TitleStep/TitleStep.d.ts +1 -1
- package/dist/FormSteps/TitleStep/TitleStep.js +4 -14
- package/dist/Icons/Construction/LeakIcon.d.ts +2 -2
- package/dist/Icons/Construction/LeakIcon.js +2 -1
- package/dist/Icons/Construction/ProjectIcon.d.ts +2 -2
- package/dist/Icons/Construction/ProjectIcon.js +2 -1
- package/dist/Icons/Construction/PropertyIcon.d.ts +2 -2
- package/dist/Icons/Construction/PropertyIcon.js +2 -1
- package/dist/Icons/Construction/SpaceIcon.d.ts +2 -2
- package/dist/Icons/Construction/SpaceIcon.js +2 -1
- package/dist/Icons/DocumentIcon.d.ts +2 -2
- package/dist/Icons/DocumentIcon.js +2 -1
- package/dist/Icons/Entities/CheckListIcon.d.ts +2 -2
- package/dist/Icons/Entities/CheckListIcon.js +2 -1
- package/dist/Icons/Entities/GenericEntityIcon.d.ts +2 -1
- package/dist/Icons/Entities/GenericEntityIcon.js +1 -1
- package/dist/Icons/Entities/HandshakeIcon.d.ts +2 -1
- package/dist/Icons/Entities/HandshakeIcon.js +1 -1
- package/dist/Icons/Entities/SupplierIcon.d.ts +2 -1
- package/dist/Icons/Entities/SupplierIcon.js +4 -1
- package/dist/{controllers → Services}/FileService.d.ts +1 -1
- package/dist/{controllers → Services}/FileService.js +5 -5
- package/dist/Services/FormService.d.ts +5 -0
- package/dist/Services/FormService.js +59 -0
- package/dist/Services/OrganizationService.d.ts +2 -0
- package/dist/Services/OrganizationService.js +65 -0
- package/dist/Shared/Navbar/Navbar.module.css +8 -0
- package/dist/{shared → Shared}/Rating/Rating.d.ts +1 -1
- package/dist/Shared/Rating/Rating.module.css +18 -0
- package/dist/{shared → Shared}/Rating/Ratings/LikeRating.js +5 -5
- package/dist/{shared → Shared}/Rating/Ratings/SatisfactionRating.js +9 -9
- package/dist/{shared → Shared}/Rating/Ratings/ScaleRating.js +1 -2
- package/dist/{shared → Shared}/RoundedCheckBox/RoundedCheckBox.d.ts +1 -1
- package/dist/{shared → Shared}/RoundedSmartSelect/RoundedSmartSelect.js +4 -4
- package/dist/{shared → Shared}/RoundedTextField/RoundedTextField.d.ts +1 -1
- package/dist/{shared → Shared}/RoundedTextField/RoundedTextField.js +3 -2
- package/dist/Shared/RoundedTextField/RoundedTextField.stories.d.ts +24 -0
- package/dist/Shared/RoundedTextField/RoundedTextField.stories.js +25 -0
- package/dist/States/GlobalStateReducer.d.ts +35 -0
- package/dist/States/GlobalStateReducer.js +34 -0
- package/dist/States/SiteStateReducer.d.ts +63 -0
- package/dist/States/SiteStateReducer.js +110 -0
- package/dist/States/WidthStatsStateReducer.d.ts +11 -0
- package/dist/States/WidthStatsStateReducer.js +64 -0
- package/dist/Utils/DraftFunctions.d.ts +3 -0
- package/dist/Utils/DraftFunctions.js +42 -0
- package/dist/Utils/MaterialProviders.d.ts +6 -0
- package/dist/Utils/MaterialProviders.js +31 -0
- package/dist/Utils/store.d.ts +25 -0
- package/dist/Utils/store.js +52 -0
- package/dist/Widget.js +3 -3
- package/dist/constants/CBRFormStepTypes.d.ts +2 -2
- package/dist/constants/CBRFormStepTypes.js +22 -22
- package/dist/hooks.d.ts +5 -0
- package/dist/hooks.js +7 -0
- package/dist/index.js +1 -1
- package/dist/index.lib.d.ts +1 -1
- package/dist/index.lib.js +1 -1
- package/package.json +63 -44
- package/dist/App.js +0 -472
- package/dist/shared/Navbar/Navbar.module.css +0 -18
- package/dist/shared/Rating/Rating.module.css +0 -32
- package/dist/{App.module.css → App/App.module.css} +0 -0
- package/dist/{shared → Shared}/InputIcon/InputIcon.d.ts +0 -0
- package/dist/{shared → Shared}/InputIcon/InputIcon.js +0 -0
- package/dist/{shared → Shared}/Loader/Loader.d.ts +0 -0
- package/dist/{shared → Shared}/Loader/Loader.js +0 -0
- package/dist/{shared → Shared}/Loader/Loader.module.css +0 -0
- package/dist/{shared → Shared}/Navbar/Navbar.d.ts +0 -0
- package/dist/{shared → Shared}/Navbar/Navbar.js +0 -0
- package/dist/{shared → Shared}/Rating/Rating.js +2 -2
- /package/dist/{shared → Shared}/Rating/Ratings/LikeRating.d.ts +0 -0
- /package/dist/{shared → Shared}/Rating/Ratings/SatisfactionRating.d.ts +0 -0
- /package/dist/{shared → Shared}/Rating/Ratings/ScaleRating.d.ts +0 -0
- /package/dist/{shared → Shared}/RoundedButton/RoundedButton.d.ts +0 -0
- /package/dist/{shared → Shared}/RoundedButton/RoundedButton.js +0 -0
- /package/dist/{shared → Shared}/RoundedCheckBox/RoundedCheckBox.js +0 -0
- /package/dist/{shared → Shared}/RoundedDatePicker/RoundedDatePicker.d.ts +0 -0
- /package/dist/{shared → Shared}/RoundedDatePicker/RoundedDatePicker.js +0 -0
- /package/dist/{shared → Shared}/RoundedSelect/RoundedSelect.d.ts +0 -0
- /package/dist/{shared → Shared}/RoundedSelect/RoundedSelect.js +0 -0
- /package/dist/{shared → Shared}/RoundedSmartSelect/RoundedSmartSelect.d.ts +0 -0
- /package/dist/{AxiosAPI.d.ts → Utils/AxiosAPI.d.ts} +0 -0
- /package/dist/{AxiosAPI.js → Utils/AxiosAPI.js} +0 -0
- /package/dist/{AxiosWidget.d.ts → Utils/AxiosWidget.d.ts} +0 -0
- /package/dist/{AxiosWidget.js → Utils/AxiosWidget.js} +0 -0
- /package/dist/{utils/CbrFunctions.d.ts → Utils/CBRFunctions.d.ts} +0 -0
- /package/dist/{utils/CbrFunctions.js → Utils/CBRFunctions.js} +0 -0
|
@@ -1,7 +1,10 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
+
import { FieldError } from 'react-hook-form';
|
|
2
3
|
import { SmartSelectStepProps } from '../SmartSelectStep';
|
|
3
|
-
|
|
4
|
-
|
|
4
|
+
import { GSmartSelect } from '../../../@Types/GenericFormSteps';
|
|
5
|
+
export declare function SmartSelect<StepType extends GSmartSelect>({ icon, step, value, error, onBlur, editable, onChange, inputRef, getOptions, calcDepError, valueOverwrite, getValueString, changeListener, getValueWarning, getOptionSelected, renderNestedSteps, }: SmartSelectStepProps<StepType> & {
|
|
6
|
+
error: FieldError | undefined;
|
|
7
|
+
onChange: any;
|
|
5
8
|
onBlur: (event: any) => void;
|
|
6
9
|
value: any;
|
|
7
10
|
inputRef: any;
|
|
@@ -56,109 +56,83 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
56
56
|
}
|
|
57
57
|
return t;
|
|
58
58
|
};
|
|
59
|
-
var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
|
|
60
|
-
if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
|
|
61
|
-
if (ar || !(i in from)) {
|
|
62
|
-
if (!ar) ar = Array.prototype.slice.call(from, 0, i);
|
|
63
|
-
ar[i] = from[i];
|
|
64
|
-
}
|
|
65
|
-
}
|
|
66
|
-
return to.concat(ar || Array.prototype.slice.call(from));
|
|
67
|
-
};
|
|
68
59
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
69
60
|
import styles from './MaterialSmartSelectStep.module.css';
|
|
70
|
-
import {
|
|
61
|
+
import { useController, useFormContext } from 'react-hook-form';
|
|
71
62
|
import { calcStepWidth } from '../../StepFunctions';
|
|
72
|
-
import RoundedSmartSelect from '../../../
|
|
73
|
-
import {
|
|
63
|
+
import RoundedSmartSelect from '../../../Shared/RoundedSmartSelect/RoundedSmartSelect';
|
|
64
|
+
import { useCallback, useContext, useEffect, useMemo, useState } from 'react';
|
|
74
65
|
import React from 'react';
|
|
66
|
+
import FormContext from '../../../Contexts/FormContext';
|
|
67
|
+
import { selectBreakPoint, useAppDispatch, useAppSelector, } from '../../../hooks';
|
|
68
|
+
import { focusStep, setEmptyDependency, } from '../../../States/SiteStateReducer';
|
|
69
|
+
import { selectDependencies, useStepDependency } from '../../StepHooks';
|
|
75
70
|
export function SmartSelect(_a) {
|
|
76
71
|
var _this = this;
|
|
77
|
-
var _b, _c, _d, _e;
|
|
78
|
-
var icon = _a.icon, step = _a.step,
|
|
79
|
-
var
|
|
80
|
-
var
|
|
81
|
-
var
|
|
82
|
-
var
|
|
83
|
-
var
|
|
84
|
-
var
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
72
|
+
var _b, _c, _d, _e, _f, _g, _h;
|
|
73
|
+
var icon = _a.icon, step = _a.step, value = _a.value, error = _a.error, onBlur = _a.onBlur, editable = _a.editable, onChange = _a.onChange, inputRef = _a.inputRef, getOptions = _a.getOptions, calcDepError = _a.calcDepError, valueOverwrite = _a.valueOverwrite, getValueString = _a.getValueString, changeListener = _a.changeListener, getValueWarning = _a.getValueWarning, getOptionSelected = _a.getOptionSelected, renderNestedSteps = _a.renderNestedSteps;
|
|
74
|
+
var _j = useAppSelector(function (state) { return state.global; }), postview = _j.postview, formStyle = _j.formStyle, idOrganization = _j.idOrganization;
|
|
75
|
+
var form = useContext(FormContext);
|
|
76
|
+
var currentBreakPoint = useAppSelector(selectBreakPoint);
|
|
77
|
+
var _k = useState(), options = _k[0], setOptions = _k[1];
|
|
78
|
+
var _l = useState(false), loading = _l[0], setLoading = _l[1];
|
|
79
|
+
var _m = useState(true), firstTime = _m[0], setFirstTime = _m[1];
|
|
80
|
+
var _o = useState(false), touched = _o[0], setTouched = _o[1];
|
|
81
|
+
var dispatch = useAppDispatch();
|
|
82
|
+
var dependencyStore = useAppSelector(function (state) { return state.site.dependencies; });
|
|
83
|
+
var _p = useAppSelector(function (state) {
|
|
84
|
+
return selectDependencies(state, step, form);
|
|
85
|
+
}), emptyDep = _p.emptyDep, invalids = _p.invalids;
|
|
86
|
+
var _q = useFormContext(), getValues = _q.getValues, setFocus = _q.setFocus;
|
|
87
|
+
var isEmpty = useAppSelector(function (state) { var _a; return (_a = state.site.dependencies[step.id]) === null || _a === void 0 ? void 0 : _a.empty; });
|
|
88
|
+
var disabled = emptyDep;
|
|
89
|
+
useEffect(function () {
|
|
90
|
+
if (!postview) {
|
|
91
|
+
calcOptions(firstTime);
|
|
92
|
+
if (firstTime)
|
|
93
|
+
setFirstTime(false);
|
|
94
94
|
}
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
var calcInvalidDeps = function () {
|
|
98
|
-
var missingDeps = [];
|
|
99
|
-
for (var _i = 0, _a = calcDependencies(step.id); _i < _a.length; _i++) {
|
|
100
|
-
var idDep = _a[_i];
|
|
101
|
-
var dependency = dependencyStore[idDep];
|
|
102
|
-
if ((dependency === null || dependency === void 0 ? void 0 : dependency.value) === null) {
|
|
103
|
-
missingDeps.push(idDep);
|
|
104
|
-
}
|
|
95
|
+
else if (value && !step.searchable) {
|
|
96
|
+
setOptions([value]);
|
|
105
97
|
}
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
return __generator(this, function (_b) {
|
|
112
|
-
switch (_b.label) {
|
|
98
|
+
}, (_c = (_b = step.dependencies) === null || _b === void 0 ? void 0 : _b.map(function (dep) { var _a; return (_a = dependencyStore[dep]) === null || _a === void 0 ? void 0 : _a.value; })) !== null && _c !== void 0 ? _c : []);
|
|
99
|
+
var calcOptions = function (firstTime) { return __awaiter(_this, void 0, void 0, function () {
|
|
100
|
+
var resp, newValue, empty, error_1;
|
|
101
|
+
return __generator(this, function (_a) {
|
|
102
|
+
switch (_a.label) {
|
|
113
103
|
case 0:
|
|
114
104
|
setOptions(undefined);
|
|
115
|
-
|
|
105
|
+
if (value && !firstTime)
|
|
106
|
+
setLoading(true);
|
|
107
|
+
_a.label = 1;
|
|
116
108
|
case 1:
|
|
117
|
-
|
|
118
|
-
return [4 /*yield*/, (getOptions === null || getOptions === void 0 ? void 0 : getOptions(
|
|
109
|
+
_a.trys.push([1, 3, , 4]);
|
|
110
|
+
return [4 /*yield*/, (getOptions === null || getOptions === void 0 ? void 0 : getOptions(idOrganization, step, dependencyStore))];
|
|
119
111
|
case 2:
|
|
120
|
-
resp =
|
|
121
|
-
if (
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
if (!currentOption) {
|
|
127
|
-
setError('Este campo es obligatorio');
|
|
128
|
-
}
|
|
129
|
-
}
|
|
130
|
-
else {
|
|
131
|
-
invalids = calcInvalidDeps();
|
|
132
|
-
if (invalids.length === 0) {
|
|
133
|
-
setError(undefined);
|
|
134
|
-
}
|
|
135
|
-
}
|
|
136
|
-
if (resp.length === 0) {
|
|
137
|
-
setDependencyStore(function (dependencyStore) {
|
|
138
|
-
var _a;
|
|
139
|
-
return (__assign(__assign({}, dependencyStore), (_a = {}, _a[step.id] = {
|
|
140
|
-
type: step.type,
|
|
141
|
-
value: currentValue,
|
|
142
|
-
empty: true,
|
|
143
|
-
}, _a)));
|
|
144
|
-
});
|
|
145
|
-
}
|
|
146
|
-
else if ((_a = dependencyStore[step.id]) === null || _a === void 0 ? void 0 : _a.empty) {
|
|
147
|
-
setDependencyStore(function (dependencyStore) {
|
|
148
|
-
var _a;
|
|
149
|
-
return (__assign(__assign({}, dependencyStore), (_a = {}, _a[step.id] = {
|
|
150
|
-
type: step.type,
|
|
151
|
-
value: currentValue,
|
|
152
|
-
}, _a)));
|
|
112
|
+
resp = _a.sent();
|
|
113
|
+
if (value) {
|
|
114
|
+
/** If the value is still valid select it */
|
|
115
|
+
if (resp && getValueString(value) !== undefined) {
|
|
116
|
+
newValue = resp.find(function (option) {
|
|
117
|
+
return getValueString(option) === getValueString(value);
|
|
153
118
|
});
|
|
119
|
+
onChange(newValue);
|
|
154
120
|
}
|
|
121
|
+
else
|
|
122
|
+
onChange(null);
|
|
155
123
|
}
|
|
156
|
-
empty = calcDependencies(step.id).find(function (idDep) { var _a; return (_a = dependencyStore[idDep]) === null || _a === void 0 ? void 0 : _a.empty; });
|
|
157
|
-
setDisabled(!!empty);
|
|
158
124
|
setOptions(resp);
|
|
125
|
+
empty = resp === null ? undefined : resp.length === 0;
|
|
126
|
+
/** Tell the dependency store this input is empty or not */
|
|
127
|
+
if (empty !== !!isEmpty) {
|
|
128
|
+
dispatch(setEmptyDependency({
|
|
129
|
+
step: step,
|
|
130
|
+
empty: empty,
|
|
131
|
+
}));
|
|
132
|
+
}
|
|
159
133
|
return [3 /*break*/, 4];
|
|
160
134
|
case 3:
|
|
161
|
-
error_1 =
|
|
135
|
+
error_1 = _a.sent();
|
|
162
136
|
console.error(error_1);
|
|
163
137
|
setOptions(null);
|
|
164
138
|
return [3 /*break*/, 4];
|
|
@@ -168,135 +142,81 @@ export function SmartSelect(_a) {
|
|
|
168
142
|
}
|
|
169
143
|
});
|
|
170
144
|
}); };
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
145
|
+
var warning = useMemo(function () { return getValueWarning === null || getValueWarning === void 0 ? void 0 : getValueWarning(value); }, [value]);
|
|
146
|
+
var onFocus = useCallback(function () {
|
|
147
|
+
if (disabled)
|
|
148
|
+
return;
|
|
149
|
+
if (options === null && !(!editable || postview)) {
|
|
150
|
+
if (!value) {
|
|
151
|
+
if (invalids.length > 0) {
|
|
152
|
+
var depStep = form.steps[invalids[0]];
|
|
153
|
+
if (form.type === 'STEPPER' &&
|
|
154
|
+
step.idSection !== depStep.idSection) {
|
|
155
|
+
dispatch(focusStep({
|
|
156
|
+
step: form.steps[invalids[0]],
|
|
157
|
+
values: getValues(),
|
|
158
|
+
}));
|
|
159
|
+
}
|
|
160
|
+
else {
|
|
161
|
+
setFocus(invalids[0]);
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
else if (value === undefined) {
|
|
181
165
|
setLoading(true);
|
|
182
|
-
setOptions([]);
|
|
183
|
-
onChange(null);
|
|
184
166
|
}
|
|
185
|
-
calcOptions(null);
|
|
186
167
|
}
|
|
187
168
|
}
|
|
188
|
-
|
|
189
|
-
|
|
169
|
+
if (options === undefined && !(!editable || postview)) {
|
|
170
|
+
setLoading(true);
|
|
190
171
|
}
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
!original.label) {
|
|
201
|
-
var newValue = options.find(function (option) { return getValueString(option) === getValueString(original); });
|
|
202
|
-
onChange(newValue);
|
|
172
|
+
if (!touched)
|
|
173
|
+
setTouched(true);
|
|
174
|
+
}, [options, disabled, postview, editable, invalids, touched]);
|
|
175
|
+
var handleUpdate = useCallback(function (value) {
|
|
176
|
+
valueOverwrite ? onChange(valueOverwrite(value)) : onChange(value);
|
|
177
|
+
}, [valueOverwrite, onChange]);
|
|
178
|
+
var errorMsg = useMemo(function () {
|
|
179
|
+
if (invalids.length > 0 && touched) {
|
|
180
|
+
return calcDepError === null || calcDepError === void 0 ? void 0 : calcDepError(invalids.map(function (idDep) { return form.steps[idDep]; }));
|
|
203
181
|
}
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
if (
|
|
209
|
-
|
|
210
|
-
setError(calcDepError === null || calcDepError === void 0 ? void 0 : calcDepError(invalids
|
|
211
|
-
.map(function (idDep) { return form.steps[idDep]; })
|
|
212
|
-
.filter(function (idDep) { return idDep !== undefined; })));
|
|
213
|
-
if (!value) {
|
|
214
|
-
if (invalids.length > 0) {
|
|
215
|
-
setFocus(invalids[0]);
|
|
216
|
-
}
|
|
217
|
-
else {
|
|
218
|
-
setLoading(true);
|
|
219
|
-
}
|
|
220
|
-
}
|
|
182
|
+
else if (value && options) {
|
|
183
|
+
var currentOption = options.find(function (option) {
|
|
184
|
+
return getOptionSelected(option, value);
|
|
185
|
+
});
|
|
186
|
+
if (!currentOption) {
|
|
187
|
+
return 'Este campo es obligatorio';
|
|
221
188
|
}
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
189
|
+
}
|
|
190
|
+
else if (options === null && invalids.length === 0) {
|
|
191
|
+
return 'Error al cargar las opciones';
|
|
192
|
+
}
|
|
193
|
+
return undefined;
|
|
194
|
+
}, [invalids, touched, value, options]);
|
|
226
195
|
return (_jsxs(React.Fragment, { children: [_jsx("div", __assign({ className: styles.container, style: {
|
|
227
|
-
width:
|
|
196
|
+
width: currentBreakPoint <= step.size
|
|
228
197
|
? '100%'
|
|
229
198
|
: calcStepWidth(step.size, form.size),
|
|
230
199
|
minHeight: step.description ||
|
|
231
200
|
(!postview && editable && step.required)
|
|
232
201
|
? '55px'
|
|
233
202
|
: '43px',
|
|
234
|
-
}, onClick:
|
|
235
|
-
if (disabled)
|
|
236
|
-
return;
|
|
237
|
-
if (options === null && !(!editable || postview)) {
|
|
238
|
-
handleMissingDep();
|
|
239
|
-
}
|
|
240
|
-
if (options === undefined && !(!editable || postview)) {
|
|
241
|
-
setLoading(true);
|
|
242
|
-
}
|
|
243
|
-
}, "data-testid": step.id }, { children: _jsx(RoundedSmartSelect, { value: value, onBlur: onBlur, onFocus: function () {
|
|
244
|
-
if (disabled)
|
|
245
|
-
return;
|
|
246
|
-
if (options === null && !(!editable || postview)) {
|
|
247
|
-
handleMissingDep();
|
|
248
|
-
}
|
|
249
|
-
if (options === undefined && !(!editable || postview)) {
|
|
250
|
-
setLoading(true);
|
|
251
|
-
}
|
|
252
|
-
}, disabled: options === null || disabled, hidden: disabled, loading: loading, options: options !== null && options !== void 0 ? options : undefined, inputRef: inputRef, cantEdit: !editable || postview, fullWidth: true, backgroundColor: (_d = formStyle.stepBackgroundColor) !== null && _d !== void 0 ? _d : 'white', label: step.label, required: step.required, height: '31px', changeListener: changeListener, searchable: step.searchable, icon: step.showIcon ? icon : undefined, helperTextColor: formStyle.descriptionTextColor, focusColor: formStyle.primaryColor, outlineColor: formStyle.outlineColor, errorColor: formStyle.errorColor, color: formStyle.textColor, containerMargin: "0px", handleUpdate: function (value) {
|
|
253
|
-
valueOverwrite
|
|
254
|
-
? onChange(valueOverwrite(value))
|
|
255
|
-
: onChange(value);
|
|
256
|
-
setError(undefined);
|
|
257
|
-
}, getOptionSelected: getOptionSelected, getValueString: getValueString, helperText: (_e = error !== null && error !== void 0 ? error : warning) !== null && _e !== void 0 ? _e : (errors[step.id]
|
|
258
|
-
? errors[step.id].message
|
|
259
|
-
: step.description), error: error !== undefined ||
|
|
260
|
-
(warning !== undefined && warning !== null) ||
|
|
261
|
-
!!errors[step.id] }) })), children &&
|
|
262
|
-
cloneElement(children, {
|
|
263
|
-
value: value,
|
|
264
|
-
stepProps: __assign({ step: step, form: form, errors: errors, setFocus: setFocus, postview: postview, editable: editable, formStyle: formStyle, widthStats: widthStats, organization: organization, originalValues: originalValues, dependencyStore: dependencyStore, setDependencyStore: setDependencyStore }, others),
|
|
265
|
-
})] }));
|
|
203
|
+
}, onClick: onFocus, "data-testid": step.id }, { children: _jsx(RoundedSmartSelect, { value: value, onBlur: onBlur, onFocus: onFocus, disabled: options === null || disabled, hidden: disabled, loading: loading, options: options !== null && options !== void 0 ? options : undefined, inputRef: inputRef, cantEdit: !editable || postview, fullWidth: true, backgroundColor: (_d = formStyle.stepBackgroundColor) !== null && _d !== void 0 ? _d : 'white', label: step.label, required: step.required, height: '31px', changeListener: changeListener, searchable: step.searchable, icon: step.showIcon ? icon : undefined, helperTextColor: formStyle.descriptionTextColor, focusColor: formStyle.primaryColor, outlineColor: formStyle.outlineColor, errorColor: formStyle.errorColor, color: formStyle.textColor, containerMargin: "0px", handleUpdate: handleUpdate, getOptionSelected: getOptionSelected, getValueString: getValueString, helperText: (_h = (_g = (_e = errorMsg !== null && errorMsg !== void 0 ? errorMsg : warning) !== null && _e !== void 0 ? _e : (_f = error === null || error === void 0 ? void 0 : error.message) === null || _f === void 0 ? void 0 : _f.toString()) !== null && _g !== void 0 ? _g : step.description) !== null && _h !== void 0 ? _h : undefined, error: !!errorMsg || !!warning || !!error }) })), renderNestedSteps === null || renderNestedSteps === void 0 ? void 0 : renderNestedSteps(value)] }));
|
|
266
204
|
}
|
|
267
205
|
function SmartSelectStep(props) {
|
|
268
|
-
var
|
|
269
|
-
var
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
}, []);
|
|
282
|
-
return (_jsx(
|
|
283
|
-
required: step.required
|
|
284
|
-
? 'Este campo es obligatorio'
|
|
285
|
-
: undefined,
|
|
286
|
-
}, shouldUnregister: true, render: function (_a) {
|
|
287
|
-
var _b = _a.field, ref = _b.ref, field = __rest(_b, ["ref"]);
|
|
288
|
-
return (_jsx(SmartSelect, __assign({}, props, field, { inputRef: ref, onChange: function (value) {
|
|
289
|
-
if (dependencyStore[step.id] !== undefined) {
|
|
290
|
-
props.setDependencyStore(function (dependencies) {
|
|
291
|
-
var _a;
|
|
292
|
-
return (__assign(__assign({}, dependencies), (_a = {}, _a[step.id] = {
|
|
293
|
-
type: step.type,
|
|
294
|
-
value: value !== null && value !== void 0 ? value : null,
|
|
295
|
-
}, _a)));
|
|
296
|
-
});
|
|
297
|
-
}
|
|
298
|
-
field.onChange(value);
|
|
299
|
-
} })));
|
|
300
|
-
} }));
|
|
206
|
+
var step = props.step, defaultValue = props.defaultValue;
|
|
207
|
+
var _a = useStepDependency(step, defaultValue), handleStepDep = _a.handleStepDep, originalValue = _a.originalValue;
|
|
208
|
+
var _b = useController({
|
|
209
|
+
name: step.id,
|
|
210
|
+
shouldUnregister: true,
|
|
211
|
+
rules: {
|
|
212
|
+
required: step.required ? 'Este campo es obligatorio' : undefined,
|
|
213
|
+
},
|
|
214
|
+
defaultValue: originalValue,
|
|
215
|
+
}), _c = _b.field, ref = _c.ref, field = __rest(_c, ["ref"]), error = _b.fieldState.error;
|
|
216
|
+
var onChange = useCallback(function (value) {
|
|
217
|
+
handleStepDep(value);
|
|
218
|
+
field.onChange(value);
|
|
219
|
+
}, [handleStepDep, field]);
|
|
220
|
+
return (_jsx(SmartSelect, __assign({}, props, field, { error: error, inputRef: ref, onChange: onChange })));
|
|
301
221
|
}
|
|
302
222
|
export default SmartSelectStep;
|
|
@@ -1,32 +1,31 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { StepProps } from '../Step';
|
|
3
3
|
import { GSmartSelect } from '../../@Types/GenericFormSteps';
|
|
4
|
-
import { Organization } from '../../@Types';
|
|
5
4
|
import { FormStep } from '../../@Types/FormStep';
|
|
6
5
|
import { DependencyStore } from '../../Form/Form';
|
|
7
|
-
export interface SmartSelectStepProps extends Omit<StepProps, 'step'> {
|
|
6
|
+
export interface SmartSelectStepProps<StepType extends GSmartSelect = GSmartSelect> extends Omit<StepProps, 'step'> {
|
|
8
7
|
/** The SmartSelectStep to display */
|
|
9
|
-
step:
|
|
8
|
+
step: StepType;
|
|
10
9
|
/** The icon to display */
|
|
11
10
|
icon?: React.ReactNode;
|
|
12
11
|
/** Function to call to get the options of the selector, return null if dependency is not met */
|
|
13
|
-
getOptions: (
|
|
12
|
+
getOptions: (idOrganization: string | undefined, step: StepType, dependencyStore: DependencyStore) => Promise<any[] | null>;
|
|
14
13
|
/** Function to determine the currently selected option */
|
|
15
14
|
getOptionSelected: (option: any, value: any) => boolean;
|
|
16
15
|
/** Function to determine the current value in string format */
|
|
17
|
-
getValueString: (value: any) => string;
|
|
16
|
+
getValueString: (value: any | undefined) => string;
|
|
18
17
|
/** Function to if currently selected option has warning */
|
|
19
|
-
getValueWarning?: (value: any) => string | null;
|
|
20
|
-
/** Function that returns the error message based on the
|
|
21
|
-
calcDepError?: (
|
|
22
|
-
/** children to render */
|
|
23
|
-
children?: React.ReactElement<any, string>;
|
|
18
|
+
getValueWarning?: (value: any | undefined) => string | null;
|
|
19
|
+
/** Function that returns the error message based on the steps of the missing Dependencies, undefined if no error msg */
|
|
20
|
+
calcDepError?: (steps: FormStep[]) => string | undefined;
|
|
24
21
|
/** Function that overwrites the value before setting it */
|
|
25
22
|
valueOverwrite?: (value: any | null) => any;
|
|
26
23
|
/** Function called on each value change */
|
|
27
24
|
changeListener?: (value: any) => void;
|
|
28
25
|
/** default Value to select */
|
|
29
26
|
defaultValue?: any;
|
|
27
|
+
/** function called to render nested elements when selected */
|
|
28
|
+
renderNestedSteps?: (value: any) => JSX.Element;
|
|
30
29
|
}
|
|
31
30
|
declare function SmartSelectStep(props: SmartSelectStepProps): JSX.Element;
|
|
32
31
|
export default SmartSelectStep;
|
|
@@ -12,8 +12,10 @@ var __assign = (this && this.__assign) || function () {
|
|
|
12
12
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
13
13
|
import { FormStyleTypes } from '../../constants/FormStepTypes';
|
|
14
14
|
import MaterialSmartSelectStep from './MaterialSmartSelectStep/MaterialSmartSelectStep';
|
|
15
|
+
import { useAppSelector } from '../../hooks';
|
|
15
16
|
function SmartSelectStep(props) {
|
|
16
|
-
|
|
17
|
+
var formStyle = useAppSelector(function (state) { return state.global; }).formStyle;
|
|
18
|
+
switch (formStyle.type) {
|
|
17
19
|
case FormStyleTypes.MATERIAL:
|
|
18
20
|
default: {
|
|
19
21
|
return _jsx(MaterialSmartSelectStep, __assign({}, props));
|
package/dist/FormSteps/Step.d.ts
CHANGED
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { FormStep } from '../@Types/FormStep';
|
|
3
|
-
|
|
4
|
-
export interface StepProps extends RecursiveData {
|
|
3
|
+
export interface StepProps {
|
|
5
4
|
step: FormStep;
|
|
6
|
-
|
|
5
|
+
editable: boolean;
|
|
6
|
+
handleSizeChange?: () => void;
|
|
7
7
|
level: number;
|
|
8
|
-
globalEditable: boolean;
|
|
9
8
|
}
|
|
10
9
|
declare function StepComponent({ step, ...props }: StepProps): JSX.Element;
|
|
11
10
|
export default StepComponent;
|
package/dist/FormSteps/Step.js
CHANGED
|
@@ -38,22 +38,26 @@ import EntityValuePickerStep from './EntityValueStep/EntityValuePickerStep';
|
|
|
38
38
|
import MapperStep from './MapperStep/MapperStep';
|
|
39
39
|
import CollapsibleStep from './CollapsibleStep/CollapsibleStep';
|
|
40
40
|
import ApiSelectorStep from './ApiSelectorStep/ApiSelectorStep';
|
|
41
|
+
import CustomStep from './CustomStep';
|
|
42
|
+
import { useAppSelector } from '../hooks';
|
|
43
|
+
import { useContext } from 'react';
|
|
44
|
+
import CustomContext from '../Contexts/CustomContext';
|
|
41
45
|
function StepComponent(_a) {
|
|
42
|
-
var _b
|
|
46
|
+
var _b;
|
|
43
47
|
var step = _a.step, props = __rest(_a, ["step"]);
|
|
44
48
|
if (!step) {
|
|
45
|
-
console.error('Step not found!');
|
|
49
|
+
console.error('Step not found!', step);
|
|
46
50
|
return _jsx("div", {});
|
|
47
51
|
}
|
|
48
|
-
var
|
|
49
|
-
var
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
52
|
+
var _c = useAppSelector(function (state) { return state.global; }), postview = _c.postview, partial = _c.partial;
|
|
53
|
+
var customSteps = useContext(CustomContext).customSteps;
|
|
54
|
+
var customStep = customSteps[step.type];
|
|
55
|
+
var editable = props.editable ? (_b = step.editable) !== null && _b !== void 0 ? _b : true : false;
|
|
56
|
+
if ((postview || !editable) && (partial || step.partial)) {
|
|
53
57
|
return _jsx("div", {});
|
|
54
58
|
}
|
|
55
59
|
if (customStep) {
|
|
56
|
-
return
|
|
60
|
+
return (_jsx(CustomStep, __assign({}, props, { step: step, editable: editable, customStep: customStep })));
|
|
57
61
|
}
|
|
58
62
|
switch (step.type) {
|
|
59
63
|
case Types.TITLE: {
|
|
@@ -1,5 +1,15 @@
|
|
|
1
1
|
import { FormSize } from '../@Types/Form';
|
|
2
2
|
import { ApiSelector, CheckBox, ClassifierSelector, EntityValuePicker, FormSelector, FormStep } from '../@Types/FormStep';
|
|
3
|
+
import { CBRFormStep } from '../@Types/CBRFormStep';
|
|
3
4
|
export declare function calcFillerSize(step: FormSelector | ClassifierSelector | EntityValuePicker | ApiSelector | CheckBox, steps: Record<string, FormStep>, values: Record<string, unknown>, size: FormSize): number;
|
|
4
5
|
export declare function recursivelyCheckOpenSize(idStep: string, steps: Record<string, FormStep>, values: Record<string, any>): number;
|
|
5
6
|
export declare const calcStepWidth: (stepSize: 1 | 2 | 3 | 4, size: FormSize) => number;
|
|
7
|
+
export declare const calcDefaultValue: (step: FormStep | CBRFormStep) => any;
|
|
8
|
+
export declare const iterateNestedSteps: (idStep: string, steps: Record<string, FormStep>, iteration: (step: FormStep) => void) => void;
|
|
9
|
+
/**
|
|
10
|
+
* Utility function to handle the substeps of a step
|
|
11
|
+
* @param step step to calc the substeps
|
|
12
|
+
* @param idModifier optional modifier for the ids of the substeps and all other properties
|
|
13
|
+
* @returns list of the ids of the direct substeps of the step, if modifier returns modified steps
|
|
14
|
+
*/
|
|
15
|
+
export declare const calcSubSteps: (step: FormStep, idModifier?: ((idSubStep: string) => string) | undefined) => string[];
|