@wirestate/react 0.6.1 → 0.6.3

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 (236) hide show
  1. package/CHANGELOG.md +8 -0
  2. package/README.md +114 -234
  3. package/cjs/development/test-utils.js +2 -1050
  4. package/cjs/development/test-utils.js.map +1 -1
  5. package/cjs/production/test-utils.js +1 -1
  6. package/cjs/production/test-utils.js.map +1 -1
  7. package/esm/development/commands/use-command-caller.js.map +1 -0
  8. package/esm/development/commands/use-command-handler.js.map +1 -0
  9. package/esm/development/commands/use-optional-command-caller.js.map +1 -0
  10. package/esm/development/error/error-code.js.map +1 -0
  11. package/esm/development/events/use-event-emitter.js.map +1 -0
  12. package/esm/development/events/use-event.js.map +1 -0
  13. package/esm/development/events/use-events-handler.js.map +1 -0
  14. package/esm/development/events/use-events.js.map +1 -0
  15. package/esm/development/provision/create-injectables-provider.js.map +1 -0
  16. package/esm/development/provision/ioc-context.js.map +1 -0
  17. package/esm/development/provision/ioc-provider.js.map +1 -0
  18. package/esm/development/provision/use-container-revision.js.map +1 -0
  19. package/esm/development/provision/use-container.js.map +1 -0
  20. package/esm/development/provision/use-injection.js.map +1 -0
  21. package/esm/development/provision/use-ioc-context.js.map +1 -0
  22. package/esm/development/provision/use-optional-injection.js.map +1 -0
  23. package/esm/development/queries/use-optional-query-caller.js.map +1 -0
  24. package/esm/development/queries/use-optional-sync-query-caller.js.map +1 -0
  25. package/esm/development/queries/use-query-caller.js.map +1 -0
  26. package/esm/development/queries/use-query-handler.js.map +1 -0
  27. package/esm/development/queries/use-sync-query-caller.js.map +1 -0
  28. package/esm/development/{wirestate-react/test-utils → test-utils}/with-ioc-provider.js +1 -7
  29. package/esm/development/test-utils/with-ioc-provider.js.map +1 -0
  30. package/esm/production/commands/use-command-caller.js.map +1 -0
  31. package/esm/production/commands/use-command-handler.js.map +1 -0
  32. package/esm/production/commands/use-optional-command-caller.js.map +1 -0
  33. package/esm/production/error/error-code.js.map +1 -0
  34. package/esm/production/events/use-event-emitter.js.map +1 -0
  35. package/esm/production/events/use-event.js.map +1 -0
  36. package/esm/production/events/use-events-handler.js.map +1 -0
  37. package/esm/production/events/use-events.js.map +1 -0
  38. package/esm/production/provision/create-injectables-provider.js.map +1 -0
  39. package/esm/production/provision/ioc-context.js.map +1 -0
  40. package/esm/production/provision/ioc-provider.js.map +1 -0
  41. package/esm/production/provision/use-container-revision.js.map +1 -0
  42. package/esm/production/provision/use-container.js.map +1 -0
  43. package/esm/production/provision/use-injection.js.map +1 -0
  44. package/esm/production/provision/use-ioc-context.js.map +1 -0
  45. package/esm/production/provision/use-optional-injection.js.map +1 -0
  46. package/esm/production/queries/use-optional-query-caller.js.map +1 -0
  47. package/esm/production/queries/use-optional-sync-query-caller.js.map +1 -0
  48. package/esm/production/queries/use-query-caller.js.map +1 -0
  49. package/esm/production/queries/use-query-handler.js.map +1 -0
  50. package/esm/production/queries/use-sync-query-caller.js.map +1 -0
  51. package/esm/production/test-utils/with-ioc-provider.js +1 -0
  52. package/esm/production/test-utils/with-ioc-provider.js.map +1 -0
  53. package/package.json +1 -1
  54. package/esm/development/wirestate-core/bind/bind-constant.js +0 -19
  55. package/esm/development/wirestate-core/bind/bind-constant.js.map +0 -1
  56. package/esm/development/wirestate-core/bind/bind-dynamic-value.js +0 -28
  57. package/esm/development/wirestate-core/bind/bind-dynamic-value.js.map +0 -1
  58. package/esm/development/wirestate-core/bind/bind-entry.js +0 -39
  59. package/esm/development/wirestate-core/bind/bind-entry.js.map +0 -1
  60. package/esm/development/wirestate-core/bind/bind-service.js +0 -253
  61. package/esm/development/wirestate-core/bind/bind-service.js.map +0 -1
  62. package/esm/development/wirestate-core/bind/get-entry-token.js +0 -14
  63. package/esm/development/wirestate-core/bind/get-entry-token.js.map +0 -1
  64. package/esm/development/wirestate-core/commands/command-bus.js +0 -112
  65. package/esm/development/wirestate-core/commands/command-bus.js.map +0 -1
  66. package/esm/development/wirestate-core/commands/get-command-handler-metadata.js +0 -27
  67. package/esm/development/wirestate-core/commands/get-command-handler-metadata.js.map +0 -1
  68. package/esm/development/wirestate-core/container/create-ioc-container.js +0 -35
  69. package/esm/development/wirestate-core/container/create-ioc-container.js.map +0 -1
  70. package/esm/development/wirestate-core/container/wire-scope.js +0 -151
  71. package/esm/development/wirestate-core/container/wire-scope.js.map +0 -1
  72. package/esm/development/wirestate-core/error/error-code.js +0 -10
  73. package/esm/development/wirestate-core/error/error-code.js.map +0 -1
  74. package/esm/development/wirestate-core/error/wirestate-error.js +0 -29
  75. package/esm/development/wirestate-core/error/wirestate-error.js.map +0 -1
  76. package/esm/development/wirestate-core/events/build-event-dispatcher.js +0 -39
  77. package/esm/development/wirestate-core/events/build-event-dispatcher.js.map +0 -1
  78. package/esm/development/wirestate-core/events/event-bus.js +0 -52
  79. package/esm/development/wirestate-core/events/event-bus.js.map +0 -1
  80. package/esm/development/wirestate-core/events/get-event-handler-metadata.js +0 -27
  81. package/esm/development/wirestate-core/events/get-event-handler-metadata.js.map +0 -1
  82. package/esm/development/wirestate-core/queries/get-query-handler-metadata.js +0 -27
  83. package/esm/development/wirestate-core/queries/get-query-handler-metadata.js.map +0 -1
  84. package/esm/development/wirestate-core/queries/query-bus.js +0 -99
  85. package/esm/development/wirestate-core/queries/query-bus.js.map +0 -1
  86. package/esm/development/wirestate-core/registry.js +0 -56
  87. package/esm/development/wirestate-core/registry.js.map +0 -1
  88. package/esm/development/wirestate-core/service/get-activated-handler-metadata.js +0 -27
  89. package/esm/development/wirestate-core/service/get-activated-handler-metadata.js.map +0 -1
  90. package/esm/development/wirestate-core/service/get-deactivation-handler-metadata.js +0 -27
  91. package/esm/development/wirestate-core/service/get-deactivation-handler-metadata.js.map +0 -1
  92. package/esm/development/wirestate-core/test-utils/mock-bind-entry.js +0 -24
  93. package/esm/development/wirestate-core/test-utils/mock-bind-entry.js.map +0 -1
  94. package/esm/development/wirestate-core/test-utils/mock-container.js +0 -52
  95. package/esm/development/wirestate-core/test-utils/mock-container.js.map +0 -1
  96. package/esm/development/wirestate-core/types/commands.js +0 -12
  97. package/esm/development/wirestate-core/types/commands.js.map +0 -1
  98. package/esm/development/wirestate-react/commands/use-command-caller.js.map +0 -1
  99. package/esm/development/wirestate-react/commands/use-command-handler.js.map +0 -1
  100. package/esm/development/wirestate-react/commands/use-optional-command-caller.js.map +0 -1
  101. package/esm/development/wirestate-react/error/error-code.js.map +0 -1
  102. package/esm/development/wirestate-react/events/use-event-emitter.js.map +0 -1
  103. package/esm/development/wirestate-react/events/use-event.js.map +0 -1
  104. package/esm/development/wirestate-react/events/use-events-handler.js.map +0 -1
  105. package/esm/development/wirestate-react/events/use-events.js.map +0 -1
  106. package/esm/development/wirestate-react/provision/create-injectables-provider.js.map +0 -1
  107. package/esm/development/wirestate-react/provision/ioc-context.js.map +0 -1
  108. package/esm/development/wirestate-react/provision/ioc-provider.js.map +0 -1
  109. package/esm/development/wirestate-react/provision/use-container-revision.js.map +0 -1
  110. package/esm/development/wirestate-react/provision/use-container.js.map +0 -1
  111. package/esm/development/wirestate-react/provision/use-injection.js.map +0 -1
  112. package/esm/development/wirestate-react/provision/use-ioc-context.js.map +0 -1
  113. package/esm/development/wirestate-react/provision/use-optional-injection.js.map +0 -1
  114. package/esm/development/wirestate-react/queries/use-optional-query-caller.js.map +0 -1
  115. package/esm/development/wirestate-react/queries/use-optional-sync-query-caller.js.map +0 -1
  116. package/esm/development/wirestate-react/queries/use-query-caller.js.map +0 -1
  117. package/esm/development/wirestate-react/queries/use-query-handler.js.map +0 -1
  118. package/esm/development/wirestate-react/queries/use-sync-query-caller.js.map +0 -1
  119. package/esm/development/wirestate-react/test-utils/with-ioc-provider.js.map +0 -1
  120. package/esm/production/wirestate-core/bind/bind-constant.js +0 -1
  121. package/esm/production/wirestate-core/bind/bind-constant.js.map +0 -1
  122. package/esm/production/wirestate-core/bind/bind-dynamic-value.js +0 -1
  123. package/esm/production/wirestate-core/bind/bind-dynamic-value.js.map +0 -1
  124. package/esm/production/wirestate-core/bind/bind-entry.js +0 -1
  125. package/esm/production/wirestate-core/bind/bind-entry.js.map +0 -1
  126. package/esm/production/wirestate-core/bind/bind-service.js +0 -1
  127. package/esm/production/wirestate-core/bind/bind-service.js.map +0 -1
  128. package/esm/production/wirestate-core/bind/get-entry-token.js +0 -1
  129. package/esm/production/wirestate-core/bind/get-entry-token.js.map +0 -1
  130. package/esm/production/wirestate-core/commands/command-bus.js +0 -1
  131. package/esm/production/wirestate-core/commands/command-bus.js.map +0 -1
  132. package/esm/production/wirestate-core/commands/get-command-handler-metadata.js +0 -1
  133. package/esm/production/wirestate-core/commands/get-command-handler-metadata.js.map +0 -1
  134. package/esm/production/wirestate-core/container/create-ioc-container.js +0 -1
  135. package/esm/production/wirestate-core/container/create-ioc-container.js.map +0 -1
  136. package/esm/production/wirestate-core/container/wire-scope.js +0 -1
  137. package/esm/production/wirestate-core/container/wire-scope.js.map +0 -1
  138. package/esm/production/wirestate-core/error/error-code.js +0 -1
  139. package/esm/production/wirestate-core/error/error-code.js.map +0 -1
  140. package/esm/production/wirestate-core/error/wirestate-error.js +0 -1
  141. package/esm/production/wirestate-core/error/wirestate-error.js.map +0 -1
  142. package/esm/production/wirestate-core/events/build-event-dispatcher.js +0 -1
  143. package/esm/production/wirestate-core/events/build-event-dispatcher.js.map +0 -1
  144. package/esm/production/wirestate-core/events/event-bus.js +0 -1
  145. package/esm/production/wirestate-core/events/event-bus.js.map +0 -1
  146. package/esm/production/wirestate-core/events/get-event-handler-metadata.js +0 -1
  147. package/esm/production/wirestate-core/events/get-event-handler-metadata.js.map +0 -1
  148. package/esm/production/wirestate-core/queries/get-query-handler-metadata.js +0 -1
  149. package/esm/production/wirestate-core/queries/get-query-handler-metadata.js.map +0 -1
  150. package/esm/production/wirestate-core/queries/query-bus.js +0 -1
  151. package/esm/production/wirestate-core/queries/query-bus.js.map +0 -1
  152. package/esm/production/wirestate-core/registry.js +0 -1
  153. package/esm/production/wirestate-core/registry.js.map +0 -1
  154. package/esm/production/wirestate-core/service/get-activated-handler-metadata.js +0 -1
  155. package/esm/production/wirestate-core/service/get-activated-handler-metadata.js.map +0 -1
  156. package/esm/production/wirestate-core/service/get-deactivation-handler-metadata.js +0 -1
  157. package/esm/production/wirestate-core/service/get-deactivation-handler-metadata.js.map +0 -1
  158. package/esm/production/wirestate-core/test-utils/mock-bind-entry.js +0 -1
  159. package/esm/production/wirestate-core/test-utils/mock-bind-entry.js.map +0 -1
  160. package/esm/production/wirestate-core/test-utils/mock-container.js +0 -1
  161. package/esm/production/wirestate-core/test-utils/mock-container.js.map +0 -1
  162. package/esm/production/wirestate-core/types/commands.js +0 -1
  163. package/esm/production/wirestate-core/types/commands.js.map +0 -1
  164. package/esm/production/wirestate-react/commands/use-command-caller.js.map +0 -1
  165. package/esm/production/wirestate-react/commands/use-command-handler.js.map +0 -1
  166. package/esm/production/wirestate-react/commands/use-optional-command-caller.js.map +0 -1
  167. package/esm/production/wirestate-react/error/error-code.js.map +0 -1
  168. package/esm/production/wirestate-react/events/use-event-emitter.js.map +0 -1
  169. package/esm/production/wirestate-react/events/use-event.js.map +0 -1
  170. package/esm/production/wirestate-react/events/use-events-handler.js.map +0 -1
  171. package/esm/production/wirestate-react/events/use-events.js.map +0 -1
  172. package/esm/production/wirestate-react/provision/create-injectables-provider.js.map +0 -1
  173. package/esm/production/wirestate-react/provision/ioc-context.js.map +0 -1
  174. package/esm/production/wirestate-react/provision/ioc-provider.js.map +0 -1
  175. package/esm/production/wirestate-react/provision/use-container-revision.js.map +0 -1
  176. package/esm/production/wirestate-react/provision/use-container.js.map +0 -1
  177. package/esm/production/wirestate-react/provision/use-injection.js.map +0 -1
  178. package/esm/production/wirestate-react/provision/use-ioc-context.js.map +0 -1
  179. package/esm/production/wirestate-react/provision/use-optional-injection.js.map +0 -1
  180. package/esm/production/wirestate-react/queries/use-optional-query-caller.js.map +0 -1
  181. package/esm/production/wirestate-react/queries/use-optional-sync-query-caller.js.map +0 -1
  182. package/esm/production/wirestate-react/queries/use-query-caller.js.map +0 -1
  183. package/esm/production/wirestate-react/queries/use-query-handler.js.map +0 -1
  184. package/esm/production/wirestate-react/queries/use-sync-query-caller.js.map +0 -1
  185. package/esm/production/wirestate-react/test-utils/with-ioc-provider.js +0 -1
  186. package/esm/production/wirestate-react/test-utils/with-ioc-provider.js.map +0 -1
  187. /package/esm/development/{wirestate-react/commands → commands}/use-command-caller.js +0 -0
  188. /package/esm/development/{wirestate-react/commands → commands}/use-command-handler.js +0 -0
  189. /package/esm/development/{wirestate-react/commands → commands}/use-optional-command-caller.js +0 -0
  190. /package/esm/development/{wirestate-react/error → error}/error-code.js +0 -0
  191. /package/esm/development/{wirestate-react/events → events}/use-event-emitter.js +0 -0
  192. /package/esm/development/{wirestate-react/events → events}/use-event.js +0 -0
  193. /package/esm/development/{wirestate-react/events → events}/use-events-handler.js +0 -0
  194. /package/esm/development/{wirestate-react/events → events}/use-events.js +0 -0
  195. /package/esm/development/{wirestate-react/index.js → index.js} +0 -0
  196. /package/esm/development/{wirestate-react/index.js.map → index.js.map} +0 -0
  197. /package/esm/development/{wirestate-react/provision → provision}/create-injectables-provider.js +0 -0
  198. /package/esm/development/{wirestate-react/provision → provision}/ioc-context.js +0 -0
  199. /package/esm/development/{wirestate-react/provision → provision}/ioc-provider.js +0 -0
  200. /package/esm/development/{wirestate-react/provision → provision}/use-container-revision.js +0 -0
  201. /package/esm/development/{wirestate-react/provision → provision}/use-container.js +0 -0
  202. /package/esm/development/{wirestate-react/provision → provision}/use-injection.js +0 -0
  203. /package/esm/development/{wirestate-react/provision → provision}/use-ioc-context.js +0 -0
  204. /package/esm/development/{wirestate-react/provision → provision}/use-optional-injection.js +0 -0
  205. /package/esm/development/{wirestate-react/queries → queries}/use-optional-query-caller.js +0 -0
  206. /package/esm/development/{wirestate-react/queries → queries}/use-optional-sync-query-caller.js +0 -0
  207. /package/esm/development/{wirestate-react/queries → queries}/use-query-caller.js +0 -0
  208. /package/esm/development/{wirestate-react/queries → queries}/use-query-handler.js +0 -0
  209. /package/esm/development/{wirestate-react/queries → queries}/use-sync-query-caller.js +0 -0
  210. /package/esm/development/{wirestate-react/test-utils.js → test-utils.js} +0 -0
  211. /package/esm/development/{wirestate-react/test-utils.js.map → test-utils.js.map} +0 -0
  212. /package/esm/production/{wirestate-react/commands → commands}/use-command-caller.js +0 -0
  213. /package/esm/production/{wirestate-react/commands → commands}/use-command-handler.js +0 -0
  214. /package/esm/production/{wirestate-react/commands → commands}/use-optional-command-caller.js +0 -0
  215. /package/esm/production/{wirestate-react/error → error}/error-code.js +0 -0
  216. /package/esm/production/{wirestate-react/events → events}/use-event-emitter.js +0 -0
  217. /package/esm/production/{wirestate-react/events → events}/use-event.js +0 -0
  218. /package/esm/production/{wirestate-react/events → events}/use-events-handler.js +0 -0
  219. /package/esm/production/{wirestate-react/events → events}/use-events.js +0 -0
  220. /package/esm/production/{wirestate-react/index.js → index.js} +0 -0
  221. /package/esm/production/{wirestate-react/index.js.map → index.js.map} +0 -0
  222. /package/esm/production/{wirestate-react/provision → provision}/create-injectables-provider.js +0 -0
  223. /package/esm/production/{wirestate-react/provision → provision}/ioc-context.js +0 -0
  224. /package/esm/production/{wirestate-react/provision → provision}/ioc-provider.js +0 -0
  225. /package/esm/production/{wirestate-react/provision → provision}/use-container-revision.js +0 -0
  226. /package/esm/production/{wirestate-react/provision → provision}/use-container.js +0 -0
  227. /package/esm/production/{wirestate-react/provision → provision}/use-injection.js +0 -0
  228. /package/esm/production/{wirestate-react/provision → provision}/use-ioc-context.js +0 -0
  229. /package/esm/production/{wirestate-react/provision → provision}/use-optional-injection.js +0 -0
  230. /package/esm/production/{wirestate-react/queries → queries}/use-optional-query-caller.js +0 -0
  231. /package/esm/production/{wirestate-react/queries → queries}/use-optional-sync-query-caller.js +0 -0
  232. /package/esm/production/{wirestate-react/queries → queries}/use-query-caller.js +0 -0
  233. /package/esm/production/{wirestate-react/queries → queries}/use-query-handler.js +0 -0
  234. /package/esm/production/{wirestate-react/queries → queries}/use-sync-query-caller.js +0 -0
  235. /package/esm/production/{wirestate-react/test-utils.js → test-utils.js} +0 -0
  236. /package/esm/production/{wirestate-react/test-utils.js.map → test-utils.js.map} +0 -0
@@ -1,29 +0,0 @@
1
- import { __extends } from 'tslib';
2
- import { ERROR_CODE_GENERIC } from './error-code.js';
3
-
4
- /**
5
- * A custom error class that contains generic error information for Wirestate-related issues.
6
- *
7
- * This class extends the native `Error` class and is used to represent errors specific
8
- * to the Wirestate library, providing more structured error handling.
9
- */
10
- var WirestateError = /** @class */function (_super) {
11
- __extends(WirestateError, _super);
12
- function WirestateError(code, detail) {
13
- if (code === void 0) {
14
- code = ERROR_CODE_GENERIC;
15
- }
16
- var _this = _super.call(this) || this;
17
- /**
18
- * Name or error class to help differentiate error class in minified environments.
19
- */
20
- _this.name = "WirestateError";
21
- _this.code = code;
22
- _this.message = detail || "Wirestate error.";
23
- return _this;
24
- }
25
- return WirestateError;
26
- }(Error);
27
-
28
- export { WirestateError };
29
- //# sourceMappingURL=wirestate-error.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"wirestate-error.js","sources":["../../../../../../../../../src/wirestate-core/error/wirestate-error.ts"],"sourcesContent":[null],"names":["WirestateError","_super","__extends","code","detail","ERROR_CODE_GENERIC","_this","name","message","Error"],"mappings":";;;AAEA;;;;;AAKG;AACH,IAAAA,cAAA,gBAAA,UAAAC,MAAA,EAAA;AAAoCC,EAAAA,SAAA,CAAAF,cAAA,EAAAC,MAAA,CAAA;AAclC,EAAA,SAAAD,cAAAA,CAAmBG,IAAiC,EAAEC,MAAe,EAAA;AAAlD,IAAA,IAAAD,IAAA,KAAA,MAAA,EAAA;AAAAA,MAAAA,IAAA,GAAAE,kBAAiC;AAAA,IAAA;IAClD,IAAAC,KAAA,GAAAL,MAAK,WAAE,IAAA,IAAA;AAdT;;AAEG;IACaK,KAAA,CAAAC,IAAI,GAAW,gBAAgB;IAa7CD,KAAI,CAACH,IAAI,GAAGA,IAAI;AAChBG,IAAAA,KAAI,CAACE,OAAO,GAAGJ,MAAM,IAAI,kBAAkB;;AAC7C,EAAA;AACF,EAAA,OAAAJ,cAAC;AAAD,CApBA,CAAoCS,KAAK;;;;"}
@@ -1,39 +0,0 @@
1
- import { getEventHandlerMetadata } from './get-event-handler-metadata.js';
2
-
3
- /**
4
- * Composes service event handlers into a single dispatcher.
5
- *
6
- * @param instance - service instance
7
- * @returns event handler or null if no handlers are declared
8
- * @internal
9
- */
10
- function buildEventDispatcher(instance) {
11
- var entries = [];
12
- // Register methods decorated with @OnEvent.
13
- for (var _i = 0, _a = getEventHandlerMetadata(instance); _i < _a.length; _i++) {
14
- var meta = _a[_i];
15
- var method = instance[meta.methodName];
16
- if (typeof method === "function") {
17
- entries.push({
18
- types: meta.types,
19
- handler: method.bind(instance)
20
- });
21
- }
22
- }
23
- if (entries.length) {
24
- return function (event) {
25
- // Fan out events to all matching handlers.
26
- for (var _i = 0, entries_1 = entries; _i < entries_1.length; _i++) {
27
- var entry = entries_1[_i];
28
- if (entry.types === null || entry.types.includes(event.type)) {
29
- entry.handler(event);
30
- }
31
- }
32
- };
33
- } else {
34
- return null;
35
- }
36
- }
37
-
38
- export { buildEventDispatcher };
39
- //# sourceMappingURL=build-event-dispatcher.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"build-event-dispatcher.js","sources":["../../../../../../../../../src/wirestate-core/events/build-event-dispatcher.ts"],"sourcesContent":[null],"names":["buildEventDispatcher","instance","entries","_i","_a","getEventHandlerMetadata","length","meta","method","methodName","push","types","handler","bind","event","entries_1","entry","includes","type"],"mappings":";;AAQA;;;;;;AAMG;AACG,SAAUA,oBAAoBA,CAAmBC,QAAW,EAAA;EAGhE,IAAMC,OAAO,GAA8B,EAAE;AAE7C;EACA,KAAmB,IAAAC,EAAA,GAAA,CAAiC,EAAjCC,EAAA,GAAAC,uBAAuB,CAACJ,QAAQ,CAAC,EAAjCE,EAAA,GAAAC,EAAA,CAAAE,MAAiC,EAAjCH,EAAA,EAAiC,EAAE;AAAjD,IAAA,IAAMI,IAAI,GAAAH,EAAA,CAAAD,EAAA,CAAA;AACb,IAAA,IAAMK,MAAM,GAAIP,QAAwD,CAACM,IAAI,CAACE,UAAU,CAAC;AAEzF,IAAA,IAAI,OAAOD,MAAM,KAAK,UAAU,EAAE;MAChCN,OAAO,CAACQ,IAAI,CAAC;QACXC,KAAK,EAAEJ,IAAI,CAACI,KAAK;AACjBC,QAAAA,OAAO,EAAGJ,MAAuB,CAACK,IAAI,CAACZ,QAAQ;AAChD,OAAA,CAAC;AACJ,IAAA;AACF,EAAA;EAEA,IAAIC,OAAO,CAACI,MAAM,EAAE;IAOlB,OAAO,UAACQ,KAAK,EAAA;AACX;AACA,MAAA,KAAoB,IAAAX,EAAA,GAAA,CAAO,EAAPY,SAAA,GAAAb,OAAO,EAAPC,qBAAO,EAAPA,EAAA,EAAO,EAAE;AAAxB,QAAA,IAAMa,KAAK,GAAAD,SAAA,CAAAZ,EAAA,CAAA;AACd,QAAA,IAAIa,KAAK,CAACL,KAAK,KAAK,IAAI,IAAIK,KAAK,CAACL,KAAK,CAACM,QAAQ,CAACH,KAAK,CAACI,IAAI,CAAC,EAAE;AAC5DF,UAAAA,KAAK,CAACJ,OAAO,CAACE,KAAK,CAAC;AACtB,QAAA;AACF,MAAA;IACF,CAAC;AACH,EAAA,CAAC,MAAM;AAOL,IAAA,OAAO,IAAI;AACb,EAAA;AACF;;;;"}
@@ -1,52 +0,0 @@
1
- /**
2
- * Dispatches events to subscribers.
3
- */
4
- var EventBus = /** @class */function () {
5
- function EventBus() {
6
- this.handlers = new Set();
7
- }
8
- /**
9
- * Broadcasts an event to all subscribers.
10
- *
11
- * @param event - event to emit
12
- */
13
- EventBus.prototype.emit = function (event) {
14
- // Snapshot prevents concurrent modification errors if handlers sub/unsub during emit.
15
- var snapshot = Array.from(this.handlers);
16
- for (var _i = 0, snapshot_1 = snapshot; _i < snapshot_1.length; _i++) {
17
- var handler = snapshot_1[_i];
18
- try {
19
- handler(event);
20
- } catch (error) {
21
- // Prevent one failing listener from stalling the entire bus.
22
- console.error("[wirestate] Event handler threw:", error);
23
- }
24
- }
25
- };
26
- /**
27
- * Subscribes a handler to all events.
28
- * Returns an unsubscribe function.
29
- *
30
- * @param handler - event handler function
31
- * @returns unsubscribe function
32
- */
33
- EventBus.prototype.subscribe = function (handler) {
34
- var _this = this;
35
- this.handlers.add(handler);
36
- return function () {
37
- _this.handlers.delete(handler);
38
- };
39
- };
40
- /**
41
- * Removes all registered handlers.
42
- *
43
- * @internal
44
- */
45
- EventBus.prototype.clear = function () {
46
- this.handlers.clear();
47
- };
48
- return EventBus;
49
- }();
50
-
51
- export { EventBus };
52
- //# sourceMappingURL=event-bus.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"event-bus.js","sources":["../../../../../../../../../src/wirestate-core/events/event-bus.ts"],"sourcesContent":[null],"names":["EventBus","handlers","Set","prototype","emit","event","snapshot","Array","from","_i","snapshot_1","handler","error","console","subscribe","_this","add","delete","clear"],"mappings":"AAKA;;AAEG;AACH,IAAAA,QAAA,gBAAA,YAAA;EAAA,SAAAA,QAAAA,GAAA;AACmB,IAAA,IAAA,CAAAC,QAAQ,GAAsB,IAAIC,GAAG,EAAE;AAsD1D,EAAA;AApDE;;;;AAIG;AACIF,EAAAA,QAAA,CAAAG,SAAA,CAAAC,IAAI,GAAX,UAAuEC,KAAqB,EAAA;AAC1F;IACA,IAAMC,QAAQ,GAAwBC,KAAK,CAACC,IAAI,CAAC,IAAI,CAACP,QAAQ,CAAC;AAE/D,IAAA,KAAsB,IAAAQ,EAAA,GAAA,CAAQ,EAARC,UAAA,GAAAJ,QAAQ,EAARG,sBAAQ,EAARA,EAAA,EAAQ,EAAE;AAA3B,MAAA,IAAME,OAAO,GAAAD,UAAA,CAAAD,EAAA,CAAA;MAChB,IAAI;QACFE,OAAO,CAACN,KAAK,CAAC;MAChB,CAAC,CAAC,OAAOO,KAAK,EAAE;AACd;AACAC,QAAAA,OAAO,CAACD,KAAK,CAAC,kCAAkC,EAAEA,KAAK,CAAC;AAC1D,MAAA;AACF,IAAA;EACF,CAAC;AAED;;;;;;AAMG;AACIZ,EAAAA,QAAA,CAAAG,SAAA,CAAAW,SAAS,GAAhB,UAAiBH,OAAqB,EAAA;IAAtC,IAAAI,KAAA,GAAA,IAAA;AAME,IAAA,IAAI,CAACd,QAAQ,CAACe,GAAG,CAACL,OAAO,CAAC;AAE1B,IAAA,OAAO,YAAA;AAMLI,MAAAA,KAAI,CAACd,QAAQ,CAACgB,MAAM,CAACN,OAAO,CAAC;IAC/B,CAAC;EACH,CAAC;AAED;;;;AAIG;AACIX,EAAAA,QAAA,CAAAG,SAAA,CAAAe,KAAK,GAAZ,YAAA;AACE,IAAA,IAAI,CAACjB,QAAQ,CAACiB,KAAK,EAAE;EACvB,CAAC;AACH,EAAA,OAAAlB,QAAC;AAAD,CAAC;;;;"}
@@ -1,27 +0,0 @@
1
- import { EVENT_HANDLER_METADATA } from '../registry.js';
2
-
3
- /**
4
- * Retrieves `@OnEvent` metadata from the class hierarchy.
5
- * Returns handlers ordered from base to derived class.
6
- *
7
- * @param instance - service instance
8
- * @returns metadata list
9
- * @internal
10
- */
11
- function getEventHandlerMetadata(instance) {
12
- var constructor = instance.constructor;
13
- var chain = [];
14
- // Traverse prototype chain up to Object/Function
15
- while (typeof constructor === "function" && constructor !== Object && constructor !== Function.prototype) {
16
- var own = EVENT_HANDLER_METADATA.get(constructor);
17
- if (own && own.length > 0) {
18
- chain.push(own);
19
- }
20
- constructor = Object.getPrototypeOf(constructor);
21
- }
22
- // Reverse to ensure parent-first execution order
23
- return chain.reverse().flat();
24
- }
25
-
26
- export { getEventHandlerMetadata };
27
- //# sourceMappingURL=get-event-handler-metadata.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"get-event-handler-metadata.js","sources":["../../../../../../../../../src/wirestate-core/events/get-event-handler-metadata.ts"],"sourcesContent":[null],"names":["getEventHandlerMetadata","instance","constructor","chain","Object","Function","prototype","own","EVENT_HANDLER_METADATA","get","length","push","getPrototypeOf","reverse","flat"],"mappings":";;AAOA;;;;;;;AAOG;AACG,SAAUA,uBAAuBA,CAACC,QAAgB,EAAA;AAGtD,EAAA,IAAIC,WAAW,GAAYD,QAAQ,CAACC,WAAW;EAE/C,IAAMC,KAAK,GAAuC,EAAE;AAEpD;AACA,EAAA,OAAO,OAAOD,WAAW,KAAK,UAAU,IAAIA,WAAW,KAAKE,MAAM,IAAIF,WAAW,KAAKG,QAAQ,CAACC,SAAS,EAAE;AACxG,IAAA,IAAMC,GAAG,GAAuCC,sBAAsB,CAACC,GAAG,CAACP,WAAqB,CAAC;AAEjG,IAAA,IAAIK,GAAG,IAAIA,GAAG,CAACG,MAAM,GAAG,CAAC,EAAE;AACzBP,MAAAA,KAAK,CAACQ,IAAI,CAACJ,GAAG,CAAC;AACjB,IAAA;AAEAL,IAAAA,WAAW,GAAGE,MAAM,CAACQ,cAAc,CAACV,WAAW,CAAC;AAClD,EAAA;AAQA;EACA,OAAOC,KAAK,CAACU,OAAO,EAAE,CAACC,IAAI,EAAE;AAC/B;;;;"}
@@ -1,27 +0,0 @@
1
- import { QUERY_HANDLER_METADATA } from '../registry.js';
2
-
3
- /**
4
- * Retrieves `@OnQuery` metadata from the class hierarchy.
5
- * Returns handlers ordered from base to derived class.
6
- *
7
- * @param instance - service instance
8
- * @returns metadata list
9
- * @internal
10
- */
11
- function getQueryHandlerMetadata(instance) {
12
- var constructor = instance.constructor;
13
- var chain = [];
14
- // Traverse prototype chain up to Object/Function
15
- while (typeof constructor === "function" && constructor !== Object && constructor !== Function.prototype) {
16
- var own = QUERY_HANDLER_METADATA.get(constructor);
17
- if (own && own.length > 0) {
18
- chain.push(own);
19
- }
20
- constructor = Object.getPrototypeOf(constructor);
21
- }
22
- // Reverse to ensure parent-first execution order.
23
- return chain.reverse().flat();
24
- }
25
-
26
- export { getQueryHandlerMetadata };
27
- //# sourceMappingURL=get-query-handler-metadata.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"get-query-handler-metadata.js","sources":["../../../../../../../../../src/wirestate-core/queries/get-query-handler-metadata.ts"],"sourcesContent":[null],"names":["getQueryHandlerMetadata","instance","constructor","chain","Object","Function","prototype","own","QUERY_HANDLER_METADATA","get","length","push","getPrototypeOf","reverse","flat"],"mappings":";;AAOA;;;;;;;AAOG;AACG,SAAUA,uBAAuBA,CAACC,QAAgB,EAAA;AAGtD,EAAA,IAAIC,WAAW,GAAYD,QAAQ,CAACC,WAAW;EAE/C,IAAMC,KAAK,GAAuC,EAAE;AAEpD;AACA,EAAA,OAAO,OAAOD,WAAW,KAAK,UAAU,IAAIA,WAAW,KAAKE,MAAM,IAAIF,WAAW,KAAKG,QAAQ,CAACC,SAAS,EAAE;AACxG,IAAA,IAAMC,GAAG,GAAuCC,sBAAsB,CAACC,GAAG,CAACP,WAAqB,CAAC;AAEjG,IAAA,IAAIK,GAAG,IAAIA,GAAG,CAACG,MAAM,GAAG,CAAC,EAAE;AACzBP,MAAAA,KAAK,CAACQ,IAAI,CAACJ,GAAG,CAAC;AACjB,IAAA;AAEAL,IAAAA,WAAW,GAAGE,MAAM,CAACQ,cAAc,CAACV,WAAW,CAAC;AAClD,EAAA;AAQA;EACA,OAAOC,KAAK,CAACU,OAAO,EAAE,CAACC,IAAI,EAAE;AAC/B;;;;"}
@@ -1,99 +0,0 @@
1
- import { ERROR_CODE_FAILED_TO_RESOLVE_QUERY_HANDLER } from '../error/error-code.js';
2
- import { WirestateError } from '../error/wirestate-error.js';
3
-
4
- /**
5
- * Dispatches queries to handlers.
6
- */
7
- var QueryBus = /** @class */function () {
8
- function QueryBus() {
9
- /**
10
- * Internal handler storage.
11
- * Uses a stack for each query type to support shadowing (e.g., component-level vs service-level).
12
- */
13
- this.handlers = new Map();
14
- }
15
- /**
16
- * Registers a query handler.
17
- * Returns an unregister function.
18
- *
19
- * @param type - query type
20
- * @param handler - handler function
21
- * @returns unregister function
22
- */
23
- QueryBus.prototype.register = function (type, handler) {
24
- var _this = this;
25
- var stack = this.handlers.get(type);
26
- if (!stack) {
27
- stack = [];
28
- this.handlers.set(type, stack);
29
- }
30
- stack.push(handler);
31
- return function () {
32
- var current = _this.handlers.get(type);
33
- if (!current) {
34
- return;
35
- }
36
- var index = current.indexOf(handler);
37
- if (index >= 0) {
38
- current.splice(index, 1);
39
- }
40
- // Clean empty stacks.
41
- if (current.length === 0) {
42
- _this.handlers.delete(type);
43
- }
44
- };
45
- };
46
- /**
47
- * Dispatches a query to the last registered handler.
48
- *
49
- * @param type - query type
50
- * @param data - query payload
51
- * @returns query result
52
- *
53
- * @throws if no handler is registered
54
- */
55
- QueryBus.prototype.query = function (type, data) {
56
- var stack = this.handlers.get(type);
57
- // Always use the top of the stack (most recent registration) if handlers are available.
58
- if (stack === null || stack === void 0 ? void 0 : stack.length) {
59
- return stack[stack.length - 1](data);
60
- }
61
- throw new WirestateError(ERROR_CODE_FAILED_TO_RESOLVE_QUERY_HANDLER, "No query handler registered in container for type: '".concat(String(type), "'."));
62
- };
63
- /**
64
- * Dispatches a query to the last registered handler, returning null if no handler exists.
65
- *
66
- * @param type - query type
67
- * @param data - query payload
68
- * @returns query result or null if no handler is registered
69
- */
70
- QueryBus.prototype.queryOptional = function (type, data) {
71
- var stack = this.handlers.get(type);
72
- if (stack === null || stack === void 0 ? void 0 : stack.length) {
73
- return stack[stack.length - 1](data);
74
- }
75
- return null;
76
- };
77
- /**
78
- * Checks if a handler is registered for the given type.
79
- *
80
- * @param type - query type
81
- * @returns true if handler exists
82
- */
83
- QueryBus.prototype.has = function (type) {
84
- var stack = this.handlers.get(type);
85
- return Boolean(stack && stack.length);
86
- };
87
- /**
88
- * Removes all registered handlers.
89
- *
90
- * @internal
91
- */
92
- QueryBus.prototype.clear = function () {
93
- this.handlers.clear();
94
- };
95
- return QueryBus;
96
- }();
97
-
98
- export { QueryBus };
99
- //# sourceMappingURL=query-bus.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"query-bus.js","sources":["../../../../../../../../../src/wirestate-core/queries/query-bus.ts"],"sourcesContent":[null],"names":["QueryBus","handlers","Map","prototype","register","type","handler","_this","stack","get","set","push","current","index","indexOf","splice","length","delete","query","data","WirestateError","ERROR_CODE_FAILED_TO_RESOLVE_QUERY_HANDLER","concat","String","queryOptional","has","Boolean","clear"],"mappings":";;;AAQA;;AAEG;AACH,IAAAA,QAAA,gBAAA,YAAA;EAAA,SAAAA,QAAAA,GAAA;AACE;;;AAGG;AACc,IAAA,IAAA,CAAAC,QAAQ,GAAwC,IAAIC,GAAG,EAAE;AAmH5E,EAAA;AAjHE;;;;;;;AAOG;EACIF,QAAA,CAAAG,SAAA,CAAAC,QAAQ,GAAf,UAA0CC,IAAe,EAAEC,OAA2B,EAAA;IAAtF,IAAAC,KAAA,GAAA,IAAA;IAOE,IAAIC,KAAK,GAA+B,IAAI,CAACP,QAAQ,CAACQ,GAAG,CAACJ,IAAI,CAAC;IAE/D,IAAI,CAACG,KAAK,EAAE;AACVA,MAAAA,KAAK,GAAG,EAAE;MACV,IAAI,CAACP,QAAQ,CAACS,GAAG,CAACL,IAAI,EAAEG,KAAK,CAAC;AAChC,IAAA;AAEAA,IAAAA,KAAK,CAACG,IAAI,CAACL,OAAuB,CAAC;AAEnC,IAAA,OAAO,YAAA;MAOL,IAAMM,OAAO,GAA+BL,KAAI,CAACN,QAAQ,CAACQ,GAAG,CAACJ,IAAI,CAAC;MAEnE,IAAI,CAACO,OAAO,EAAE;AACZ,QAAA;AACF,MAAA;AAEA,MAAA,IAAMC,KAAK,GAAWD,OAAO,CAACE,OAAO,CAACR,OAAuB,CAAC;MAE9D,IAAIO,KAAK,IAAI,CAAC,EAAE;AACdD,QAAAA,OAAO,CAACG,MAAM,CAACF,KAAK,EAAE,CAAC,CAAC;AAC1B,MAAA;AAEA;AACA,MAAA,IAAID,OAAO,CAACI,MAAM,KAAK,CAAC,EAAE;AACxBT,QAAAA,KAAI,CAACN,QAAQ,CAACgB,MAAM,CAACZ,IAAI,CAAC;AAC5B,MAA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AA,CAAAwB,KAAK,GAAZ,YAAA;AACE,IAAA,IAAI,CAAC1B,QAAQ,CAAC0B,KAAK,EAAE;EACvB,CAAC;AACH,EAAA,OAAA3B,QAAC;AAAD,CAAC;;;;"}
@@ -1,56 +0,0 @@
1
- /**
2
- * Token for the container-scoped seeds map.
3
- */
4
- var SEEDS_TOKEN = Symbol("@wirestate/seeds");
5
- /**
6
- * Token for the container-scoped shared seed object.
7
- */
8
- var SEED_TOKEN = Symbol("@wirestate/seed");
9
- /**
10
- * Map of class constructors to their declared query handlers.
11
- * Inherited via a prototype chain at resolve time.
12
- */
13
- var QUERY_HANDLER_METADATA = new WeakMap();
14
- /**
15
- * Map of class constructors to their declared command handlers.
16
- * Inherited via a prototype chain at resolve time.
17
- */
18
- var COMMAND_HANDLER_METADATA = new WeakMap();
19
- /**
20
- * Map of class constructors to their `@OnActivated`-decorated method names.
21
- * Inherited via a prototype chain at resolve time.
22
- */
23
- var ACTIVATED_HANDLER_METADATA = new WeakMap();
24
- /**
25
- * Map of class constructors to their `@OnDeactivation`-decorated method names.
26
- * Inherited via a prototype chain at resolve time.
27
- */
28
- var DEACTIVATION_HANDLER_METADATA = new WeakMap();
29
- /**
30
- * Map of class constructors for their declared event handlers.
31
- * Inherited via a prototype chain at resolve time.
32
- */
33
- var EVENT_HANDLER_METADATA = new WeakMap();
34
- /**
35
- * Private storage for service-to-container references.
36
- */
37
- var CONTAINER_REFS_BY_SERVICE = new WeakMap();
38
- /**
39
- * Private storage for injected WireScope instances per service.
40
- */
41
- var WIRE_SCOPES_BY_SERVICE = new WeakMap();
42
- /**
43
- * Private storage for service event unsubscribers.
44
- */
45
- var EVENT_UNSUBSCRIBERS_BY_SERVICE = new WeakMap();
46
- /**
47
- * Private storage for service query unregisters.
48
- */
49
- var QUERY_UNREGISTERS_BY_SERVICE = new WeakMap();
50
- /**
51
- * Private storage for service command unregisters.
52
- */
53
- var COMMAND_UNREGISTERS_BY_SERVICE = new WeakMap();
54
-
55
- export { ACTIVATED_HANDLER_METADATA, COMMAND_HANDLER_METADATA, COMMAND_UNREGISTERS_BY_SERVICE, CONTAINER_REFS_BY_SERVICE, DEACTIVATION_HANDLER_METADATA, EVENT_HANDLER_METADATA, EVENT_UNSUBSCRIBERS_BY_SERVICE, QUERY_HANDLER_METADATA, QUERY_UNREGISTERS_BY_SERVICE, SEEDS_TOKEN, SEED_TOKEN, WIRE_SCOPES_BY_SERVICE };
56
- //# sourceMappingURL=registry.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"registry.js","sources":["../../../../../../../../src/wirestate-core/registry.ts"],"sourcesContent":[null],"names":["SEEDS_TOKEN","Symbol","SEED_TOKEN","QUERY_HANDLER_METADATA","WeakMap","COMMAND_HANDLER_METADATA","ACTIVATED_HANDLER_METADATA","DEACTIVATION_HANDLER_METADATA","EVENT_HANDLER_METADATA","CONTAINER_REFS_BY_SERVICE","WIRE_SCOPES_BY_SERVICE","EVENT_UNSUBSCRIBERS_BY_SERVICE","QUERY_UNREGISTERS_BY_SERVICE","COMMAND_UNREGISTERS_BY_SERVICE"],"mappings":"AAOA;;AAEG;IACUA,WAAW,GAAkBC,MAAM,CAAC,kBAAkB;AAEnE;;AAEG;IACUC,UAAU,GAAkBD,MAAM,CAAC,iBAAiB;AAEjE;;;AAGG;IACUE,sBAAsB,GAAiD,IAAIC,OAAO;AAE/F;;;AAGG;IACUC,wBAAwB,GAAmD,IAAID,OAAO;AAEnG;;;AAGG;IACUE,0BAA0B,GAA4C,IAAIF,OAAO;AAE9F;;;AAGG;IACUG,6BAA6B,GAA4C,IAAIH,OAAO;AAEjG;;;AAGG;IACUI,sBAAsB,GAAiD,IAAIJ,OAAO;AAE/F;;AAEG;IACUK,yBAAyB,GAA+B,IAAIL,OAAO;AAEhF;;AAEG;IACUM,sBAAsB,GAAsC,IAAIN,OAAO;AAEpF;;AAEG;IACUO,8BAA8B,GAAuC,IAAIP,OAAO;AAE7F;;AAEG;IACUQ,4BAA4B,GAA4C,IAAIR,OAAO;AAEhG;;AAEG;IACUS,8BAA8B,GAA8C,IAAIT,OAAO;;;;"}
@@ -1,27 +0,0 @@
1
- import { ACTIVATED_HANDLER_METADATA } from '../registry.js';
2
-
3
- /**
4
- * Retrieves `@OnActivated` method names from the class hierarchy.
5
- * Returns method names ordered from base to derived class.
6
- *
7
- * @param instance - service instance
8
- * @returns list of method names
9
- * @internal
10
- */
11
- function getActivatedHandlerMetadata(instance) {
12
- var constructor = instance.constructor;
13
- var chain = [];
14
- // Traverse prototype chain up to Object/Function.
15
- while (typeof constructor === "function" && constructor !== Object && constructor !== Function.prototype) {
16
- var own = ACTIVATED_HANDLER_METADATA.get(constructor);
17
- if (own && own.length > 0) {
18
- chain.push(own);
19
- }
20
- constructor = Object.getPrototypeOf(constructor);
21
- }
22
- // Reverse to ensure parent-first execution order.
23
- return chain.reverse().flat();
24
- }
25
-
26
- export { getActivatedHandlerMetadata };
27
- //# sourceMappingURL=get-activated-handler-metadata.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"get-activated-handler-metadata.js","sources":["../../../../../../../../../src/wirestate-core/service/get-activated-handler-metadata.ts"],"sourcesContent":[null],"names":["getActivatedHandlerMetadata","instance","constructor","chain","Object","Function","prototype","own","ACTIVATED_HANDLER_METADATA","get","length","push","getPrototypeOf","reverse","flat"],"mappings":";;AAMA;;;;;;;AAOG;AACG,SAAUA,2BAA2BA,CAACC,QAAgB,EAAA;AAG1D,EAAA,IAAIC,WAAW,GAAYD,QAAQ,CAACC,WAAW;EAE/C,IAAMC,KAAK,GAAkC,EAAE;AAE/C;AACA,EAAA,OAAO,OAAOD,WAAW,KAAK,UAAU,IAAIA,WAAW,KAAKE,MAAM,IAAIF,WAAW,KAAKG,QAAQ,CAACC,SAAS,EAAE;AACxG,IAAA,IAAMC,GAAG,GAAkCC,0BAA0B,CAACC,GAAG,CAACP,WAAqB,CAAC;AAEhG,IAAA,IAAIK,GAAG,IAAIA,GAAG,CAACG,MAAM,GAAG,CAAC,EAAE;AACzBP,MAAAA,KAAK,CAACQ,IAAI,CAACJ,GAAG,CAAC;AACjB,IAAA;AAEAL,IAAAA,WAAW,GAAGE,MAAM,CAACQ,cAAc,CAACV,WAAW,CAAC;AAClD,EAAA;AAIA;EACA,OAAOC,KAAK,CAACU,OAAO,EAAE,CAACC,IAAI,EAAE;AAC/B;;;;"}
@@ -1,27 +0,0 @@
1
- import { DEACTIVATION_HANDLER_METADATA } from '../registry.js';
2
-
3
- /**
4
- * Retrieves `@OnDeactivation` method names from the class hierarchy.
5
- * Returns method names ordered from base to derived class.
6
- *
7
- * @param instance - service instance
8
- * @returns list of method names
9
- * @internal
10
- */
11
- function getDeactivationHandlerMetadata(instance) {
12
- var constructor = instance.constructor;
13
- var chain = [];
14
- // Traverse prototype chain up to Object/Function.
15
- while (typeof constructor === "function" && constructor !== Object && constructor !== Function.prototype) {
16
- var own = DEACTIVATION_HANDLER_METADATA.get(constructor);
17
- if (own && own.length > 0) {
18
- chain.push(own);
19
- }
20
- constructor = Object.getPrototypeOf(constructor);
21
- }
22
- // Reverse to ensure parent-first execution order.
23
- return chain.reverse().flat();
24
- }
25
-
26
- export { getDeactivationHandlerMetadata };
27
- //# sourceMappingURL=get-deactivation-handler-metadata.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"get-deactivation-handler-metadata.js","sources":["../../../../../../../../../src/wirestate-core/service/get-deactivation-handler-metadata.ts"],"sourcesContent":[null],"names":["getDeactivationHandlerMetadata","instance","constructor","chain","Object","Function","prototype","own","DEACTIVATION_HANDLER_METADATA","get","length","push","getPrototypeOf","reverse","flat"],"mappings":";;AAMA;;;;;;;AAOG;AACG,SAAUA,8BAA8BA,CAACC,QAAgB,EAAA;AAG7D,EAAA,IAAIC,WAAW,GAAYD,QAAQ,CAACC,WAAW;EAE/C,IAAMC,KAAK,GAAkC,EAAE;AAE/C;AACA,EAAA,OAAO,OAAOD,WAAW,KAAK,UAAU,IAAIA,WAAW,KAAKE,MAAM,IAAIF,WAAW,KAAKG,QAAQ,CAACC,SAAS,EAAE;AACxG,IAAA,IAAMC,GAAG,GAAkCC,6BAA6B,CAACC,GAAG,CAACP,WAAqB,CAAC;AAEnG,IAAA,IAAIK,GAAG,IAAIA,GAAG,CAACG,MAAM,GAAG,CAAC,EAAE;AACzBP,MAAAA,KAAK,CAACQ,IAAI,CAACJ,GAAG,CAAC;AACjB,IAAA;AAEAL,IAAAA,WAAW,GAAGE,MAAM,CAACQ,cAAc,CAACV,WAAW,CAAC;AAClD,EAAA;AAQA;EACA,OAAOC,KAAK,CAACU,OAAO,EAAE,CAACC,IAAI,EAAE;AAC/B;;;;"}
@@ -1,24 +0,0 @@
1
- import { bindEntry } from '../bind/bind-entry.js';
2
-
3
- /**
4
- * Binds a service entry to the IoC container for testing purposes.
5
- * This utility uses {@link bindEntry} internally.
6
- * It supports both service classes and injectable descriptors (constants, dynamic values, etc.).
7
- *
8
- * @param container - the IoC container to bind the entry to
9
- * @param entry - the service class or injectable descriptor to bind
10
- * @param options - optional binding configuration
11
- * @returns void
12
- */
13
- function mockBindEntry(container, entry, options) {
14
- if (options === void 0) {
15
- options = {};
16
- }
17
- var skipLifecycle = options.skipLifecycle;
18
- return bindEntry(container, entry, {
19
- isWithIgnoreLifecycle: skipLifecycle
20
- });
21
- }
22
-
23
- export { mockBindEntry };
24
- //# sourceMappingURL=mock-bind-entry.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"mock-bind-entry.js","sources":["../../../../../../../../../src/wirestate-core/test-utils/mock-bind-entry.ts"],"sourcesContent":[null],"names":["mockBindEntry","container","entry","options","skipLifecycle","bindEntry","isWithIgnoreLifecycle"],"mappings":";;AAiBA;;;;;;;;;AASG;SACaA,aAAaA,CAC3BC,SAAoB,EACpBC,KAAwC,EACxCC,OAAkC,EAAA;AAAlC,EAAA,IAAAA,OAAA,KAAA,MAAA,EAAA;IAAAA,OAAA,GAAA,EAAkC;AAAA,EAAA;AAE1B,EAAA,IAAAC,aAAa,GAAKD,OAAO,CAAAC,aAAZ;AAErB,EAAA,OAAOC,SAAS,CAACJ,SAAS,EAAEC,KAAK,EAAE;AACjCI,IAAAA,qBAAqB,EAAEF;AACxB,GAAA,CAAC;AACJ;;;;"}
@@ -1,52 +0,0 @@
1
- import { getEntryToken } from '../bind/get-entry-token.js';
2
- import { createIocContainer } from '../container/create-ioc-container.js';
3
- import { ERROR_CODE_INVALID_ARGUMENTS } from '../error/error-code.js';
4
- import { WirestateError } from '../error/wirestate-error.js';
5
- import { mockBindEntry } from './mock-bind-entry.js';
6
-
7
- /**
8
- * Creates and configures a mock IoC container for testing.
9
- * This utility initializes a new container and binds the provided services or descriptors using {@link mockBindEntry}.
10
- * It also supports optional immediate activation of services.
11
- *
12
- * @param options - configuration options for the mock container
13
- * @returns a configured InversifyJS {@link Container}
14
- *
15
- * @throws {WirestateError} if an identifier in `activate` is not found in `services`
16
- */
17
- function mockContainer(options) {
18
- if (options === void 0) {
19
- options = {};
20
- }
21
- var _a = options.activate,
22
- activate = _a === void 0 ? [] : _a,
23
- _b = options.entries,
24
- entries = _b === void 0 ? [] : _b,
25
- skipLifecycle = options.skipLifecycle;
26
- if (activate.length) {
27
- var serviceTokens = entries.map(function (s) {
28
- return getEntryToken(s);
29
- });
30
- for (var _i = 0, activate_1 = activate; _i < activate_1.length; _i++) {
31
- var token = activate_1[_i];
32
- if (!serviceTokens.includes(token)) {
33
- throw new WirestateError(ERROR_CODE_INVALID_ARGUMENTS, "Provided services for activation not matching list of services to bind.");
34
- }
35
- }
36
- }
37
- var container = createIocContainer();
38
- for (var _c = 0, entries_1 = entries; _c < entries_1.length; _c++) {
39
- var it_1 = entries_1[_c];
40
- mockBindEntry(container, it_1, {
41
- skipLifecycle: skipLifecycle
42
- });
43
- }
44
- for (var _d = 0, activate_2 = activate; _d < activate_2.length; _d++) {
45
- var it_2 = activate_2[_d];
46
- container.get(it_2);
47
- }
48
- return container;
49
- }
50
-
51
- export { mockContainer };
52
- //# sourceMappingURL=mock-container.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"mock-container.js","sources":["../../../../../../../../../src/wirestate-core/test-utils/mock-container.ts"],"sourcesContent":[null],"names":["mockContainer","options","_a","activate","_b","entries","skipLifecycle","length","serviceTokens","map","s","getEntryToken","_i","activate_1","token","includes","WirestateError","ERROR_CODE_INVALID_ARGUMENTS","container","createIocContainer","_c","entries_1","it_1","mockBindEntry","_d","activate_2","it_2","get"],"mappings":";;;;;;AA8BA;;;;;;;;;AASG;AACG,SAAUA,aAAaA,CAACC,OAAkC,EAAA;AAAlC,EAAA,IAAAA,OAAA,KAAA,MAAA,EAAA;IAAAA,OAAA,GAAA,EAAkC;AAAA,EAAA;AACtD,EAAA,IAAAC,EAAA,GAA+CD,OAAO,CAAAE,QAAzC;IAAbA,QAAQ,GAAAD,EAAA,KAAA,MAAA,GAAG,EAAE,GAAAA,EAAA;IAAEE,EAAA,GAAgCH,OAAO,QAA3B;IAAZI,OAAO,mBAAG,EAAE,GAAAD,EAAA;IAAEE,aAAa,GAAKL,OAAO,CAAAK,aAAZ;EAElD,IAAIH,QAAQ,CAACI,MAAM,EAAE;IACnB,IAAMC,aAAa,GAA6BH,OAAO,CAACI,GAAG,CAAC,UAACC,CAAC,EAAA;MAAK,OAAAC,aAAa,CAACD,CAAC,CAAC;AAAhB,IAAA,CAAgB,CAAC;AAEpF,IAAA,KAAoB,IAAAE,EAAA,GAAA,CAAQ,EAARC,UAAA,GAAAV,QAAQ,EAARS,sBAAQ,EAARA,EAAA,EAAQ,EAAE;AAAzB,MAAA,IAAME,KAAK,GAAAD,UAAA,CAAAD,EAAA,CAAA;AACd,MAAA,IAAI,CAACJ,aAAa,CAACO,QAAQ,CAACD,KAAK,CAAC,EAAE;AAClC,QAAA,MAAM,IAAIE,cAAc,CACtBC,4BAA4B,EAC5B,yEAAyE,CAC1E;AACH,MAAA;AACF,IAAA;AACF,EAAA;AAEA,EAAA,IAAMC,SAAS,GAAcC,kBAAkB,EAAE;AAEjD,EAAA,KAAiB,IAAAC,EAAA,GAAA,CAAO,EAAPC,SAAA,GAAAhB,OAAO,EAAPe,qBAAO,EAAPA,EAAA,EAAO,EAAE;AAArB,IAAA,IAAME,IAAE,GAAAD,SAAA,CAAAD,EAAA,CAAA;AACXG,IAAAA,aAAa,CAACL,SAAS,EAAEI,IAAE,EAAE;AAAEhB,MAAAA,aAAa,EAAEA;AAAa,KAAE,CAAC;AAChE,EAAA;AAEA,EAAA,KAAiB,IAAAkB,EAAA,GAAA,CAAQ,EAARC,UAAA,GAAAtB,QAAQ,EAARqB,sBAAQ,EAARA,EAAA,EAAQ,EAAE;AAAtB,IAAA,IAAME,IAAE,GAAAD,UAAA,CAAAD,EAAA,CAAA;AACXN,IAAAA,SAAS,CAACS,GAAG,CAACD,IAAE,CAAC;AACnB,EAAA;AAEA,EAAA,OAAOR,SAAS;AAClB;;;;"}
@@ -1,12 +0,0 @@
1
- /**
2
- * Command execution status.
3
- */
4
- var CommandStatus;
5
- (function (CommandStatus) {
6
- CommandStatus["PENDING"] = "pending";
7
- CommandStatus["SETTLED"] = "settled";
8
- CommandStatus["ERROR"] = "error";
9
- })(CommandStatus || (CommandStatus = {}));
10
-
11
- export { CommandStatus };
12
- //# sourceMappingURL=commands.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"commands.js","sources":["../../../../../../../../../src/wirestate-core/types/commands.ts"],"sourcesContent":[null],"names":["CommandStatus"],"mappings":"AA2BA;;AAEG;IACSA;AAAZ,CAAA,UAAYA,aAAa,EAAA;AACvBA,EAAAA,aAAA,CAAA,SAAA,CAAA,GAAA,SAAmB;AACnBA,EAAAA,aAAA,CAAA,SAAA,CAAA,GAAA,SAAmB;AACnBA,EAAAA,aAAA,CAAA,OAAA,CAAA,GAAA,OAAe;AACjB,CAAC,EAJWA,aAAa,KAAbA,aAAa,GAAA,EAAA,CAAA,CAAA;;;;"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"use-command-caller.js","sources":["../../../../../../../../../src/wirestate-react/commands/use-command-caller.ts"],"sourcesContent":[null],"names":["useCommandCaller","container","useContainer","useCallback","type","data","get","CommandBus","command"],"mappings":";;;;AAQA;;;;AAIG;SACaA,gBAAgBA,GAAA;AAC9B,EAAA,IAAMC,SAAS,GAAcC,YAAY,EAAE;AAE3C,EAAA,OAAOC,WAAW,CAChB,UAAgEC,IAAO,EAAEC,IAAQ,EAAA;AAM/E,IAAA,OAAOJ,SAAS,CAACK,GAAG,CAACC,UAAU,CAAC,CAACC,OAAO,CAAOJ,IAAI,EAAEC,IAAI,CAAC;AAC5D,EAAA,CAAC,EACD,CAACJ,SAAS,CAAC,CACZ;AACH;;;;"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"use-command-handler.js","sources":["../../../../../../../../../src/wirestate-react/commands/use-command-handler.ts"],"sourcesContent":[null],"names":["useCommandHandler","type","handler","container","useContainer","handlerRef","useRef","useEffect","current","get","CommandBus","register","data"],"mappings":";;;;AAKA;;;;;;;AAOG;AACG,SAAUA,iBAAiBA,CAA2BC,IAAiB,EAAEC,OAA6B,EAAA;AAC1G,EAAA,IAAMC,SAAS,GAAcC,YAAY,EAAE;AAC3C,EAAA,IAAMC,UAAU,GAAGC,MAAM,CAAuBJ,OAAO,CAAC;AAExD;AACAK,EAAAA,SAAS,CAAC,YAAA;IACRF,UAAU,CAACG,OAAO,GAAGN,OAAO;AAC9B,EAAA,CAAC,CAAC;AAEFK,EAAAA,SAAS,CAAC,YAAA;AACR,IAAA,OAAOJ,SAAS,CAACM,GAAG,CAACC,UAAU,CAAC,CAACC,QAAQ,CAAOV,IAAI,EAAE,UAACW,IAAI,EAAA;AAAK,MAAA,OAAAP,UAAU,CAACG,OAAO,CAACI,IAAI,CAAC;AAAxB,IAAA,CAAwB,CAAC;AAC3F,EAAA,CAAC,EAAE,CAACT,SAAS,EAAEF,IAAI,CAAC,CAAC;AACvB;;;;"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"use-optional-command-caller.js","sources":["../../../../../../../../../src/wirestate-react/commands/use-optional-command-caller.ts"],"sourcesContent":[null],"names":["useOptionalCommandCaller","container","useContainer","useCallback","type","data","get","CommandBus","commandOptional"],"mappings":";;;;AAQA;;;;;AAKG;SACaA,wBAAwBA,GAAA;AACtC,EAAA,IAAMC,SAAS,GAAcC,YAAY,EAAE;AAE3C,EAAA,OAAOC,WAAW,CAChB,UAAgEC,IAAO,EAAEC,IAAQ,EAAA;AAM/E,IAAA,OAAOJ,SAAS,CAACK,GAAG,CAACC,UAAU,CAAC,CAACC,eAAe,CAAOJ,IAAI,EAAEC,IAAI,CAAC;AACpE,EAAA,CAAC,EACD,CAACJ,SAAS,CAAC,CACZ;AACH;;;;"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"error-code.js","sources":["../../../../../../../../../src/wirestate-react/error/error-code.ts"],"sourcesContent":[null],"names":["ERROR_CODE_VALIDATION_ERROR","ERROR_CODE_INVALID_CONTEXT","ERROR_CODE_FAILED_TO_RESOLVE_QUERY_HANDLER"],"mappings":"AAAO,IAAMA,2BAA2B,GAAW;AAC5C,IAAMC,0BAA0B,GAAW;AAE3C,IAAMC,0CAA0C,GAAW;;;;"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"use-event-emitter.js","sources":["../../../../../../../../../src/wirestate-react/events/use-event-emitter.ts"],"sourcesContent":[null],"names":["useEventEmitter","container","useIocContext","useCallback","type","payload","from","get","EventBus","emit"],"mappings":";;;;AASA;;;;AAIG;SACaA,eAAeA,GAAA;AAC7B,EAAA,IAAMC,SAAS,GAAcC,aAAa,EAAE,CAACD,SAAS;EAEtD,OAAOE,WAAW,CAChB,UAAyBC,IAAO,EAAEC,OAAW,EAAEC,IAAc,EAAA;AAO3DL,IAAAA,SAAS,CAACM,GAAG,CAACC,QAAQ,CAAC,CAACC,IAAI,CAAC;AAAEL,MAAAA,IAAI,EAAAA,IAAA;AAAEC,MAAAA,OAAO,EAAAA,OAAA;AAAEC,MAAAA,IAAI,EAAAA;AAAA,KAAE,CAAC;AACvD,EAAA,CAAC,EACD,CAACL,SAAS,CAAC,CACZ;AACH;;;;"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"use-event.js","sources":["../../../../../../../../../src/wirestate-react/events/use-event.ts"],"sourcesContent":[null],"names":["useEvent","type","handler","typeRef","useRef","handlerRef","container","useContainer","useEffect","current","get","EventBus","subscribe","event","_a","call"],"mappings":";;;;AAKA;;;;;AAKG;AACG,SAAUA,QAAQA,CAACC,IAAe,EAAEC,OAAqB,EAAA;AAC7D,EAAA,IAAMC,OAAO,GAAgCC,MAAM,CAACH,IAAI,CAAC;AACzD,EAAA,IAAMI,UAAU,GAAmCD,MAAM,CAACF,OAAO,CAAC;AAClE,EAAA,IAAMI,SAAS,GAAcC,YAAY,EAAE;AAE3CC,EAAAA,SAAS,CAAC,YAAA;IACRL,OAAO,CAACM,OAAO,GAAGR,IAAI;IACtBI,UAAU,CAACI,OAAO,GAAGP,OAAO;AAC9B,EAAA,CAAC,CAAC;AAEFM,EAAAA,SAAS,CAAC,YAAA;IACR,OAAOF,SAAS,CAACI,GAAG,CAACC,QAAQ,CAAC,CAACC,SAAS,CAAC,UAACC,KAAK,EAAA;;AAC7C,MAAA,IAAIA,KAAK,CAACZ,IAAI,KAAKE,OAAO,CAACM,OAAO,EAAE;QAClC,CAAAK,EAAA,GAAAT,UAAU,CAACI,OAAO,MAAA,IAAA,IAAAK,EAAA,KAAA,MAAA,GAAA,MAAA,GAAAA,EAAA,CAAAC,IAAA,CAAAV,UAAA,EAAGQ,KAAK,CAAC;AAC7B,MAAA;AACF,IAAA,CAAC,CAAC;AACJ,EAAA,CAAC,EAAE,CAACP,SAAS,EAAEL,IAAI,CAAC,CAAC;AACvB;;;;"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"use-events-handler.js","sources":["../../../../../../../../../src/wirestate-react/events/use-events-handler.ts"],"sourcesContent":[null],"names":["useEventsHandler","handler","handlerRef","useRef","container","useContainer","useEffect","current","get","EventBus","subscribe","event","_a","call"],"mappings":";;;;AAMA;;;;AAIG;AACG,SAAUA,gBAAgBA,CAACC,OAAqB,EAAA;AACpD,EAAA,IAAMC,UAAU,GAA0CC,MAAM,CAACF,OAAO,CAAC;AACzE,EAAA,IAAMG,SAAS,GAAcC,YAAY,EAAE;AAE3CC,EAAAA,SAAS,CAAC,YAAA;IACRJ,UAAU,CAACK,OAAO,GAAGN,OAAO;AAC9B,EAAA,CAAC,CAAC;AAEFK,EAAAA,SAAS,CAAC,YAAA;IACR,OAAOF,SAAS,CAACI,GAAG,CAACC,QAAQ,CAAC,CAACC,SAAS,CAAC,UAACC,KAAK,EAAA;;MAC7C,CAAAC,EAAA,GAAAV,UAAU,CAACK,OAAO,MAAA,IAAA,IAAAK,EAAA,KAAA,MAAA,GAAA,MAAA,GAAAA,EAAA,CAAAC,IAAA,CAAAX,UAAA,EAAGS,KAAK,CAAC;AAC7B,IAAA,CAAC,CAAC;AACJ,EAAA,CAAC,EAAE,CAACP,SAAS,CAAC,CAAC;AACjB;;;;"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"use-events.js","sources":["../../../../../../../../../src/wirestate-react/events/use-events.ts"],"sourcesContent":[null],"names":["useEvents","types","handler","typesRef","useRef","handlerRef","container","useContainer","useEffect","current","get","EventBus","subscribe","event","includes","type","_a","call"],"mappings":";;;;AAKA;;;;;AAKG;AACG,SAAUA,SAASA,CAACC,KAA+B,EAAEC,OAAqB,EAAA;AAC9E,EAAA,IAAMC,QAAQ,GAA+CC,MAAM,CAACH,KAAK,CAAC;AAC1E,EAAA,IAAMI,UAAU,GAAmCD,MAAM,CAACF,OAAO,CAAC;AAClE,EAAA,IAAMI,SAAS,GAAcC,YAAY,EAAE;AAE3CC,EAAAA,SAAS,CAAC,YAAA;IACRL,QAAQ,CAACM,OAAO,GAAGR,KAAK;IACxBI,UAAU,CAACI,OAAO,GAAGP,OAAO;AAC9B,EAAA,CAAC,CAAC;AAEFM,EAAAA,SAAS,CAAC,YAAA;IACR,OAAOF,SAAS,CAACI,GAAG,CAACC,QAAQ,CAAC,CAACC,SAAS,CAAC,UAACC,KAAK,EAAA;;MAC7C,IAAIV,QAAQ,CAACM,OAAO,CAACK,QAAQ,CAACD,KAAK,CAACE,IAAI,CAAC,EAAE;QACzC,CAAAC,EAAA,GAAAX,UAAU,CAACI,OAAO,MAAA,IAAA,IAAAO,EAAA,KAAA,MAAA,GAAA,MAAA,GAAAA,EAAA,CAAAC,IAAA,CAAAZ,UAAA,EAAGQ,KAAK,CAAC;AAC7B,MAAA;AACF,IAAA,CAAC,CAAC;AACJ,EAAA,CAAC,EAAE,CAACP,SAAS,CAAC,CAAC;AACjB;;;;"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"create-injectables-provider.js","sources":["../../../../../../../../../src/wirestate-react/provision/create-injectables-provider.ts"],"sourcesContent":[null],"names":["createInjectablesProvider","entries","options","activate","length","entryTokens","map","getEntryToken","_i","activate_1","eager","includes","WirestateError","ERROR_CODE_VALIDATION_ERROR","concat","String","InjectablesProviderComponent","props","iocContext","useContext","IocReactContext","ERROR_CODE_INVALID_CONTEXT","initialPropsSnapshot","useState","useMemo","seeds","applySeeds","container","entries_1","entry","isBound","bindEntry","_a","activate_2","get","useEffect","didRebind","entries_2","activate_3","setRevision","r","entries_3","token","unbind","unapplySeeds","children","displayName"],"mappings":";;;;;AAmDA;;;;;;AAMG;AACG,SAAUA,yBAAyBA,CACvCC,OAA8D,EAC9DC,OAA8C,EAAA;AAA9C,EAAA,IAAAA,OAAA,KAAA,MAAA,EAAA;IAAAA,OAAA,GAAA,EAA8C;AAAA,EAAA;AAItC,EAAA,IAAAC,QAAQ,GAAKD,OAAO,CAAAC,QAAZ;AAEhB,EAAA,IAAIA,QAAQ,IAAIA,QAAQ,CAACC,MAAM,GAAG,CAAC,EAAE;AACnC,IAAA,IAAMC,WAAW,GAAqCJ,OAAO,CAACK,GAAG,CAACC,aAAa,CAAC;AAEhF,IAAA,KAAoB,IAAAC,EAAA,GAAA,CAAQ,EAARC,UAAA,GAAAN,QAAQ,EAARK,sBAAQ,EAARA,EAAA,EAA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K,OAAAA,CAAC,GAAG,CAAC;AAAL,QAAA,CAAK,CAAC;AACtC,MAAA;AAEA,MAAA,OAAO,YAAA;AAOL,QAAA,KAAoB,IAAAhC,EAAA,GAAA,CAAO,EAAPiC,SAAA,GAAAxC,OAAO,EAAPO,qBAAO,EAAPA,EAAA,EAAO,EAAE;AAAxB,UAAA,IAAMqB,KAAK,GAAAY,SAAA,CAAAjC,EAAA,CAAA;AACd,UAAA,IAAMkC,KAAK,GAAsBnC,aAAa,CAACsB,KAAK,CAAC;UAErD,IAAIX,UAAU,CAACS,SAAS,CAACG,OAAO,CAACY,KAAK,CAAC,EAAE;AACvCxB,YAAAA,UAAU,CAACS,SAAS,CAACgB,MAAM,CAACD,KAAK,CAAC;AACpC,UAAA;AACF,QAAA;AAEA;QACA,IAAIpB,oBAAoB,CAACG,KAAK,EAAE;UAC9BmB,YAAY,CAAC1B,UAAU,CAACS,SAAS,EAAEL,oBAAoB,CAACG,KAAK,CAAC;AAChE,QAAA;MACF,CAAC;IACH,CAAC,EAAExB,OAAO,CAAC;IAEX,OAAOgB,KAAK,CAAC4B,QAAwB;AACvC,EAAA;EAEA7B,4BAA4B,CAAC8B,WAAW,GAAG,qBAAqB;AAIhE,EAAA,OAAO9B,4BAA4B;AACrC;;;;"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"ioc-context.js","sources":["../../../../../../../../../src/wirestate-react/provision/ioc-context.ts"],"sourcesContent":[null],"names":["IocReactContext","createContext","displayName"],"mappings":";;AAuBA;;;AAGG;IACUA,eAAe,GAAkCC,aAAa,CAAuB,IAAI;AAEtGD,eAAe,CAACE,WAAW,GAAG,YAAY;;;;"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"ioc-provider.js","sources":["../../../../../../../../../src/wirestate-react/provision/ioc-provider.ts"],"sourcesContent":[null],"names":["IocProvider","_a","externalContainer","seed","children","_b","useState","revision","setRevision","ownedContainer","createIocContainer","container","WirestateError","ERROR_CODE_FAILED_TO_RESOLVE_QUERY_HAND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AAQ,EAAE;AAAEN,IAAAA,KAAK,EAAAA;GAAE,EAAEV,QAAQ,CAAC;AACrE;;;;"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"use-container-revision.js","sources":["../../../../../../../../../src/wirestate-react/provision/use-container-revision.ts"],"sourcesContent":[null],"names":["useContainerRevision","useIocContext","revision"],"mappings":";;AAEA;;;;AAIG;SACaA,oBAAoBA,GAAA;AAClC,EAAA,OAAOC,aAAa,EAAE,CAACC,QAAQ;AACjC;;;;"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"use-container.js","sources":["../../../../../../../../../src/wirestate-react/provision/use-container.ts"],"sourcesContent":[null],"names":["useContainer","useIocContext","container"],"mappings":";;AAIA;;;;AAIG;SACaA,YAAYA,GAAA;AAC1B,EAAA,OAAOC,aAAa,EAAE,CAACC,SAAS;AAClC;;;;"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"use-injection.js","sources":["../../../../../../../../../src/wirestate-react/provision/use-injection.ts"],"sourcesContent":[null],"names":["useInjection","injectionId","_a","useIocContext","container","revision","useMemo","get"],"mappings":";;;AAUA;;;;;;AAMG;AACG,SAAUA,YAAYA,CAAIC,WAAiC,EAAA;AACzD,EAAA,IAAAC,EAAA,GAA0BC,aAAa,EAAE;IAAvCC,SAAS,GAAAF,EAAA,CAAAE,SAAA;IAAEC,QAAQ,GAAAH,EAAA,CAAAG,QAAoB;AAE/C;EACA,OAAOC,OAAO,CAAC,YAAA;AAQb,IAAA,OAAOF,SAAS,CAACG,GAAG,CAAIN,WAAW,CAAC;EACtC,CAAC,EAAE,CAACG,SAAS,EAAEC,QAAQ,EAAEJ,WAAW,CAAC,CAAC;AACxC;;;;"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"use-ioc-context.js","sources":["../../../../../../../../../src/wirestate-react/provision/use-ioc-context.ts"],"sourcesContent":[null],"names":["useIocContext","value","useContext","IocReactContext","WirestateError","ERROR_CODE_INVALID_CONTEXT"],"mappings":";;;;;AAOA;;;;;AAKG;SACaA,aAAaA,GAAA;AAC3B,EAAA,IAAMC,KAAK,GAAGC,UAAU,CAACC,eAAe,CAAC;EAEzC,IAAI,CAACF,KAAK,EAAE;AACV,IAAA,MAAM,IAAIG,cAAc,CACtBC,0BAA0B,EAC1B,+EAA+E,CAChF;AACH,EAAA;AAEA,EAAA,OAAOJ,KAAK;AACd;;;;"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"use-optional-injection.js","sources":["../../../../../../../../../src/wirestate-react/provision/use-optional-injection.ts"],"sourcesContent":[null],"names":["useOptionalInjection","injectionId","onFallback","_a","useIocContext","container","revision","useMemo","isBound","get"],"mappings":";;;AAUA;;;;;;;AAOG;AACG,SAAUA,oBAAoBA,CAClCC,WAAiC,EACjCC,UAAwC,EAAA;AAElC,EAAA,IAAAC,EAAA,GAA0BC,aAAa,EAAE;IAAvCC,SAAS,GAAAF,EAAA,CAAAE,SAAA;IAAEC,QAAQ,GAAAH,EAAA,CAAAG,QAAoB;AAE/C;EACA,OAAOC,OAAO,CAAC,YAAA;AACb,IAAA,IAAIF,SAAS,CAACG,OAAO,CAACP,WAAW,CAAC,EAAE;AASlC,MAAA,OAAOI,SAAS,CAACI,GAAG,CAAIR,WAAW,CAAC;IACtC,CAAC,MAAM,IAAIC,UAAU,EAAE;MASrB,OAAOA,UAAU,CAACG,SAAS,CAAC;AAC9B,IAAA,CAAC,MAAM;AASL,MAAA,OAAO,IAAI;AACb,IAAA;EACF,CAAC,EAAE,CAACA,SAAS,EAAEC,QAAQ,EAAEL,WAAW,CAAC,CAAC;AACxC;;;;"}