@safetech/inheriti-client-sdk 1.0.0

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.
Files changed (257) hide show
  1. package/README.md +22 -0
  2. package/dist/index.d.ts +4 -0
  3. package/dist/index.js +2 -0
  4. package/dist/src/modules/_shared/domain/contexts/data-provider-context.d.ts +2 -0
  5. package/dist/src/modules/_shared/domain/contexts/service-provider-context.d.ts +2 -0
  6. package/dist/src/modules/_shared/domain/contexts/utils-provider-context.d.ts +5 -0
  7. package/dist/src/modules/_shared/domain/errors/getErrorMessage.d.ts +1 -0
  8. package/dist/src/modules/_shared/domain/hooks/resources/use-create.d.ts +18 -0
  9. package/dist/src/modules/_shared/domain/hooks/resources/use-delete.d.ts +19 -0
  10. package/dist/src/modules/_shared/domain/hooks/resources/use-get-list.d.ts +25 -0
  11. package/dist/src/modules/_shared/domain/hooks/resources/use-get-one.d.ts +17 -0
  12. package/dist/src/modules/_shared/domain/hooks/use-data-provider.d.ts +2 -0
  13. package/dist/src/modules/_shared/domain/hooks/use-repository.d.ts +1 -0
  14. package/dist/src/modules/_shared/domain/hooks/use-service-provider.d.ts +2 -0
  15. package/dist/src/modules/_shared/domain/hooks/use-service.d.ts +1 -0
  16. package/dist/src/modules/_shared/domain/hooks/utils-hooks.d.ts +4 -0
  17. package/dist/src/modules/_shared/domain/models/app-utils.d.ts +10 -0
  18. package/dist/src/modules/_shared/domain/models/currency-price.d.ts +39 -0
  19. package/dist/src/modules/_shared/domain/models/currency.d.ts +24 -0
  20. package/dist/src/modules/_shared/domain/models/euro-currency.d.ts +3 -0
  21. package/dist/src/modules/_shared/domain/models/mutation-options.d.ts +8 -0
  22. package/dist/src/modules/_shared/domain/models/mutation.d.ts +5 -0
  23. package/dist/src/modules/_shared/domain/models/pagination-options.d.ts +4 -0
  24. package/dist/src/modules/_shared/domain/models/query-options.d.ts +6 -0
  25. package/dist/src/modules/_shared/domain/models/query.d.ts +5 -0
  26. package/dist/src/modules/_shared/domain/models/resource-count.d.ts +3 -0
  27. package/dist/src/modules/_shared/domain/models/sort-options.d.ts +4 -0
  28. package/dist/src/modules/_shared/domain/models/use-mutation-value.d.ts +13 -0
  29. package/dist/src/modules/_shared/domain/models/use-query-value.d.ts +11 -0
  30. package/dist/src/modules/_shared/domain/services/mutation-creator.d.ts +6 -0
  31. package/dist/src/modules/_shared/domain/services/query-creator.d.ts +6 -0
  32. package/dist/src/modules/_shared/domain/utils/misc/array-utils.d.ts +48 -0
  33. package/dist/src/modules/_shared/domain/utils/misc/datetime-utils.d.ts +40 -0
  34. package/dist/src/modules/_shared/domain/utils/misc/encrypt-utils.d.ts +17 -0
  35. package/dist/src/modules/_shared/domain/utils/misc/number-utils.d.ts +4 -0
  36. package/dist/src/modules/_shared/domain/utils/misc/object-utils.d.ts +76 -0
  37. package/dist/src/modules/_shared/domain/utils/misc/text-utils.d.ts +7 -0
  38. package/dist/src/modules/_shared/domain/utils/misc/uuid-utils.d.ts +6 -0
  39. package/dist/src/modules/_shared/infrastructure/api/api-repository.d.ts +36 -0
  40. package/dist/src/modules/_shared/infrastructure/api/app-payload-encrypter.d.ts +9 -0
  41. package/dist/src/modules/_shared/infrastructure/http/HttpError.d.ts +7 -0
  42. package/dist/src/modules/_shared/infrastructure/http/fetch.d.ts +48 -0
  43. package/dist/src/modules/_shared/infrastructure/local-storage/browser-local-storage.d.ts +9 -0
  44. package/dist/src/modules/_shared/infrastructure/providers/app-data-provider.d.ts +20 -0
  45. package/dist/src/modules/_shared/infrastructure/providers/app-provider.d.ts +15 -0
  46. package/dist/src/modules/_shared/infrastructure/providers/app-service-provider.d.ts +28 -0
  47. package/dist/src/modules/_shared/infrastructure/providers/app-utils-provider.d.ts +175 -0
  48. package/dist/src/modules/_shared/infrastructure/providers/inheriti-client-provider.d.ts +46 -0
  49. package/dist/src/modules/_shared/infrastructure/secure-storage/app-secure-storage.d.ts +8 -0
  50. package/dist/src/modules/_shared/infrastructure/services/hexEncoder.d.ts +4 -0
  51. package/dist/src/modules/_shared/infrastructure/services/react-q-query-creator.d.ts +7 -0
  52. package/dist/src/modules/_shared/infrastructure/services/react-query-mutation-creator.d.ts +7 -0
  53. package/dist/src/modules/_shared/infrastructure/services/safeshareLegacy.d.ts +29 -0
  54. package/dist/src/modules/_shared/infrastructure/session-storage/browser-session-storage.d.ts +12 -0
  55. package/dist/src/modules/_shared/infrastructure/utils/context-selector.d.ts +2 -0
  56. package/dist/src/modules/_shared/infrastructure/utils/get-api-url.d.ts +1 -0
  57. package/dist/src/modules/_shared/infrastructure/utils/set-query-params.d.ts +5 -0
  58. package/dist/src/modules/auth/application/use-auth-dispatch.d.ts +1 -0
  59. package/dist/src/modules/auth/application/use-auth-provider.d.ts +4 -0
  60. package/dist/src/modules/auth/application/use-auth-state.d.ts +1 -0
  61. package/dist/src/modules/auth/application/use-client.d.ts +27 -0
  62. package/dist/src/modules/auth/application/use-ensure-connected-client.d.ts +3 -0
  63. package/dist/src/modules/auth/application/use-get-identity.d.ts +36 -0
  64. package/dist/src/modules/auth/application/use-is-logged-in.d.ts +8 -0
  65. package/dist/src/modules/auth/application/use-login-client.d.ts +6 -0
  66. package/dist/src/modules/auth/application/use-logout-client.d.ts +5 -0
  67. package/dist/src/modules/auth/domain/contexts/auth-provider-context.d.ts +2 -0
  68. package/dist/src/modules/auth/domain/models/auth-credentials.d.ts +3 -0
  69. package/dist/src/modules/auth/domain/models/user-identity.d.ts +28 -0
  70. package/dist/src/modules/auth/domain/services/auth-provider.d.ts +16 -0
  71. package/dist/src/modules/auth/index.d.ts +6 -0
  72. package/dist/src/modules/auth/infrastructure/providers/app-auth-provider.d.ts +30 -0
  73. package/dist/src/modules/auth/infrastructure/providers/app-identity-service.d.ts +9 -0
  74. package/dist/src/modules/auth/infrastructure/providers/auth-constants.d.ts +6 -0
  75. package/dist/src/modules/beneficiary/domain/models/beneficiary-device.d.ts +28 -0
  76. package/dist/src/modules/beneficiary/domain/models/beneficiary-relation.d.ts +13 -0
  77. package/dist/src/modules/beneficiary/domain/models/beneficiary-type.d.ts +16 -0
  78. package/dist/src/modules/beneficiary/domain/models/beneficiary.d.ts +54 -0
  79. package/dist/src/modules/beneficiary/index.d.ts +1 -0
  80. package/dist/src/modules/beneficiary/infrastructure/mappers/beneficiary-mapper.d.ts +6 -0
  81. package/dist/src/modules/protection-plan/application/configuration-process/blockchain/use-create-smart-contract.d.ts +9 -0
  82. package/dist/src/modules/protection-plan/application/configuration-process/plan-shares/creation/use-create-backup-shares.d.ts +6 -0
  83. package/dist/src/modules/protection-plan/application/configuration-process/plan-shares/creation/use-create-cold-shares.d.ts +6 -0
  84. package/dist/src/modules/protection-plan/application/configuration-process/plan-shares/creation/use-create-mobile-shares.d.ts +6 -0
  85. package/dist/src/modules/protection-plan/application/configuration-process/plan-shares/creation/use-create-validator-shares.d.ts +6 -0
  86. package/dist/src/modules/protection-plan/application/configuration-process/plan-shares/distribution/use-distribute-backup-shares.d.ts +9 -0
  87. package/dist/src/modules/protection-plan/application/configuration-process/plan-shares/distribution/use-distribute-cold-share.d.ts +8 -0
  88. package/dist/src/modules/protection-plan/application/configuration-process/plan-shares/distribution/use-distribute-mobile-shares.d.ts +9 -0
  89. package/dist/src/modules/protection-plan/application/configuration-process/plan-shares/distribution/use-distribute-validator-shares.d.ts +9 -0
  90. package/dist/src/modules/protection-plan/application/configuration-process/use-configure-plan.d.ts +12 -0
  91. package/dist/src/modules/protection-plan/application/configuration-process/use-delete-plan-configuration-process.d.ts +8 -0
  92. package/dist/src/modules/protection-plan/application/configuration-process/use-get-plan-configuration-process.d.ts +12 -0
  93. package/dist/src/modules/protection-plan/application/configuration-process/use-save-plan-creation-process.d.ts +9 -0
  94. package/dist/src/modules/protection-plan/application/creation/use-create-protection-plan.d.ts +24 -0
  95. package/dist/src/modules/protection-plan/application/creation/use-get-available-plan-triggers.d.ts +3 -0
  96. package/dist/src/modules/protection-plan/application/creation/use-get-protection-plan-security-level.d.ts +47 -0
  97. package/dist/src/modules/protection-plan/application/creation/use-persist-protection-plan.d.ts +10 -0
  98. package/dist/src/modules/protection-plan/application/listing/use-find-protection-plan-summary-by-criteria.d.ts +13 -0
  99. package/dist/src/modules/protection-plan/application/listing/use-find-protection-plans-by-criteria.d.ts +15 -0
  100. package/dist/src/modules/protection-plan/application/listing/use-get-protection-plan-summary.d.ts +13 -0
  101. package/dist/src/modules/protection-plan/application/listing/use-is-merge-authority-mode.d.ts +3 -0
  102. package/dist/src/modules/protection-plan/application/listing/use-protection-plan-listener.d.ts +25 -0
  103. package/dist/src/modules/protection-plan/application/merging-process/merge-authority/use-authorize-merge-authority.d.ts +13 -0
  104. package/dist/src/modules/protection-plan/application/merging-process/merge-authority/use-get-merge-authority-protection-plan.d.ts +12 -0
  105. package/dist/src/modules/protection-plan/application/merging-process/merge-authority/use-merge-authority-merge-process-events.d.ts +6 -0
  106. package/dist/src/modules/protection-plan/application/merging-process/merge-triggers/use-retry-active-merge-trigger.d.ts +10 -0
  107. package/dist/src/modules/protection-plan/application/merging-process/merge-triggers/use-validate-merge-trigger.d.ts +12 -0
  108. package/dist/src/modules/protection-plan/application/merging-process/plan-shares/collection/use-collect-backup-shares.d.ts +9 -0
  109. package/dist/src/modules/protection-plan/application/merging-process/plan-shares/collection/use-collect-cold-share.d.ts +8 -0
  110. package/dist/src/modules/protection-plan/application/merging-process/plan-shares/collection/use-collect-mobile-shares.d.ts +5 -0
  111. package/dist/src/modules/protection-plan/application/merging-process/plan-shares/collection/use-collect-released-mobile-shares.d.ts +9 -0
  112. package/dist/src/modules/protection-plan/application/merging-process/plan-shares/collection/use-collect-validator-shares.d.ts +9 -0
  113. package/dist/src/modules/protection-plan/application/merging-process/plan-shares/use-check-can-collect-shares.d.ts +2 -0
  114. package/dist/src/modules/protection-plan/application/merging-process/plan-shares/use-save-release-mobile-share-request.d.ts +11 -0
  115. package/dist/src/modules/protection-plan/application/merging-process/plan-shares/use-send-plan-share-merge-status-event.d.ts +15 -0
  116. package/dist/src/modules/protection-plan/application/merging-process/plan-shares/use-send-plan-shares-merged.d.ts +10 -0
  117. package/dist/src/modules/protection-plan/application/merging-process/use-close-protection-plan.d.ts +10 -0
  118. package/dist/src/modules/protection-plan/application/merging-process/use-create-merging-process.d.ts +9 -0
  119. package/dist/src/modules/protection-plan/application/merging-process/use-delete-merging-process-by-criteria.d.ts +11 -0
  120. package/dist/src/modules/protection-plan/application/merging-process/use-delete-merging-process.d.ts +10 -0
  121. package/dist/src/modules/protection-plan/application/merging-process/use-get-merging-process-by-plan.d.ts +23 -0
  122. package/dist/src/modules/protection-plan/application/merging-process/use-merge-plan-beneficiary-selection.d.ts +27 -0
  123. package/dist/src/modules/protection-plan/application/merging-process/use-persist-merge-process.d.ts +12 -0
  124. package/dist/src/modules/protection-plan/application/merging-process/use-reveal-plan-data.d.ts +13 -0
  125. package/dist/src/modules/protection-plan/application/merging-process/use-save-merging-process.d.ts +9 -0
  126. package/dist/src/modules/protection-plan/application/merging-process/use-scan-plans-from-merge-authority-device.d.ts +10 -0
  127. package/dist/src/modules/protection-plan/application/merging-process/use-shareholder-merge-process-events.d.ts +2 -0
  128. package/dist/src/modules/protection-plan/domain/dto/plan-dto.d.ts +68 -0
  129. package/dist/src/modules/protection-plan/domain/dto/protection-plan-input.d.ts +173 -0
  130. package/dist/src/modules/protection-plan/domain/models/app-process.d.ts +29 -0
  131. package/dist/src/modules/protection-plan/domain/models/backup/backup-plan.d.ts +18 -0
  132. package/dist/src/modules/protection-plan/domain/models/backup/backup-shareholder.d.ts +9 -0
  133. package/dist/src/modules/protection-plan/domain/models/client/protection-plan-summary.d.ts +218 -0
  134. package/dist/src/modules/protection-plan/domain/models/data-asset.d.ts +113 -0
  135. package/dist/src/modules/protection-plan/domain/models/device-share-info.d.ts +10 -0
  136. package/dist/src/modules/protection-plan/domain/models/inheritance/heir.d.ts +9 -0
  137. package/dist/src/modules/protection-plan/domain/models/inheritance/inheritance-plan.d.ts +16 -0
  138. package/dist/src/modules/protection-plan/domain/models/merging-process/active-merge-process.d.ts +15 -0
  139. package/dist/src/modules/protection-plan/domain/models/merging-process/merging-process.d.ts +135 -0
  140. package/dist/src/modules/protection-plan/domain/models/plan-creation-proccess/plan-creation-process.d.ts +69 -0
  141. package/dist/src/modules/protection-plan/domain/models/plan-share.d.ts +69 -0
  142. package/dist/src/modules/protection-plan/domain/models/proccess-step.d.ts +21 -0
  143. package/dist/src/modules/protection-plan/domain/models/protection-plan-details.d.ts +70 -0
  144. package/dist/src/modules/protection-plan/domain/models/protection-plan-passphrase.d.ts +18 -0
  145. package/dist/src/modules/protection-plan/domain/models/protection-plan.d.ts +238 -0
  146. package/dist/src/modules/protection-plan/domain/models/shareholder.d.ts +32 -0
  147. package/dist/src/modules/protection-plan/domain/models/storage-option.d.ts +29 -0
  148. package/dist/src/modules/protection-plan/domain/models/trigger-settings-info.d.ts +6 -0
  149. package/dist/src/modules/protection-plan/domain/models/trigger.d.ts +46 -0
  150. package/dist/src/modules/protection-plan/domain/repositories/merge-authority-protection-plan-repository.d.ts +13 -0
  151. package/dist/src/modules/protection-plan/domain/repositories/merging-process-repository.d.ts +62 -0
  152. package/dist/src/modules/protection-plan/domain/repositories/plan-creation-repository.d.ts +7 -0
  153. package/dist/src/modules/protection-plan/domain/repositories/plan-security-repository.d.ts +7 -0
  154. package/dist/src/modules/protection-plan/domain/repositories/plan-triggers-repository.d.ts +4 -0
  155. package/dist/src/modules/protection-plan/domain/repositories/protection-plan-repository.d.ts +24 -0
  156. package/dist/src/modules/protection-plan/domain/services/blockchain-service.d.ts +32 -0
  157. package/dist/src/modules/protection-plan/domain/services/input-validation/PlanTypeInputValidator.d.ts +4 -0
  158. package/dist/src/modules/protection-plan/domain/services/input-validation/plan-beneficiaries-input-validator.d.ts +240 -0
  159. package/dist/src/modules/protection-plan/domain/services/input-validation/plan-data-assets-input-validator.d.ts +1108 -0
  160. package/dist/src/modules/protection-plan/domain/services/input-validation/plan-details-input-validator.d.ts +23 -0
  161. package/dist/src/modules/protection-plan/domain/services/input-validation/plan-shares-configuration-input-validator.d.ts +13 -0
  162. package/dist/src/modules/protection-plan/domain/services/input-validation/plan-storage-configuration-input-validator.d.ts +25 -0
  163. package/dist/src/modules/protection-plan/domain/services/input-validation/plan-triggers-input-validator.d.ts +105 -0
  164. package/dist/src/modules/protection-plan/domain/services/input-validation/utils/index.d.ts +3 -0
  165. package/dist/src/modules/protection-plan/domain/services/merge-authorization-handler.d.ts +14 -0
  166. package/dist/src/modules/protection-plan/domain/services/merge-process-event-listener.d.ts +14 -0
  167. package/dist/src/modules/protection-plan/domain/services/plan-data-assets-manager.d.ts +69 -0
  168. package/dist/src/modules/protection-plan/domain/services/plan-data-revealer.d.ts +5 -0
  169. package/dist/src/modules/protection-plan/domain/services/plan-event-listener.d.ts +10 -0
  170. package/dist/src/modules/protection-plan/domain/services/plan-merge-threshold-range-calculator.d.ts +8 -0
  171. package/dist/src/modules/protection-plan/domain/services/plan-recovery-shares-range-calculator.d.ts +8 -0
  172. package/dist/src/modules/protection-plan/domain/services/plan-shares-generator.d.ts +18 -0
  173. package/dist/src/modules/protection-plan/domain/services/vault-service.d.ts +10 -0
  174. package/dist/src/modules/protection-plan/domain/utils/plan-details-mapper.d.ts +12 -0
  175. package/dist/src/modules/protection-plan/domain/utils/plan-shares-details-mapper.d.ts +10 -0
  176. package/dist/src/modules/protection-plan/domain/utils/plan-triggers-details-mapper.d.ts +5 -0
  177. package/dist/src/modules/protection-plan/domain/utils/protection-plan-internal-mapper.d.ts +5 -0
  178. package/dist/src/modules/protection-plan/index.d.ts +28 -0
  179. package/dist/src/modules/protection-plan/infrastructure/mappers/backup-shareholder-mapper.d.ts +7 -0
  180. package/dist/src/modules/protection-plan/infrastructure/mappers/draft-protection-plan-mapper.d.ts +8 -0
  181. package/dist/src/modules/protection-plan/infrastructure/mappers/heir-mapper.d.ts +7 -0
  182. package/dist/src/modules/protection-plan/infrastructure/mappers/merging-process-mapper.d.ts +5 -0
  183. package/dist/src/modules/protection-plan/infrastructure/mappers/plan-creation-mapper.d.ts +5 -0
  184. package/dist/src/modules/protection-plan/infrastructure/mappers/protection-plan-filters-mapper.d.ts +4 -0
  185. package/dist/src/modules/protection-plan/infrastructure/mappers/protection-plan-mapper.d.ts +10 -0
  186. package/dist/src/modules/protection-plan/infrastructure/repositories/app-merging-process-repository.d.ts +65 -0
  187. package/dist/src/modules/protection-plan/infrastructure/repositories/app-plan-creation-repository.d.ts +12 -0
  188. package/dist/src/modules/protection-plan/infrastructure/repositories/app-plan-security-repository.d.ts +11 -0
  189. package/dist/src/modules/protection-plan/infrastructure/repositories/app-plan-triggers-repository.d.ts +10 -0
  190. package/dist/src/modules/protection-plan/infrastructure/repositories/protection-plan/app-merge-authority-protection-plan-repository.d.ts +17 -0
  191. package/dist/src/modules/protection-plan/infrastructure/repositories/protection-plan/app-protection-plan-repository.d.ts +13 -0
  192. package/dist/src/modules/protection-plan/infrastructure/services/app-blockchain-service.d.ts +42 -0
  193. package/dist/src/modules/protection-plan/infrastructure/services/app-plan-data-revealer.d.ts +14 -0
  194. package/dist/src/modules/protection-plan/infrastructure/services/app-plan-shares-generator.d.ts +5 -0
  195. package/dist/src/modules/protection-plan/infrastructure/services/constants/device-constants.d.ts +1 -0
  196. package/dist/src/modules/protection-plan/infrastructure/services/inheriti-vault-service.d.ts +15 -0
  197. package/dist/src/modules/protection-plan/infrastructure/services/socket-io-merge-authorization-handler.d.ts +17 -0
  198. package/dist/src/modules/protection-plan/infrastructure/services/socket-io-merge-process-event-listener.d.ts +14 -0
  199. package/dist/src/modules/protection-plan/infrastructure/services/socket-io-plan-event-listener.d.ts +14 -0
  200. package/dist/src/modules/protection-plan/ui/plan-creation-process/hooks/use-distribute-cold-shares-process.d.ts +15 -0
  201. package/dist/src/modules/protection-plan/ui/plan-creation-process/hooks/use-get-active-plan-configuration-process.d.ts +11 -0
  202. package/dist/src/modules/protection-plan/ui/plan-creation-process/hooks/use-plan-configuration-process-steps.d.ts +16 -0
  203. package/dist/src/modules/protection-plan/ui/plan-creation-process/hooks/use-plan-configuration-process.d.ts +25 -0
  204. package/dist/src/modules/protection-plan/ui/plan-creation-process/hooks/use-start-protection-plan-configuration-process.d.ts +10 -0
  205. package/dist/src/modules/protection-plan/ui/plan-creation-process/view-models/plan-configuration-process-view.d.ts +55 -0
  206. package/dist/src/modules/protection-plan/ui/plan-merge-process/hooks/merge-athority/use-merge-authority-sk-mobile-plan-detection.d.ts +13 -0
  207. package/dist/src/modules/protection-plan/ui/plan-merge-process/hooks/merge-athority/use-merge-authority-sk-pro-plan-detection.d.ts +12 -0
  208. package/dist/src/modules/protection-plan/ui/plan-merge-process/hooks/use-abort-merge-process.d.ts +6 -0
  209. package/dist/src/modules/protection-plan/ui/plan-merge-process/hooks/use-active-merge-process-listener.d.ts +9 -0
  210. package/dist/src/modules/protection-plan/ui/plan-merge-process/hooks/use-collect-plan-cold-share-process.d.ts +13 -0
  211. package/dist/src/modules/protection-plan/ui/plan-merge-process/hooks/use-count-down.d.ts +7 -0
  212. package/dist/src/modules/protection-plan/ui/plan-merge-process/hooks/use-initialize-merging-process.d.ts +21 -0
  213. package/dist/src/modules/protection-plan/ui/plan-merge-process/hooks/use-merge-process-controller.d.ts +13 -0
  214. package/dist/src/modules/protection-plan/ui/plan-merge-process/hooks/use-merge-process-release-shares-controller.d.ts +9 -0
  215. package/dist/src/modules/protection-plan/ui/plan-merge-process/hooks/use-plan-merge-process.d.ts +55 -0
  216. package/dist/src/modules/protection-plan/ui/plan-merge-process/hooks/use-process-plan-merge-steps.d.ts +11 -0
  217. package/dist/src/modules/protection-plan/ui/plan-merge-process/hooks/use-reveal-data-controller.d.ts +26 -0
  218. package/dist/src/modules/protection-plan/ui/plan-merge-process/hooks/use-start-merge-process.d.ts +20 -0
  219. package/dist/src/modules/protection-plan/ui/plan-merge-process/hooks/use-trigger-countdown.d.ts +18 -0
  220. package/dist/src/modules/protection-plan/ui/plan-merge-process/utils/merge-process-utils.d.ts +3 -0
  221. package/dist/src/modules/protection-plan/ui/plan-merge-process/view-models/plan-merge-process-view.d.ts +173 -0
  222. package/dist/src/modules/protection-plan/ui/protection-plan/utils/plan-beneficiary-builder.d.ts +12 -0
  223. package/dist/src/modules/protection-plan/ui/protection-plan/utils/plan-data-asset-builder.d.ts +35 -0
  224. package/dist/src/modules/protection-plan/ui/protection-plan/utils/protection-plan-code.d.ts +7 -0
  225. package/dist/src/modules/protection-plan/ui/protection-plan/utils/protection-plan-id.d.ts +7 -0
  226. package/dist/src/modules/protection-plan/ui/protection-plan/utils/trigger-builder.d.ts +24 -0
  227. package/dist/src/modules/safekey/application/use-connect-safekey-pro-device.d.ts +10 -0
  228. package/dist/src/modules/safekey/application/use-disconnect-safekey-device.d.ts +8 -0
  229. package/dist/src/modules/safekey/application/use-safekey-device.d.ts +16 -0
  230. package/dist/src/modules/safekey/application/use-validate-safekey-device-pin.d.ts +12 -0
  231. package/dist/src/modules/safekey/domain/services/cold-storage-service.d.ts +55 -0
  232. package/dist/src/modules/safekey/index.d.ts +4 -0
  233. package/dist/src/modules/safekey/infrastructure/services/safekey-cold-storage-service.d.ts +45 -0
  234. package/dist/src/modules/safekey/infrastructure/services/safekey-service.d.ts +9 -0
  235. package/dist/test/index.js +14 -0
  236. package/dist/tests/modules/_shared/domain/models/FinancialMother.d.ts +11 -0
  237. package/dist/tests/modules/_shared/domain/models/date-mother.d.ts +6 -0
  238. package/dist/tests/modules/_shared/domain/models/email-mother.d.ts +3 -0
  239. package/dist/tests/modules/_shared/domain/models/id-mother.d.ts +3 -0
  240. package/dist/tests/modules/_shared/domain/models/internet-mother.d.ts +11 -0
  241. package/dist/tests/modules/_shared/domain/models/mother-creator.d.ts +3 -0
  242. package/dist/tests/modules/_shared/domain/models/name-mother.d.ts +5 -0
  243. package/dist/tests/modules/_shared/domain/models/number-mother.d.ts +7 -0
  244. package/dist/tests/modules/_shared/domain/models/random-element-picker-mother.d.ts +3 -0
  245. package/dist/tests/modules/_shared/domain/models/uuid-mother.d.ts +3 -0
  246. package/dist/tests/modules/_shared/domain/models/word-mother.d.ts +5 -0
  247. package/dist/tests/modules/index.d.ts +6 -0
  248. package/dist/tests/modules/protection-plan/domain/plan-beneficiary-input-generator.d.ts +18 -0
  249. package/dist/tests/modules/protection-plan/domain/plan-data-asset-input-generator.d.ts +13 -0
  250. package/dist/tests/modules/protection-plan/domain/plan-details-input-generator.d.ts +7 -0
  251. package/dist/tests/modules/protection-plan/domain/plan-shares-configuration-input-generator.d.ts +20 -0
  252. package/dist/tests/modules/protection-plan/domain/plan-storage-configuration-input-generator.d.ts +4 -0
  253. package/dist/tests/modules/protection-plan/domain/plan-trigger-input-generator.d.ts +27 -0
  254. package/dist/tests/modules/protection-plan/domain/protection-plan-input-generator.d.ts +4 -0
  255. package/dist/tests/modules/protection-plan/index.d.ts +8 -0
  256. package/index.ts +6 -0
  257. package/package.json +78 -0
@@ -0,0 +1,54 @@
1
+ import BeneficiaryType, { BeneficiaryTypePrimitiveProps } from '../../../beneficiary/domain/models/beneficiary-type';
2
+ import BeneficiaryRelation, { BeneficiaryRelationPrimitiveProps } from '../../../beneficiary/domain/models/beneficiary-relation';
3
+ import BeneficiaryDevice, { BeneficiaryDevicePrimitiveProps } from '../../../beneficiary/domain/models/beneficiary-device';
4
+ export interface BeneficiaryProps {
5
+ id: string;
6
+ firstName: string;
7
+ lastName?: string;
8
+ email?: string;
9
+ code?: string;
10
+ relation?: BeneficiaryRelation;
11
+ profilePictureUrl?: string;
12
+ types: BeneficiaryType[];
13
+ summary?: {
14
+ backup: number;
15
+ inheritance: number;
16
+ planShares: number;
17
+ storageDevices: number;
18
+ mergeAuthority: number;
19
+ };
20
+ devices: BeneficiaryDevice[];
21
+ }
22
+ export interface BeneficiaryPrimitiveProps extends Omit<BeneficiaryProps, 'types' | 'relation' | 'devices'> {
23
+ types: BeneficiaryTypePrimitiveProps[];
24
+ relation?: BeneficiaryRelationPrimitiveProps;
25
+ devices: BeneficiaryDevicePrimitiveProps[];
26
+ }
27
+ export default class Beneficiary {
28
+ private props;
29
+ constructor(props: BeneficiaryProps);
30
+ get id(): string;
31
+ get code(): string | undefined;
32
+ get devices(): BeneficiaryDevice[];
33
+ get fullName(): string | undefined;
34
+ get firstName(): string;
35
+ get lastName(): string | undefined;
36
+ get description(): "" | "Wife" | "Husband" | "Spouse" | "Child" | "Grandchild" | "Parent" | "Grandparent" | "Family member" | "Friend" | "Business Partner" | "Colleague" | "Lawyer" | "Notary" | "Trustee" | "Executor" | "Other" | undefined;
37
+ get hasConnection(): boolean;
38
+ get profilePictureUrl(): string | undefined;
39
+ get email(): string | undefined;
40
+ get types(): BeneficiaryType[];
41
+ get typeNames(): string;
42
+ get protectionPlansCount(): number;
43
+ get involvement(): {
44
+ backup: number;
45
+ inheritance: number;
46
+ planShares: number;
47
+ storageDevices: number;
48
+ mergeAuthority: number;
49
+ } | undefined;
50
+ static fromPrimitives(props: BeneficiaryPrimitiveProps): Beneficiary;
51
+ update(props: Partial<BeneficiaryProps>): void;
52
+ includesType(type: string): boolean;
53
+ toPrimitives(): BeneficiaryPrimitiveProps;
54
+ }
@@ -0,0 +1 @@
1
+ export { default as Beneficiary } from './domain/models/beneficiary';
@@ -0,0 +1,6 @@
1
+ import Beneficiary from '../../../beneficiary/domain/models/beneficiary';
2
+ export default class BeneficiaryMapper {
3
+ static toDomain(item: any): Beneficiary;
4
+ static toDomainFromArray(items: any[]): Beneficiary[];
5
+ static toPersistence(item: Beneficiary): Partial<any>;
6
+ }
@@ -0,0 +1,9 @@
1
+ import PlanCreationProcess from '../../../../protection-plan/domain/models/plan-creation-proccess/plan-creation-process';
2
+ export default function useCreateSmartContract(): {
3
+ create: (process: PlanCreationProcess) => Promise<any>;
4
+ reset: () => any;
5
+ loading: boolean;
6
+ loaded: boolean;
7
+ data: any;
8
+ error: any;
9
+ };
@@ -0,0 +1,6 @@
1
+ import PlanCreationProcess from '../../../../../protection-plan/domain/models/plan-creation-proccess/plan-creation-process';
2
+ export default function useCreateBackupShares(): {
3
+ create: (process: PlanCreationProcess, shares: {
4
+ [shareId: string]: string[];
5
+ }) => Promise<void>;
6
+ };
@@ -0,0 +1,6 @@
1
+ import PlanCreationProcess from '../../../../../protection-plan/domain/models/plan-creation-proccess/plan-creation-process';
2
+ export default function useCreateColdShares(): {
3
+ create: (process: PlanCreationProcess, shares: {
4
+ [shareId: string]: string[];
5
+ }) => Promise<void>;
6
+ };
@@ -0,0 +1,6 @@
1
+ import PlanCreationProcess from '../../../../../protection-plan/domain/models/plan-creation-proccess/plan-creation-process';
2
+ export default function useCreateMobileShares(): {
3
+ create: (process: PlanCreationProcess, shares: {
4
+ [shareId: string]: string[];
5
+ }) => Promise<void>;
6
+ };
@@ -0,0 +1,6 @@
1
+ import PlanCreationProcess from '../../../../../protection-plan/domain/models/plan-creation-proccess/plan-creation-process';
2
+ export default function useCreateValidatorShares(): {
3
+ create: (process: PlanCreationProcess, shares: {
4
+ [shareId: string]: string[];
5
+ }) => Promise<void>;
6
+ };
@@ -0,0 +1,9 @@
1
+ import PlanCreationProcess from '../../../../../protection-plan/domain/models/plan-creation-proccess/plan-creation-process';
2
+ export default function useDistributeBackupShares(): {
3
+ distribute: (process: PlanCreationProcess) => Promise<any>;
4
+ reset: () => any;
5
+ loading: boolean;
6
+ loaded: boolean;
7
+ data: any;
8
+ error: any;
9
+ };
@@ -0,0 +1,8 @@
1
+ import PlanCreationProcess from '../../../../../protection-plan/domain/models/plan-creation-proccess/plan-creation-process';
2
+ import PlanShare from '../../../../../protection-plan/domain/models/plan-share';
3
+ import { IOResponse } from '../../../../../safekey/domain/services/cold-storage-service';
4
+ export default function useDistributeColdShare(): {
5
+ distribute: (process: PlanCreationProcess, share: PlanShare) => Promise<void>;
6
+ ioResponse: IOResponse | undefined;
7
+ error: string | undefined;
8
+ };
@@ -0,0 +1,9 @@
1
+ import PlanCreationProcess from '../../../../../protection-plan/domain/models/plan-creation-proccess/plan-creation-process';
2
+ export default function useDistributeMobileShares(): {
3
+ distribute: (process: PlanCreationProcess) => Promise<any>;
4
+ reset: () => any;
5
+ loading: boolean;
6
+ loaded: boolean;
7
+ data: any;
8
+ error: any;
9
+ };
@@ -0,0 +1,9 @@
1
+ import PlanCreationProcess from '../../../../../protection-plan/domain/models/plan-creation-proccess/plan-creation-process';
2
+ export default function useDistributeValidatorShares(): {
3
+ distribute: (process: PlanCreationProcess) => Promise<any>;
4
+ reset: () => any;
5
+ loading: boolean;
6
+ loaded: boolean;
7
+ data: any;
8
+ error: any;
9
+ };
@@ -0,0 +1,12 @@
1
+ import ProtectionPlan from '../../../protection-plan/domain/models/protection-plan';
2
+ export default function useConfigurePlan(): {
3
+ save: (newInstanceData?: {
4
+ operation: string;
5
+ plan: ProtectionPlan<any>;
6
+ } | undefined) => Promise<any>;
7
+ reset: () => any;
8
+ loading: boolean;
9
+ loaded: boolean;
10
+ data: any;
11
+ error: any;
12
+ };
@@ -0,0 +1,8 @@
1
+ export default function useDeletePlanConfigurationProcess(): {
2
+ delete: (id: string, additionalParams?: any) => Promise<void>;
3
+ reset: () => any;
4
+ loading: boolean;
5
+ loaded: boolean;
6
+ data: null;
7
+ error: any;
8
+ };
@@ -0,0 +1,12 @@
1
+ import QueryOptions from '../../../_shared/domain/models/query-options';
2
+ import PlanCreationProcess from '../../../protection-plan/domain/models/plan-creation-proccess/plan-creation-process';
3
+ export default function useGetPlanConfigurationProcess(id: string, options?: QueryOptions): {
4
+ error?: any;
5
+ isIdle: boolean;
6
+ loading: boolean;
7
+ loaded: boolean;
8
+ refetch: any;
9
+ isFetching: boolean;
10
+ isRefetching: boolean;
11
+ data?: PlanCreationProcess | undefined;
12
+ };
@@ -0,0 +1,9 @@
1
+ import PlanCreationProcess from '../../../protection-plan/domain/models/plan-creation-proccess/plan-creation-process';
2
+ export default function useSavePlanCreationProcess(invalidate?: boolean): {
3
+ save: (newInstanceData?: PlanCreationProcess | undefined) => Promise<any>;
4
+ reset: () => any;
5
+ loading: boolean;
6
+ loaded: boolean;
7
+ data: any;
8
+ error: any;
9
+ };
@@ -0,0 +1,24 @@
1
+ import { ProtectionPlanInput } from '../../../protection-plan/domain/dto/protection-plan-input';
2
+ import { ProtectionPlanSummary } from '../../../protection-plan/domain/models/client/protection-plan-summary';
3
+ /**
4
+ * Custom hook for creating a protection plan using the `useCreateProtectionPlan` hook.
5
+ *
6
+ * It provides a `create` function that accepts the plan properties (`ProtectionPlanInput`),
7
+ * maps them to internal plan data, and then saves the plan. Once saved, it returns
8
+ * a summary of the protection plan.
9
+ *
10
+ * @returns An object with the `create` function for creating a new protection plan
11
+ */
12
+ export default function useCreateProtectionPlan(): {
13
+ /**
14
+ * Create a new protection plan based on the provided properties.
15
+ *
16
+ * @param props - The properties used to create the new protection plan.
17
+ * @returns A summary of the created protection plan.
18
+ * @see ProtectionPlanInput for the structure of the properties.
19
+ */
20
+ create(props: ProtectionPlanInput): Promise<ProtectionPlanSummary>;
21
+ loading: boolean;
22
+ data: ProtectionPlanSummary | undefined;
23
+ error: null;
24
+ };
@@ -0,0 +1,3 @@
1
+ import QueryOptions from '../../../_shared/domain/models/query-options';
2
+ import TriggerSettingsInfo from '../../../protection-plan/domain/models/trigger-settings-info';
3
+ export default function useGetAvailablePlanTriggers(options?: QueryOptions): import("../../../_shared/domain/hooks/resources/use-get-list").UseGetListValue<TriggerSettingsInfo>;
@@ -0,0 +1,47 @@
1
+ import QueryOptions from '../../../_shared/domain/models/query-options';
2
+ export interface ProtectionPlanSecurityLevelRequestInput {
3
+ planType: string;
4
+ beneficiariesAmount: number;
5
+ coldSharesAmount: number;
6
+ mobileSharesAmount: number;
7
+ activationMethodsAmount: number;
8
+ mergeThreshold?: number;
9
+ }
10
+ export interface ProtectionPlanSecurityLevelRequest {
11
+ planType: string;
12
+ isFree: boolean;
13
+ variables?: {
14
+ security: {
15
+ beneficiariesAmount: number;
16
+ recoverySharesRatio: number;
17
+ coldSharesAmount: number;
18
+ mobileSharesAmount: number;
19
+ mobileSharesVsColdSharesRatio: number;
20
+ mergeThresholdRatio: number;
21
+ activationMethodsAmount: number;
22
+ };
23
+ };
24
+ }
25
+ export default function useGetProtectionPlanSecurityLevel(data: ProtectionPlanSecurityLevelRequestInput, options?: QueryOptions): {
26
+ error?: any;
27
+ isIdle: boolean;
28
+ loading: boolean;
29
+ loaded: boolean;
30
+ refetch: any;
31
+ isFetching: boolean;
32
+ isRefetching: boolean;
33
+ data?: {
34
+ index: number;
35
+ rating: string;
36
+ evaluation: {
37
+ beneficiariesAmount: number;
38
+ recoverySharesRatio: number;
39
+ mergeThresholdRatio: number;
40
+ coldSharesAmount: number;
41
+ mobileSharesAmount: number;
42
+ mobileSharesVsColdSharesRatio: number;
43
+ activationMethodsAmount: number;
44
+ amountOfLayers: number;
45
+ };
46
+ };
47
+ };
@@ -0,0 +1,10 @@
1
+ import ProtectionPlan from '../../../protection-plan/domain/models/protection-plan';
2
+ import { ProtectionPlanDto } from '../../../protection-plan/domain/dto/plan-dto';
3
+ export default function usePersistProtectionPlan(): {
4
+ save: (newInstanceData?: Omit<ProtectionPlanDto, "owner"> | undefined) => Promise<ProtectionPlan<any>>;
5
+ reset: () => any;
6
+ loading: boolean;
7
+ loaded: boolean;
8
+ data: any;
9
+ error: any;
10
+ };
@@ -0,0 +1,13 @@
1
+ import QueryOptions from '../../../_shared/domain/models/query-options';
2
+ import { ProtectionPlanFilters } from '../../../protection-plan/domain/repositories/protection-plan-repository';
3
+ export default function useFindProtectionPlanSummaryByCriteria(filter?: ProtectionPlanFilters, options?: QueryOptions): {
4
+ total?: number | undefined;
5
+ error?: any;
6
+ loading: boolean;
7
+ loaded: boolean;
8
+ refetch: any;
9
+ isFetching: boolean;
10
+ isRefetching: boolean;
11
+ isIdle?: boolean;
12
+ data: unknown;
13
+ };
@@ -0,0 +1,15 @@
1
+ import PaginationOptions from '../../../_shared/domain/models/pagination-options';
2
+ import SortOptions from '../../../_shared/domain/models/sort-options';
3
+ import QueryOptions from '../../../_shared/domain/models/query-options';
4
+ import { ProtectionPlanFilters } from '../../../protection-plan/domain/repositories/protection-plan-repository';
5
+ export default function useFindProtectionPlansByCriteria(filter?: ProtectionPlanFilters, pagination?: PaginationOptions, sort?: SortOptions, options?: QueryOptions): {
6
+ total?: number | undefined;
7
+ error?: any;
8
+ loading: boolean;
9
+ loaded: boolean;
10
+ refetch: any;
11
+ isFetching: boolean;
12
+ isRefetching: boolean;
13
+ isIdle?: boolean;
14
+ data: {} | undefined;
15
+ };
@@ -0,0 +1,13 @@
1
+ import QueryOptions from '../../../_shared/domain/models/query-options';
2
+ import { ProtectionPlanFilters } from "../../../protection-plan/domain/repositories/protection-plan-repository";
3
+ export default function useGetProtectionPlanSummary(filter: ProtectionPlanFilters, options?: QueryOptions): {
4
+ total?: number | undefined;
5
+ error?: any;
6
+ loading: boolean;
7
+ loaded: boolean;
8
+ refetch: any;
9
+ isFetching: boolean;
10
+ isRefetching: boolean;
11
+ isIdle?: boolean;
12
+ data: {} | undefined;
13
+ };
@@ -0,0 +1,3 @@
1
+ export declare function useIsMergeAuthorityMode(): {
2
+ check: () => boolean;
3
+ };
@@ -0,0 +1,25 @@
1
+ import QueryOptions from '../../../_shared/domain/models/query-options';
2
+ export declare function useProtectionPlanListener(id: string, options?: QueryOptions): {
3
+ total?: number | undefined;
4
+ error?: any;
5
+ loading: boolean;
6
+ loaded: boolean;
7
+ isFetching: boolean;
8
+ isRefetching: boolean;
9
+ isIdle?: boolean;
10
+ data: {} | undefined;
11
+ };
12
+ export declare function useProtectionPlanEventSubscriber(id: any, onEvent: any, options?: {
13
+ enabled: boolean;
14
+ }): void;
15
+ export declare function useExternalProtectionPlanListener(id: string, handlers: {
16
+ onMergeProcessAborted: any;
17
+ }, options?: QueryOptions): {
18
+ error?: any;
19
+ isIdle: boolean;
20
+ loading: boolean;
21
+ loaded: boolean;
22
+ isFetching: boolean;
23
+ isRefetching: boolean;
24
+ data?: import("../../domain/models/protection-plan").default<any> | undefined;
25
+ };
@@ -0,0 +1,13 @@
1
+ export default function useAuthorizeMergeAuthority(): {
2
+ save: (newInstanceData?: {
3
+ id: string;
4
+ source: string;
5
+ password: string;
6
+ legacyPlanIds?: string[];
7
+ } | undefined) => Promise<any>;
8
+ reset: () => any;
9
+ loading: boolean;
10
+ loaded: boolean;
11
+ data: any;
12
+ error: any;
13
+ };
@@ -0,0 +1,12 @@
1
+ import QueryOptions from '../../../../_shared/domain/models/query-options';
2
+ import ProtectionPlan from '../../../../protection-plan/domain/models/protection-plan';
3
+ export default function useGetMergeAuthorityProtectionPlan(id: string, options?: QueryOptions): {
4
+ error?: any;
5
+ isIdle: boolean;
6
+ loading: boolean;
7
+ loaded: boolean;
8
+ refetch: any;
9
+ isFetching: boolean;
10
+ isRefetching: boolean;
11
+ data?: ProtectionPlan<any> | undefined;
12
+ };
@@ -0,0 +1,6 @@
1
+ import { MergeProcessSubscriptionParams } from '../../../../protection-plan/domain/services/merge-process-event-listener';
2
+ import MergingProcess from '../../../../protection-plan/domain/models/merging-process/merging-process';
3
+ export declare function useMergeAuthorityMergeProcessEvents(): MergeProcessSubscriptionParams['handlers'];
4
+ export default function useRefetchMergeProcessInfo(): {
5
+ refetch(process: MergingProcess): Promise<void>;
6
+ };
@@ -0,0 +1,10 @@
1
+ export default function useRetryActiveMergeTrigger(): {
2
+ save: (newInstanceData?: {
3
+ processId: string;
4
+ } | undefined) => Promise<any>;
5
+ reset: () => any;
6
+ loading: boolean;
7
+ loaded: boolean;
8
+ data: any;
9
+ error: any;
10
+ };
@@ -0,0 +1,12 @@
1
+ export default function useValidateMergeTrigger(): {
2
+ validate: (newInstanceData?: {
3
+ id: string;
4
+ verificationId?: string;
5
+ triggerId: string;
6
+ code?: string;
7
+ } | undefined) => Promise<any>;
8
+ data: any;
9
+ error: any;
10
+ reset: () => any;
11
+ loading: boolean;
12
+ };
@@ -0,0 +1,9 @@
1
+ import MergingProcess from '../../../../../protection-plan/domain/models/merging-process/merging-process';
2
+ export default function useCollectBackupShares(): {
3
+ collect: (process: MergingProcess) => Promise<any>;
4
+ reset: () => any;
5
+ loading: boolean;
6
+ loaded: boolean;
7
+ data: any;
8
+ error: any;
9
+ };
@@ -0,0 +1,8 @@
1
+ import MergingProcess from '../../../../../protection-plan/domain/models/merging-process/merging-process';
2
+ import PlanShare from '../../../../../protection-plan/domain/models/plan-share';
3
+ import { IOResponse } from '../../../../../safekey/domain/services/cold-storage-service';
4
+ export default function useCollectColdShare(): {
5
+ collect: (process: MergingProcess, share: PlanShare) => Promise<void>;
6
+ error: boolean;
7
+ ioResponse: IOResponse | null;
8
+ };
@@ -0,0 +1,5 @@
1
+ import MergingProcess from '../../../../../protection-plan/domain/models/merging-process/merging-process';
2
+ import PlanShare from '../../../../../protection-plan/domain/models/plan-share';
3
+ export default function useCollectMobileShares(): {
4
+ collect: (process: MergingProcess, share: PlanShare, shareData: any) => Promise<void>;
5
+ };
@@ -0,0 +1,9 @@
1
+ import MergingProcess from '../../../../../protection-plan/domain/models/merging-process/merging-process';
2
+ export default function useCollectReleasedMobileShares(): {
3
+ collect: (process: MergingProcess) => Promise<any>;
4
+ reset: () => any;
5
+ loading: boolean;
6
+ loaded: boolean;
7
+ data: any;
8
+ error: any;
9
+ };
@@ -0,0 +1,9 @@
1
+ import MergingProcess from '../../../../../protection-plan/domain/models/merging-process/merging-process';
2
+ export default function useCollectValidatorShares(): {
3
+ collect: (process: MergingProcess) => Promise<any>;
4
+ reset: () => any;
5
+ loading: boolean;
6
+ loaded: boolean;
7
+ data: any;
8
+ error: any;
9
+ };
@@ -0,0 +1,2 @@
1
+ import QueryOptions from '../../../../_shared/domain/models/query-options';
2
+ export default function useCheckCanCollectShares(processId: string, options?: QueryOptions): any;
@@ -0,0 +1,11 @@
1
+ export default function useSaveReleaseMobileShareRequest(): {
2
+ save: (newInstanceData?: {
3
+ processId: string;
4
+ shareholdersIds: string[];
5
+ } | undefined) => Promise<any>;
6
+ reset: () => any;
7
+ loading: boolean;
8
+ loaded: boolean;
9
+ data: any;
10
+ error: any;
11
+ };
@@ -0,0 +1,15 @@
1
+ import { ShareStatus, ShareType } from '../../../../protection-plan/domain/models/plan-share';
2
+ export default function useSendPlanShareMergeStatusEvent(): {
3
+ save: (newInstanceData?: {
4
+ planId: string;
5
+ type: ShareType;
6
+ name: ShareStatus;
7
+ processId: string;
8
+ shareId?: string;
9
+ } | undefined) => Promise<any>;
10
+ reset: () => any;
11
+ loading: boolean;
12
+ loaded: boolean;
13
+ data: any;
14
+ error: any;
15
+ };
@@ -0,0 +1,10 @@
1
+ export default function useSendPlanSharesMerged(): {
2
+ save: (newInstanceData?: {
3
+ processId: string;
4
+ } | undefined) => Promise<any>;
5
+ reset: () => any;
6
+ loading: boolean;
7
+ loaded: boolean;
8
+ data: any;
9
+ error: any;
10
+ };
@@ -0,0 +1,10 @@
1
+ export default function useCloseProtectionPlan(): {
2
+ save: (newInstanceData?: {
3
+ processId: string;
4
+ } | undefined) => Promise<any>;
5
+ reset: () => any;
6
+ loading: boolean;
7
+ loaded: boolean;
8
+ data: any;
9
+ error: any;
10
+ };
@@ -0,0 +1,9 @@
1
+ import MergingProcess from '../../../protection-plan/domain/models/merging-process/merging-process';
2
+ export default function useCreateMergingProcess(invalidate?: boolean): {
3
+ save: (newInstanceData?: MergingProcess | undefined) => Promise<any>;
4
+ reset: () => any;
5
+ loading: boolean;
6
+ loaded: boolean;
7
+ data: any;
8
+ error: any;
9
+ };
@@ -0,0 +1,11 @@
1
+ import { MergeProcessFilterCriteria } from '../../../protection-plan/domain/repositories/merging-process-repository';
2
+ export default function useDeleteMergingProcessByCriteria({ onSuccess }: {
3
+ onSuccess?: any;
4
+ }): {
5
+ remove: (criteria: MergeProcessFilterCriteria) => Promise<any>;
6
+ reset: () => any;
7
+ loading: boolean;
8
+ loaded: boolean;
9
+ data: any;
10
+ error: any;
11
+ };
@@ -0,0 +1,10 @@
1
+ export default function useDeleteMergingProcess({ onSuccess }: {
2
+ onSuccess: any;
3
+ }): {
4
+ delete: (id: string, additionalParams?: any) => Promise<void>;
5
+ reset: () => any;
6
+ loading: boolean;
7
+ loaded: boolean;
8
+ data: null;
9
+ error: any;
10
+ };
@@ -0,0 +1,23 @@
1
+ import QueryOptions from '../../../_shared/domain/models/query-options';
2
+ import MergingProcess from '../../../protection-plan/domain/models/merging-process/merging-process';
3
+ import { ActiveMergeProcess } from '../../../protection-plan/domain/models/merging-process/active-merge-process';
4
+ export default function useGetMergingProcessByPlan(id: string, options?: QueryOptions): {
5
+ error?: any;
6
+ isIdle: boolean;
7
+ loading: boolean;
8
+ loaded: boolean;
9
+ refetch: any;
10
+ isFetching: boolean;
11
+ isRefetching: boolean;
12
+ data?: MergingProcess | undefined;
13
+ };
14
+ export declare function useGetActiveMergingProcessByPlan(id: string, options?: QueryOptions): {
15
+ error?: any;
16
+ isIdle: boolean;
17
+ loading: boolean;
18
+ loaded: boolean;
19
+ refetch: any;
20
+ isFetching: boolean;
21
+ isRefetching: boolean;
22
+ data?: ActiveMergeProcess | undefined;
23
+ };
@@ -0,0 +1,27 @@
1
+ import { ProtectionPlanSummary } from "../../../protection-plan";
2
+ type BeneficiaryIdentity = OnlyOne<{
3
+ id: string;
4
+ email: string;
5
+ code: string;
6
+ }>;
7
+ export default function useMergePlanBeneficiarySelection({ plan, mergeAuthorityDeviceId }: {
8
+ plan?: ProtectionPlanSummary;
9
+ mergeAuthorityDeviceId: string;
10
+ }): {
11
+ selection: {
12
+ count: number;
13
+ max: number;
14
+ };
15
+ isBeneficiarySelected: (beneficiary: BeneficiaryIdentity) => boolean;
16
+ canUseRecoveryShares: boolean;
17
+ useRecoveryShares: boolean;
18
+ toggleUseRecoveryShares: (value: boolean) => void;
19
+ selectedBeneficiaries: OnlyOne<{
20
+ id: string;
21
+ email: string;
22
+ code: string;
23
+ }>[];
24
+ selectedMergeAuthority: any;
25
+ toggleSelectBeneficiary: (beneficiary: BeneficiaryIdentity) => void;
26
+ };
27
+ export {};
@@ -0,0 +1,12 @@
1
+ export default function usePersistMergeProcess(): {
2
+ save: (newInstanceData?: {
3
+ id: string;
4
+ planId: string;
5
+ selectedBeneficiariesIds: string[];
6
+ } | undefined) => Promise<any>;
7
+ reset: () => any;
8
+ loading: boolean;
9
+ loaded: boolean;
10
+ data: any;
11
+ error: any;
12
+ };