@hmcts/opal-frontend-common 0.0.17 → 0.0.18
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/components/abstract/abstract-form-alias-base/index.d.ts +118 -5
- package/components/abstract/abstract-form-alias-base/interfaces/index.d.ts +7 -5
- package/components/abstract/abstract-form-array-base/index.d.ts +159 -5
- package/components/abstract/abstract-form-array-base/interfaces/index.d.ts +7 -5
- package/components/abstract/abstract-form-array-parent-base/index.d.ts +16 -5
- package/components/abstract/abstract-form-array-removal-base/index.d.ts +52 -5
- package/components/abstract/abstract-form-array-removal-base/interfaces/index.d.ts +7 -5
- package/components/abstract/abstract-form-base/index.d.ts +253 -5
- package/components/abstract/abstract-form-base/interfaces/index.d.ts +34 -5
- package/components/abstract/abstract-form-parent-base/index.d.ts +36 -5
- package/components/abstract/abstract-sortable-table/index.d.ts +82 -5
- package/components/abstract/abstract-sortable-table/interfaces/index.d.ts +10 -5
- package/components/abstract/abstract-sortable-table/types/index.d.ts +5 -5
- package/components/abstract/abstract-sortable-table-pagination/index.d.ts +36 -5
- package/components/abstract/abstract-tab-data/index.d.ts +86 -5
- package/components/abstract/interfaces/index.d.ts +27 -5
- package/components/alphagov/alphagov-accessible-autocomplete/index.d.ts +66 -5
- package/components/alphagov/alphagov-accessible-autocomplete/interfaces/index.d.ts +6 -5
- package/components/govuk/govuk-accordion/index.d.ts +16 -5
- package/components/govuk/govuk-back-link/index.d.ts +17 -5
- package/components/govuk/govuk-button/index.d.ts +17 -5
- package/components/govuk/govuk-cancel-link/index.d.ts +15 -5
- package/components/govuk/govuk-checkboxes/index.d.ts +44 -5
- package/components/govuk/govuk-checkboxes/interfaces/index.d.ts +18 -5
- package/components/govuk/govuk-date-input/index.d.ts +32 -5
- package/components/govuk/govuk-date-input/interfaces/index.d.ts +13 -5
- package/components/govuk/govuk-details/index.d.ts +9 -5
- package/components/govuk/govuk-error-summary/index.d.ts +19 -5
- package/components/govuk/govuk-footer/index.d.ts +15 -5
- package/components/govuk/govuk-footer/interfaces/index.d.ts +7 -5
- package/components/govuk/govuk-header/index.d.ts +26 -5
- package/components/govuk/govuk-header/interfaces/index.d.ts +6 -5
- package/components/govuk/govuk-heading-with-caption/index.d.ts +12 -5
- package/components/govuk/govuk-inset-text/index.d.ts +9 -5
- package/components/govuk/govuk-notification-banner/index.d.ts +14 -5
- package/components/govuk/govuk-pagination/index.d.ts +47 -5
- package/components/govuk/govuk-panel/index.d.ts +10 -5
- package/components/govuk/govuk-radio/index.d.ts +47 -5
- package/components/govuk/govuk-radio/interfaces/index.d.ts +23 -5
- package/components/govuk/govuk-select/index.d.ts +25 -5
- package/components/govuk/govuk-select/interfaces/index.d.ts +6 -5
- package/components/govuk/govuk-summary-card-list/index.d.ts +31 -5
- package/components/govuk/govuk-summary-list/index.d.ts +49 -5
- package/components/govuk/govuk-table/index.d.ts +31 -5
- package/components/govuk/govuk-tabs/index.d.ts +39 -5
- package/components/govuk/govuk-tag/index.d.ts +10 -5
- package/components/govuk/govuk-task-list/index.d.ts +18 -5
- package/components/govuk/govuk-text-area/index.d.ts +24 -5
- package/components/govuk/govuk-text-input/index.d.ts +20 -5
- package/components/govuk/govuk-text-input-prefix-suffix/index.d.ts +25 -5
- package/components/govuk/helpers/index.d.ts +4 -3
- package/components/moj/moj-alert/index.d.ts +47 -0
- package/components/moj/moj-badge/index.d.ts +10 -5
- package/components/moj/moj-button-menu/index.d.ts +21 -5
- package/components/moj/moj-date-picker/index.d.ts +43 -5
- package/components/moj/moj-header/index.d.ts +26 -5
- package/components/moj/moj-header/interfaces/index.d.ts +6 -5
- package/components/moj/moj-notification-badge/index.d.ts +9 -5
- package/components/moj/moj-page-header/index.d.ts +9 -5
- package/components/moj/moj-pagination/index.d.ts +165 -5
- package/components/moj/moj-primary-navigation/index.d.ts +50 -5
- package/components/moj/moj-sortable-table/index.d.ts +55 -5
- package/components/moj/moj-sub-navigation/index.d.ts +43 -5
- package/components/moj/moj-ticket-panel/index.d.ts +11 -5
- package/components/moj/moj-timeline/index.d.ts +13 -5
- package/constants/index.d.ts +8 -5
- package/directives/capitalisation/index.d.ts +17 -5
- package/fesm2022/hmcts-opal-frontend-common-components-moj-moj-alert.mjs +211 -0
- package/fesm2022/hmcts-opal-frontend-common-components-moj-moj-alert.mjs.map +1 -0
- package/fesm2022/hmcts-opal-frontend-common-components-moj-moj-sub-navigation.mjs +2 -2
- package/fesm2022/hmcts-opal-frontend-common-components-moj-moj-sub-navigation.mjs.map +1 -1
- package/guards/auth/index.d.ts +7 -5
- package/guards/can-deactivate/index.d.ts +10 -5
- package/guards/can-deactivate/interfaces/index.d.ts +7 -5
- package/guards/can-deactivate/types/index.d.ts +6 -5
- package/guards/has-flow-state/index.d.ts +5 -5
- package/guards/helpers/index.d.ts +30 -3
- package/guards/route-permissions/index.d.ts +5 -5
- package/guards/signed-in/index.d.ts +9 -3
- package/guards/types/index.d.ts +5 -5
- package/index.d.ts +2 -5
- package/interceptors/http-error/index.d.ts +5 -5
- package/package.json +6 -6
- package/pages/index.d.ts +5 -5
- package/pages/routing/constants/index.d.ts +7 -5
- package/pages/routing/interfaces/index.d.ts +28 -5
- package/pipes/date-format/index.d.ts +13 -5
- package/pipes/days-ago/index.d.ts +10 -5
- package/resolvers/title/index.d.ts +13 -5
- package/resolvers/user-state/index.d.ts +8 -3
- package/services/app-initializer-service/index.d.ts +28 -5
- package/services/app-insights-service/index.d.ts +17 -5
- package/services/auth-service/constants/index.d.ts +5 -5
- package/services/auth-service/index.d.ts +12 -5
- package/services/auth-service/interfaces/index.d.ts +8 -5
- package/services/date-service/index.d.ts +147 -5
- package/services/launch-darkly-service/index.d.ts +44 -5
- package/services/launch-darkly-service/mocks/index.d.ts +17 -5
- package/services/permissions-service/index.d.ts +17 -5
- package/services/session-service/constants/index.d.ts +5 -5
- package/services/session-service/index.d.ts +33 -5
- package/services/session-service/interfaces/index.d.ts +27 -5
- package/services/session-service/mocks/index.d.ts +7 -5
- package/services/sort-service/index.d.ts +67 -5
- package/services/sort-service/interfaces/index.d.ts +15 -5
- package/services/transfer-state-service/index.d.ts +31 -5
- package/services/transfer-state-service/interfaces/index.d.ts +19 -5
- package/services/transfer-state-service/mocks/index.d.ts +17 -5
- package/services/transformation-service/index.d.ts +33 -5
- package/services/transformation-service/interfaces/index.d.ts +8 -5
- package/services/utils-service/index.d.ts +88 -5
- package/stores/global/index.d.ts +42 -5
- package/stores/global/interfaces/index.d.ts +6 -5
- package/stores/global/types/index.d.ts +5 -5
- package/validators/alphabetical-text/index.d.ts +5 -5
- package/validators/amount/index.d.ts +5 -5
- package/validators/date-after-year/index.d.ts +5 -5
- package/validators/date-before/index.d.ts +5 -5
- package/validators/date-of-birth/index.d.ts +5 -5
- package/validators/future-date/index.d.ts +5 -5
- package/validators/invalid-value/index.d.ts +5 -5
- package/validators/national-insurance-number/index.d.ts +5 -5
- package/validators/numerical-only/index.d.ts +5 -5
- package/validators/optional-max-length/index.d.ts +5 -5
- package/validators/optional-valid-date/index.d.ts +5 -5
- package/validators/optional-valid-email-address/index.d.ts +5 -5
- package/validators/optional-valid-telephone/index.d.ts +5 -5
- package/validators/over-eighteen/index.d.ts +15 -3
- package/validators/past-date/index.d.ts +5 -5
- package/validators/special-characters/index.d.ts +5 -5
- package/validators/two-decimal-places/index.d.ts +5 -5
- package/validators/valid-value/index.d.ts +5 -5
- package/components/abstract/abstract-form-alias-base/abstract-form-alias-base.component.d.ts +0 -115
- package/components/abstract/abstract-form-alias-base/interfaces/abstract-form-alias-base-alias-controls.interface.d.ts +0 -4
- package/components/abstract/abstract-form-alias-base/interfaces/public-api.d.ts +0 -1
- package/components/abstract/abstract-form-alias-base/public-api.d.ts +0 -1
- package/components/abstract/abstract-form-array-base/abstract-form-array-base.component.d.ts +0 -156
- package/components/abstract/abstract-form-array-base/interfaces/abstract-form-array-base-form-array-controls.interface.d.ts +0 -4
- package/components/abstract/abstract-form-array-base/interfaces/public-api.d.ts +0 -1
- package/components/abstract/abstract-form-array-base/public-api.d.ts +0 -1
- package/components/abstract/abstract-form-array-parent-base/abstract-form-array-parent-base.component.d.ts +0 -13
- package/components/abstract/abstract-form-array-parent-base/public-api.d.ts +0 -1
- package/components/abstract/abstract-form-array-removal-base/abstract-form-array-removal-base.component.d.ts +0 -44
- package/components/abstract/abstract-form-array-removal-base/interfaces/abstract-form-array-removal-base-control-value.interface.d.ts +0 -5
- package/components/abstract/abstract-form-array-removal-base/interfaces/public-api.d.ts +0 -1
- package/components/abstract/abstract-form-array-removal-base/public-api.d.ts +0 -1
- package/components/abstract/abstract-form-base/abstract-form-base.component.d.ts +0 -230
- package/components/abstract/abstract-form-base/interfaces/abstract-form-base-field-error.interface.d.ts +0 -6
- package/components/abstract/abstract-form-base/interfaces/abstract-form-base-field-errors.interface.d.ts +0 -4
- package/components/abstract/abstract-form-base/interfaces/abstract-form-base-form-error.interface.d.ts +0 -6
- package/components/abstract/abstract-form-base/interfaces/abstract-form-base-form.interface.d.ts +0 -4
- package/components/abstract/abstract-form-base/interfaces/abstract-form-base-high-priority-form-error.interface.d.ts +0 -5
- package/components/abstract/abstract-form-base/interfaces/abstract-form-base-status.interface.d.ts +0 -3
- package/components/abstract/abstract-form-base/interfaces/public-api.d.ts +0 -6
- package/components/abstract/abstract-form-base/public-api.d.ts +0 -1
- package/components/abstract/abstract-form-parent-base/abstract-form-parent-base.component.d.ts +0 -33
- package/components/abstract/abstract-form-parent-base/public-api.d.ts +0 -1
- package/components/abstract/abstract-sortable-table/abstract-sortable-table.component.d.ts +0 -79
- package/components/abstract/abstract-sortable-table/interfaces/abstract-sortable-table.interfaces.d.ts +0 -7
- package/components/abstract/abstract-sortable-table/interfaces/public-api.d.ts +0 -1
- package/components/abstract/abstract-sortable-table/public-api.d.ts +0 -1
- package/components/abstract/abstract-sortable-table/types/abstract-sortable-table-sort-direction.type.d.ts +0 -1
- package/components/abstract/abstract-sortable-table/types/abstract-sortable-table-sortable-values.type.d.ts +0 -1
- package/components/abstract/abstract-sortable-table/types/public-api.d.ts +0 -2
- package/components/abstract/abstract-sortable-table-pagination/abstract-sortable-table-pagination.component.d.ts +0 -31
- package/components/abstract/abstract-sortable-table-pagination/public-api.d.ts +0 -1
- package/components/abstract/abstract-tab-data/abstract-tab-data.d.ts +0 -83
- package/components/abstract/abstract-tab-data/public-api.d.ts +0 -1
- package/components/abstract/interfaces/abstract-form-array-control-validation.interface.d.ts +0 -5
- package/components/abstract/interfaces/abstract-form-array-control.interface.d.ts +0 -5
- package/components/abstract/interfaces/abstract-form-array-controls.interface.d.ts +0 -4
- package/components/abstract/interfaces/abstract-form-base-form-error-summary-message.interface.d.ts +0 -4
- package/components/abstract/interfaces/abstract-form-control-error-message.interface.d.ts +0 -3
- package/components/abstract/interfaces/public-api.d.ts +0 -6
- package/components/alphagov/alphagov-accessible-autocomplete/alphagov-accessible-autocomplete.component.d.ts +0 -59
- package/components/alphagov/alphagov-accessible-autocomplete/interfaces/alphagov-accessible-autocomplete-item.interface.d.ts +0 -4
- package/components/alphagov/alphagov-accessible-autocomplete/interfaces/public-api.d.ts +0 -1
- package/components/alphagov/alphagov-accessible-autocomplete/public-api.d.ts +0 -1
- package/components/govuk/govuk-accordion/govuk-accordion.component.d.ts +0 -13
- package/components/govuk/govuk-accordion/public-api.d.ts +0 -1
- package/components/govuk/govuk-back-link/govuk-back-link.component.d.ts +0 -14
- package/components/govuk/govuk-back-link/public-api.d.ts +0 -1
- package/components/govuk/govuk-button/govuk-button.component.d.ts +0 -14
- package/components/govuk/govuk-button/public-api.d.ts +0 -1
- package/components/govuk/govuk-cancel-link/govuk-cancel-link.component.d.ts +0 -12
- package/components/govuk/govuk-cancel-link/public-api.d.ts +0 -1
- package/components/govuk/govuk-checkboxes/govuk-checkboxes-conditional/govuk-checkboxes-conditional.component.d.ts +0 -10
- package/components/govuk/govuk-checkboxes/govuk-checkboxes-divider/govuk-checkboxes-divider.component.d.ts +0 -5
- package/components/govuk/govuk-checkboxes/govuk-checkboxes-item/govuk-checkboxes-item.component.d.ts +0 -16
- package/components/govuk/govuk-checkboxes/govuk-checkboxes.component.d.ts +0 -10
- package/components/govuk/govuk-checkboxes/interfaces/govuk-checkboxes-input.interface.d.ts +0 -17
- package/components/govuk/govuk-checkboxes/interfaces/public-api.d.ts +0 -1
- package/components/govuk/govuk-checkboxes/public-api.d.ts +0 -4
- package/components/govuk/govuk-date-input/govuk-date-input.component.d.ts +0 -18
- package/components/govuk/govuk-date-input/interfaces/govuk-date-input.interface.d.ts +0 -12
- package/components/govuk/govuk-date-input/interfaces/public-api.d.ts +0 -1
- package/components/govuk/govuk-date-input/public-api.d.ts +0 -1
- package/components/govuk/govuk-details/govuk-details.component.d.ts +0 -6
- package/components/govuk/govuk-details/public-api.d.ts +0 -1
- package/components/govuk/govuk-error-summary/govuk-error-summary.component.d.ts +0 -16
- package/components/govuk/govuk-error-summary/public-api.d.ts +0 -1
- package/components/govuk/govuk-footer/govuk-footer.component.d.ts +0 -7
- package/components/govuk/govuk-footer/interfaces/govuk-footer-links.interface.d.ts +0 -5
- package/components/govuk/govuk-footer/interfaces/public-api.d.ts +0 -1
- package/components/govuk/govuk-footer/public-api.d.ts +0 -1
- package/components/govuk/govuk-header/govuk-header-navigation-item/govuk-header-navigation-item.component.d.ts +0 -12
- package/components/govuk/govuk-header/govuk-header.component.d.ts +0 -7
- package/components/govuk/govuk-header/interfaces/govuk-header-links.interface.d.ts +0 -4
- package/components/govuk/govuk-header/interfaces/public-api.d.ts +0 -1
- package/components/govuk/govuk-header/public-api.d.ts +0 -2
- package/components/govuk/govuk-heading-with-caption/govuk-heading-with-caption.component.d.ts +0 -9
- package/components/govuk/govuk-heading-with-caption/public-api.d.ts +0 -1
- package/components/govuk/govuk-inset-text/govuk-inset-text.component.d.ts +0 -6
- package/components/govuk/govuk-inset-text/public-api.d.ts +0 -1
- package/components/govuk/govuk-notification-banner/govuk-notification-banner.component.d.ts +0 -10
- package/components/govuk/govuk-notification-banner/public-api.d.ts +0 -1
- package/components/govuk/govuk-pagination/govuk-pagination.component.d.ts +0 -44
- package/components/govuk/govuk-pagination/public-api.d.ts +0 -1
- package/components/govuk/govuk-panel/govuk-panel.component.d.ts +0 -7
- package/components/govuk/govuk-panel/public-api.d.ts +0 -1
- package/components/govuk/govuk-radio/govuk-radio.component.d.ts +0 -11
- package/components/govuk/govuk-radio/govuk-radios-conditional/govuk-radios-conditional.component.d.ts +0 -10
- package/components/govuk/govuk-radio/govuk-radios-divider/govuk-radios-divider.component.d.ts +0 -5
- package/components/govuk/govuk-radio/govuk-radios-item/govuk-radios-item.component.d.ts +0 -18
- package/components/govuk/govuk-radio/interfaces/govuk-radio-input.interface.d.ts +0 -17
- package/components/govuk/govuk-radio/interfaces/govuk-radio-options.interface.d.ts +0 -4
- package/components/govuk/govuk-radio/interfaces/public-api.d.ts +0 -2
- package/components/govuk/govuk-radio/public-api.d.ts +0 -4
- package/components/govuk/govuk-select/govuk-select.component.d.ts +0 -18
- package/components/govuk/govuk-select/interfaces/govuk-select-options.interface.d.ts +0 -4
- package/components/govuk/govuk-select/interfaces/public-api.d.ts +0 -1
- package/components/govuk/govuk-select/public-api.d.ts +0 -1
- package/components/govuk/govuk-summary-card-list/govuk-summary-card-action/govuk-summary-card-action.component.d.ts +0 -17
- package/components/govuk/govuk-summary-card-list/govuk-summary-card-list.component.d.ts +0 -12
- package/components/govuk/govuk-summary-card-list/public-api.d.ts +0 -2
- package/components/govuk/govuk-summary-list/govuk-summary-list-row/govuk-summary-list-row-actions/govuk-summary-list-row-action-item/govuk-summary-list-row-action-item.component.d.ts +0 -15
- package/components/govuk/govuk-summary-list/govuk-summary-list-row/govuk-summary-list-row-actions/govuk-summary-list-row-actions.component.d.ts +0 -5
- package/components/govuk/govuk-summary-list/govuk-summary-list-row/govuk-summary-list-row.component.d.ts +0 -20
- package/components/govuk/govuk-summary-list/govuk-summary-list.component.d.ts +0 -7
- package/components/govuk/govuk-summary-list/public-api.d.ts +0 -4
- package/components/govuk/govuk-table/govuk-table-body-row/govuk-table-body-row-data/govuk-table-body-row-data.component.d.ts +0 -8
- package/components/govuk/govuk-table/govuk-table-body-row/govuk-table-body-row.component.d.ts +0 -7
- package/components/govuk/govuk-table/govuk-table-heading/govuk-table-heading.component.d.ts +0 -7
- package/components/govuk/govuk-table/govuk-table.component.d.ts +0 -6
- package/components/govuk/govuk-table/public-api.d.ts +0 -4
- package/components/govuk/govuk-tabs/govuk-tab-list-item/govuk-tab-list-item.component.d.ts +0 -13
- package/components/govuk/govuk-tabs/govuk-tab-panel/govuk-tab-panel.component.d.ts +0 -9
- package/components/govuk/govuk-tabs/govuk-tabs.component.d.ts +0 -14
- package/components/govuk/govuk-tabs/public-api.d.ts +0 -3
- package/components/govuk/govuk-tag/govuk-tag.component.d.ts +0 -7
- package/components/govuk/govuk-tag/public-api.d.ts +0 -1
- package/components/govuk/govuk-task-list/govuk-task-list-item/govuk-task-list-item.component.d.ts +0 -8
- package/components/govuk/govuk-task-list/govuk-task-list.component.d.ts +0 -7
- package/components/govuk/govuk-task-list/public-api.d.ts +0 -2
- package/components/govuk/govuk-text-area/govuk-text-area.component.d.ts +0 -21
- package/components/govuk/govuk-text-area/public-api.d.ts +0 -1
- package/components/govuk/govuk-text-input/govuk-text-input.component.d.ts +0 -17
- package/components/govuk/govuk-text-input/public-api.d.ts +0 -1
- package/components/govuk/govuk-text-input-prefix-suffix/govuk-text-input-prefix-suffix.component.d.ts +0 -22
- package/components/govuk/govuk-text-input-prefix-suffix/public-api.d.ts +0 -1
- package/components/govuk/helpers/add-gds-body-class.d.ts +0 -4
- package/components/govuk/helpers/public-api.d.ts +0 -1
- package/components/moj/moj-badge/moj.badge.component.d.ts +0 -7
- package/components/moj/moj-badge/public-api.d.ts +0 -1
- package/components/moj/moj-banner/index.d.ts +0 -5
- package/components/moj/moj-banner/moj-banner.component.d.ts +0 -8
- package/components/moj/moj-banner/public-api.d.ts +0 -1
- package/components/moj/moj-button-menu/moj-button-menu-item/moj-button-menu-item.component.d.ts +0 -8
- package/components/moj/moj-button-menu/moj-button-menu.component.d.ts +0 -10
- package/components/moj/moj-button-menu/public-api.d.ts +0 -2
- package/components/moj/moj-date-picker/moj-date-picker.component.d.ts +0 -40
- package/components/moj/moj-date-picker/public-api.d.ts +0 -1
- package/components/moj/moj-header/interfaces/moj-header-links.interface.d.ts +0 -4
- package/components/moj/moj-header/interfaces/public-api.d.ts +0 -1
- package/components/moj/moj-header/moj-header-navigation-item/moj-header-navigation-item.component.d.ts +0 -12
- package/components/moj/moj-header/moj-header.component.d.ts +0 -7
- package/components/moj/moj-header/public-api.d.ts +0 -2
- package/components/moj/moj-notification-badge/moj-notification-badge.component.d.ts +0 -6
- package/components/moj/moj-notification-badge/public-api.d.ts +0 -1
- package/components/moj/moj-page-header/moj-page-header.component.d.ts +0 -6
- package/components/moj/moj-page-header/public-api.d.ts +0 -1
- package/components/moj/moj-pagination/moj-pagination-item/moj-pagination-item.component.d.ts +0 -6
- package/components/moj/moj-pagination/moj-pagination-link/moj-pagination-link.component.d.ts +0 -43
- package/components/moj/moj-pagination/moj-pagination-list/moj-pagination-list.component.d.ts +0 -6
- package/components/moj/moj-pagination/moj-pagination.component.d.ts +0 -108
- package/components/moj/moj-pagination/public-api.d.ts +0 -4
- package/components/moj/moj-primary-navigation/moj-primary-navigation-item/moj-primary-navigation-item.component.d.ts +0 -21
- package/components/moj/moj-primary-navigation/moj-primary-navigation.component.d.ts +0 -26
- package/components/moj/moj-primary-navigation/public-api.d.ts +0 -2
- package/components/moj/moj-sortable-table/moj-sortable-table-header/directive/constants/moj-sortable-table-header-sort-icons.constant.d.ts +0 -5
- package/components/moj/moj-sortable-table/moj-sortable-table-header/directive/moj-sortable-table-header-sort-icon.directive.d.ts +0 -18
- package/components/moj/moj-sortable-table/moj-sortable-table-header/moj-sortable-table-header.component.d.ts +0 -24
- package/components/moj/moj-sortable-table/moj-sortable-table-row/moj-sortable-table-row-data/moj-sortable-table-row-data.component.d.ts +0 -8
- package/components/moj/moj-sortable-table/moj-sortable-table-row/moj-sortable-table-row.component.d.ts +0 -7
- package/components/moj/moj-sortable-table/moj-sortable-table-status/moj-sortable-table-status.component.d.ts +0 -7
- package/components/moj/moj-sortable-table/moj-sortable-table.component.d.ts +0 -6
- package/components/moj/moj-sortable-table/public-api.d.ts +0 -5
- package/components/moj/moj-sub-navigation/moj-sub-navigation-item/moj-sub-navigation-item.component.d.ts +0 -19
- package/components/moj/moj-sub-navigation/moj-sub-navigation.component.d.ts +0 -21
- package/components/moj/moj-sub-navigation/public-api.d.ts +0 -2
- package/components/moj/moj-ticket-panel/moj-ticket-panel.component.d.ts +0 -8
- package/components/moj/moj-ticket-panel/public-api.d.ts +0 -1
- package/components/moj/moj-timeline/moj-timeline-item/moj-timeline-item.component.d.ts +0 -5
- package/components/moj/moj-timeline/moj-timeline.component.d.ts +0 -5
- package/components/moj/moj-timeline/public-api.d.ts +0 -2
- package/constants/public-api.d.ts +0 -2
- package/constants/src/footer-links.constant.d.ts +0 -2
- package/constants/src/header-links.constant.d.ts +0 -2
- package/directives/capitalisation/capitalisation.directive.d.ts +0 -14
- package/directives/capitalisation/public-api.d.ts +0 -1
- package/fesm2022/hmcts-opal-frontend-common-components-moj-moj-banner.mjs +0 -26
- package/fesm2022/hmcts-opal-frontend-common-components-moj-moj-banner.mjs.map +0 -1
- package/guards/auth/auth.guard.d.ts +0 -4
- package/guards/auth/public-api.d.ts +0 -1
- package/guards/can-deactivate/can-deactivate.guard.d.ts +0 -3
- package/guards/can-deactivate/interfaces/can-deactivate-can-component-deactivate.interface.d.ts +0 -4
- package/guards/can-deactivate/interfaces/public-api.d.ts +0 -1
- package/guards/can-deactivate/public-api.d.ts +0 -1
- package/guards/can-deactivate/types/can-deactivate.type.d.ts +0 -3
- package/guards/can-deactivate/types/public-api.d.ts +0 -1
- package/guards/has-flow-state/has-flow-state.guard.d.ts +0 -2
- package/guards/has-flow-state/public-api.d.ts +0 -1
- package/guards/helpers/get-guard-with-dummy-url.d.ts +0 -12
- package/guards/helpers/handle-observable-result.d.ts +0 -8
- package/guards/helpers/public-api.d.ts +0 -4
- package/guards/helpers/run-auth-guard-with-context.d.ts +0 -9
- package/guards/helpers/run-has-flow-state-guard-with-context.d.ts +0 -3
- package/guards/route-permissions/public-api.d.ts +0 -1
- package/guards/route-permissions/route-permissions.guard.d.ts +0 -2
- package/guards/signed-in/public-api.d.ts +0 -1
- package/guards/signed-in/signed-in.guard.d.ts +0 -8
- package/guards/types/guard-return.type.d.ts +0 -2
- package/guards/types/public-api.d.ts +0 -1
- package/interceptors/http-error/constants/http-error-message.constant.d.ts +0 -1
- package/interceptors/http-error/http-error.interceptor.d.ts +0 -2
- package/interceptors/http-error/public-api.d.ts +0 -1
- package/pages/access-denied/access-denied.component.d.ts +0 -7
- package/pages/public-api.d.ts +0 -1
- package/pages/routing/constants/public-api.d.ts +0 -2
- package/pages/routing/constants/routing-paths.constant.d.ts +0 -2
- package/pages/routing/constants/routing-titles.constant.d.ts +0 -2
- package/pages/routing/interfaces/child-routing-paths.interface.d.ts +0 -6
- package/pages/routing/interfaces/nested-routes.interface.d.ts +0 -4
- package/pages/routing/interfaces/parent-routing-paths.interface.d.ts +0 -7
- package/pages/routing/interfaces/public-api.d.ts +0 -4
- package/pages/routing/interfaces/routing-paths.interface.d.ts +0 -8
- package/pages/routing/pages.routes.d.ts +0 -2
- package/pages/sign-in/interfaces/index.d.ts +0 -2
- package/pages/sign-in/interfaces/sign-in-stub-form.interface.d.ts +0 -3
- package/pages/sign-in/sign-in-stub/sign-in-stub.component.d.ts +0 -19
- package/pages/sign-in/sign-in.component.d.ts +0 -47
- package/pipes/date-format/date-format.pipe.d.ts +0 -10
- package/pipes/date-format/public-api.d.ts +0 -1
- package/pipes/days-ago/days-ago.pipe.d.ts +0 -7
- package/pipes/days-ago/public-api.d.ts +0 -1
- package/public-api.d.ts +0 -1
- package/resolvers/title/public-api.d.ts +0 -1
- package/resolvers/title/title.resolver.d.ts +0 -10
- package/resolvers/user-state/public-api.d.ts +0 -1
- package/resolvers/user-state/user-state.resolver.d.ts +0 -7
- package/services/app-initializer-service/app-initializer.service.d.ts +0 -25
- package/services/app-initializer-service/public-api.d.ts +0 -1
- package/services/app-insights-service/app-insights.service.d.ts +0 -14
- package/services/app-insights-service/public-api.d.ts +0 -1
- package/services/auth-service/auth.service.d.ts +0 -8
- package/services/auth-service/constants/public-api.d.ts +0 -1
- package/services/auth-service/constants/sso-endpoints.constant.d.ts +0 -2
- package/services/auth-service/interfaces/public-api.d.ts +0 -1
- package/services/auth-service/interfaces/sso-endpoints.interface.d.ts +0 -6
- package/services/auth-service/public-api.d.ts +0 -1
- package/services/date-service/date.service.d.ts +0 -140
- package/services/date-service/interfaces/date.service.interface.d.ts +0 -4
- package/services/date-service/public-api.d.ts +0 -1
- package/services/launch-darkly-service/launch-darkly.service.d.ts +0 -41
- package/services/launch-darkly-service/mocks/launch-darkly-change-flags.mock.d.ts +0 -10
- package/services/launch-darkly-service/mocks/launch-darkly-flags.mock.d.ts +0 -4
- package/services/launch-darkly-service/mocks/public-api.d.ts +0 -2
- package/services/launch-darkly-service/public-api.d.ts +0 -1
- package/services/permissions-service/permissions.service.d.ts +0 -14
- package/services/permissions-service/public-api.d.ts +0 -1
- package/services/session-service/constants/public-api.d.ts +0 -1
- package/services/session-service/constants/session-endpoints.constant.d.ts +0 -2
- package/services/session-service/interfaces/public-api.d.ts +0 -3
- package/services/session-service/interfaces/session-endpoints.interface.d.ts +0 -4
- package/services/session-service/interfaces/session-token-expiry.interface.d.ts +0 -4
- package/services/session-service/interfaces/session-user-state.interface.d.ts +0 -15
- package/services/session-service/mocks/public-api.d.ts +0 -2
- package/services/session-service/mocks/session-token-expiry.mock.d.ts +0 -2
- package/services/session-service/mocks/session-user-state.mock.d.ts +0 -2
- package/services/session-service/public-api.d.ts +0 -1
- package/services/session-service/session.service.d.ts +0 -30
- package/services/sort-service/interfaces/public-api.d.ts +0 -2
- package/services/sort-service/interfaces/sort-service-values.interface.d.ts +0 -7
- package/services/sort-service/interfaces/sort-service.interface.d.ts +0 -4
- package/services/sort-service/public-api.d.ts +0 -1
- package/services/sort-service/sort.service.d.ts +0 -64
- package/services/transfer-state-service/interfaces/public-api.d.ts +0 -3
- package/services/transfer-state-service/interfaces/transfer-state-app-insights-config.interface.d.ts +0 -5
- package/services/transfer-state-service/interfaces/transfer-state-launch-darkly-config.interface.d.ts +0 -5
- package/services/transfer-state-service/interfaces/transfer-state-server-state.interface.d.ts +0 -7
- package/services/transfer-state-service/mocks/public-api.d.ts +0 -3
- package/services/transfer-state-service/mocks/transfer-state-app-insights-config.mock.d.ts +0 -5
- package/services/transfer-state-service/mocks/transfer-state-launch-darkly-config.mock.d.ts +0 -5
- package/services/transfer-state-service/mocks/transfer-state.mock.d.ts +0 -2
- package/services/transfer-state-service/public-api.d.ts +0 -1
- package/services/transfer-state-service/transfer-state.service.d.ts +0 -28
- package/services/transformation-service/interfaces/public-api.d.ts +0 -1
- package/services/transformation-service/interfaces/transform-item.interface.d.ts +0 -6
- package/services/transformation-service/public-api.d.ts +0 -1
- package/services/transformation-service/transformation.service.d.ts +0 -30
- package/services/utils-service/public-api.d.ts +0 -1
- package/services/utils-service/utils.service.d.ts +0 -85
- package/stores/global/global.store.d.ts +0 -37
- package/stores/global/interfaces/error-state.interface.d.ts +0 -4
- package/stores/global/interfaces/public-api.d.ts +0 -1
- package/stores/global/public-api.d.ts +0 -1
- package/stores/global/types/global-store.type.d.ts +0 -2
- package/stores/global/types/public-api.d.ts +0 -1
- package/validators/alphabetical-text/alphabetical-text.validator.d.ts +0 -2
- package/validators/alphabetical-text/public-api.d.ts +0 -1
- package/validators/amount/amount.validator.d.ts +0 -2
- package/validators/amount/public-api.d.ts +0 -1
- package/validators/date-after-year/date-after-year.validator.d.ts +0 -2
- package/validators/date-after-year/public-api.d.ts +0 -1
- package/validators/date-before/date-before.validator.d.ts +0 -2
- package/validators/date-before/public-api.d.ts +0 -1
- package/validators/date-of-birth/date-of-birth.validator.d.ts +0 -2
- package/validators/date-of-birth/public-api.d.ts +0 -1
- package/validators/future-date/future-date.validator.d.ts +0 -2
- package/validators/future-date/public-api.d.ts +0 -1
- package/validators/invalid-value/invalid-value.validator.d.ts +0 -2
- package/validators/invalid-value/public-api.d.ts +0 -1
- package/validators/national-insurance-number/national-insurance-number.validator.d.ts +0 -2
- package/validators/national-insurance-number/public-api.d.ts +0 -1
- package/validators/numerical-only/numerical-only.validator.d.ts +0 -2
- package/validators/numerical-only/public-api.d.ts +0 -1
- package/validators/optional-max-length/optional-max-length.validator.d.ts +0 -2
- package/validators/optional-max-length/public-api.d.ts +0 -1
- package/validators/optional-valid-date/optional-valid-date.validator.d.ts +0 -2
- package/validators/optional-valid-date/public-api.d.ts +0 -1
- package/validators/optional-valid-email-address/optional-valid-email-address.validator.d.ts +0 -2
- package/validators/optional-valid-email-address/public-api.d.ts +0 -1
- package/validators/optional-valid-telephone/optional-valid-telephone.validator.d.ts +0 -2
- package/validators/optional-valid-telephone/public-api.d.ts +0 -1
- package/validators/over-eighteen/over-eighteen.validator.d.ts +0 -14
- package/validators/over-eighteen/public-api.d.ts +0 -1
- package/validators/past-date/past-date.validator.d.ts +0 -2
- package/validators/past-date/public-api.d.ts +0 -1
- package/validators/special-characters/public-api.d.ts +0 -1
- package/validators/special-characters/special-characters.validator.d.ts +0 -2
- package/validators/two-decimal-places/public-api.d.ts +0 -1
- package/validators/two-decimal-places/two-decimal-places.validator.d.ts +0 -2
- package/validators/valid-value/public-api.d.ts +0 -1
- package/validators/valid-value/valid-value.validator.d.ts +0 -2
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hmcts/opal-frontend-common",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.18",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"peerDependencies": {
|
|
6
6
|
"@angular/common": "^18.2.0 || ^19.0.0",
|
|
@@ -269,16 +269,16 @@
|
|
|
269
269
|
"types": "./components/govuk/helpers/index.d.ts",
|
|
270
270
|
"default": "./fesm2022/hmcts-opal-frontend-common-components-govuk-helpers.mjs"
|
|
271
271
|
},
|
|
272
|
+
"./components/moj/moj-alert": {
|
|
273
|
+
"import": "./fesm2022/hmcts-opal-frontend-common-components-moj-moj-alert.mjs",
|
|
274
|
+
"types": "./components/moj/moj-alert/index.d.ts",
|
|
275
|
+
"default": "./fesm2022/hmcts-opal-frontend-common-components-moj-moj-alert.mjs"
|
|
276
|
+
},
|
|
272
277
|
"./components/moj/moj-badge": {
|
|
273
278
|
"import": "./fesm2022/hmcts-opal-frontend-common-components-moj-moj-badge.mjs",
|
|
274
279
|
"types": "./components/moj/moj-badge/index.d.ts",
|
|
275
280
|
"default": "./fesm2022/hmcts-opal-frontend-common-components-moj-moj-badge.mjs"
|
|
276
281
|
},
|
|
277
|
-
"./components/moj/moj-banner": {
|
|
278
|
-
"import": "./fesm2022/hmcts-opal-frontend-common-components-moj-moj-banner.mjs",
|
|
279
|
-
"types": "./components/moj/moj-banner/index.d.ts",
|
|
280
|
-
"default": "./fesm2022/hmcts-opal-frontend-common-components-moj-moj-banner.mjs"
|
|
281
|
-
},
|
|
282
282
|
"./components/moj/moj-button-menu": {
|
|
283
283
|
"import": "./fesm2022/hmcts-opal-frontend-common-components-moj-moj-button-menu.mjs",
|
|
284
284
|
"types": "./components/moj/moj-button-menu/index.d.ts",
|
package/pages/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
export
|
|
1
|
+
import { Routes } from '@angular/router';
|
|
2
|
+
|
|
3
|
+
declare const routing: Routes;
|
|
4
|
+
|
|
5
|
+
export { routing };
|
|
@@ -1,5 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import { IPagesRoutingPaths } from '@hmcts/opal-frontend-common/pages/routing/interfaces';
|
|
2
|
+
|
|
3
|
+
declare const PAGES_ROUTING_PATHS: IPagesRoutingPaths;
|
|
4
|
+
|
|
5
|
+
declare const PAGES_ROUTING_TITLES: IPagesRoutingPaths;
|
|
6
|
+
|
|
7
|
+
export { PAGES_ROUTING_PATHS, PAGES_ROUTING_TITLES };
|
|
@@ -1,5 +1,28 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
interface IChildRoutingPaths {
|
|
2
|
+
root: string;
|
|
3
|
+
children: {
|
|
4
|
+
[key: string]: string;
|
|
5
|
+
};
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
interface INestedRoutes {
|
|
9
|
+
nextRoute: string;
|
|
10
|
+
buttonText: string;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
interface IParentRoutingPaths {
|
|
14
|
+
root: string;
|
|
15
|
+
children: {
|
|
16
|
+
[key: string]: IChildRoutingPaths;
|
|
17
|
+
};
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
interface IPagesRoutingPaths extends IChildRoutingPaths {
|
|
21
|
+
children: {
|
|
22
|
+
accessDenied: string;
|
|
23
|
+
signIn: string;
|
|
24
|
+
signInStub: string;
|
|
25
|
+
};
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
export type { IChildRoutingPaths, INestedRoutes, IPagesRoutingPaths, IParentRoutingPaths };
|
|
@@ -1,5 +1,13 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { PipeTransform } from '@angular/core';
|
|
3
|
+
import { DateService } from '@hmcts/opal-frontend-common/services/date-service';
|
|
4
|
+
|
|
5
|
+
declare class DateFormatPipe implements PipeTransform {
|
|
6
|
+
private readonly dateService;
|
|
7
|
+
constructor(dateService: DateService);
|
|
8
|
+
transform(value: string | null | undefined, inputFormat: string, outputFormat: string): string;
|
|
9
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<DateFormatPipe, never>;
|
|
10
|
+
static ɵpipe: i0.ɵɵPipeDeclaration<DateFormatPipe, "dateFormat", true>;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export { DateFormatPipe };
|
|
@@ -1,5 +1,10 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { PipeTransform } from '@angular/core';
|
|
3
|
+
|
|
4
|
+
declare class DaysAgoPipe implements PipeTransform {
|
|
5
|
+
transform(value: number): string;
|
|
6
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<DaysAgoPipe, never>;
|
|
7
|
+
static ɵpipe: i0.ɵɵPipeDeclaration<DaysAgoPipe, "daysAgo", true>;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
export { DaysAgoPipe };
|
|
@@ -1,5 +1,13 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import { Resolve, ActivatedRouteSnapshot } from '@angular/router';
|
|
2
|
+
import { Title } from '@angular/platform-browser';
|
|
3
|
+
import * as i0 from '@angular/core';
|
|
4
|
+
|
|
5
|
+
declare class TitleResolver implements Resolve<void> {
|
|
6
|
+
private readonly titleService;
|
|
7
|
+
constructor(titleService: Title);
|
|
8
|
+
resolve(route: ActivatedRouteSnapshot): void;
|
|
9
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<TitleResolver, never>;
|
|
10
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<TitleResolver>;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export { TitleResolver };
|
|
@@ -1,5 +1,10 @@
|
|
|
1
|
+
import { ResolveFn } from '@angular/router';
|
|
2
|
+
import { ISessionUserState } from '@hmcts/opal-frontend-common/services/session-service/interfaces';
|
|
3
|
+
|
|
1
4
|
/**
|
|
2
|
-
*
|
|
5
|
+
* Resolver function for retrieving the user state.
|
|
6
|
+
* @returns A promise that resolves to the user state.
|
|
3
7
|
*/
|
|
4
|
-
|
|
5
|
-
|
|
8
|
+
declare const userStateResolver: ResolveFn<ISessionUserState>;
|
|
9
|
+
|
|
10
|
+
export { userStateResolver };
|
|
@@ -1,5 +1,28 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
|
|
3
|
+
declare class AppInitializerService {
|
|
4
|
+
private readonly transferStateService;
|
|
5
|
+
private readonly appInsightsService;
|
|
6
|
+
/**
|
|
7
|
+
* Initializes the SSO (Single Sign-On) enabled state.
|
|
8
|
+
* This method calls the `initializeSsoEnabled` method of the `transferStateService`.
|
|
9
|
+
*/
|
|
10
|
+
private initializeSsoEnabled;
|
|
11
|
+
/**
|
|
12
|
+
* Initializes the LaunchDarkly configuration.
|
|
13
|
+
*/
|
|
14
|
+
private initializeLaunchDarkly;
|
|
15
|
+
/**
|
|
16
|
+
* Initializes the Application Insights configuration.
|
|
17
|
+
*/
|
|
18
|
+
private initializeAppInsights;
|
|
19
|
+
/**
|
|
20
|
+
* Initializes the application.
|
|
21
|
+
* This method calls the necessary initialization functions.
|
|
22
|
+
*/
|
|
23
|
+
initializeApp(): Promise<void>;
|
|
24
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AppInitializerService, never>;
|
|
25
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<AppInitializerService>;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
export { AppInitializerService };
|
|
@@ -1,5 +1,17 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
|
|
3
|
+
declare class AppInsightsService {
|
|
4
|
+
private appInsights;
|
|
5
|
+
private isInitialized;
|
|
6
|
+
private readonly globalStore;
|
|
7
|
+
private readonly platformId;
|
|
8
|
+
private initializeAppInsights;
|
|
9
|
+
private telemetryInitializer;
|
|
10
|
+
logPageView(name?: string, url?: string): void;
|
|
11
|
+
logException(exception: Error, severityLevel?: number): void;
|
|
12
|
+
initialize(): Promise<void>;
|
|
13
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AppInsightsService, never>;
|
|
14
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<AppInsightsService>;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
export { AppInsightsService };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
export
|
|
1
|
+
import { ISsoEndpoints } from '@hmcts/opal-frontend-common/services/auth-service/interfaces';
|
|
2
|
+
|
|
3
|
+
declare const SSO_ENDPOINTS: ISsoEndpoints;
|
|
4
|
+
|
|
5
|
+
export { SSO_ENDPOINTS };
|
|
@@ -1,5 +1,12 @@
|
|
|
1
|
-
|
|
2
|
-
*
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import * as rxjs from 'rxjs';
|
|
2
|
+
import * as i0 from '@angular/core';
|
|
3
|
+
|
|
4
|
+
declare class AuthService {
|
|
5
|
+
private readonly http;
|
|
6
|
+
private readonly globalStore;
|
|
7
|
+
checkAuthenticated(): rxjs.Observable<boolean>;
|
|
8
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AuthService, never>;
|
|
9
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<AuthService>;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
export { AuthService };
|
|
@@ -1,5 +1,8 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
interface ISsoEndpoints {
|
|
2
|
+
login: string;
|
|
3
|
+
logout: string;
|
|
4
|
+
callback: string;
|
|
5
|
+
authenticated: string;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
export type { ISsoEndpoints };
|
|
@@ -1,5 +1,147 @@
|
|
|
1
|
-
|
|
2
|
-
*
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import { DateTime, DurationLikeObject } from 'luxon';
|
|
2
|
+
import * as i0 from '@angular/core';
|
|
3
|
+
|
|
4
|
+
interface IDateRange {
|
|
5
|
+
to: string;
|
|
6
|
+
from: string;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
declare class DateService {
|
|
10
|
+
/**
|
|
11
|
+
* Calculates the difference in minutes between two DateTime objects.
|
|
12
|
+
* @param startDate The start date and time.
|
|
13
|
+
* @param endDate The end date and time.
|
|
14
|
+
* @returns The difference in minutes between the start and end dates.
|
|
15
|
+
*/
|
|
16
|
+
calculateMinutesDifference(startDate: DateTime, endDate: DateTime): number;
|
|
17
|
+
/**
|
|
18
|
+
* Converts milliseconds to minutes.
|
|
19
|
+
* @param milliseconds - The number of milliseconds to convert.
|
|
20
|
+
* @returns The equivalent number of minutes.
|
|
21
|
+
*/
|
|
22
|
+
convertMillisecondsToMinutes(milliseconds: number): number;
|
|
23
|
+
/**
|
|
24
|
+
* Calculates the age based on the given date of birth.
|
|
25
|
+
* @param dateOfBirth - The date of birth to calculate the age from.
|
|
26
|
+
* @param format - The format of the date of birth. Defaults to 'dd/MM/yyyy'.
|
|
27
|
+
* @returns The calculated age.
|
|
28
|
+
*/
|
|
29
|
+
calculateAge(dateOfBirth: DateTime | string, format?: string): number;
|
|
30
|
+
/**
|
|
31
|
+
* Checks if a given date is valid.
|
|
32
|
+
* @param dateInput - The date to be checked. It can be a DateTime object, a string, or null.
|
|
33
|
+
* @param format - The format of the date string (default: 'dd/MM/yyyy').
|
|
34
|
+
* @returns A boolean indicating whether the date is valid or not.
|
|
35
|
+
*/
|
|
36
|
+
isValidDate(dateInput: DateTime | string | null, format?: string): boolean;
|
|
37
|
+
/**
|
|
38
|
+
* Returns a string representation of a date subtracted by the given duration.
|
|
39
|
+
* @param duration A DurationLikeObject representing the amount of time to subtract from the current date.
|
|
40
|
+
* @returns A string representing the subtracted date in the format specified by the current locale.
|
|
41
|
+
*/
|
|
42
|
+
getPreviousDate(duration: DurationLikeObject): string;
|
|
43
|
+
/**
|
|
44
|
+
* Parses a string value into a DateTime object based on the specified format.
|
|
45
|
+
* @param value - The string value to parse.
|
|
46
|
+
* @param format - The format of the string value.
|
|
47
|
+
* @returns A DateTime object representing the parsed value.
|
|
48
|
+
*/
|
|
49
|
+
getFromFormat(value: string, format: string): DateTime<true> | DateTime<false>;
|
|
50
|
+
/**
|
|
51
|
+
* Parses a string value into a native JavaScript Date object based on the specified format.
|
|
52
|
+
* @param value - The string value to parse.
|
|
53
|
+
* @param format - The format of the string value.
|
|
54
|
+
* @returns A Date object representing the parsed value, or null if parsing fails.
|
|
55
|
+
*/
|
|
56
|
+
getDateFromFormat(value: string, format: string): Date | null;
|
|
57
|
+
/**
|
|
58
|
+
* Converts a DateTime value to a formatted string.
|
|
59
|
+
*
|
|
60
|
+
* @param value - The DateTime value to format.
|
|
61
|
+
* @param format - The format string to apply to the DateTime value.
|
|
62
|
+
* @returns The formatted string representation of the DateTime value.
|
|
63
|
+
*/
|
|
64
|
+
toFormat(value: DateTime<true> | DateTime<false>, format: string): string;
|
|
65
|
+
/**
|
|
66
|
+
* Converts a given Date object to a formatted string based on the specified format.
|
|
67
|
+
*
|
|
68
|
+
* @param value - The Date object to be formatted.
|
|
69
|
+
* @param format - The string format to apply to the Date object.
|
|
70
|
+
* @returns The formatted date string.
|
|
71
|
+
*/
|
|
72
|
+
toDateStringFormat(value: Date, format: string): string;
|
|
73
|
+
/**
|
|
74
|
+
* Converts a string in ISO format to a DateTime object.
|
|
75
|
+
* @param value - The string value in ISO format.
|
|
76
|
+
* @returns A DateTime object representing the given value.
|
|
77
|
+
*/
|
|
78
|
+
getFromIso(value: string): DateTime;
|
|
79
|
+
/**
|
|
80
|
+
* Returns the current date and time.
|
|
81
|
+
* @returns {DateTime} The current date and time.
|
|
82
|
+
*/
|
|
83
|
+
getDateNow(): DateTime;
|
|
84
|
+
/**
|
|
85
|
+
* Adds a duration to a given date and returns the result in the specified format.
|
|
86
|
+
* @param date - The date to which the duration will be added.
|
|
87
|
+
* @param years - The number of years to add to the date (default: 0).
|
|
88
|
+
* @param months - The number of months to add to the date (default: 0).
|
|
89
|
+
* @param weeks - The number of weeks to add to the date (default: 0).
|
|
90
|
+
* @param days - The number of days to add to the date (default: 0).
|
|
91
|
+
* @param format - The format in which the resulting date will be returned (default: 'dd/MM/yyyy').
|
|
92
|
+
* @returns The resulting date in the specified format.
|
|
93
|
+
*/
|
|
94
|
+
addDurationToDate(date: string, years?: number, months?: number, weeks?: number, days?: number, format?: string): string;
|
|
95
|
+
/**
|
|
96
|
+
* Calculates the number of days between two dates.
|
|
97
|
+
* @param startDate - The start date in the specified format.
|
|
98
|
+
* @param endDate - The end date in the specified format.
|
|
99
|
+
* @param format - The format of the dates (default: 'dd/MM/yyyy').
|
|
100
|
+
* @returns The number of days between the start and end dates.
|
|
101
|
+
*/
|
|
102
|
+
calculateDaysBetweenDates(startDate: string, endDate: string, format?: string): number;
|
|
103
|
+
/**
|
|
104
|
+
* Checks if a given date is in the past.
|
|
105
|
+
* @param date - The date to check.
|
|
106
|
+
* @param format - The format of the date string. Defaults to 'dd/MM/yyyy'.
|
|
107
|
+
* @returns True if the date is in the past, false otherwise.
|
|
108
|
+
*/
|
|
109
|
+
isDateInThePast(date: string, format?: string): boolean;
|
|
110
|
+
/**
|
|
111
|
+
* Checks if a given date is in the future.
|
|
112
|
+
* @param date - The date to check.
|
|
113
|
+
* @param yearsInTheFuture - Optional. The number of years in the future to compare against. If not provided, the current date is used.
|
|
114
|
+
* @param format - Optional. The format of the input date. Defaults to 'dd/MM/yyyy'.
|
|
115
|
+
* @returns True if the date is in the future, false otherwise.
|
|
116
|
+
*/
|
|
117
|
+
isDateInTheFuture(date: string, yearsInTheFuture?: number, format?: string): boolean;
|
|
118
|
+
/**
|
|
119
|
+
* Converts a date string from one format to another.
|
|
120
|
+
*
|
|
121
|
+
* @param date - The date string to be converted.
|
|
122
|
+
* @param fromFormat - The format of the input date string.
|
|
123
|
+
* @param toFormat - The desired format of the output date string.
|
|
124
|
+
* @returns The date string in the desired format.
|
|
125
|
+
*/
|
|
126
|
+
getFromFormatToFormat(date: string, fromFormat: string, toFormat: string): string;
|
|
127
|
+
/**
|
|
128
|
+
* Calculates the number of days between the current date and a given ISO date string.
|
|
129
|
+
*
|
|
130
|
+
* @param value - An ISO 8601 formatted date string representing the target date.
|
|
131
|
+
* @returns The number of days between the current date and the input date.
|
|
132
|
+
* Returns 0 if the input date is invalid.
|
|
133
|
+
*/
|
|
134
|
+
getDaysAgo(value: string): number;
|
|
135
|
+
/**
|
|
136
|
+
* Returns a date range object with 'from' and 'to' properties.
|
|
137
|
+
* @param pastDays - The number of days in the past from today.
|
|
138
|
+
* @param futureDays - The number of days in the future from today.
|
|
139
|
+
* @param format - The format for the date strings (default: 'yyyy-MM-dd').
|
|
140
|
+
* @returns An object containing 'from' and 'to' date strings in the specified format.
|
|
141
|
+
*/
|
|
142
|
+
getDateRange(pastDays?: number, futureDays?: number, format?: string): IDateRange;
|
|
143
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<DateService, never>;
|
|
144
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<DateService>;
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
export { DateService };
|
|
@@ -1,5 +1,44 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { OnDestroy } from '@angular/core';
|
|
3
|
+
|
|
4
|
+
declare class LaunchDarklyService implements OnDestroy {
|
|
5
|
+
private readonly globalStore;
|
|
6
|
+
private ldClient;
|
|
7
|
+
/**
|
|
8
|
+
* Sets the LaunchDarkly flags by updating the featureFlags in the state service.
|
|
9
|
+
*/
|
|
10
|
+
private setLaunchDarklyFlags;
|
|
11
|
+
/**
|
|
12
|
+
* Formats the LDFlagChangeset into an LDFlagSet.
|
|
13
|
+
*
|
|
14
|
+
* @param flags - The LDFlagChangeset to be formatted.
|
|
15
|
+
* @returns The formatted LDFlagSet.
|
|
16
|
+
*/
|
|
17
|
+
private formatChangeFlags;
|
|
18
|
+
/**
|
|
19
|
+
* Closes the LaunchDarkly client if it is open.
|
|
20
|
+
*/
|
|
21
|
+
private closeLaunchDarklyClient;
|
|
22
|
+
/**
|
|
23
|
+
* Initializes the LaunchDarkly change listener.
|
|
24
|
+
* This method listens for changes in feature flags and updates the state accordingly.
|
|
25
|
+
*/
|
|
26
|
+
initializeLaunchDarklyChangeListener(): void;
|
|
27
|
+
/**
|
|
28
|
+
* Initializes the LaunchDarkly flags and sets them.
|
|
29
|
+
* If the LD client is already initialized, it waits for initialization and then sets the flags.
|
|
30
|
+
* If the LD client is not initialized, it returns a resolved promise.
|
|
31
|
+
* @returns A promise that resolves when the flags are set.
|
|
32
|
+
*/
|
|
33
|
+
initializeLaunchDarklyFlags(): Promise<void>;
|
|
34
|
+
/**
|
|
35
|
+
* Initializes the LaunchDarkly client.
|
|
36
|
+
* If a stored LaunchDarkly client ID exists, it initializes the client with the ID and anonymous mode enabled.
|
|
37
|
+
*/
|
|
38
|
+
initializeLaunchDarklyClient(): void;
|
|
39
|
+
ngOnDestroy(): void;
|
|
40
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<LaunchDarklyService, never>;
|
|
41
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<LaunchDarklyService>;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
export { LaunchDarklyService };
|
|
@@ -1,5 +1,17 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
declare const LAUNCH_DARKLY_CHANGE_FLAGS_MOCK: {
|
|
2
|
+
flag1: {
|
|
3
|
+
current: boolean;
|
|
4
|
+
previous: boolean;
|
|
5
|
+
};
|
|
6
|
+
flag2: {
|
|
7
|
+
current: boolean;
|
|
8
|
+
previous: boolean;
|
|
9
|
+
};
|
|
10
|
+
};
|
|
11
|
+
|
|
12
|
+
declare const LAUNCH_DARKLY_FLAGS_MOCK: {
|
|
13
|
+
flag1: boolean;
|
|
14
|
+
flag2: boolean;
|
|
15
|
+
};
|
|
16
|
+
|
|
17
|
+
export { LAUNCH_DARKLY_CHANGE_FLAGS_MOCK, LAUNCH_DARKLY_FLAGS_MOCK };
|
|
@@ -1,5 +1,17 @@
|
|
|
1
|
-
|
|
2
|
-
*
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import { ISessionUserState, ISessionUserStateRole } from '@hmcts/opal-frontend-common/services/session-service/interfaces';
|
|
2
|
+
import * as i0 from '@angular/core';
|
|
3
|
+
|
|
4
|
+
declare class PermissionsService {
|
|
5
|
+
private storedUniquePermissionIds;
|
|
6
|
+
/**
|
|
7
|
+
* Retrieves the unique permission IDs associated with the user.
|
|
8
|
+
* If the unique permission IDs have not been stored yet, it calculates them based on the user's roles and permissions.
|
|
9
|
+
* @returns An array of unique permission IDs.
|
|
10
|
+
*/
|
|
11
|
+
getUniquePermissions(userState: ISessionUserState | null): number[];
|
|
12
|
+
hasPermissionAccess(permissionId: number, businessUnitId: number, roles: ISessionUserStateRole[]): boolean;
|
|
13
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<PermissionsService, never>;
|
|
14
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<PermissionsService>;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
export { PermissionsService };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
export
|
|
1
|
+
import { ISessionEndpoints } from '@hmcts/opal-frontend-common/services/session-service/interfaces';
|
|
2
|
+
|
|
3
|
+
declare const SESSION_ENDPOINTS: ISessionEndpoints;
|
|
4
|
+
|
|
5
|
+
export { SESSION_ENDPOINTS };
|
|
@@ -1,5 +1,33 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import { Observable } from 'rxjs';
|
|
2
|
+
import { ISessionUserState, ISessionTokenExpiry } from '@hmcts/opal-frontend-common/services/session-service/interfaces';
|
|
3
|
+
import * as i0 from '@angular/core';
|
|
4
|
+
|
|
5
|
+
declare class SessionService {
|
|
6
|
+
private readonly http;
|
|
7
|
+
private readonly globalStore;
|
|
8
|
+
private userStateCache$;
|
|
9
|
+
private tokenExpiryCache$;
|
|
10
|
+
private readonly MAX_RETRIES;
|
|
11
|
+
private readonly RETRY_DELAY_MS;
|
|
12
|
+
/**
|
|
13
|
+
* Retrieves the user state from the backend.
|
|
14
|
+
* If the user state is not available or needs to be refreshed, it makes an HTTP request to fetch the user state.
|
|
15
|
+
* The user state is then stored in the state service for future use.
|
|
16
|
+
* The user state is cached using the `shareReplay` operator to avoid unnecessary HTTP requests.
|
|
17
|
+
* @returns An observable that emits the user state.
|
|
18
|
+
*/
|
|
19
|
+
getUserState(): Observable<ISessionUserState>;
|
|
20
|
+
/**
|
|
21
|
+
* Retrieves the token expiry information from the server.
|
|
22
|
+
* If the token expiry information is already cached, it returns the cached value.
|
|
23
|
+
* Otherwise, it makes an HTTP GET request to fetch the token expiry information,
|
|
24
|
+
* retries the request up to a maximum number of times if it fails, and caches the result.
|
|
25
|
+
*
|
|
26
|
+
* @returns {Observable<ISessionTokenExpiry>} An observable that emits the token expiry information.
|
|
27
|
+
*/
|
|
28
|
+
getTokenExpiry(): Observable<ISessionTokenExpiry>;
|
|
29
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<SessionService, never>;
|
|
30
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<SessionService>;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
export { SessionService };
|
|
@@ -1,5 +1,27 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
interface ISessionEndpoints {
|
|
2
|
+
userState: string;
|
|
3
|
+
expiry: string;
|
|
4
|
+
}
|
|
5
|
+
|
|
6
|
+
interface ISessionTokenExpiry {
|
|
7
|
+
expiry: string | null;
|
|
8
|
+
warningThresholdInMilliseconds: number | null;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
interface ISessionUserStatePermission {
|
|
12
|
+
permission_id: number;
|
|
13
|
+
permission_name: string;
|
|
14
|
+
}
|
|
15
|
+
interface ISessionUserStateRole {
|
|
16
|
+
business_unit_user_id: string;
|
|
17
|
+
business_unit_id: number;
|
|
18
|
+
permissions: ISessionUserStatePermission[];
|
|
19
|
+
}
|
|
20
|
+
interface ISessionUserState {
|
|
21
|
+
user_id: string;
|
|
22
|
+
user_name: string;
|
|
23
|
+
name: string;
|
|
24
|
+
business_unit_user: ISessionUserStateRole[];
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
export type { ISessionEndpoints, ISessionTokenExpiry, ISessionUserState, ISessionUserStatePermission, ISessionUserStateRole };
|
|
@@ -1,5 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import { ISessionTokenExpiry, ISessionUserState } from '@hmcts/opal-frontend-common/services/session-service/interfaces';
|
|
2
|
+
|
|
3
|
+
declare const SESSION_TOKEN_EXPIRY_MOCK: ISessionTokenExpiry;
|
|
4
|
+
|
|
5
|
+
declare const SESSION_USER_STATE_MOCK: ISessionUserState;
|
|
6
|
+
|
|
7
|
+
export { SESSION_TOKEN_EXPIRY_MOCK, SESSION_USER_STATE_MOCK };
|