@lifesg/web-frontend-engine 2.2.4 → 2.2.5
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/chunks/file-upload-manager.817b80cc.js +2 -0
- package/chunks/file-upload-manager.817b80cc.js.map +1 -0
- package/chunks/{index.ac3b6195.js → index.44b5e2a5.js} +10 -10
- package/chunks/{index.ac3b6195.js.map → index.44b5e2a5.js.map} +1 -1
- package/chunks/{index.a24b1857.js → index.51ad1607.js} +2 -2
- package/chunks/{index.a24b1857.js.map → index.51ad1607.js.map} +1 -1
- package/chunks/{index.8edac70b.js → index.f1de2e77.js} +2 -2
- package/chunks/{index.8edac70b.js.map → index.f1de2e77.js.map} +1 -1
- package/chunks/{location-modal.6475a4db.js → location-modal.1859f93a.js} +2 -2
- package/chunks/{location-modal.6475a4db.js.map → location-modal.1859f93a.js.map} +1 -1
- package/cjs/chunks/file-upload-manager.85af8429.js +2 -0
- package/cjs/chunks/file-upload-manager.85af8429.js.map +1 -0
- package/cjs/chunks/{index.d136a8bd.js → index.48f1a1f1.js} +2 -2
- package/cjs/chunks/{index.d136a8bd.js.map → index.48f1a1f1.js.map} +1 -1
- package/cjs/chunks/{index.6a929030.js → index.c2370225.js} +7 -7
- package/cjs/chunks/{index.6a929030.js.map → index.c2370225.js.map} +1 -1
- package/cjs/chunks/{index.6e0e20f7.js → index.efc005fc.js} +2 -2
- package/cjs/chunks/{index.6e0e20f7.js.map → index.efc005fc.js.map} +1 -1
- package/cjs/chunks/{location-modal.e5989ca3.js → location-modal.6885ccea.js} +2 -2
- package/cjs/chunks/{location-modal.e5989ca3.js.map → location-modal.6885ccea.js.map} +1 -1
- package/cjs/index.js +1 -1
- package/components/custom/array-field/array-field-element.d.ts +10 -11
- package/components/custom/array-field/array-field.d.ts +3 -3
- package/components/custom/array-field/array-field.styles.d.ts +22 -23
- package/components/custom/array-field/index.d.ts +2 -2
- package/components/custom/array-field/types.d.ts +39 -39
- package/components/custom/filter/filter/filter.d.ts +3 -3
- package/components/custom/filter/filter/types.d.ts +12 -12
- package/components/custom/filter/filter-checkbox/filter-checkbox.d.ts +3 -3
- package/components/custom/filter/filter-checkbox/types.d.ts +23 -23
- package/components/custom/filter/filter-helper.d.ts +8 -8
- package/components/custom/filter/filter-item/filter-item.d.ts +3 -3
- package/components/custom/filter/filter-item/types.d.ts +13 -13
- package/components/custom/filter/index.d.ts +3 -3
- package/components/custom/filter/types.d.ts +11 -11
- package/components/custom/iframe/iframe.d.ts +3 -3
- package/components/custom/iframe/index.d.ts +2 -2
- package/components/custom/iframe/types.d.ts +28 -29
- package/components/custom/index.d.ts +6 -6
- package/components/custom/review/index.d.ts +2 -2
- package/components/custom/review/review.d.ts +3 -3
- package/components/custom/review/review.styles.d.ts +12 -13
- package/components/custom/review/types.d.ts +60 -60
- package/components/custom/timeline/index.d.ts +2 -2
- package/components/custom/timeline/timeline.d.ts +3 -3
- package/components/custom/timeline/types.d.ts +19 -19
- package/components/custom/types.d.ts +87 -87
- package/components/elements/accordion/accordion.d.ts +6 -6
- package/components/elements/accordion/accordion.styles.d.ts +1 -2
- package/components/elements/accordion/index.d.ts +2 -2
- package/components/elements/accordion/types.d.ts +27 -27
- package/components/elements/alert/alert.d.ts +3 -3
- package/components/elements/alert/index.d.ts +2 -2
- package/components/elements/alert/types.d.ts +9 -10
- package/components/elements/divider/divider.d.ts +3 -3
- package/components/elements/divider/index.d.ts +2 -2
- package/components/elements/divider/types.d.ts +6 -6
- package/components/elements/grid/grid.d.ts +3 -3
- package/components/elements/grid/index.d.ts +2 -2
- package/components/elements/grid/types.d.ts +11 -11
- package/components/elements/index.d.ts +9 -9
- package/components/elements/list/data.d.ts +3 -3
- package/components/elements/list/index.d.ts +3 -3
- package/components/elements/list/list-item.d.ts +3 -3
- package/components/elements/list/list.d.ts +3 -3
- package/components/elements/list/types.d.ts +17 -17
- package/components/elements/popover/index.d.ts +2 -2
- package/components/elements/popover/popover.d.ts +3 -3
- package/components/elements/popover/types.d.ts +15 -15
- package/components/elements/section/index.d.ts +2 -2
- package/components/elements/section/section.d.ts +2 -2
- package/components/elements/section/section.styles.d.ts +11 -12
- package/components/elements/section/types.d.ts +16 -16
- package/components/elements/sections/index.d.ts +1 -1
- package/components/elements/sections/sections.d.ts +13 -13
- package/components/elements/tab/index.d.ts +2 -2
- package/components/elements/tab/tab.d.ts +3 -3
- package/components/elements/tab/types.d.ts +23 -23
- package/components/elements/text/data.d.ts +121 -122
- package/components/elements/text/index.d.ts +2 -2
- package/components/elements/text/text.d.ts +3 -3
- package/components/elements/text/types.d.ts +18 -18
- package/components/elements/types.d.ts +97 -97
- package/components/elements/wrapper/col-wrapper.d.ts +12 -12
- package/components/elements/wrapper/conditional-renderer.d.ts +16 -16
- package/components/elements/wrapper/field-wrapper.d.ts +9 -10
- package/components/elements/wrapper/index.d.ts +2 -2
- package/components/elements/wrapper/types.d.ts +29 -30
- package/components/elements/wrapper/wrapper.d.ts +2 -3
- package/components/fields/button/button.d.ts +3 -3
- package/components/fields/button/index.d.ts +2 -2
- package/components/fields/button/types.d.ts +17 -17
- package/components/fields/checkbox-group/checkbox-group.d.ts +3 -3
- package/components/fields/checkbox-group/checkbox-group.styles.d.ts +23 -24
- package/components/fields/checkbox-group/index.d.ts +2 -2
- package/components/fields/checkbox-group/types.d.ts +33 -33
- package/components/fields/chips/chips.d.ts +3 -3
- package/components/fields/chips/chips.styles.d.ts +5 -6
- package/components/fields/chips/index.d.ts +2 -2
- package/components/fields/chips/types.d.ts +18 -19
- package/components/fields/contact-field/contact-field.d.ts +3 -3
- package/components/fields/contact-field/data.d.ts +6 -6
- package/components/fields/contact-field/index.d.ts +2 -2
- package/components/fields/contact-field/types.d.ts +31 -31
- package/components/fields/contact-field/utils.d.ts +7 -7
- package/components/fields/date-field/date-field.d.ts +3 -3
- package/components/fields/date-field/index.d.ts +2 -2
- package/components/fields/date-field/types.d.ts +20 -20
- package/components/fields/date-range-field/date-range-field.d.ts +3 -3
- package/components/fields/date-range-field/index.d.ts +2 -2
- package/components/fields/date-range-field/types.d.ts +32 -32
- package/components/fields/e-signature-field/e-signature-field.d.ts +3 -3
- package/components/fields/e-signature-field/e-signature-field.styles.d.ts +4 -5
- package/components/fields/e-signature-field/index.d.ts +2 -2
- package/components/fields/e-signature-field/types.d.ts +22 -22
- package/components/fields/error-field/error-field.d.ts +3 -3
- package/components/fields/error-field/index.d.ts +2 -2
- package/components/fields/error-field/types.d.ts +11 -11
- package/components/fields/file-upload/file-upload-context.d.ts +14 -14
- package/components/fields/file-upload/file-upload-helper.d.ts +10 -10
- package/components/fields/file-upload/file-upload-manager.d.ts +14 -14
- package/components/fields/file-upload/file-upload.d.ts +4 -4
- package/components/fields/file-upload/index.d.ts +2 -2
- package/components/fields/file-upload/types.d.ts +78 -78
- package/components/fields/hidden-field/hidden-field.d.ts +3 -3
- package/components/fields/hidden-field/index.d.ts +2 -2
- package/components/fields/hidden-field/types.d.ts +29 -29
- package/components/fields/histogram-slider/histogram-slider.d.ts +3 -3
- package/components/fields/histogram-slider/index.d.ts +2 -2
- package/components/fields/histogram-slider/types.d.ts +20 -20
- package/components/fields/image-upload/image-context/image-context.d.ts +16 -16
- package/components/fields/image-upload/image-context/index.d.ts +1 -1
- package/components/fields/image-upload/image-input/drag-upload/drag-upload.d.ts +2 -3
- package/components/fields/image-upload/image-input/drag-upload/drag-upload.styles.d.ts +14 -15
- package/components/fields/image-upload/image-input/drag-upload/index.d.ts +2 -2
- package/components/fields/image-upload/image-input/drag-upload/types.d.ts +15 -16
- package/components/fields/image-upload/image-input/file-item/file-item.d.ts +11 -11
- package/components/fields/image-upload/image-input/file-item/file-item.styles.d.ts +48 -49
- package/components/fields/image-upload/image-input/file-item/index.d.ts +1 -1
- package/components/fields/image-upload/image-input/image-input.d.ts +26 -26
- package/components/fields/image-upload/image-input/image-input.styles.d.ts +47 -48
- package/components/fields/image-upload/image-input/index.d.ts +1 -1
- package/components/fields/image-upload/image-manager/image-manager.d.ts +25 -25
- package/components/fields/image-upload/image-manager/index.d.ts +2 -2
- package/components/fields/image-upload/image-review/image-editor/image-editor.d.ts +2 -3
- package/components/fields/image-upload/image-review/image-editor/image-editor.styles.d.ts +6 -7
- package/components/fields/image-upload/image-review/image-editor/index.d.ts +3 -3
- package/components/fields/image-upload/image-review/image-editor/types.d.ts +17 -17
- package/components/fields/image-upload/image-review/image-error/image-error.d.ts +10 -10
- package/components/fields/image-upload/image-review/image-error/image-error.styles.d.ts +31 -32
- package/components/fields/image-upload/image-review/image-error/index.d.ts +1 -1
- package/components/fields/image-upload/image-review/image-prompts/image-prompts.d.ts +11 -11
- package/components/fields/image-upload/image-review/image-prompts/index.d.ts +1 -1
- package/components/fields/image-upload/image-review/image-review.d.ts +18 -18
- package/components/fields/image-upload/image-review/image-review.styles.d.ts +128 -129
- package/components/fields/image-upload/image-review/image-thumbnails/image-thumbnails.d.ts +11 -11
- package/components/fields/image-upload/image-review/image-thumbnails/image-thumbnails.styles.d.ts +29 -30
- package/components/fields/image-upload/image-review/image-thumbnails/index.d.ts +1 -1
- package/components/fields/image-upload/image-review/index.d.ts +1 -1
- package/components/fields/image-upload/image-upload-helper.d.ts +12 -10
- package/components/fields/image-upload/image-upload.d.ts +4 -4
- package/components/fields/image-upload/index.d.ts +2 -2
- package/components/fields/image-upload/types.d.ts +151 -151
- package/components/fields/index.d.ts +30 -30
- package/components/fields/location-field/index.d.ts +2 -2
- package/components/fields/location-field/location-field.d.ts +3 -3
- package/components/fields/location-field/location-helper.d.ts +38 -39
- package/components/fields/location-field/location-input/dummy-location-field.d.ts +13 -14
- package/components/fields/location-field/location-input/index.d.ts +1 -1
- package/components/fields/location-field/location-input/location-input.d.ts +6 -7
- package/components/fields/location-field/location-input/location-input.styles.d.ts +22 -23
- package/components/fields/location-field/location-modal/infinite-scroll/index.d.ts +1 -1
- package/components/fields/location-field/location-modal/infinite-scroll/infinite-scroll.d.ts +11 -12
- package/components/fields/location-field/location-modal/infinite-scroll/infinite-scroll.style.d.ts +1 -2
- package/components/fields/location-field/location-modal/infinite-scroll/loading-indicator/config.d.ts +5 -5
- package/components/fields/location-field/location-modal/infinite-scroll/loading-indicator/index.d.ts +1 -1
- package/components/fields/location-field/location-modal/infinite-scroll/loading-indicator/loading-indicator.d.ts +5 -5
- package/components/fields/location-field/location-modal/infinite-scroll/loading-indicator/loading-indicator.styles.d.ts +2 -3
- package/components/fields/location-field/location-modal/location-modal.d.ts +8 -8
- package/components/fields/location-field/location-modal/location-modal.data.d.ts +3 -3
- package/components/fields/location-field/location-modal/location-modal.styles.d.ts +16 -17
- package/components/fields/location-field/location-modal/location-picker/helper.d.ts +4 -4
- package/components/fields/location-field/location-modal/location-picker/index.d.ts +1 -1
- package/components/fields/location-field/location-modal/location-picker/legend/index.d.ts +1 -1
- package/components/fields/location-field/location-modal/location-picker/legend/legend.d.ts +8 -8
- package/components/fields/location-field/location-modal/location-picker/legend/legend.styles.d.ts +10 -11
- package/components/fields/location-field/location-modal/location-picker/location-picker.d.ts +3 -3
- package/components/fields/location-field/location-modal/location-picker/location-picker.styles.d.ts +17 -18
- package/components/fields/location-field/location-modal/location-picker/types.d.ts +34 -35
- package/components/fields/location-field/location-modal/location-search/helper.d.ts +14 -14
- package/components/fields/location-field/location-modal/location-search/index.d.ts +1 -1
- package/components/fields/location-field/location-modal/location-search/location-search.d.ts +2 -2
- package/components/fields/location-field/location-modal/location-search/location-search.styles.d.ts +84 -85
- package/components/fields/location-field/location-modal/location-search/types.d.ts +30 -30
- package/components/fields/location-field/location-modal/no-network-modal/no-network-modal.d.ts +7 -7
- package/components/fields/location-field/location-modal/no-network-modal/no-network-modal.styles.d.ts +29 -30
- package/components/fields/location-field/location-modal/types.d.ts +18 -18
- package/components/fields/location-field/types.d.ts +163 -163
- package/components/fields/masked-field/index.d.ts +2 -2
- package/components/fields/masked-field/masked-field.d.ts +3 -3
- package/components/fields/masked-field/types.d.ts +12 -12
- package/components/fields/multi-select/index.d.ts +2 -2
- package/components/fields/multi-select/multi-select.d.ts +3 -3
- package/components/fields/multi-select/types.d.ts +9 -9
- package/components/fields/nested-multi-select/index.d.ts +2 -2
- package/components/fields/nested-multi-select/nested-multi-select.d.ts +3 -3
- package/components/fields/nested-multi-select/types.d.ts +33 -34
- package/components/fields/otp-verification-field/index.d.ts +2 -2
- package/components/fields/otp-verification-field/otp-verification-field.d.ts +3 -3
- package/components/fields/otp-verification-field/types.d.ts +46 -46
- package/components/fields/radio-button/index.d.ts +2 -2
- package/components/fields/radio-button/radio-button.d.ts +3 -3
- package/components/fields/radio-button/radio-button.styles.d.ts +29 -30
- package/components/fields/radio-button/types.d.ts +41 -41
- package/components/fields/range-select/index.d.ts +2 -2
- package/components/fields/range-select/range-select.d.ts +3 -3
- package/components/fields/range-select/types.d.ts +9 -9
- package/components/fields/reset-button/index.d.ts +2 -2
- package/components/fields/reset-button/reset-button.d.ts +3 -3
- package/components/fields/reset-button/types.d.ts +8 -8
- package/components/fields/select/index.d.ts +2 -2
- package/components/fields/select/select.d.ts +3 -3
- package/components/fields/select/types.d.ts +9 -9
- package/components/fields/select-histogram/index.d.ts +2 -2
- package/components/fields/select-histogram/select-histogram.d.ts +3 -3
- package/components/fields/select-histogram/types.d.ts +17 -17
- package/components/fields/slider/index.d.ts +2 -2
- package/components/fields/slider/slider.d.ts +3 -3
- package/components/fields/slider/types.d.ts +11 -11
- package/components/fields/submit-button/index.d.ts +2 -2
- package/components/fields/submit-button/submit-button.d.ts +3 -3
- package/components/fields/submit-button/types.d.ts +7 -7
- package/components/fields/switch/index.d.ts +2 -2
- package/components/fields/switch/switch.d.ts +3 -3
- package/components/fields/switch/switch.styles.d.ts +1 -2
- package/components/fields/switch/types.d.ts +10 -10
- package/components/fields/text-field/index.d.ts +2 -2
- package/components/fields/text-field/text-field.d.ts +3 -3
- package/components/fields/text-field/types.d.ts +37 -37
- package/components/fields/textarea/index.d.ts +2 -2
- package/components/fields/textarea/textarea.d.ts +3 -3
- package/components/fields/textarea/textarea.styles.d.ts +19 -20
- package/components/fields/textarea/types.d.ts +8 -8
- package/components/fields/time-field/index.d.ts +2 -2
- package/components/fields/time-field/time-field.d.ts +3 -3
- package/components/fields/time-field/types.d.ts +7 -7
- package/components/fields/types.d.ts +122 -122
- package/components/fields/unit-number-field/index.d.ts +2 -2
- package/components/fields/unit-number-field/types.d.ts +8 -8
- package/components/fields/unit-number-field/unit-number-field.d.ts +3 -3
- package/components/frontend-engine/frontend-engine.d.ts +23 -23
- package/components/frontend-engine/index.d.ts +2 -2
- package/components/frontend-engine/types.d.ts +213 -214
- package/components/frontend-engine/use-form-change.d.ts +12 -12
- package/components/index.d.ts +2 -2
- package/components/shared/chip/chip.d.ts +6 -6
- package/components/shared/chip/chip.styles.d.ts +16 -17
- package/components/shared/chip/index.d.ts +2 -2
- package/components/shared/chip/types.d.ts +4 -4
- package/components/shared/error-messages.d.ts +102 -102
- package/components/shared/index.d.ts +6 -6
- package/components/shared/prompt/index.d.ts +2 -2
- package/components/shared/prompt/prompt.d.ts +2 -2
- package/components/shared/prompt/prompt.styles.d.ts +40 -41
- package/components/shared/prompt/types.d.ts +16 -16
- package/components/shared/sanitize/index.d.ts +1 -1
- package/components/shared/sanitize/sanitize.d.ts +13 -14
- package/components/shared/static-map/index.d.ts +1 -1
- package/components/shared/static-map/static-map.d.ts +12 -12
- package/components/shared/static-map/static-map.styles.d.ts +12 -13
- package/components/shared/warning/index.d.ts +1 -1
- package/components/shared/warning/warning.d.ts +6 -6
- package/components/types.d.ts +4 -4
- package/context-providers/context-providers.d.ts +7 -7
- package/context-providers/custom-components/context-provider.d.ts +14 -14
- package/context-providers/custom-components/index.d.ts +1 -1
- package/context-providers/event/context-provider.d.ts +14 -14
- package/context-providers/event/index.d.ts +2 -2
- package/context-providers/event/types.d.ts +10 -10
- package/context-providers/form-schema/context-provider.d.ts +12 -12
- package/context-providers/form-schema/index.d.ts +1 -1
- package/context-providers/form-values/context-provider.d.ts +23 -23
- package/context-providers/form-values/index.d.ts +1 -1
- package/context-providers/frontend-engine-form/context-provider.d.ts +13 -13
- package/context-providers/frontend-engine-form/index.d.ts +1 -1
- package/context-providers/index.d.ts +7 -7
- package/context-providers/recaptcha/index.d.ts +3 -3
- package/context-providers/recaptcha/recaptcha-hook.d.ts +5 -5
- package/context-providers/recaptcha/recaptcha-provider.d.ts +10 -11
- package/context-providers/recaptcha/types.d.ts +14 -14
- package/context-providers/yup/context-provider.d.ts +16 -16
- package/context-providers/yup/custom-conditions/html-safe.d.ts +1 -1
- package/context-providers/yup/custom-conditions/index.d.ts +3 -3
- package/context-providers/yup/custom-conditions/uen.d.ts +1 -1
- package/context-providers/yup/custom-conditions/uinfin.d.ts +1 -1
- package/context-providers/yup/helper.d.ts +44 -44
- package/context-providers/yup/index.d.ts +4 -4
- package/context-providers/yup/types.d.ts +82 -82
- package/index.d.ts +3 -3
- package/index.js +1 -1
- package/package.json +1 -1
- package/services/index.d.ts +1 -1
- package/services/onemap/onemap-service.d.ts +21 -21
- package/services/onemap/types.d.ts +48 -48
- package/utils/api-client/api-client.d.ts +65 -65
- package/utils/api-client/index.d.ts +1 -1
- package/utils/date-time-helper.d.ts +22 -22
- package/utils/file-helper.d.ts +45 -47
- package/utils/geolocation-helper.d.ts +17 -17
- package/utils/hooks/index.d.ts +12 -12
- package/utils/hooks/use-custom-components.d.ts +5 -6
- package/utils/hooks/use-deep-layout-effect.d.ts +3 -3
- package/utils/hooks/use-field-event.d.ts +10 -10
- package/utils/hooks/use-form-schema.d.ts +6 -7
- package/utils/hooks/use-form-values.d.ts +11 -12
- package/utils/hooks/use-frontend-engine-component.d.ts +17 -17
- package/utils/hooks/use-frontend-engine-form.d.ts +6 -7
- package/utils/hooks/use-iframe-message.d.ts +5 -5
- package/utils/hooks/use-previous.d.ts +4 -4
- package/utils/hooks/use-validation-config.d.ts +10 -10
- package/utils/hooks/use-validation-schema.d.ts +15 -15
- package/utils/hooks/use-window-helper.d.ts +1 -1
- package/utils/id-helper.d.ts +1 -1
- package/utils/image-helper.d.ts +49 -49
- package/utils/index.d.ts +11 -11
- package/utils/math-helper.d.ts +5 -5
- package/utils/object-helper.d.ts +15 -15
- package/utils/prop-helper.d.ts +8 -8
- package/utils/test-helper.d.ts +4 -4
- package/utils/ts-helper.d.ts +1 -1
- package/utils/types.d.ts +9 -9
- package/chunks/file-upload-manager.ddb44c1f.js +0 -2
- package/chunks/file-upload-manager.ddb44c1f.js.map +0 -1
- package/cjs/chunks/file-upload-manager.b22d56d4.js +0 -2
- package/cjs/chunks/file-upload-manager.b22d56d4.js.map +0 -1
|
@@ -1,48 +1,48 @@
|
|
|
1
|
-
export type OneMapGeocodeInfo = {
|
|
2
|
-
BUILDINGNAME: string;
|
|
3
|
-
BLOCK: string;
|
|
4
|
-
ROAD: string;
|
|
5
|
-
POSTALCODE: string;
|
|
6
|
-
XCOORD: string;
|
|
7
|
-
YCOORD: string;
|
|
8
|
-
LATITUDE: string;
|
|
9
|
-
LONGITUDE: string;
|
|
10
|
-
};
|
|
11
|
-
export type OneMapSearchParam = {
|
|
12
|
-
searchValue: string;
|
|
13
|
-
returnGeom: OneMapBoolean;
|
|
14
|
-
getAddressDetails: OneMapBoolean;
|
|
15
|
-
pageNum: number;
|
|
16
|
-
};
|
|
17
|
-
export declare enum OneMapBoolean {
|
|
18
|
-
YES = "Y",
|
|
19
|
-
NO = "N"
|
|
20
|
-
}
|
|
21
|
-
export type OneMapSearchResults = {
|
|
22
|
-
found: number;
|
|
23
|
-
totalNumPages: number;
|
|
24
|
-
pageNum: number;
|
|
25
|
-
results: OneMapSearchBuildingResult[];
|
|
26
|
-
};
|
|
27
|
-
export type OneMapSearchBuildingResult = {
|
|
28
|
-
SEARCHVAL: string;
|
|
29
|
-
BLK_NO: string;
|
|
30
|
-
ROAD_NAME: string;
|
|
31
|
-
BUILDING: string;
|
|
32
|
-
ADDRESS: string;
|
|
33
|
-
POSTAL: string;
|
|
34
|
-
X: string;
|
|
35
|
-
Y: string;
|
|
36
|
-
LATITUDE: string;
|
|
37
|
-
LONGITUDE: string;
|
|
38
|
-
DISPLAY_ADDRESS?: string;
|
|
39
|
-
};
|
|
40
|
-
export interface IColor {
|
|
41
|
-
r: number;
|
|
42
|
-
g: number;
|
|
43
|
-
b: number;
|
|
44
|
-
}
|
|
45
|
-
export declare class OneMapError extends Error {
|
|
46
|
-
innerError: any;
|
|
47
|
-
constructor(error: any, message?: string);
|
|
48
|
-
}
|
|
1
|
+
export type OneMapGeocodeInfo = {
|
|
2
|
+
BUILDINGNAME: string;
|
|
3
|
+
BLOCK: string;
|
|
4
|
+
ROAD: string;
|
|
5
|
+
POSTALCODE: string;
|
|
6
|
+
XCOORD: string;
|
|
7
|
+
YCOORD: string;
|
|
8
|
+
LATITUDE: string;
|
|
9
|
+
LONGITUDE: string;
|
|
10
|
+
};
|
|
11
|
+
export type OneMapSearchParam = {
|
|
12
|
+
searchValue: string;
|
|
13
|
+
returnGeom: OneMapBoolean;
|
|
14
|
+
getAddressDetails: OneMapBoolean;
|
|
15
|
+
pageNum: number;
|
|
16
|
+
};
|
|
17
|
+
export declare enum OneMapBoolean {
|
|
18
|
+
YES = "Y",
|
|
19
|
+
NO = "N"
|
|
20
|
+
}
|
|
21
|
+
export type OneMapSearchResults = {
|
|
22
|
+
found: number;
|
|
23
|
+
totalNumPages: number;
|
|
24
|
+
pageNum: number;
|
|
25
|
+
results: OneMapSearchBuildingResult[];
|
|
26
|
+
};
|
|
27
|
+
export type OneMapSearchBuildingResult = {
|
|
28
|
+
SEARCHVAL: string;
|
|
29
|
+
BLK_NO: string;
|
|
30
|
+
ROAD_NAME: string;
|
|
31
|
+
BUILDING: string;
|
|
32
|
+
ADDRESS: string;
|
|
33
|
+
POSTAL: string;
|
|
34
|
+
X: string;
|
|
35
|
+
Y: string;
|
|
36
|
+
LATITUDE: string;
|
|
37
|
+
LONGITUDE: string;
|
|
38
|
+
DISPLAY_ADDRESS?: string;
|
|
39
|
+
};
|
|
40
|
+
export interface IColor {
|
|
41
|
+
r: number;
|
|
42
|
+
g: number;
|
|
43
|
+
b: number;
|
|
44
|
+
}
|
|
45
|
+
export declare class OneMapError extends Error {
|
|
46
|
+
innerError: any;
|
|
47
|
+
constructor(error: any, message?: string);
|
|
48
|
+
}
|
|
@@ -1,65 +1,65 @@
|
|
|
1
|
-
import { AxiosInstance, AxiosRequestConfig, AxiosResponse } from "axios";
|
|
2
|
-
export declare class AxiosApiClient {
|
|
3
|
-
private _client;
|
|
4
|
-
constructor(
|
|
5
|
-
/** the base url of the api. We suggest each api to have it's own client */
|
|
6
|
-
baseURL: string,
|
|
7
|
-
/** the api timeout duration. Default 15000ms */
|
|
8
|
-
timeout?: number,
|
|
9
|
-
/**
|
|
10
|
-
* Default:
|
|
11
|
-
* "Content-Type": "application/json",
|
|
12
|
-
* "Accept": "application/json",
|
|
13
|
-
*/
|
|
14
|
-
headers?: {
|
|
15
|
-
"Content-Type": string;
|
|
16
|
-
Accept: string;
|
|
17
|
-
},
|
|
18
|
-
/** Specify if cross-site Access-Control requests should be
|
|
19
|
-
* made using credentials such as cookies, authorization headers
|
|
20
|
-
* or TLS client certificates
|
|
21
|
-
*/
|
|
22
|
-
withCredentials?: boolean, config?: AxiosRequestConfig);
|
|
23
|
-
/**
|
|
24
|
-
*
|
|
25
|
-
* @param path the path of the endpoint
|
|
26
|
-
* @param config AxiosRequestConfig. For simple usage with params, just wrap it in an object (e.g. { params })
|
|
27
|
-
*/
|
|
28
|
-
get<T>(path: string, config?: AxiosRequestConfig): Promise<T>;
|
|
29
|
-
/**
|
|
30
|
-
* Gets response along with the full schema
|
|
31
|
-
* @param path the path of the endpoint
|
|
32
|
-
* @param config AxiosRequestConfig. For simple usage with params, just wrap it in an object (e.g. { params })
|
|
33
|
-
*/
|
|
34
|
-
getFull<T>(path: string, config?: AxiosRequestConfig): Promise<AxiosResponse<T>>;
|
|
35
|
-
/**
|
|
36
|
-
*
|
|
37
|
-
* @param path the path of the endpoint
|
|
38
|
-
* @param payload the data of the POST request
|
|
39
|
-
* @param config AxiosRequestConfig
|
|
40
|
-
*/
|
|
41
|
-
post<T>(path: string, payload?: any, config?: AxiosRequestConfig): Promise<T>;
|
|
42
|
-
/**
|
|
43
|
-
*
|
|
44
|
-
* @param path the path of the endpoint
|
|
45
|
-
* @param payload the data of the PUT request
|
|
46
|
-
* @param config AxiosRequestConfig
|
|
47
|
-
*/
|
|
48
|
-
put<T>(path: string, payload?: any, config?: AxiosRequestConfig): Promise<T>;
|
|
49
|
-
/**
|
|
50
|
-
*
|
|
51
|
-
* @param path the path of the endpoint
|
|
52
|
-
* @param payload the data of the PATCH request
|
|
53
|
-
* @param config AxiosRequestConfig
|
|
54
|
-
*/
|
|
55
|
-
patch<T>(path: string, payload?: any, config?: AxiosRequestConfig): Promise<T>;
|
|
56
|
-
/**
|
|
57
|
-
*
|
|
58
|
-
* @param path the path of the endpoint
|
|
59
|
-
* @param config AxiosRequestConfig
|
|
60
|
-
*/
|
|
61
|
-
delete<T>(path: string, config?: AxiosRequestConfig): Promise<T>;
|
|
62
|
-
getClient(): AxiosInstance;
|
|
63
|
-
private _handleSuccess;
|
|
64
|
-
private _handleError;
|
|
65
|
-
}
|
|
1
|
+
import { AxiosInstance, AxiosRequestConfig, AxiosResponse } from "axios";
|
|
2
|
+
export declare class AxiosApiClient {
|
|
3
|
+
private _client;
|
|
4
|
+
constructor(
|
|
5
|
+
/** the base url of the api. We suggest each api to have it's own client */
|
|
6
|
+
baseURL: string,
|
|
7
|
+
/** the api timeout duration. Default 15000ms */
|
|
8
|
+
timeout?: number,
|
|
9
|
+
/**
|
|
10
|
+
* Default:
|
|
11
|
+
* "Content-Type": "application/json",
|
|
12
|
+
* "Accept": "application/json",
|
|
13
|
+
*/
|
|
14
|
+
headers?: {
|
|
15
|
+
"Content-Type": string;
|
|
16
|
+
Accept: string;
|
|
17
|
+
},
|
|
18
|
+
/** Specify if cross-site Access-Control requests should be
|
|
19
|
+
* made using credentials such as cookies, authorization headers
|
|
20
|
+
* or TLS client certificates
|
|
21
|
+
*/
|
|
22
|
+
withCredentials?: boolean, config?: AxiosRequestConfig);
|
|
23
|
+
/**
|
|
24
|
+
*
|
|
25
|
+
* @param path the path of the endpoint
|
|
26
|
+
* @param config AxiosRequestConfig. For simple usage with params, just wrap it in an object (e.g. { params })
|
|
27
|
+
*/
|
|
28
|
+
get<T>(path: string, config?: AxiosRequestConfig): Promise<T>;
|
|
29
|
+
/**
|
|
30
|
+
* Gets response along with the full schema
|
|
31
|
+
* @param path the path of the endpoint
|
|
32
|
+
* @param config AxiosRequestConfig. For simple usage with params, just wrap it in an object (e.g. { params })
|
|
33
|
+
*/
|
|
34
|
+
getFull<T>(path: string, config?: AxiosRequestConfig): Promise<AxiosResponse<T>>;
|
|
35
|
+
/**
|
|
36
|
+
*
|
|
37
|
+
* @param path the path of the endpoint
|
|
38
|
+
* @param payload the data of the POST request
|
|
39
|
+
* @param config AxiosRequestConfig
|
|
40
|
+
*/
|
|
41
|
+
post<T>(path: string, payload?: any, config?: AxiosRequestConfig): Promise<T>;
|
|
42
|
+
/**
|
|
43
|
+
*
|
|
44
|
+
* @param path the path of the endpoint
|
|
45
|
+
* @param payload the data of the PUT request
|
|
46
|
+
* @param config AxiosRequestConfig
|
|
47
|
+
*/
|
|
48
|
+
put<T>(path: string, payload?: any, config?: AxiosRequestConfig): Promise<T>;
|
|
49
|
+
/**
|
|
50
|
+
*
|
|
51
|
+
* @param path the path of the endpoint
|
|
52
|
+
* @param payload the data of the PATCH request
|
|
53
|
+
* @param config AxiosRequestConfig
|
|
54
|
+
*/
|
|
55
|
+
patch<T>(path: string, payload?: any, config?: AxiosRequestConfig): Promise<T>;
|
|
56
|
+
/**
|
|
57
|
+
*
|
|
58
|
+
* @param path the path of the endpoint
|
|
59
|
+
* @param config AxiosRequestConfig
|
|
60
|
+
*/
|
|
61
|
+
delete<T>(path: string, config?: AxiosRequestConfig): Promise<T>;
|
|
62
|
+
getClient(): AxiosInstance;
|
|
63
|
+
private _handleSuccess;
|
|
64
|
+
private _handleError;
|
|
65
|
+
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export * from "./api-client";
|
|
1
|
+
export * from "./api-client";
|
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
import { LocalDate, LocalDateTime, LocalTime } from "@js-joda/core";
|
|
2
|
-
import { IDaysRangeRule, IWithinDaysRangeRule } from "../context-providers";
|
|
3
|
-
export declare namespace DateTimeHelper {
|
|
4
|
-
const formatDateTime: (value: string, format: string, type: "date" | "time" | "datetime", errorMessage?: string) => string | undefined;
|
|
5
|
-
function toLocalDateOrTime(value: string, format: string, type: "date"): LocalDate | undefined;
|
|
6
|
-
function toLocalDateOrTime(value: string, format: string, type: "time"): LocalTime | undefined;
|
|
7
|
-
function toLocalDateOrTime(value: string, format: string, type: "datetime"): LocalDateTime | undefined;
|
|
8
|
-
function calculateWithinDaysRange(withinDays: IWithinDaysRangeRule): {
|
|
9
|
-
startDate: LocalDate;
|
|
10
|
-
endDate: LocalDate;
|
|
11
|
-
};
|
|
12
|
-
function calculateDisabledWithinDaysRange(withinDays: IWithinDaysRangeRule): {
|
|
13
|
-
startDate: LocalDate;
|
|
14
|
-
endDate: LocalDate;
|
|
15
|
-
};
|
|
16
|
-
function calculateDisabledBeyondDaysRange(beyondDays: IDaysRangeRule): {
|
|
17
|
-
startDate: any;
|
|
18
|
-
endDate: any;
|
|
19
|
-
};
|
|
20
|
-
function checkWithinDays(value: string, withinDays: IWithinDaysRangeRule): boolean;
|
|
21
|
-
function checkBeyondDays(value: string, beyondDays: IDaysRangeRule): boolean;
|
|
22
|
-
}
|
|
1
|
+
import { LocalDate, LocalDateTime, LocalTime } from "@js-joda/core";
|
|
2
|
+
import { IDaysRangeRule, IWithinDaysRangeRule } from "../context-providers";
|
|
3
|
+
export declare namespace DateTimeHelper {
|
|
4
|
+
const formatDateTime: (value: string, format: string, type: "date" | "time" | "datetime", errorMessage?: string) => string | undefined;
|
|
5
|
+
function toLocalDateOrTime(value: string, format: string, type: "date"): LocalDate | undefined;
|
|
6
|
+
function toLocalDateOrTime(value: string, format: string, type: "time"): LocalTime | undefined;
|
|
7
|
+
function toLocalDateOrTime(value: string, format: string, type: "datetime"): LocalDateTime | undefined;
|
|
8
|
+
function calculateWithinDaysRange(withinDays: IWithinDaysRangeRule): {
|
|
9
|
+
startDate: LocalDate;
|
|
10
|
+
endDate: LocalDate;
|
|
11
|
+
};
|
|
12
|
+
function calculateDisabledWithinDaysRange(withinDays: IWithinDaysRangeRule): {
|
|
13
|
+
startDate: LocalDate;
|
|
14
|
+
endDate: LocalDate;
|
|
15
|
+
};
|
|
16
|
+
function calculateDisabledBeyondDaysRange(beyondDays: IDaysRangeRule): {
|
|
17
|
+
startDate: any;
|
|
18
|
+
endDate: any;
|
|
19
|
+
};
|
|
20
|
+
function checkWithinDays(value: string, withinDays: IWithinDaysRangeRule): boolean;
|
|
21
|
+
function checkBeyondDays(value: string, beyondDays: IDaysRangeRule): boolean;
|
|
22
|
+
}
|
package/utils/file-helper.d.ts
CHANGED
|
@@ -1,47 +1,45 @@
|
|
|
1
|
-
export declare namespace FileHelper {
|
|
2
|
-
/**
|
|
3
|
-
* truncate file name according to wrapping element width
|
|
4
|
-
*/
|
|
5
|
-
|
|
6
|
-
/**
|
|
7
|
-
* converts file/blob to dataURL
|
|
8
|
-
*/
|
|
9
|
-
|
|
10
|
-
/**
|
|
11
|
-
* converts dataURL to blob
|
|
12
|
-
*/
|
|
13
|
-
|
|
14
|
-
/**
|
|
15
|
-
* estimate filesize (in terms of bytes) from base64 string
|
|
16
|
-
* https://stackoverflow.com/questions/53228948/how-to-get-image-file-size-from-base-64-string-in-javascript#answer-53229045
|
|
17
|
-
*/
|
|
18
|
-
|
|
19
|
-
/**
|
|
20
|
-
* convert array of file extensions to a proper sentence
|
|
21
|
-
* convert to uppercase
|
|
22
|
-
* joins array with comma
|
|
23
|
-
* add `or` before last extension
|
|
24
|
-
*/
|
|
25
|
-
|
|
26
|
-
setBothJpegAndJpgIfEitherExists?: boolean;
|
|
27
|
-
}) => string;
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
export {};
|
|
47
|
-
}
|
|
1
|
+
export declare namespace FileHelper {
|
|
2
|
+
/**
|
|
3
|
+
* truncate file name according to wrapping element width
|
|
4
|
+
*/
|
|
5
|
+
const truncateFileName: (fileName: string, ref?: React.MutableRefObject<HTMLDivElement | HTMLParagraphElement> | undefined) => string;
|
|
6
|
+
/**
|
|
7
|
+
* converts file/blob to dataURL
|
|
8
|
+
*/
|
|
9
|
+
const fileToDataUrl: (file: File | Blob) => Promise<string>;
|
|
10
|
+
/**
|
|
11
|
+
* converts dataURL to blob
|
|
12
|
+
*/
|
|
13
|
+
const dataUrlToBlob: (dataUrl: string) => Promise<Blob>;
|
|
14
|
+
/**
|
|
15
|
+
* estimate filesize (in terms of bytes) from base64 string
|
|
16
|
+
* https://stackoverflow.com/questions/53228948/how-to-get-image-file-size-from-base-64-string-in-javascript#answer-53229045
|
|
17
|
+
*/
|
|
18
|
+
const getFilesizeFromBase64: (base64: string) => number;
|
|
19
|
+
/**
|
|
20
|
+
* convert array of file extensions to a proper sentence
|
|
21
|
+
* convert to uppercase
|
|
22
|
+
* joins array with comma
|
|
23
|
+
* add `or` before last extension
|
|
24
|
+
*/
|
|
25
|
+
const extensionsToSentence: (list: string[], options?: {
|
|
26
|
+
setBothJpegAndJpgIfEitherExists?: boolean;
|
|
27
|
+
}) => string;
|
|
28
|
+
/**
|
|
29
|
+
* converts file extension to mime type
|
|
30
|
+
*/
|
|
31
|
+
const fileExtensionToMimeType: (ext: string) => string | undefined;
|
|
32
|
+
/**
|
|
33
|
+
* reliably derive file type by checking magic number of the buffer
|
|
34
|
+
*/
|
|
35
|
+
const getType: (file: Blob | File) => Promise<import("file-type").FileTypeResult>;
|
|
36
|
+
/**
|
|
37
|
+
* ensure file name is unique against a list of file names
|
|
38
|
+
*/
|
|
39
|
+
const deduplicateFileName: (fileNameList: string[], index: number, fileName: string, originalFilename?: string, counter?: number) => string;
|
|
40
|
+
const sanitizeFileName: (fileName: string) => string;
|
|
41
|
+
const blobToFile: (blob: Blob, metadata: {
|
|
42
|
+
name: string;
|
|
43
|
+
lastModified: number;
|
|
44
|
+
}) => File;
|
|
45
|
+
}
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import { ILocationCoord } from "src/components/fields/location-field/types";
|
|
2
|
-
export interface IGetCurrentLocationOptions {
|
|
3
|
-
maxAttempts?: number;
|
|
4
|
-
timeout?: number;
|
|
5
|
-
maximumAge?: number;
|
|
6
|
-
}
|
|
7
|
-
export declare namespace GeoLocationHelper {
|
|
8
|
-
/**
|
|
9
|
-
* @param options An optional options object that lets you specify the maximum no. of attempts (default: 3),
|
|
10
|
-
* the timeout in milliseconds (default: 2000), the maximum age of a possible cached position in milliseconds (default: 2000)
|
|
11
|
-
* A minimum of one attempt will be made, even if maxAttempts is 0.
|
|
12
|
-
* @returns A Promise that gets the current location.
|
|
13
|
-
* @resolve type: ILocationCoord
|
|
14
|
-
* @reject type: GeolocationPositionError | undefined
|
|
15
|
-
*/
|
|
16
|
-
const getCurrentLocation: (options?: IGetCurrentLocationOptions) => Promise<ILocationCoord>;
|
|
17
|
-
}
|
|
1
|
+
import { ILocationCoord } from "src/components/fields/location-field/types";
|
|
2
|
+
export interface IGetCurrentLocationOptions {
|
|
3
|
+
maxAttempts?: number;
|
|
4
|
+
timeout?: number;
|
|
5
|
+
maximumAge?: number;
|
|
6
|
+
}
|
|
7
|
+
export declare namespace GeoLocationHelper {
|
|
8
|
+
/**
|
|
9
|
+
* @param options An optional options object that lets you specify the maximum no. of attempts (default: 3),
|
|
10
|
+
* the timeout in milliseconds (default: 2000), the maximum age of a possible cached position in milliseconds (default: 2000)
|
|
11
|
+
* A minimum of one attempt will be made, even if maxAttempts is 0.
|
|
12
|
+
* @returns A Promise that gets the current location.
|
|
13
|
+
* @resolve type: ILocationCoord
|
|
14
|
+
* @reject type: GeolocationPositionError | undefined
|
|
15
|
+
*/
|
|
16
|
+
const getCurrentLocation: (options?: IGetCurrentLocationOptions) => Promise<ILocationCoord>;
|
|
17
|
+
}
|
package/utils/hooks/index.d.ts
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
export * from "./use-custom-components";
|
|
2
|
-
export * from "./use-deep-layout-effect";
|
|
3
|
-
export * from "./use-field-event";
|
|
4
|
-
export * from "./use-form-schema";
|
|
5
|
-
export * from "./use-form-values";
|
|
6
|
-
export * from "./use-frontend-engine-component";
|
|
7
|
-
export * from "./use-frontend-engine-form";
|
|
8
|
-
export * from "./use-iframe-message";
|
|
9
|
-
export * from "./use-previous";
|
|
10
|
-
export * from "./use-validation-config";
|
|
11
|
-
export * from "./use-validation-schema";
|
|
12
|
-
export * from "./use-window-helper";
|
|
1
|
+
export * from "./use-custom-components";
|
|
2
|
+
export * from "./use-deep-layout-effect";
|
|
3
|
+
export * from "./use-field-event";
|
|
4
|
+
export * from "./use-form-schema";
|
|
5
|
+
export * from "./use-form-values";
|
|
6
|
+
export * from "./use-frontend-engine-component";
|
|
7
|
+
export * from "./use-frontend-engine-form";
|
|
8
|
+
export * from "./use-iframe-message";
|
|
9
|
+
export * from "./use-previous";
|
|
10
|
+
export * from "./use-validation-config";
|
|
11
|
+
export * from "./use-validation-schema";
|
|
12
|
+
export * from "./use-window-helper";
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
};
|
|
1
|
+
export declare const useCustomComponents: () => {
|
|
2
|
+
customComponents: import("../../context-providers").TCustomComponents;
|
|
3
|
+
getCustomComponent: (referenceKey: string) => import("../..").TCustomComponent<any>;
|
|
4
|
+
setCustomComponents: import("react").Dispatch<import("react").SetStateAction<import("../../context-providers").TCustomComponents>>;
|
|
5
|
+
};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { useLayoutEffect } from "react";
|
|
2
|
-
export declare const useDeepLayoutEffect: typeof useLayoutEffect;
|
|
3
|
-
export declare const useIsomorphicDeepLayoutEffect: typeof useLayoutEffect;
|
|
1
|
+
import { useLayoutEffect } from "react";
|
|
2
|
+
export declare const useDeepLayoutEffect: typeof useLayoutEffect;
|
|
3
|
+
export declare const useIsomorphicDeepLayoutEffect: typeof useLayoutEffect;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { TAddFieldEventListener } from "../../context-providers";
|
|
2
|
-
/**
|
|
3
|
-
* Hook that interacts with the event context provider
|
|
4
|
-
* use this hook to add/dispatch/remove event listeners
|
|
5
|
-
*/
|
|
6
|
-
export declare const useFieldEvent: () => {
|
|
7
|
-
addFieldEventListener: TAddFieldEventListener;
|
|
8
|
-
dispatchFieldEvent: <T = any>(arg1: string, arg2: string, arg3?: string | T, arg4?: T) => boolean;
|
|
9
|
-
removeFieldEventListener: TAddFieldEventListener;
|
|
10
|
-
};
|
|
1
|
+
import { TAddFieldEventListener } from "../../context-providers";
|
|
2
|
+
/**
|
|
3
|
+
* Hook that interacts with the event context provider
|
|
4
|
+
* use this hook to add/dispatch/remove event listeners
|
|
5
|
+
*/
|
|
6
|
+
export declare const useFieldEvent: () => {
|
|
7
|
+
addFieldEventListener: TAddFieldEventListener;
|
|
8
|
+
dispatchFieldEvent: <T = any>(arg1: string, arg2: string, arg3?: string | T | undefined, arg4?: T | undefined) => boolean;
|
|
9
|
+
removeFieldEventListener: TAddFieldEventListener;
|
|
10
|
+
};
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
};
|
|
1
|
+
import { IFrontendEngineData } from "../../components";
|
|
2
|
+
export declare const useFormSchema: () => {
|
|
3
|
+
setFormSchema: import("react").Dispatch<import("react").SetStateAction<IFrontendEngineData<undefined, undefined>>>;
|
|
4
|
+
formSchema: IFrontendEngineData<undefined, undefined>;
|
|
5
|
+
overrideSchema: <T>(children: T, overrides: IFrontendEngineData["overrides"]) => T;
|
|
6
|
+
};
|
|
@@ -1,12 +1,11 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
};
|
|
1
|
+
import { UseFormReturn } from "react-hook-form";
|
|
2
|
+
export declare const useFormValues: (formMethods?: UseFormReturn | undefined) => {
|
|
3
|
+
formValues: Record<string, unknown>;
|
|
4
|
+
getField: (id: string) => unknown;
|
|
5
|
+
setFields: (values: Record<string, unknown>) => void;
|
|
6
|
+
setField: (id: string, value: unknown) => void;
|
|
7
|
+
resetFields: (values: Record<string, unknown>) => void;
|
|
8
|
+
registeredFields: string[];
|
|
9
|
+
setRegisteredFields: import("react").Dispatch<import("react").SetStateAction<string[]>>;
|
|
10
|
+
getFormValues: (payload?: string | string[] | undefined, stripUnknown?: boolean) => any;
|
|
11
|
+
};
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* returns various functions for custom component's use
|
|
3
|
-
*
|
|
4
|
-
* to be used within custom components
|
|
5
|
-
*/
|
|
6
|
-
export declare const useFrontendEngineComponent: () => {
|
|
7
|
-
event: {
|
|
8
|
-
addFieldEventListener: import("../../context-providers").TAddFieldEventListener;
|
|
9
|
-
dispatchFieldEvent: <T = any>(arg1: string, arg2: string, arg3?: string | T, arg4?: T) => boolean;
|
|
10
|
-
removeFieldEventListener: import("../../context-providers").TAddFieldEventListener;
|
|
11
|
-
};
|
|
12
|
-
formContext: import("react-hook-form").UseFormReturn<import("react-hook-form").FieldValues, any, undefined>;
|
|
13
|
-
validation: {
|
|
14
|
-
setValidation: <V = import("../..").IYupValidationRule<undefined, undefined>>(id: string, schema: import("yup").AnySchema
|
|
15
|
-
removeValidation: (id: string) => void;
|
|
16
|
-
};
|
|
17
|
-
};
|
|
1
|
+
/**
|
|
2
|
+
* returns various functions for custom component's use
|
|
3
|
+
*
|
|
4
|
+
* to be used within custom components
|
|
5
|
+
*/
|
|
6
|
+
export declare const useFrontendEngineComponent: () => {
|
|
7
|
+
event: {
|
|
8
|
+
addFieldEventListener: import("../../context-providers").TAddFieldEventListener;
|
|
9
|
+
dispatchFieldEvent: <T = any>(arg1: string, arg2: string, arg3?: string | T | undefined, arg4?: T | undefined) => boolean;
|
|
10
|
+
removeFieldEventListener: import("../../context-providers").TAddFieldEventListener;
|
|
11
|
+
};
|
|
12
|
+
formContext: import("react-hook-form").UseFormReturn<import("react-hook-form").FieldValues, any, undefined>;
|
|
13
|
+
validation: {
|
|
14
|
+
setValidation: <V = import("../..").IYupValidationRule<undefined, undefined>>(id: string, schema: import("yup").AnySchema, validationRules?: V[]) => void;
|
|
15
|
+
removeValidation: (id: string) => void;
|
|
16
|
+
};
|
|
17
|
+
};
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
};
|
|
1
|
+
export declare const useFrontendEngineForm: () => {
|
|
2
|
+
submitHandler: () => void;
|
|
3
|
+
setSubmitHandler: import("react").Dispatch<import("react").SetStateAction<() => void>>;
|
|
4
|
+
wrapInForm: boolean;
|
|
5
|
+
setWrapInForm: import("react").Dispatch<import("react").SetStateAction<boolean>>;
|
|
6
|
+
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
type MessageHandler<T = any> = (event: MessageEvent<{
|
|
2
|
-
payload: T;
|
|
3
|
-
}>) => void;
|
|
4
|
-
export declare const useIframeMessage: <T>(eventType: string, handler: MessageHandler<T>) => void;
|
|
5
|
-
export {};
|
|
1
|
+
type MessageHandler<T = any> = (event: MessageEvent<{
|
|
2
|
+
payload: T;
|
|
3
|
+
}>) => void;
|
|
4
|
+
export declare const useIframeMessage: <T>(eventType: string, handler: MessageHandler<T>) => void;
|
|
5
|
+
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* tracks the previous value
|
|
3
|
-
*/
|
|
4
|
-
export declare const usePrevious: <T = unknown>(value: T) => T;
|
|
1
|
+
/**
|
|
2
|
+
* tracks the previous value
|
|
3
|
+
*/
|
|
4
|
+
export declare const usePrevious: <T = unknown>(value: T) => T;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import * as Yup from "yup";
|
|
2
|
-
import { IYupValidationRule } from "../../context-providers";
|
|
3
|
-
/**
|
|
4
|
-
* Hook that interacts with the validation config
|
|
5
|
-
*/
|
|
6
|
-
export declare const useValidationConfig: () => {
|
|
7
|
-
formValidationConfig: import("../../context-providers").TFormYupConfig;
|
|
8
|
-
setFieldValidationConfig: <V = IYupValidationRule<undefined, undefined>>(id: string, schema: Yup.AnySchema, validationRules?: V[]) => void;
|
|
9
|
-
removeFieldValidationConfig: (id: string) => void;
|
|
10
|
-
};
|
|
1
|
+
import * as Yup from "yup";
|
|
2
|
+
import { IYupValidationRule } from "../../context-providers";
|
|
3
|
+
/**
|
|
4
|
+
* Hook that interacts with the validation config
|
|
5
|
+
*/
|
|
6
|
+
export declare const useValidationConfig: () => {
|
|
7
|
+
formValidationConfig: import("../../context-providers").TFormYupConfig;
|
|
8
|
+
setFieldValidationConfig: <V = IYupValidationRule<undefined, undefined>>(id: string, schema: Yup.AnySchema, validationRules?: V[]) => void;
|
|
9
|
+
removeFieldValidationConfig: (id: string) => void;
|
|
10
|
+
};
|