@ukhomeoffice/cop-react-form-renderer 7.3.2-alpha.5 → 8.0.0-alpha
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/README.md +106 -32
- package/dist/components/CheckYourAnswers/Answer.d.ts +10 -0
- package/dist/components/CheckYourAnswers/CheckYourAnswers.d.ts +35 -0
- package/dist/components/CheckYourAnswers/index.d.ts +2 -0
- package/dist/components/CollectionPage/CollectionPage.d.ts +24 -0
- package/dist/components/CollectionPage/index.d.ts +1 -0
- package/dist/components/CollectionSummary/BannerStrip.d.ts +9 -0
- package/dist/components/CollectionSummary/CollectionSummary.d.ts +53 -0
- package/dist/components/CollectionSummary/Confirmation.d.ts +15 -0
- package/dist/components/CollectionSummary/RenderListView.d.ts +42 -0
- package/dist/components/CollectionSummary/SummaryCard.d.ts +62 -0
- package/dist/components/CollectionSummary/SummaryCardButtons.d.ts +21 -0
- package/dist/components/CollectionSummary/SummaryCardDetails.d.ts +14 -0
- package/dist/components/CollectionSummary/SummaryCardValidationContext.d.ts +9 -0
- package/dist/components/CollectionSummary/index.d.ts +2 -0
- package/dist/components/FormComponent/Collection.d.ts +39 -0
- package/dist/components/FormComponent/Container.d.ts +26 -0
- package/dist/components/FormComponent/FormComponent.d.ts +39 -0
- package/dist/components/FormComponent/helpers/addLabel.d.ts +7 -0
- package/dist/components/FormComponent/helpers/getComponentDisabled.d.ts +2 -0
- package/dist/components/FormComponent/helpers/getComponentError.d.ts +4 -0
- package/dist/components/FormComponent/helpers/getComponentFieldSet.d.ts +2 -0
- package/dist/components/FormComponent/helpers/index.d.ts +5 -0
- package/dist/components/FormComponent/index.d.ts +2 -0
- package/dist/components/FormPage/FormPage.d.ts +36 -0
- package/dist/components/FormPage/index.d.ts +2 -0
- package/dist/components/FormRenderer/FormRenderer.d.ts +39 -0
- package/dist/components/FormRenderer/handlers/cyaAction.d.ts +9 -0
- package/dist/components/FormRenderer/handlers/getPageId.d.ts +8 -0
- package/dist/components/FormRenderer/handlers/index.d.ts +6 -0
- package/dist/components/FormRenderer/handlers/navigate.d.ts +10 -0
- package/dist/components/FormRenderer/handlers/submissionError.d.ts +7 -0
- package/dist/components/FormRenderer/helpers/canActionProceed.d.ts +12 -0
- package/dist/components/FormRenderer/helpers/canCYASubmit.d.ts +10 -0
- package/dist/components/FormRenderer/helpers/cleanHiddenNestedData.d.ts +2 -0
- package/dist/components/FormRenderer/helpers/clearOutUncompletedRoutes.d.ts +51 -0
- package/dist/components/FormRenderer/helpers/clearOutUncompletedRoutesUtils.d.ts +179 -0
- package/dist/components/FormRenderer/helpers/getCYA.d.ts +20 -0
- package/dist/components/FormRenderer/helpers/getFormState.d.ts +25 -0
- package/dist/components/FormRenderer/helpers/getNextPageId.d.ts +2 -0
- package/dist/components/FormRenderer/helpers/getPage.d.ts +9 -0
- package/dist/components/FormRenderer/helpers/getRelevantPages.d.ts +2 -0
- package/dist/components/FormRenderer/helpers/getSubmissionStatus.d.ts +2 -0
- package/dist/components/FormRenderer/helpers/getUpdatedSectionStates.d.ts +10 -0
- package/dist/components/FormRenderer/helpers/index.d.ts +29 -0
- package/dist/components/FormRenderer/index.d.ts +2 -0
- package/dist/components/FormRenderer/onCYAAction.d.ts +6 -0
- package/dist/components/FormRenderer/onPageAction.d.ts +2 -0
- package/dist/components/FormRenderer/onTaskAction.d.ts +2 -0
- package/dist/components/PageActions/ActionButton.d.ts +7 -0
- package/dist/components/PageActions/PageActions.d.ts +7 -0
- package/dist/components/PageActions/index.d.ts +2 -0
- package/dist/components/SummaryList/GroupAction.d.ts +12 -0
- package/dist/components/SummaryList/RowAction.d.ts +12 -0
- package/dist/components/SummaryList/SummaryList.d.ts +28 -0
- package/dist/components/SummaryList/SummaryList.stories.d.ts +10 -0
- package/dist/components/SummaryList/SummaryListHeadingRow.d.ts +7 -0
- package/dist/components/SummaryList/SummaryListHeadingRowWithAction.d.ts +16 -0
- package/dist/components/SummaryList/SummaryListRow.d.ts +19 -0
- package/dist/components/SummaryList/SummaryListTitleRow.d.ts +7 -0
- package/dist/components/SummaryList/helpers/getGroupActionAttributes.d.ts +17 -0
- package/dist/components/SummaryList/helpers/getRowActionAttributes.d.ts +17 -0
- package/dist/components/SummaryList/helpers/index.d.ts +2 -0
- package/dist/components/SummaryList/index.d.ts +2 -0
- package/dist/components/TaskList/Task.d.ts +12 -0
- package/dist/components/TaskList/TaskList.d.ts +40 -0
- package/dist/components/TaskList/TaskState.d.ts +6 -0
- package/dist/components/TaskList/index.d.ts +2 -0
- package/dist/components/index.d.ts +8 -0
- package/dist/context/HooksContext/HooksContext.d.ts +23 -0
- package/dist/context/HooksContext/index.d.ts +3 -0
- package/dist/context/ValidationContext/ValidationContext.d.ts +7 -0
- package/dist/context/ValidationContext/index.d.ts +3 -0
- package/dist/context/index.d.ts +3 -0
- package/dist/hooks/index.d.ts +6 -0
- package/dist/hooks/useAxios.d.ts +2 -0
- package/dist/hooks/useGetRequest.d.ts +12 -0
- package/dist/hooks/useHooks.d.ts +2 -0
- package/dist/hooks/useRefData.d.ts +7 -0
- package/dist/hooks/useValidation.d.ts +2 -0
- package/dist/index.cjs +5 -0
- package/dist/index.css +1 -0
- package/dist/index.d.ts +6 -0
- package/dist/index.js +6124 -81
- package/dist/models/CollectionLabels.d.ts +7 -0
- package/dist/models/ComponentTypes.d.ts +27 -0
- package/dist/models/EventTypes.d.ts +6 -0
- package/dist/models/FormPages.d.ts +6 -0
- package/dist/models/FormTypes.d.ts +10 -0
- package/dist/models/HubFormats.d.ts +5 -0
- package/dist/models/PageAction.d.ts +89 -0
- package/dist/models/TaskStates.d.ts +39 -0
- package/dist/models/index.d.ts +143 -0
- package/dist/setupTests.d.ts +14 -0
- package/dist/utils/CheckYourAnswers/getCYAAction.d.ts +20 -0
- package/dist/utils/CheckYourAnswers/getCYACollectionChangeAction.d.ts +22 -0
- package/dist/utils/CheckYourAnswers/getCYACollectionDeleteAction.d.ts +22 -0
- package/dist/utils/CheckYourAnswers/getCYARow.d.ts +26 -0
- package/dist/utils/CheckYourAnswers/getCYARowForGroup.d.ts +17 -0
- package/dist/utils/CheckYourAnswers/getCYARowsForCollection.d.ts +2 -0
- package/dist/utils/CheckYourAnswers/getCYARowsForCollectionPage.d.ts +23 -0
- package/dist/utils/CheckYourAnswers/getCYARowsForContainer.d.ts +2 -0
- package/dist/utils/CheckYourAnswers/getCYARowsForPage.d.ts +11 -0
- package/dist/utils/CheckYourAnswers/getSummaryListRowForDetails.d.ts +3 -0
- package/dist/utils/CheckYourAnswers/index.d.ts +5 -0
- package/dist/utils/CheckYourAnswers/showComponentCYA.d.ts +11 -0
- package/dist/utils/CollectionPage/addCollectionPageEntry.d.ts +12 -0
- package/dist/utils/CollectionPage/duplicateCollectionPageActiveEntry.d.ts +13 -0
- package/dist/utils/CollectionPage/duplicateCollectionPageEntry.d.ts +13 -0
- package/dist/utils/CollectionPage/getCollectionPageActiveId.d.ts +14 -0
- package/dist/utils/CollectionPage/getCollectionPageActiveIndex.d.ts +15 -0
- package/dist/utils/CollectionPage/getCollectionPageData.d.ts +15 -0
- package/dist/utils/CollectionPage/getErrorsForCollection.d.ts +2 -0
- package/dist/utils/CollectionPage/getQuickEditPage.d.ts +40 -0
- package/dist/utils/CollectionPage/index.d.ts +13 -0
- package/dist/utils/CollectionPage/mergeCollectionPages.d.ts +13 -0
- package/dist/utils/CollectionPage/removeCollectionPageEntry.d.ts +11 -0
- package/dist/utils/CollectionPage/setCollectionPageData.d.ts +16 -0
- package/dist/utils/Component/addShowWhen.d.ts +13 -0
- package/dist/utils/Component/applyToComponentTree.d.ts +15 -0
- package/dist/utils/Component/cleanAttributes.d.ts +14 -0
- package/dist/utils/Component/elevateNestedComponents.d.ts +28 -0
- package/dist/utils/Component/getDefaultValue.d.ts +2 -0
- package/dist/utils/Component/getDefaultValueFromConfig.d.ts +2 -0
- package/dist/utils/Component/index.d.ts +12 -0
- package/dist/utils/Component/isEditable.d.ts +3 -0
- package/dist/utils/Component/optionIsSelected.d.ts +10 -0
- package/dist/utils/Component/setupContainerComponentsPath.d.ts +2 -0
- package/dist/utils/Component/showComponent.d.ts +2 -0
- package/dist/utils/Condition/index.d.ts +6 -0
- package/dist/utils/Condition/meetsAllConditions.d.ts +8 -0
- package/dist/utils/Condition/meetsCondition.d.ts +14 -0
- package/dist/utils/Condition/meetsOneCondition.d.ts +8 -0
- package/dist/utils/Condition/setupConditions.d.ts +2 -0
- package/dist/utils/Container/getEditableComponents.d.ts +7 -0
- package/dist/utils/Container/index.d.ts +6 -0
- package/dist/utils/Container/setupNesting.d.ts +2 -0
- package/dist/utils/Container/showContainer.d.ts +8 -0
- package/dist/utils/Data/applyFormula.d.ts +2 -0
- package/dist/utils/Data/deleteValues.d.ts +8 -0
- package/dist/utils/Data/getAutocompleteSource.d.ts +2 -0
- package/dist/utils/Data/getDataPath.d.ts +21 -0
- package/dist/utils/Data/getOptions.d.ts +2 -0
- package/dist/utils/Data/getSourceData.d.ts +17 -0
- package/dist/utils/Data/index.d.ts +15 -0
- package/dist/utils/Data/nestInRefdataOptions.d.ts +10 -0
- package/dist/utils/Data/refDataToOptions.d.ts +8 -0
- package/dist/utils/Data/setDataItem.d.ts +2 -0
- package/dist/utils/Data/setupFormData.d.ts +15 -0
- package/dist/utils/Data/setupRefDataUrlForComponent.d.ts +2 -0
- package/dist/utils/FormPage/applyConditionalProperties.d.ts +8 -0
- package/dist/utils/FormPage/getConditionalText.d.ts +23 -0
- package/dist/utils/FormPage/getFormPage.d.ts +9 -0
- package/dist/utils/FormPage/getFormPages.d.ts +9 -0
- package/dist/utils/FormPage/getPageActions.d.ts +13 -0
- package/dist/utils/FormPage/getParagraphFromText.d.ts +11 -0
- package/dist/utils/FormPage/index.d.ts +10 -0
- package/dist/utils/FormPage/showFormPage.d.ts +8 -0
- package/dist/utils/FormPage/showFormPageCYA.d.ts +8 -0
- package/dist/utils/FormPage/useComponent.d.ts +9 -0
- package/dist/utils/Format/formatData.d.ts +8 -0
- package/dist/utils/Format/formatDataForComponent.d.ts +15 -0
- package/dist/utils/Format/formatDataForForm.d.ts +8 -0
- package/dist/utils/Format/formatDataForPage.d.ts +15 -0
- package/dist/utils/Format/index.d.ts +7 -0
- package/dist/utils/Hub/getFormHub.d.ts +15 -0
- package/dist/utils/Hub/index.d.ts +4 -0
- package/dist/utils/Meta/constants.d.ts +2 -0
- package/dist/utils/Meta/documents/getDocuments.d.ts +2 -0
- package/dist/utils/Meta/documents/index.d.ts +6 -0
- package/dist/utils/Meta/documents/setDocumentsForField.d.ts +2 -0
- package/dist/utils/Meta/index.d.ts +9 -0
- package/dist/utils/Operate/checkValueIsTruthy.d.ts +9 -0
- package/dist/utils/Operate/deleteValueInFormData.d.ts +8 -0
- package/dist/utils/Operate/doesContainValue.d.ts +11 -0
- package/dist/utils/Operate/getFirstOf.d.ts +2 -0
- package/dist/utils/Operate/getIndexOfMatchingValueIn.d.ts +11 -0
- package/dist/utils/Operate/getLength.d.ts +11 -0
- package/dist/utils/Operate/index.d.ts +4 -0
- package/dist/utils/Operate/persistValueInFormData.d.ts +9 -0
- package/dist/utils/Operate/runPageOperations.d.ts +19 -0
- package/dist/utils/Operate/setValueInFormData.d.ts +2 -0
- package/dist/utils/Operate/shouldRun.d.ts +9 -0
- package/dist/utils/Validate/additional/conditionallyPermittedChange.d.ts +14 -0
- package/dist/utils/Validate/additional/conditionallyRequired.d.ts +11 -0
- package/dist/utils/Validate/additional/index.d.ts +2 -0
- package/dist/utils/Validate/additional/mustBeAfter.d.ts +14 -0
- package/dist/utils/Validate/additional/mustBeBefore.d.ts +14 -0
- package/dist/utils/Validate/additional/mustBeEarlierDateTime.d.ts +15 -0
- package/dist/utils/Validate/additional/mustBeGreaterThan.d.ts +7 -0
- package/dist/utils/Validate/additional/mustBeInTheFuture.d.ts +8 -0
- package/dist/utils/Validate/additional/mustBeInThePast.d.ts +9 -0
- package/dist/utils/Validate/additional/mustBeLessThan.d.ts +7 -0
- package/dist/utils/Validate/additional/mustBeLongerThan.d.ts +9 -0
- package/dist/utils/Validate/additional/mustBeNumbersOnly.d.ts +9 -0
- package/dist/utils/Validate/additional/mustBeOneOf.d.ts +8 -0
- package/dist/utils/Validate/additional/mustBeShorterThan.d.ts +9 -0
- package/dist/utils/Validate/additional/mustBeUniqueInCollection.d.ts +10 -0
- package/dist/utils/Validate/additional/mustEnterAtLeastOne.d.ts +9 -0
- package/dist/utils/Validate/additional/mustHaveLessThanDecimalPlaces.d.ts +7 -0
- package/dist/utils/Validate/additional/mustNotContainSql.d.ts +2 -0
- package/dist/utils/Validate/additional/mustSelectOnlyOne.d.ts +8 -0
- package/dist/utils/Validate/additional/utils.d.ts +4 -0
- package/dist/utils/Validate/index.d.ts +42 -0
- package/dist/utils/Validate/validateCollection.d.ts +9 -0
- package/dist/utils/Validate/validateComponent.d.ts +16 -0
- package/dist/utils/Validate/validateContainer.d.ts +12 -0
- package/dist/utils/Validate/validateDate.d.ts +29 -0
- package/dist/utils/Validate/validateEmail.d.ts +13 -0
- package/dist/utils/Validate/validateMultifile.d.ts +3 -0
- package/dist/utils/Validate/validateOnPageLoad.d.ts +1 -0
- package/dist/utils/Validate/validatePage.d.ts +8 -0
- package/dist/utils/Validate/validateRegex.d.ts +13 -0
- package/dist/utils/Validate/validateRequired.d.ts +9 -0
- package/dist/utils/Validate/validateTextArea.d.ts +13 -0
- package/dist/utils/Validate/validateTime.d.ts +20 -0
- package/dist/utils/canOverrideFieldRequired.d.ts +9 -0
- package/dist/utils/index.d.ts +140 -0
- package/package.json +81 -170
- package/LICENCE.md +0 -21
- package/dist/components/CheckYourAnswers/Answer.js +0 -59
- package/dist/components/CheckYourAnswers/Answer.test.js +0 -142
- package/dist/components/CheckYourAnswers/CheckYourAnswers.js +0 -252
- package/dist/components/CheckYourAnswers/CheckYourAnswers.scss +0 -43
- package/dist/components/CheckYourAnswers/CheckYourAnswers.stories.mdx +0 -409
- package/dist/components/CheckYourAnswers/CheckYourAnswers.test.js +0 -603
- package/dist/components/CheckYourAnswers/index.js +0 -10
- package/dist/components/CollectionPage/CollectionPage.js +0 -178
- package/dist/components/CollectionPage/CollectionPage.test.js +0 -507
- package/dist/components/CollectionPage/index.js +0 -10
- package/dist/components/CollectionSummary/BannerStrip.js +0 -65
- package/dist/components/CollectionSummary/BannerStrip.scss +0 -60
- package/dist/components/CollectionSummary/BannerStrip.test.js +0 -167
- package/dist/components/CollectionSummary/CollectionSummary.js +0 -362
- package/dist/components/CollectionSummary/CollectionSummary.scss +0 -26
- package/dist/components/CollectionSummary/CollectionSummary.test.js +0 -368
- package/dist/components/CollectionSummary/Confirmation.js +0 -65
- package/dist/components/CollectionSummary/Confirmation.scss +0 -26
- package/dist/components/CollectionSummary/Confirmation.test.js +0 -109
- package/dist/components/CollectionSummary/RenderListView.js +0 -162
- package/dist/components/CollectionSummary/RenderListView.scss +0 -295
- package/dist/components/CollectionSummary/RenderListView.test.js +0 -303
- package/dist/components/CollectionSummary/SummaryCard.js +0 -277
- package/dist/components/CollectionSummary/SummaryCard.scss +0 -114
- package/dist/components/CollectionSummary/SummaryCard.test.js +0 -1442
- package/dist/components/CollectionSummary/SummaryCardButtons.js +0 -76
- package/dist/components/CollectionSummary/SummaryCardButtons.test.js +0 -87
- package/dist/components/CollectionSummary/SummaryCardDetails.js +0 -206
- package/dist/components/CollectionSummary/SummaryCardDetails.scss +0 -216
- package/dist/components/CollectionSummary/SummaryCardDetails.test.js +0 -654
- package/dist/components/CollectionSummary/SummaryCardValidationContext.js +0 -79
- package/dist/components/CollectionSummary/SummaryCardValidationContext.test.js +0 -104
- package/dist/components/CollectionSummary/index.js +0 -10
- package/dist/components/FormComponent/Collection.js +0 -234
- package/dist/components/FormComponent/Collection.scss +0 -24
- package/dist/components/FormComponent/Collection.test.js +0 -934
- package/dist/components/FormComponent/Container.js +0 -130
- package/dist/components/FormComponent/Container.scss +0 -15
- package/dist/components/FormComponent/Container.test.js +0 -456
- package/dist/components/FormComponent/FormComponent.js +0 -238
- package/dist/components/FormComponent/FormComponent.stories.mdx +0 -186
- package/dist/components/FormComponent/FormComponent.test.js +0 -436
- package/dist/components/FormComponent/helpers/addLabel.js +0 -25
- package/dist/components/FormComponent/helpers/getComponentDisabled.js +0 -15
- package/dist/components/FormComponent/helpers/getComponentDisabled.test.js +0 -27
- package/dist/components/FormComponent/helpers/getComponentError.js +0 -23
- package/dist/components/FormComponent/helpers/getComponentError.test.js +0 -51
- package/dist/components/FormComponent/helpers/getComponentFieldSet.js +0 -11
- package/dist/components/FormComponent/helpers/getComponentFieldSet.test.js +0 -30
- package/dist/components/FormComponent/helpers/index.js +0 -35
- package/dist/components/FormComponent/index.js +0 -10
- package/dist/components/FormPage/FormPage.js +0 -212
- package/dist/components/FormPage/FormPage.scss +0 -7
- package/dist/components/FormPage/FormPage.stories.mdx +0 -157
- package/dist/components/FormPage/FormPage.test.js +0 -454
- package/dist/components/FormPage/index.js +0 -10
- package/dist/components/FormRenderer/FormRenderer.js +0 -426
- package/dist/components/FormRenderer/FormRenderer.scss +0 -5
- package/dist/components/FormRenderer/FormRenderer.stories.mdx +0 -178
- package/dist/components/FormRenderer/FormRenderer.test.js +0 -799
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/cop-reassign-task-to-rcc.json +0 -446
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-chained-component-show-whens-containerised.json +0 -120
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-chained-component-show-whens-dependent-component-nested-block.json +0 -113
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-chained-component-show-whens-dependent-component-nested.json +0 -106
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-chained-component-show-whens-refdata.json +0 -106
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-chained-component-show-whens-target-component-nested.json +0 -99
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-chained-component-show-whens.json +0 -106
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-chained-show-whens-page-hidden.json +0 -113
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-cop-airpax.json +0 -26408
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-cop-mandec.json +0 -9405
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-hidden-collection-component-dependent-on-external-data.json +0 -158
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-hidden-collection-component.json +0 -86
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-hidden-component-referring-to-collection.json +0 -173
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-hidden-component-referring-to-hidden-collection.json +0 -202
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-hidden-component-show-when-in-component-and-page.json +0 -63
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-hidden-component-with-nested-questions-visible-elsewhere.json +0 -118
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-hidden-component-with-nested-questions.json +0 -112
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-hidden-component.json +0 -58
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-hidden-containerised-component.json +0 -97
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-hidden-embedded-collection-component.json +0 -83
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-hidden-embedded-component.json +0 -55
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-hidden-entire-collection.json +0 -114
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-hidden-multilevel-containerised-component-leaf-hidden.json +0 -106
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-hidden-multilevel-containerised-component.json +0 -106
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-hidden-options.json +0 -99
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-hidden-page-collection.json +0 -128
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-hidden-page-component-used-elsewhere.json +0 -109
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-hidden-page-same-component-reused.json +0 -62
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-hidden-page.json +0 -96
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-nested-answers-hidden-by-option-visible-elsewhere.json +0 -113
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-nested-answers-hidden-by-option.json +0 -112
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-page-nested-component.json +0 -26003
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-page-nested-radio-component.json +0 -201
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-page-same-component-reused-one-shown.json +0 -75
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/forms/form-variance-breach.json +0 -4272
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/cop-airpax-carrier.json +0 -407
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/cop-airpax-change-what-happened-before.json +0 -300
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/cop-airpax-remove-photos-before.json +0 -384
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/cop-mandec-remove-business-interests-before.json +0 -140
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/cop-mandec-remove-criminality-before.json +0 -186
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/cop-mandec-remove-unspent-convictions-before.json +0 -143
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/cop-variance-breach-with-upload-files.json +0 -1264
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-chained-component-show-whens-containerised.json +0 -11
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-chained-component-show-whens-dependent-component-nested-block.json +0 -10
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-chained-component-show-whens-dependent-component-nested.json +0 -9
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-chained-component-show-whens-refdata.json +0 -11
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-chained-component-show-whens-target-component-nested.json +0 -9
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-chained-component-show-whens.json +0 -9
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-chained-show-whens-page-hidden.json +0 -9
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-hidden-collection-component-dependent-on-external-data.json +0 -26
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-hidden-collection-component.json +0 -15
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-hidden-component-referring-to-collection.json +0 -25
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-hidden-component-referring-to-hidden-collection.json +0 -26
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-hidden-component-show-when-in-component-and-page.json +0 -6
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-hidden-component-with-nested-questions-visible-elsewhere.json +0 -12
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-hidden-component-with-nested-questions.json +0 -12
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-hidden-component.json +0 -5
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-hidden-containerised-component.json +0 -11
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-hidden-embedded-collection-component.json +0 -15
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-hidden-embedded-component.json +0 -5
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-hidden-entire-collection.json +0 -20
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-hidden-multilevel-containerised-component-leaf-hidden.json +0 -14
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-hidden-multilevel-containerised-component.json +0 -14
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-hidden-options.json +0 -10
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-hidden-page-collection.json +0 -18
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-hidden-page-component-used-elsewhere.json +0 -9
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-hidden-page-same-component-reused.json +0 -6
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-hidden-page.json +0 -9
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-nested-answers-hidden-by-option-visible-elsewhere.json +0 -12
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-nested-answers-hidden-by-option.json +0 -12
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-page-nested-component.json +0 -63
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-page-nested-radio-component.json +0 -45
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/data-page-same-component-reused-one-shown.json +0 -8
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/input/reassign-to-rcc.json +0 -72
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/cop-airpax-change-what-happened-after.json +0 -280
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/cop-airpax-remove-photos-after.json +0 -355
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/cop-mandec-base-file.json +0 -80
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/cop-mandec-remove-business-interests-after.json +0 -122
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/cop-mandec-remove-criminality-after.json +0 -86
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/cop-mandec-remove-unspent-convictions-after.json +0 -127
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-chained-component-show-whens-containerised-removed.json +0 -11
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-chained-component-show-whens-dependent-component-nested-block-removed.json +0 -7
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-chained-component-show-whens-dependent-component-nested-removed.json +0 -7
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-chained-component-show-whens-refdata-removed.json +0 -7
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-chained-component-show-whens-removed.json +0 -7
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-chained-component-show-whens-target-component-nested-removed.json +0 -6
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-chained-show-whens-page-hidden-removed.json +0 -6
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-hidden-collection-component-dependent-on-external-data-removed.json +0 -23
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-hidden-collection-component-removed.json +0 -4
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-hidden-component-referring-to-collection-removed.json +0 -21
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-hidden-component-referring-to-hidden-collection-removed.json +0 -6
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-hidden-component-removed.json +0 -4
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-hidden-component-show-when-in-component-and-page-removed.json +0 -5
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-hidden-component-with-nested-questions-removed.json +0 -10
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-hidden-component-with-nested-questions-visible-elsewhere-removed.json +0 -11
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-hidden-containerised-component-removed.json +0 -10
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-hidden-embedded-collection-component-removed.json +0 -4
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-hidden-embedded-component-removed.json +0 -4
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-hidden-entire-collection-removed.json +0 -3
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-hidden-multilevel-containerised-component-leaf-hidden-removed.json +0 -13
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-hidden-multilevel-containerised-component-removed.json +0 -10
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-hidden-options-removed.json +0 -8
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-hidden-page-collection-removed.json +0 -15
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-hidden-page-component-used-elsewhere-removed.json +0 -5
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-hidden-page-removed.json +0 -4
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-hidden-page-same-component-reused-removed.json +0 -5
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-nested-answers-hidden-by-option-removed.json +0 -11
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-nested-answers-hidden-by-option-visible-elsewhere-removed.json +0 -12
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-page-nested-component.json +0 -63
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-page-nested-radio-component-removed.json +0 -45
- package/dist/components/FormRenderer/clear-uncompleted-routes/test-data/output/data-page-same-component-reused-one-shown-removed.json +0 -7
- package/dist/components/FormRenderer/handlers/cyaAction.js +0 -23
- package/dist/components/FormRenderer/handlers/getPageId.js +0 -15
- package/dist/components/FormRenderer/handlers/getPageId.test.js +0 -35
- package/dist/components/FormRenderer/handlers/handlers.test.js +0 -81
- package/dist/components/FormRenderer/handlers/index.js +0 -17
- package/dist/components/FormRenderer/handlers/navigate.js +0 -25
- package/dist/components/FormRenderer/handlers/submissionError.js +0 -18
- package/dist/components/FormRenderer/helpers/canActionProceed.js +0 -27
- package/dist/components/FormRenderer/helpers/canActionProceed.test.js +0 -84
- package/dist/components/FormRenderer/helpers/canCYASubmit.js +0 -17
- package/dist/components/FormRenderer/helpers/canCYASubmit.test.js +0 -75
- package/dist/components/FormRenderer/helpers/cleanHiddenNestedData.js +0 -63
- package/dist/components/FormRenderer/helpers/cleanHiddenNestedData.test.js +0 -191
- package/dist/components/FormRenderer/helpers/clearOutUncompletedRoutes.js +0 -338
- package/dist/components/FormRenderer/helpers/clearOutUncompletedRoutes.test.js +0 -434
- package/dist/components/FormRenderer/helpers/clearOutUncompletedRoutesUtils.js +0 -399
- package/dist/components/FormRenderer/helpers/clearOutUncompletedRoutesUtils.test.js +0 -559
- package/dist/components/FormRenderer/helpers/getCYA.js +0 -42
- package/dist/components/FormRenderer/helpers/getCYA.test.js +0 -46
- package/dist/components/FormRenderer/helpers/getFormState.js +0 -25
- package/dist/components/FormRenderer/helpers/getFormState.test.js +0 -60
- package/dist/components/FormRenderer/helpers/getNextPageId.js +0 -76
- package/dist/components/FormRenderer/helpers/getNextPageId.test.js +0 -292
- package/dist/components/FormRenderer/helpers/getPage.js +0 -27
- package/dist/components/FormRenderer/helpers/getPage.test.js +0 -45
- package/dist/components/FormRenderer/helpers/getRelevantPages.js +0 -27
- package/dist/components/FormRenderer/helpers/getRelevantPages.test.js +0 -70
- package/dist/components/FormRenderer/helpers/getSubmissionStatus.js +0 -65
- package/dist/components/FormRenderer/helpers/getSubmissionStatus.test.js +0 -309
- package/dist/components/FormRenderer/helpers/getUpdatedSectionStates.js +0 -201
- package/dist/components/FormRenderer/helpers/getUpdatedSectionStates.test.js +0 -473
- package/dist/components/FormRenderer/helpers/index.js +0 -33
- package/dist/components/FormRenderer/index.js +0 -10
- package/dist/components/FormRenderer/onCYAAction.js +0 -150
- package/dist/components/FormRenderer/onCYAAction.test.js +0 -741
- package/dist/components/FormRenderer/onPageAction.js +0 -227
- package/dist/components/FormRenderer/onPageAction.test.js +0 -960
- package/dist/components/FormRenderer/onTaskAction.js +0 -47
- package/dist/components/FormRenderer/onTaskAction.test.js +0 -247
- package/dist/components/PageActions/ActionButton.js +0 -48
- package/dist/components/PageActions/ActionButton.test.js +0 -73
- package/dist/components/PageActions/PageActions.js +0 -37
- package/dist/components/PageActions/PageActions.stories.mdx +0 -74
- package/dist/components/PageActions/PageActions.test.js +0 -106
- package/dist/components/PageActions/index.js +0 -10
- package/dist/components/SummaryList/GroupAction.js +0 -50
- package/dist/components/SummaryList/GroupAction.test.js +0 -86
- package/dist/components/SummaryList/RowAction.js +0 -48
- package/dist/components/SummaryList/RowAction.test.js +0 -86
- package/dist/components/SummaryList/SummaryList.js +0 -128
- package/dist/components/SummaryList/SummaryList.scss +0 -79
- package/dist/components/SummaryList/SummaryList.stories.mdx +0 -84
- package/dist/components/SummaryList/SummaryList.test.js +0 -504
- package/dist/components/SummaryList/SummaryListHeadingRow.js +0 -39
- package/dist/components/SummaryList/SummaryListHeadingRowWithAction.js +0 -65
- package/dist/components/SummaryList/SummaryListHeadingRowWithAction.scss +0 -38
- package/dist/components/SummaryList/SummaryListRow.js +0 -58
- package/dist/components/SummaryList/SummaryListTitleRow.js +0 -32
- package/dist/components/SummaryList/helpers/getGroupActionAttributes.js +0 -29
- package/dist/components/SummaryList/helpers/getGroupActionAttributes.test.js +0 -72
- package/dist/components/SummaryList/helpers/getRowActionAttributes.js +0 -29
- package/dist/components/SummaryList/helpers/getRowActionAttributes.test.js +0 -72
- package/dist/components/SummaryList/helpers/index.js +0 -14
- package/dist/components/SummaryList/index.js +0 -10
- package/dist/components/TaskList/Task.js +0 -62
- package/dist/components/TaskList/Task.test.js +0 -176
- package/dist/components/TaskList/TaskList.js +0 -175
- package/dist/components/TaskList/TaskList.scss +0 -123
- package/dist/components/TaskList/TaskList.stories.mdx +0 -164
- package/dist/components/TaskList/TaskList.test.js +0 -535
- package/dist/components/TaskList/TaskState.js +0 -37
- package/dist/components/TaskList/TaskState.test.js +0 -95
- package/dist/components/TaskList/index.js +0 -10
- package/dist/components/index.js +0 -56
- package/dist/context/HooksContext/HooksContext.js +0 -122
- package/dist/context/HooksContext/HooksContext.test.js +0 -45
- package/dist/context/HooksContext/index.js +0 -16
- package/dist/context/ValidationContext/ValidationContext.js +0 -98
- package/dist/context/ValidationContext/ValidationContext.test.js +0 -107
- package/dist/context/ValidationContext/index.js +0 -16
- package/dist/context/index.js +0 -21
- package/dist/hooks/index.js +0 -55
- package/dist/hooks/useAxios.js +0 -36
- package/dist/hooks/useGetRequest.js +0 -89
- package/dist/hooks/useHooks.js +0 -15
- package/dist/hooks/useRefData.js +0 -62
- package/dist/hooks/useValidation.js +0 -15
- package/dist/json/actions.json +0 -17
- package/dist/json/actionsNoSave.json +0 -17
- package/dist/json/addressDetails.json +0 -149
- package/dist/json/areYouACivilServant.json +0 -7
- package/dist/json/firstForm.json +0 -94
- package/dist/json/grade.json +0 -108
- package/dist/json/group.data.json +0 -21
- package/dist/json/group.json +0 -402
- package/dist/json/groupOfRow.json +0 -137
- package/dist/json/groupOfRowData.json +0 -15
- package/dist/json/port.json +0 -346
- package/dist/json/saveAndContinue.json +0 -98
- package/dist/json/sublocation.json +0 -859
- package/dist/json/taskList.json +0 -265
- package/dist/json/team.json +0 -17351
- package/dist/json/terminal.json +0 -81
- package/dist/json/userProfile.data.json +0 -21
- package/dist/json/userProfile.json +0 -276
- package/dist/models/CollectionLabels.js +0 -15
- package/dist/models/ComponentTypes.js +0 -58
- package/dist/models/EventTypes.js +0 -16
- package/dist/models/FormPages.js +0 -16
- package/dist/models/FormTypes.js +0 -24
- package/dist/models/HubFormats.js +0 -14
- package/dist/models/PageAction.js +0 -65
- package/dist/models/TaskStates.js +0 -46
- package/dist/models/index.js +0 -77
- package/dist/setupTests.js +0 -54
- package/dist/utils/CheckYourAnswers/getCYAAction.js +0 -44
- package/dist/utils/CheckYourAnswers/getCYAAction.test.js +0 -120
- package/dist/utils/CheckYourAnswers/getCYACollectionChangeAction.js +0 -57
- package/dist/utils/CheckYourAnswers/getCYACollectionChangeAction.test.js +0 -162
- package/dist/utils/CheckYourAnswers/getCYACollectionDeleteAction.js +0 -66
- package/dist/utils/CheckYourAnswers/getCYACollectionDeleteAction.test.js +0 -198
- package/dist/utils/CheckYourAnswers/getCYARow.js +0 -58
- package/dist/utils/CheckYourAnswers/getCYARow.test.js +0 -373
- package/dist/utils/CheckYourAnswers/getCYARowForGroup.js +0 -69
- package/dist/utils/CheckYourAnswers/getCYARowForGroup.test.js +0 -70
- package/dist/utils/CheckYourAnswers/getCYARowsForCollection.js +0 -71
- package/dist/utils/CheckYourAnswers/getCYARowsForCollection.test.js +0 -285
- package/dist/utils/CheckYourAnswers/getCYARowsForCollectionPage.js +0 -237
- package/dist/utils/CheckYourAnswers/getCYARowsForCollectionPage.test.js +0 -844
- package/dist/utils/CheckYourAnswers/getCYARowsForContainer.js +0 -45
- package/dist/utils/CheckYourAnswers/getCYARowsForContainer.test.js +0 -535
- package/dist/utils/CheckYourAnswers/getCYARowsForPage.js +0 -72
- package/dist/utils/CheckYourAnswers/getCYARowsForPage.test.js +0 -343
- package/dist/utils/CheckYourAnswers/getSummaryListRowForDetails.js +0 -42
- package/dist/utils/CheckYourAnswers/getSummaryListRowForDetails.test.js +0 -56
- package/dist/utils/CheckYourAnswers/index.js +0 -15
- package/dist/utils/CheckYourAnswers/showComponentCYA.js +0 -53
- package/dist/utils/CheckYourAnswers/showComponentCYA.test.js +0 -149
- package/dist/utils/CollectionPage/addCollectionPageEntry.js +0 -23
- package/dist/utils/CollectionPage/addCollectionPageEntry.test.js +0 -17
- package/dist/utils/CollectionPage/duplicateCollectionPageActiveEntry.js +0 -26
- package/dist/utils/CollectionPage/duplicateCollectionPageActiveEntry.test.js +0 -70
- package/dist/utils/CollectionPage/duplicateCollectionPageEntry.js +0 -51
- package/dist/utils/CollectionPage/duplicateCollectionPageEntry.test.js +0 -125
- package/dist/utils/CollectionPage/getCollectionPageActiveId.js +0 -24
- package/dist/utils/CollectionPage/getCollectionPageActiveId.test.js +0 -26
- package/dist/utils/CollectionPage/getCollectionPageActiveIndex.js +0 -44
- package/dist/utils/CollectionPage/getCollectionPageActiveIndex.test.js +0 -88
- package/dist/utils/CollectionPage/getCollectionPageData.js +0 -53
- package/dist/utils/CollectionPage/getCollectionPageData.test.js +0 -103
- package/dist/utils/CollectionPage/getErrorsForCollection.js +0 -55
- package/dist/utils/CollectionPage/getErrorsForCollection.test.js +0 -154
- package/dist/utils/CollectionPage/getQuickEditPage.js +0 -122
- package/dist/utils/CollectionPage/getQuickEditPage.test.js +0 -143
- package/dist/utils/CollectionPage/index.js +0 -33
- package/dist/utils/CollectionPage/mergeCollectionPages.js +0 -128
- package/dist/utils/CollectionPage/mergeCollectionPages.test.js +0 -198
- package/dist/utils/CollectionPage/removeCollectionPageEntry.js +0 -36
- package/dist/utils/CollectionPage/removeCollectionPageEntry.test.js +0 -62
- package/dist/utils/CollectionPage/setCollectionPageData.js +0 -60
- package/dist/utils/CollectionPage/setCollectionPageData.test.js +0 -182
- package/dist/utils/Component/addShowWhen.js +0 -43
- package/dist/utils/Component/addShowWhen.test.js +0 -217
- package/dist/utils/Component/applyToComponentTree.js +0 -68
- package/dist/utils/Component/applyToComponentTree.test.js +0 -125
- package/dist/utils/Component/cleanAttributes.js +0 -42
- package/dist/utils/Component/cleanAttributes.test.js +0 -67
- package/dist/utils/Component/elevateNestedComponents.js +0 -58
- package/dist/utils/Component/elevateNestedComponents.test.js +0 -305
- package/dist/utils/Component/getComponent.js +0 -305
- package/dist/utils/Component/getComponentTests/getComponent.autocomplete.test.js +0 -73
- package/dist/utils/Component/getComponentTests/getComponent.calculation.test.js +0 -251
- package/dist/utils/Component/getComponentTests/getComponent.checkboxes.test.js +0 -156
- package/dist/utils/Component/getComponentTests/getComponent.date.test.js +0 -104
- package/dist/utils/Component/getComponentTests/getComponent.details.test.js +0 -56
- package/dist/utils/Component/getComponentTests/getComponent.email.test.js +0 -60
- package/dist/utils/Component/getComponentTests/getComponent.file.test.js +0 -60
- package/dist/utils/Component/getComponentTests/getComponent.heading.test.js +0 -31
- package/dist/utils/Component/getComponentTests/getComponent.html.test.js +0 -42
- package/dist/utils/Component/getComponentTests/getComponent.insetText.test.js +0 -29
- package/dist/utils/Component/getComponentTests/getComponent.list.test.js +0 -47
- package/dist/utils/Component/getComponentTests/getComponent.multifile.test.js +0 -66
- package/dist/utils/Component/getComponentTests/getComponent.nested.test.js +0 -211
- package/dist/utils/Component/getComponentTests/getComponent.paragraph.test.js +0 -46
- package/dist/utils/Component/getComponentTests/getComponent.phoneNumber.test.js +0 -60
- package/dist/utils/Component/getComponentTests/getComponent.radios.test.js +0 -221
- package/dist/utils/Component/getComponentTests/getComponent.select.test.js +0 -62
- package/dist/utils/Component/getComponentTests/getComponent.text.test.js +0 -60
- package/dist/utils/Component/getComponentTests/getComponent.textArea.test.js +0 -104
- package/dist/utils/Component/getComponentTests/getComponent.time.test.js +0 -80
- package/dist/utils/Component/getComponentTests/getComponent.unknown.test.js +0 -14
- package/dist/utils/Component/getComponentTests/getComponent.warningText.test.js +0 -29
- package/dist/utils/Component/getDefaultValue.js +0 -22
- package/dist/utils/Component/getDefaultValue.test.js +0 -62
- package/dist/utils/Component/getDefaultValueFromConfig.js +0 -106
- package/dist/utils/Component/getDefaultValueFromConfig.test.js +0 -141
- package/dist/utils/Component/index.js +0 -29
- package/dist/utils/Component/isEditable.js +0 -13
- package/dist/utils/Component/isEditable.test.js +0 -42
- package/dist/utils/Component/optionIsSelected.js +0 -25
- package/dist/utils/Component/optionIsSelected.test.js +0 -69
- package/dist/utils/Component/setupContainerComponentsPath.js +0 -35
- package/dist/utils/Component/setupContainerComponentsPath.test.js +0 -79
- package/dist/utils/Component/showComponent.js +0 -25
- package/dist/utils/Component/showComponent.test.js +0 -157
- package/dist/utils/Component/wrapInFormGroup.js +0 -26
- package/dist/utils/Condition/index.js +0 -17
- package/dist/utils/Condition/meetsAllConditions.js +0 -44
- package/dist/utils/Condition/meetsAllConditions.test.js +0 -109
- package/dist/utils/Condition/meetsCondition.js +0 -165
- package/dist/utils/Condition/meetsCondition.test.js +0 -899
- package/dist/utils/Condition/meetsOneCondition.js +0 -32
- package/dist/utils/Condition/meetsOneCondition.test.js +0 -101
- package/dist/utils/Condition/setupConditions.js +0 -36
- package/dist/utils/Condition/setupConditions.test.js +0 -34
- package/dist/utils/Container/getEditableComponents.js +0 -29
- package/dist/utils/Container/getEditableComponents.test.js +0 -134
- package/dist/utils/Container/index.js +0 -17
- package/dist/utils/Container/setupNesting.js +0 -53
- package/dist/utils/Container/setupNesting.test.js +0 -143
- package/dist/utils/Container/showContainer.js +0 -52
- package/dist/utils/Container/showContainer.test.js +0 -179
- package/dist/utils/Data/applyFormula.js +0 -90
- package/dist/utils/Data/applyFormula.test.js +0 -264
- package/dist/utils/Data/deleteValues.js +0 -19
- package/dist/utils/Data/deleteValues.test.js +0 -58
- package/dist/utils/Data/getAutocompleteSource.js +0 -87
- package/dist/utils/Data/getAutocompleteSource.test.js +0 -335
- package/dist/utils/Data/getDataPath.js +0 -66
- package/dist/utils/Data/getDataPath.test.js +0 -49
- package/dist/utils/Data/getOptions.js +0 -86
- package/dist/utils/Data/getOptions.test.js +0 -279
- package/dist/utils/Data/getSourceData.js +0 -44
- package/dist/utils/Data/getSourceData.test.js +0 -158
- package/dist/utils/Data/index.js +0 -35
- package/dist/utils/Data/nestInRefdataOptions.js +0 -47
- package/dist/utils/Data/nestInRefdataOptions.test.js +0 -237
- package/dist/utils/Data/refDataToOptions.js +0 -44
- package/dist/utils/Data/refDataToOptions.test.js +0 -197
- package/dist/utils/Data/setDataItem.js +0 -26
- package/dist/utils/Data/setDataItem.test.js +0 -136
- package/dist/utils/Data/setupFormData.js +0 -49
- package/dist/utils/Data/setupFormData.test.js +0 -215
- package/dist/utils/Data/setupRefDataUrlForComponent.js +0 -44
- package/dist/utils/Data/setupRefDataUrlForComponent.test.js +0 -150
- package/dist/utils/FormPage/applyConditionalProperties.js +0 -34
- package/dist/utils/FormPage/applyConditionalProperties.test.js +0 -61
- package/dist/utils/FormPage/getConditionalText.js +0 -55
- package/dist/utils/FormPage/getConditionalText.test.js +0 -163
- package/dist/utils/FormPage/getFormPage.js +0 -54
- package/dist/utils/FormPage/getFormPage.test.js +0 -206
- package/dist/utils/FormPage/getFormPages.js +0 -30
- package/dist/utils/FormPage/getFormPages.test.js +0 -97
- package/dist/utils/FormPage/getPageActions.js +0 -58
- package/dist/utils/FormPage/getPageActions.test.js +0 -115
- package/dist/utils/FormPage/getParagraphFromText.js +0 -21
- package/dist/utils/FormPage/getParagraphFromText.test.js +0 -28
- package/dist/utils/FormPage/index.js +0 -24
- package/dist/utils/FormPage/showFormPage.js +0 -52
- package/dist/utils/FormPage/showFormPage.test.js +0 -181
- package/dist/utils/FormPage/showFormPageCYA.js +0 -23
- package/dist/utils/FormPage/showFormPageCYA.test.js +0 -29
- package/dist/utils/FormPage/useComponent.js +0 -83
- package/dist/utils/FormPage/useComponent.test.js +0 -216
- package/dist/utils/Format/formatData.js +0 -27
- package/dist/utils/Format/formatData.test.js +0 -46
- package/dist/utils/Format/formatDataForComponent.js +0 -35
- package/dist/utils/Format/formatDataForComponent.test.js +0 -114
- package/dist/utils/Format/formatDataForForm.js +0 -27
- package/dist/utils/Format/formatDataForForm.test.js +0 -79
- package/dist/utils/Format/formatDataForPage.js +0 -31
- package/dist/utils/Format/formatDataForPage.test.js +0 -94
- package/dist/utils/Format/index.js +0 -21
- package/dist/utils/Hub/getFormHub.js +0 -40
- package/dist/utils/Hub/getFormHub.test.js +0 -105
- package/dist/utils/Hub/index.js +0 -15
- package/dist/utils/Meta/constants.js +0 -9
- package/dist/utils/Meta/documents/getDocuments.js +0 -15
- package/dist/utils/Meta/documents/getDocuments.test.js +0 -46
- package/dist/utils/Meta/documents/index.js +0 -19
- package/dist/utils/Meta/documents/setDocumentsForField.js +0 -30
- package/dist/utils/Meta/documents/setDocumentsForField.test.js +0 -97
- package/dist/utils/Meta/index.js +0 -17
- package/dist/utils/Operate/checkValueIsTruthy.js +0 -29
- package/dist/utils/Operate/checkValueIsTruthy.test.js +0 -43
- package/dist/utils/Operate/deleteValueInFormData.js +0 -27
- package/dist/utils/Operate/deleteValueInFormData.test.js +0 -61
- package/dist/utils/Operate/doesContainValue.js +0 -35
- package/dist/utils/Operate/doesContainValue.test.js +0 -76
- package/dist/utils/Operate/getFirstOf.js +0 -31
- package/dist/utils/Operate/getFirstOf.test.js +0 -87
- package/dist/utils/Operate/getIndexOfMatchingValueIn.js +0 -68
- package/dist/utils/Operate/getIndexOfMatchingValueIn.test.js +0 -158
- package/dist/utils/Operate/getLength.js +0 -51
- package/dist/utils/Operate/getLength.test.js +0 -90
- package/dist/utils/Operate/index.js +0 -13
- package/dist/utils/Operate/persistValueInFormData.js +0 -40
- package/dist/utils/Operate/persistValueInFormData.test.js +0 -118
- package/dist/utils/Operate/runPageOperations.js +0 -75
- package/dist/utils/Operate/runPageOperations.test.js +0 -105
- package/dist/utils/Operate/setValueInFormData.js +0 -22
- package/dist/utils/Operate/setValueInFormData.test.js +0 -45
- package/dist/utils/Operate/shouldRun.js +0 -57
- package/dist/utils/Operate/shouldRun.test.js +0 -65
- package/dist/utils/Validate/additional/conditionallyPermittedChange.js +0 -26
- package/dist/utils/Validate/additional/conditionallyPermittedChange.test.js +0 -34
- package/dist/utils/Validate/additional/conditionallyRequired.js +0 -24
- package/dist/utils/Validate/additional/conditionallyRequired.test.js +0 -74
- package/dist/utils/Validate/additional/index.js +0 -74
- package/dist/utils/Validate/additional/index.test.js +0 -130
- package/dist/utils/Validate/additional/mustBeAfter.js +0 -34
- package/dist/utils/Validate/additional/mustBeAfter.test.js +0 -109
- package/dist/utils/Validate/additional/mustBeBefore.js +0 -34
- package/dist/utils/Validate/additional/mustBeBefore.test.js +0 -77
- package/dist/utils/Validate/additional/mustBeEarlierDateTime.js +0 -57
- package/dist/utils/Validate/additional/mustBeEarlierDateTime.test.js +0 -128
- package/dist/utils/Validate/additional/mustBeGreaterThan.js +0 -22
- package/dist/utils/Validate/additional/mustBeGreaterThan.test.js +0 -57
- package/dist/utils/Validate/additional/mustBeInTheFuture.js +0 -33
- package/dist/utils/Validate/additional/mustBeInTheFuture.test.js +0 -32
- package/dist/utils/Validate/additional/mustBeInThePast.js +0 -36
- package/dist/utils/Validate/additional/mustBeInThePast.test.js +0 -32
- package/dist/utils/Validate/additional/mustBeLessThan.js +0 -22
- package/dist/utils/Validate/additional/mustBeLessThan.test.js +0 -53
- package/dist/utils/Validate/additional/mustBeLongerThan.js +0 -23
- package/dist/utils/Validate/additional/mustBeLongerThan.test.js +0 -49
- package/dist/utils/Validate/additional/mustBeNumbersOnly.js +0 -24
- package/dist/utils/Validate/additional/mustBeNumbersOnly.test.js +0 -45
- package/dist/utils/Validate/additional/mustBeOneOf.js +0 -22
- package/dist/utils/Validate/additional/mustBeOneOf.test.js +0 -37
- package/dist/utils/Validate/additional/mustBeShorterThan.js +0 -23
- package/dist/utils/Validate/additional/mustBeShorterThan.test.js +0 -49
- package/dist/utils/Validate/additional/mustBeUniqueInCollection.js +0 -40
- package/dist/utils/Validate/additional/mustBeUniqueInCollection.test.js +0 -163
- package/dist/utils/Validate/additional/mustEnterAtLeastOne.js +0 -26
- package/dist/utils/Validate/additional/mustEnterAtLeastOne.test.js +0 -37
- package/dist/utils/Validate/additional/mustHaveLessThanDecimalPlaces.js +0 -19
- package/dist/utils/Validate/additional/mustHaveLessThanDecimalPlaces.test.js +0 -37
- package/dist/utils/Validate/additional/mustNotContainSql.js +0 -19
- package/dist/utils/Validate/additional/mustNotContainSql.test.js +0 -33
- package/dist/utils/Validate/additional/mustSelectOnlyOne.js +0 -29
- package/dist/utils/Validate/additional/mustSelectOnlyOne.test.js +0 -55
- package/dist/utils/Validate/additional/utils.js +0 -35
- package/dist/utils/Validate/index.js +0 -33
- package/dist/utils/Validate/validateCollection.js +0 -50
- package/dist/utils/Validate/validateCollection.test.js +0 -134
- package/dist/utils/Validate/validateComponent.js +0 -126
- package/dist/utils/Validate/validateComponent.test.js +0 -435
- package/dist/utils/Validate/validateContainer.js +0 -52
- package/dist/utils/Validate/validateContainer.test.js +0 -115
- package/dist/utils/Validate/validateDate.js +0 -112
- package/dist/utils/Validate/validateDate.test.js +0 -133
- package/dist/utils/Validate/validateEmail.js +0 -45
- package/dist/utils/Validate/validateEmail.test.js +0 -78
- package/dist/utils/Validate/validateMultifile.js +0 -29
- package/dist/utils/Validate/validateMultifile.test.js +0 -46
- package/dist/utils/Validate/validateOnPageLoad.js +0 -24
- package/dist/utils/Validate/validateOnPageLoad.test.js +0 -89
- package/dist/utils/Validate/validatePage.js +0 -56
- package/dist/utils/Validate/validatePage.test.js +0 -795
- package/dist/utils/Validate/validateRegex.js +0 -41
- package/dist/utils/Validate/validateRegex.test.js +0 -43
- package/dist/utils/Validate/validateRequired.js +0 -37
- package/dist/utils/Validate/validateRequired.test.js +0 -64
- package/dist/utils/Validate/validateTextArea.js +0 -36
- package/dist/utils/Validate/validateTextArea.test.js +0 -71
- package/dist/utils/Validate/validateTime.js +0 -76
- package/dist/utils/Validate/validateTime.test.js +0 -116
- package/dist/utils/canOverrideFieldRequired.js +0 -23
- package/dist/utils/index.js +0 -42
|
@@ -1,399 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.toArray = exports.removeObjectWithOnlySingleIdField = exports.removeEmptyArraysAndUnusedCollectionIDs = exports.pruneCollectionEntry = exports.iterateOptions = exports.isShowEntity = exports.getNestedQuestionPath = exports.getImmediateParent = exports.getDependencyObjectFromPath = exports.getDependencies = exports.findComponentDefinitionInForm = exports.deleteNodeByPath = exports.deleteCorrespondingMetaInfo = exports.deleteComponentData = exports.addValue = void 0;
|
|
7
|
-
var _Condition = _interopRequireDefault(require("../../../utils/Condition"));
|
|
8
|
-
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
9
|
-
/* eslint-disable no-param-reassign */
|
|
10
|
-
|
|
11
|
-
/**
|
|
12
|
-
* Add a value to a map of arrays. If the key exists, append the value to the array.
|
|
13
|
-
* If not, create the map entry with that key.
|
|
14
|
-
*
|
|
15
|
-
* @param {*} key
|
|
16
|
-
* @param {*} value
|
|
17
|
-
* @param {*} multiMap
|
|
18
|
-
*/
|
|
19
|
-
const addValue = (key, value, multiMap) => {
|
|
20
|
-
if (!multiMap.has(key)) {
|
|
21
|
-
multiMap.set(key, []);
|
|
22
|
-
}
|
|
23
|
-
multiMap.get(key).push(value);
|
|
24
|
-
};
|
|
25
|
-
|
|
26
|
-
/**
|
|
27
|
-
* Given a path, remove a node from this path within an object.
|
|
28
|
-
*
|
|
29
|
-
* @param {Object} payload Javascript object from which the node will be deleted. Updated by the method.
|
|
30
|
-
* @param {String} path A string containing a decimal point delimited path specifying the node to delete.
|
|
31
|
-
* @return {void}, obj above updated.
|
|
32
|
-
*/
|
|
33
|
-
exports.addValue = addValue;
|
|
34
|
-
const deleteNodeByPath = (payload, path) => {
|
|
35
|
-
if (Array.isArray(payload)) {
|
|
36
|
-
// If payload is an array, recursively call deleteNodeByPath on each element
|
|
37
|
-
for (let i = 0; i < payload.length; i += 1) {
|
|
38
|
-
deleteNodeByPath(payload[i], path);
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
const keys = path.split('.');
|
|
42
|
-
let current = payload;
|
|
43
|
-
for (let i = 0; i < keys.length - 1; i += 1) {
|
|
44
|
-
current = current[keys[i]];
|
|
45
|
-
if (current === undefined) {
|
|
46
|
-
return;
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
if (current[keys[keys.length - 1]]) {
|
|
50
|
-
delete current[keys[keys.length - 1]];
|
|
51
|
-
}
|
|
52
|
-
};
|
|
53
|
-
|
|
54
|
-
/**
|
|
55
|
-
* Return the immediate parent of a path string passed in.
|
|
56
|
-
* Useful for processing 'options' in a form, as nested fieldIds are placed in the payload at
|
|
57
|
-
* the same level in the heirarchy as the option question they relate to.
|
|
58
|
-
*
|
|
59
|
-
* @param {String} path Decimal point delimited path.
|
|
60
|
-
* @returns {String} Immediate parent of the path passed in.
|
|
61
|
-
*/
|
|
62
|
-
exports.deleteNodeByPath = deleteNodeByPath;
|
|
63
|
-
const getImmediateParent = path => {
|
|
64
|
-
if (typeof path !== 'string' || !path.includes('.')) {
|
|
65
|
-
return null;
|
|
66
|
-
}
|
|
67
|
-
const parts = path.split('.');
|
|
68
|
-
parts.pop();
|
|
69
|
-
return parts.join('.');
|
|
70
|
-
};
|
|
71
|
-
|
|
72
|
-
/**
|
|
73
|
-
* Questions can be nested within options, eg if you answer 'yes' to a radio question, this can
|
|
74
|
-
* reveal additional nested questions.
|
|
75
|
-
* The path of the fields from these nested questions are at the same level as the original option
|
|
76
|
-
* answer, so this utility derives the nested question path from the option path.
|
|
77
|
-
*
|
|
78
|
-
* @param {String} optionPath Decimal point delimited path
|
|
79
|
-
* @param {String} nestedFieldId fieldId (dataname) of the nested question within the above option
|
|
80
|
-
* @returns {String} Fully qualified path of the nested question
|
|
81
|
-
*/
|
|
82
|
-
exports.getImmediateParent = getImmediateParent;
|
|
83
|
-
const getNestedQuestionPath = (optionPath, nestedFieldId) => {
|
|
84
|
-
const parentPath = getImmediateParent(optionPath);
|
|
85
|
-
return parentPath ? "".concat(parentPath, ".").concat(nestedFieldId) : nestedFieldId;
|
|
86
|
-
};
|
|
87
|
-
|
|
88
|
-
/**
|
|
89
|
-
* Pruning a collection payload may have resulted in objects that are only left with their 'id' field, which isn't data
|
|
90
|
-
* but added by the renderer to find the activeId. If so, remove these objects entirely as they have been pruned.
|
|
91
|
-
*
|
|
92
|
-
* @param {Array} array Array of objects. Each object which has only 1 remaining field called 'id' should be removed.
|
|
93
|
-
* @return {void}, array above updated.
|
|
94
|
-
*/
|
|
95
|
-
exports.getNestedQuestionPath = getNestedQuestionPath;
|
|
96
|
-
const removeObjectWithOnlySingleIdField = array => {
|
|
97
|
-
for (let i = array.length - 1; i >= 0; i -= 1) {
|
|
98
|
-
const obj = array[i];
|
|
99
|
-
if (Object.keys(obj).length === 1 && Object.keys(obj)[0] === 'id') {
|
|
100
|
-
array.splice(i, 1);
|
|
101
|
-
}
|
|
102
|
-
}
|
|
103
|
-
};
|
|
104
|
-
|
|
105
|
-
/**
|
|
106
|
-
* Helper method to establish all the payload paths (dependencies) that an entity (page or component) is
|
|
107
|
-
* dependent on through its show_when rule.
|
|
108
|
-
*
|
|
109
|
-
* This will be used to build a graph of chained dependencies to establish in which order
|
|
110
|
-
* to resolve dependencies. The exact rule is not required at this point, just the dependencies.
|
|
111
|
-
*
|
|
112
|
-
* The form specification allows complex show_when blocks including 1...n levels of nesting, so
|
|
113
|
-
* recursively search through the show_when block looking for all 'field' data items.
|
|
114
|
-
*
|
|
115
|
-
* @param {Object} entity Entity whose show_when rule is to be searched for 'field' data items within.
|
|
116
|
-
* @returns {Set} Set of payload paths that the entity (page or component) is dependent on.
|
|
117
|
-
*/
|
|
118
|
-
exports.removeObjectWithOnlySingleIdField = removeObjectWithOnlySingleIdField;
|
|
119
|
-
const getDependencies = entity => {
|
|
120
|
-
const findShowWhenFields = (showWhenObject, showWhenFields) => {
|
|
121
|
-
if (typeof showWhenObject === 'object' && showWhenObject !== null) {
|
|
122
|
-
if (Array.isArray(showWhenObject)) {
|
|
123
|
-
showWhenObject.forEach(value => {
|
|
124
|
-
findShowWhenFields(value, showWhenFields);
|
|
125
|
-
});
|
|
126
|
-
} else {
|
|
127
|
-
Object.keys(showWhenObject).forEach(key => {
|
|
128
|
-
if (key === 'field') {
|
|
129
|
-
showWhenFields.push(showWhenObject[key]);
|
|
130
|
-
}
|
|
131
|
-
findShowWhenFields(showWhenObject[key], showWhenFields);
|
|
132
|
-
});
|
|
133
|
-
}
|
|
134
|
-
}
|
|
135
|
-
return showWhenFields;
|
|
136
|
-
};
|
|
137
|
-
return entity.show_when ? new Set(findShowWhenFields(entity.show_when, []) || []) : null;
|
|
138
|
-
};
|
|
139
|
-
|
|
140
|
-
/**
|
|
141
|
-
* Some show_when field values point to data items that are within objects provided by
|
|
142
|
-
* external calls to refdata, eg modeOfTransport.id. These won't map directly to the path
|
|
143
|
-
* keyed components in the allComponents map, so go back up levels in the path until we find
|
|
144
|
-
* the component that creates this field.
|
|
145
|
-
*
|
|
146
|
-
* This component might not be found at all, as the dependency might be on a field that is either
|
|
147
|
-
* provided by cop-ui (eg jobHolderStaffDetails.linemanagerEmail), or by the "addToFormData" function
|
|
148
|
-
* (eg epmsSubmitted). These will be leaf level in the dependency chain so component is not required.
|
|
149
|
-
*
|
|
150
|
-
* @param {String} optionPath Decimal point delimited path
|
|
151
|
-
* @param {String} nestedFieldId fieldId (dataname) of the nested question within the above option
|
|
152
|
-
* @returns {String} Fully qualified path of the nested question
|
|
153
|
-
*
|
|
154
|
-
*/
|
|
155
|
-
exports.getDependencies = getDependencies;
|
|
156
|
-
const getDependencyObjectFromPath = (dependencyPath, allComponents) => {
|
|
157
|
-
const segments = dependencyPath.split(".");
|
|
158
|
-
for (let i = segments.length; i > 0; i -= 1) {
|
|
159
|
-
const currentPath = segments.slice(0, i).join(".");
|
|
160
|
-
const dependencyObject = allComponents.get(currentPath);
|
|
161
|
-
if (dependencyObject) return dependencyObject;
|
|
162
|
-
}
|
|
163
|
-
return null;
|
|
164
|
-
};
|
|
165
|
-
|
|
166
|
-
/**
|
|
167
|
-
*
|
|
168
|
-
* Evaluate the show_when rule to establish if the component should be shown (and the
|
|
169
|
-
* payload data should not be pruned). If there is no show_when rule, then return true.
|
|
170
|
-
*
|
|
171
|
-
* @param {*} entity A page or component that may have a show_when rule associated with it
|
|
172
|
-
* @param {*} data The payload data used to evaluate the show_when rule
|
|
173
|
-
* @returns {boolean} true if the show_when rule evaluate to true, or there is no show_when rule
|
|
174
|
-
*/
|
|
175
|
-
exports.getDependencyObjectFromPath = getDependencyObjectFromPath;
|
|
176
|
-
const isShowEntity = (entity, data) => {
|
|
177
|
-
var _entity$show_when;
|
|
178
|
-
// If there is no rule set, then the entity can be shown
|
|
179
|
-
if (!entity.show_when) {
|
|
180
|
-
return true;
|
|
181
|
-
}
|
|
182
|
-
if (((_entity$show_when = entity.show_when) === null || _entity$show_when === void 0 ? void 0 : _entity$show_when.type) === "or") {
|
|
183
|
-
return _Condition.default.meetsOne(entity, data);
|
|
184
|
-
}
|
|
185
|
-
return _Condition.default.meetsAll(entity, data);
|
|
186
|
-
};
|
|
187
|
-
|
|
188
|
-
/**
|
|
189
|
-
*
|
|
190
|
-
* Components can be assigned to pages in 2 ways in the form specification:
|
|
191
|
-
*
|
|
192
|
-
* 1 - They can be included in the page's components array with the 'use' field, e.g.
|
|
193
|
-
* {
|
|
194
|
-
* "use": "port"
|
|
195
|
-
* }
|
|
196
|
-
* This "use" value will normally match a component's id, but can match its fieldId
|
|
197
|
-
* NB. In this case, a show_when rule can be applied here, which will supercede any show_when in the component. e.g.
|
|
198
|
-
*
|
|
199
|
-
* {
|
|
200
|
-
* "use": "port",
|
|
201
|
-
* "show_when": ....
|
|
202
|
-
* }
|
|
203
|
-
*
|
|
204
|
-
* 2 - The entire component can be embedded as an entry in the page's component array.
|
|
205
|
-
*
|
|
206
|
-
*
|
|
207
|
-
* @param {*} componentId The id of the component to find in the form.
|
|
208
|
-
* @param {*} componentByIdMap A map of all the form's components keyed on Id, for better performance than searching the form.
|
|
209
|
-
* @param {*} componentByFieldIdMap A map of all the form's components keyed on fieldId, for better performance than searching the form.
|
|
210
|
-
* @returns {Object} A cloned component object, containing the full definition of that component.
|
|
211
|
-
*/
|
|
212
|
-
exports.isShowEntity = isShowEntity;
|
|
213
|
-
const findComponentDefinitionInForm = (pageComponentDef, componentByIdMap, componentByFieldIdMap) => {
|
|
214
|
-
var _ref, _componentByIdMap$get;
|
|
215
|
-
const componentInForm = (_ref = (_componentByIdMap$get = componentByIdMap.get(pageComponentDef.use)) !== null && _componentByIdMap$get !== void 0 ? _componentByIdMap$get : componentByFieldIdMap.get(pageComponentDef.use)) !== null && _ref !== void 0 ? _ref : pageComponentDef;
|
|
216
|
-
|
|
217
|
-
// Create clone of component, so processing can make changes to it without changing the form
|
|
218
|
-
const componentInFormClone = JSON.parse(JSON.stringify(componentInForm));
|
|
219
|
-
if (pageComponentDef.use && pageComponentDef.show_when) {
|
|
220
|
-
componentInFormClone.show_when = pageComponentDef.show_when;
|
|
221
|
-
}
|
|
222
|
-
return componentInFormClone;
|
|
223
|
-
};
|
|
224
|
-
|
|
225
|
-
/**
|
|
226
|
-
*
|
|
227
|
-
* When documents are added to the payload of type multifile, they are also added to a section of the payload
|
|
228
|
-
* 'meta', specifically an array 'documents'. When we remove the multifile elements, we need to remove
|
|
229
|
-
* the corresponding meta.document entries.
|
|
230
|
-
*
|
|
231
|
-
* @param {*} component The component definition being deleted that needs corresponding meta data also deleted
|
|
232
|
-
* @param {*} collectionDataObject The payload containing the file data being deleted (for which the corresponding meta needs deleting)
|
|
233
|
-
* @param {*} formData The entire payload, which will include the meta section
|
|
234
|
-
* @returns {void}, as the formData will be updated in situ
|
|
235
|
-
*/
|
|
236
|
-
exports.findComponentDefinitionInForm = findComponentDefinitionInForm;
|
|
237
|
-
const deleteCorrespondingMetaInfo = (component, collectionDataObject, formData) => {
|
|
238
|
-
const {
|
|
239
|
-
meta: {
|
|
240
|
-
documents
|
|
241
|
-
}
|
|
242
|
-
} = formData;
|
|
243
|
-
const fileDataBeingDeleted = collectionDataObject[component.fieldId];
|
|
244
|
-
if (!documents || !fileDataBeingDeleted) return;
|
|
245
|
-
const fileDataAsArray = Array.isArray(fileDataBeingDeleted) ? fileDataBeingDeleted : [fileDataBeingDeleted];
|
|
246
|
-
// Iterate backwards to avoid index shifting when removing elements
|
|
247
|
-
for (let i = fileDataAsArray.length - 1; i >= 0; i -= 1) {
|
|
248
|
-
const matchIndex = documents.findIndex(metaDocument => metaDocument.url === fileDataAsArray[i].url);
|
|
249
|
-
if (matchIndex !== -1) {
|
|
250
|
-
documents.splice(matchIndex, 1);
|
|
251
|
-
}
|
|
252
|
-
}
|
|
253
|
-
};
|
|
254
|
-
|
|
255
|
-
/**
|
|
256
|
-
* After the payload has been cleansed of individual data items, empty arrays and objects may remain.
|
|
257
|
-
* Removing an array (when the payload for a collection) may leave a redundant activeId field. The active Id
|
|
258
|
-
* fields are not part of the payload data, but added by the react renderer to track which collection object
|
|
259
|
-
* is currently being worked on, so can be removed.
|
|
260
|
-
*
|
|
261
|
-
* To tidy this all up, recursively empty arrays and their associated "ActiveId" fields from a nested payload.
|
|
262
|
-
*
|
|
263
|
-
* This function traverses a given payload, which can be an array or an object, and performs the following operations:
|
|
264
|
-
* 1. If an empty array is found inside an array, it is removed using `splice`.
|
|
265
|
-
* 2. If an empty array is found inside an object:
|
|
266
|
-
* - It is removed from the object.
|
|
267
|
-
* - If there is a corresponding `<key>ActiveId` field, that field is also removed.
|
|
268
|
-
* 3. The function operates recursively to handle deeply nested structures.
|
|
269
|
-
*
|
|
270
|
-
* @param {any} payload - The input data structure, which can be an array or an object.
|
|
271
|
-
*
|
|
272
|
-
*/
|
|
273
|
-
exports.deleteCorrespondingMetaInfo = deleteCorrespondingMetaInfo;
|
|
274
|
-
const removeEmptyArraysAndUnusedCollectionIDs = payload => {
|
|
275
|
-
if (Array.isArray(payload)) {
|
|
276
|
-
for (let i = payload.length - 1; i >= 0; i -= 1) {
|
|
277
|
-
if (Array.isArray(payload[i]) && payload[i].length === 0) {
|
|
278
|
-
payload.splice(i, 1);
|
|
279
|
-
} else {
|
|
280
|
-
removeEmptyArraysAndUnusedCollectionIDs(payload[i]); // Recurse for nested structures
|
|
281
|
-
}
|
|
282
|
-
// When unwinding out of the recursion, we may have emptied an object which is the remaining element of an
|
|
283
|
-
// array, in which case remove the element
|
|
284
|
-
if (typeof payload[i] === 'object' && Object.keys(payload[i]).length === 0) {
|
|
285
|
-
payload.splice(i, 1);
|
|
286
|
-
}
|
|
287
|
-
}
|
|
288
|
-
} else if (payload !== null && typeof payload === 'object') {
|
|
289
|
-
Object.keys(payload).forEach(key => {
|
|
290
|
-
if (Array.isArray(payload[key]) && payload[key].length === 0) {
|
|
291
|
-
// If the array being removed has an activeId associated with it, remove it
|
|
292
|
-
if (payload["".concat(key, "ActiveId")]) {
|
|
293
|
-
delete payload["".concat(key, "ActiveId")];
|
|
294
|
-
}
|
|
295
|
-
delete payload["".concat(key, "ActiveId")];
|
|
296
|
-
if (payload[key]) {
|
|
297
|
-
delete payload[key];
|
|
298
|
-
}
|
|
299
|
-
} else {
|
|
300
|
-
removeEmptyArraysAndUnusedCollectionIDs(payload[key]); // Recurse for nested structures
|
|
301
|
-
}
|
|
302
|
-
});
|
|
303
|
-
}
|
|
304
|
-
};
|
|
305
|
-
|
|
306
|
-
/**
|
|
307
|
-
* Helper method to go through each option calling a passed in function for any nested fields.
|
|
308
|
-
* @param {Object} component The form component representing the path being deleted
|
|
309
|
-
* @param {Function} action The action to perform on each nested question. Varies for collections and non-collections
|
|
310
|
-
* @return {void}, obj above updated.
|
|
311
|
-
*/
|
|
312
|
-
exports.removeEmptyArraysAndUnusedCollectionIDs = removeEmptyArraysAndUnusedCollectionIDs;
|
|
313
|
-
const iterateOptions = (component, action) => {
|
|
314
|
-
var _component$data;
|
|
315
|
-
if (component !== null && component !== void 0 && (_component$data = component.data) !== null && _component$data !== void 0 && _component$data.options) {
|
|
316
|
-
var _component$data2;
|
|
317
|
-
component === null || component === void 0 || (_component$data2 = component.data) === null || _component$data2 === void 0 || (_component$data2 = _component$data2.options) === null || _component$data2 === void 0 || _component$data2.forEach(option => {
|
|
318
|
-
var _option$nested;
|
|
319
|
-
(_option$nested = option.nested) === null || _option$nested === void 0 || _option$nested.forEach(action);
|
|
320
|
-
});
|
|
321
|
-
}
|
|
322
|
-
};
|
|
323
|
-
|
|
324
|
-
/**
|
|
325
|
-
* Delete a component's payload item from the overall payload.
|
|
326
|
-
* A component can be defined in >1 places in the form spec. To cater for this,
|
|
327
|
-
* if the componentsToKeep counter tells us that there is > 1 uses of this component
|
|
328
|
-
* still unaccounted for in the form then don't delete, but reduce the count by 1.
|
|
329
|
-
*
|
|
330
|
-
* When the counter reaches 1 we know all other occurences of the component have been resolved
|
|
331
|
-
* so it is safe to delete.
|
|
332
|
-
*
|
|
333
|
-
*
|
|
334
|
-
* @param {*} payload The form payload from which to delete the component data
|
|
335
|
-
* @param {*} path The payload path of the component
|
|
336
|
-
* @param {*} component The component whose data we should attempt to delete
|
|
337
|
-
* @param {*} componentsToKeep A list of all components with a count of their number of uses in the form
|
|
338
|
-
*/
|
|
339
|
-
exports.iterateOptions = iterateOptions;
|
|
340
|
-
const deleteComponentData = (payload, path, component, componentsToKeep) => {
|
|
341
|
-
if (componentsToKeep[path] > 1) {
|
|
342
|
-
componentsToKeep[path] -= 1;
|
|
343
|
-
} else {
|
|
344
|
-
if (component.preserveInPayload) return;
|
|
345
|
-
deleteNodeByPath(payload, path);
|
|
346
|
-
|
|
347
|
-
// If the component has options, go through each option removing the data for any nested fields. Required as nested options are in the payload at the same heirarchical level.
|
|
348
|
-
iterateOptions(component, nested => {
|
|
349
|
-
const nestedQuestionPath = getNestedQuestionPath(path, nested.fieldId);
|
|
350
|
-
if (componentsToKeep[nestedQuestionPath] > 1) {
|
|
351
|
-
componentsToKeep[nestedQuestionPath] -= 1;
|
|
352
|
-
} else {
|
|
353
|
-
deleteNodeByPath(payload, nestedQuestionPath);
|
|
354
|
-
}
|
|
355
|
-
});
|
|
356
|
-
}
|
|
357
|
-
};
|
|
358
|
-
|
|
359
|
-
/**
|
|
360
|
-
*
|
|
361
|
-
* Takes a single page collection payload object and removes the payload items specified in the componentsToPrune list
|
|
362
|
-
* as long as they don't appear in the componentsToKeep list.
|
|
363
|
-
*
|
|
364
|
-
* Additionally, if the component type is multifile, remove the corresponding data entries that will have been created
|
|
365
|
-
* in the meta section of the payload by the form renderer.
|
|
366
|
-
*
|
|
367
|
-
* @param {Set} pathsToKeep paths that we cannot delete from the collectionDataObject
|
|
368
|
-
* @param {Map} componentsToPrune paths that we should delete, as long as they are not in the pathsToKeep
|
|
369
|
-
* @param {Object} collectionDataObject the payload from which to delete the paths
|
|
370
|
-
* @param {Object} formData The form data, whose meta section may include corresponding documents entries for multifile entries
|
|
371
|
-
*/
|
|
372
|
-
exports.deleteComponentData = deleteComponentData;
|
|
373
|
-
const pruneCollectionEntry = (pathsToKeep, componentsToPrune, collectionDataObject, formData) => {
|
|
374
|
-
componentsToPrune.forEach(component => {
|
|
375
|
-
if (!pathsToKeep.has(component.fieldId)) {
|
|
376
|
-
if (component.type === "multifile") {
|
|
377
|
-
deleteCorrespondingMetaInfo(component, collectionDataObject, formData);
|
|
378
|
-
}
|
|
379
|
-
if (component.preserveInPayload) return;
|
|
380
|
-
deleteNodeByPath(collectionDataObject, component.fieldId);
|
|
381
|
-
|
|
382
|
-
// If the component has options, go through each option removing the data for any nested fields. Required as nested options are in the payload at the same heirarchical level.
|
|
383
|
-
iterateOptions(component, nested => {
|
|
384
|
-
const nestedQuestionPath = getNestedQuestionPath(component.fieldId, nested.fieldId);
|
|
385
|
-
if (!pathsToKeep.has(nestedQuestionPath)) {
|
|
386
|
-
deleteNodeByPath(collectionDataObject, nestedQuestionPath);
|
|
387
|
-
}
|
|
388
|
-
});
|
|
389
|
-
}
|
|
390
|
-
});
|
|
391
|
-
};
|
|
392
|
-
|
|
393
|
-
/*
|
|
394
|
-
* Converts an object to an array if it isn't already, for use when combining show when rules.
|
|
395
|
-
*/
|
|
396
|
-
exports.pruneCollectionEntry = pruneCollectionEntry;
|
|
397
|
-
const toArray = value => Array.isArray(value) ? value : [value];
|
|
398
|
-
exports.toArray = toArray;
|
|
399
|
-
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJuYW1lcyI6WyJfQ29uZGl0aW9uIiwiX2ludGVyb3BSZXF1aXJlRGVmYXVsdCIsInJlcXVpcmUiLCJlIiwiX19lc01vZHVsZSIsImRlZmF1bHQiLCJhZGRWYWx1ZSIsImtleSIsInZhbHVlIiwibXVsdGlNYXAiLCJoYXMiLCJzZXQiLCJnZXQiLCJwdXNoIiwiZXhwb3J0cyIsImRlbGV0ZU5vZGVCeVBhdGgiLCJwYXls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uY2llcyA9IChlbnRpdHkpID0+IHtcblxuICAgIGNvbnN0IGZpbmRTaG93V2hlbkZpZWxkcyA9IChzaG93V2hlbk9iamVjdCwgc2hvd1doZW5GaWVsZHMpID0+IHtcbiAgICAgICAgaWYgKHR5cGVvZiBzaG93V2hlbk9iamVjdCA9PT0gJ29iamVjdCcgJiYgc2hvd1doZW5PYmplY3QgIT09IG51bGwpIHtcbiAgICAgICAgICAgIGlmIChBcnJheS5pc0FycmF5KHNob3dXaGVuT2JqZWN0KSkge1xuICAgICAgICAgICAgICAgIHNob3dXaGVuT2JqZWN0LmZvckVhY2goKHZhbHVlKSA9PiB7XG4gICAgICAgICAgICAgICAgICAgIGZpbmRTaG93V2hlbkZpZWxkcyh2YWx1ZSwgc2hvd1doZW5GaWVsZHMpO1xuICAgICAgICAgICAgICAgIH0pO1xuICAgICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgICAgICBPYmplY3Qua2V5cyhzaG93V2hlbk9iamVjdCkuZm9yRWFjaCgoa2V5KSA9PiB7XG4gICAgICAgICAgICAgICAgICAgIGlmIChrZXkgPT09ICdmaWVsZCcpIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIHNob3dXaGVuRmllbGRzLnB1c2goc2hvd1doZW5PYmplY3Rba2V5XSk7XG4gICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAgICAgZmluZFNob3dXaGVuRmllbGRzKHNob3dXaGVuT2JqZWN0W2tleV0sIHNob3dXaGVuRmllbGRzKTtcbiAgICAgICAgICAgICAgICB9KTtcbiAgICAgICAgICAgIH1cbiAgICAgICAgfVxuICAgICAgICByZXR1cm4gc2hvd1doZW5GaWVsZHM7XG4gICAgfTtcbiAgICByZXR1cm4gZW50aXR5LnNob3dfd2hlbiA/IG5ldyBTZXQoZmluZFNob3dXaGVuRmllbGRzKGVudGl0eS5zaG93X3doZW4sIFtdKSB8fCBbXSkgOiBudWxsO1xufTtcblxuLyoqXG4gKiBTb21lIHNob3dfd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9PT0gMCkge1xuICAgICAgICAgICAgICAgIHBheWxvYWQuc3BsaWNlKGksIDEpO1xuICAgICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgICAgICByZW1vdmVFbXB0eUFycmF5c0FuZFVudXNlZENvbGxlY3Rpb25JRHMocGF5bG9hZFtpXSk7IC8vIFJlY3Vyc2UgZm9yIG5lc3RlZCBzdHJ1Y3R1cmVzXG4gICAgICAgICAgICB9XG4gICAgICAgICAgICAvLyBXaGVuIHVud2luZGluZyBvdXQgb2YgdGhlIHJlY3Vyc2lvbiwgd2UgbWF5IGhhdmUgZW1wdGllZCBhbiBvYmplY3Qgd2hpY2ggaXMgdGhlIHJlbWFpbmluZyBlbGVtZW50IG9mIGFuIFxuICAgICAgICAgICAgLy8gYXJyYXksIGluIHdoaWNoIGNhc2UgcmVtb3ZlIHRoZSBlbGVtZW50XG4gICAgICAgICAgICBpZiAodHlwZW9mIHBheWxvYWRbaV0gPT09ICdvYmplY3QnICYmIE9iamVjdC5rZXlzKHBheWxvYWRbaV0pLmxlbmd0aCA9PT0gMCkge1xuICAgICAgICAgICAgICAgIHBheWxvYWQuc3BsaWNlKGksIDEpO1xuICAgICAgICAgICAgfVxuICAgICAgICB9XG4gICAgfSBlbHNlIGlmIChwYXlsb2FkICE9PSBudWxsICYmIHR5cGVvZiBwYXlsb2FkID09PSAnb2JqZWN0Jykge1xuICAgICAgICBPYmplY3Qua2V5cyhwYXlsb2FkKS5mb3JFYWNoKChrZXkpID0+IHtcbiAgICAgICAgICAgIGlmIChBcnJheS5pc0FycmF5KHBheWxvYWRba2V5XSkgJiYgcGF5bG9hZFtrZXldLmxlbmd0aCA9PT0gMCkge1xuICAgICAgICAgICAgICAgIC8vIElmIHRoZSBhcnJheSBiZWluZyByZW1vdmVkIGhhcyBhbiBhY3RpdmVJZCBhc3NvY2lhdGVkIHdpdGggaXQsIHJlbW92ZSBpdFxuICAgICAgICAgICAgICAgIGlmIChwYXlsb2FkW2Ake2tleX1BY3Rp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