@dereekb/dbx-core 11.1.8 → 12.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 (279) hide show
  1. package/esm2022/lib/action/action.holder.mjs +1 -1
  2. package/esm2022/lib/action/action.machine.mjs +5 -5
  3. package/esm2022/lib/action/action.mjs +1 -1
  4. package/esm2022/lib/action/action.module.mjs +14 -13
  5. package/esm2022/lib/action/action.store.mjs +22 -10
  6. package/esm2022/lib/action/action.store.source.mjs +4 -1
  7. package/esm2022/lib/action/directive/auto/action.automodify.directive.mjs +24 -32
  8. package/esm2022/lib/action/directive/auto/action.autotrigger.directive.mjs +74 -87
  9. package/esm2022/lib/action/directive/auto/index.mjs +1 -2
  10. package/esm2022/lib/action/directive/context/action.directive.mjs +7 -6
  11. package/esm2022/lib/action/directive/context/action.source.directive.mjs +12 -25
  12. package/esm2022/lib/action/directive/debug/action.logger.directive.mjs +6 -5
  13. package/esm2022/lib/action/directive/map/action.map.directive.mjs +21 -65
  14. package/esm2022/lib/action/directive/map/action.map.key.directive.mjs +9 -8
  15. package/esm2022/lib/action/directive/map/action.map.mjs +54 -1
  16. package/esm2022/lib/action/directive/map/action.map.source.directive.mjs +10 -9
  17. package/esm2022/lib/action/directive/map/action.map.utility.mjs +37 -0
  18. package/esm2022/lib/action/directive/map/action.map.working.disable.directive.mjs +16 -16
  19. package/esm2022/lib/action/directive/map/index.mjs +2 -1
  20. package/esm2022/lib/action/directive/state/action.disabled.directive.mjs +6 -5
  21. package/esm2022/lib/action/directive/state/action.disableonsuccess.directive.mjs +6 -5
  22. package/esm2022/lib/action/directive/state/action.enforce.modified.directive.mjs +6 -5
  23. package/esm2022/lib/action/directive/state/action.handler.directive.mjs +29 -43
  24. package/esm2022/lib/action/directive/state/action.handler.instance.mjs +12 -14
  25. package/esm2022/lib/action/directive/state/action.presuccess.directive.mjs +6 -5
  26. package/esm2022/lib/action/directive/state/action.success.directive.mjs +6 -5
  27. package/esm2022/lib/action/directive/state/action.success.handler.directive.mjs +12 -23
  28. package/esm2022/lib/action/directive/state/action.value.directive.mjs +23 -24
  29. package/esm2022/lib/action/directive/state/action.value.stream.directive.mjs +22 -36
  30. package/esm2022/lib/action/directive/state/action.value.trigger.directive.mjs +50 -42
  31. package/esm2022/lib/action/directive/state/action.value.trigger.instance.mjs +27 -15
  32. package/esm2022/lib/action/directive/state/action.working.directive.mjs +35 -0
  33. package/esm2022/lib/action/directive/state/index.mjs +3 -2
  34. package/esm2022/lib/auth/auth.module.mjs +13 -7
  35. package/esm2022/lib/auth/auth.providers.mjs +16 -0
  36. package/esm2022/lib/auth/auth.role.any.directive.mjs +13 -14
  37. package/esm2022/lib/auth/auth.role.has.directive.mjs +13 -14
  38. package/esm2022/lib/auth/auth.role.not.directive.mjs +13 -14
  39. package/esm2022/lib/auth/auth.state.providers.mjs +14 -0
  40. package/esm2022/lib/auth/auth.state.service.mjs +3 -3
  41. package/esm2022/lib/auth/index.mjs +3 -2
  42. package/esm2022/lib/auth/router/auth.router.module.mjs +4 -4
  43. package/esm2022/lib/auth/router/auth.router.providers.mjs +19 -0
  44. package/esm2022/lib/auth/router/auth.router.service.mjs +5 -5
  45. package/esm2022/lib/auth/router/index.mjs +2 -1
  46. package/esm2022/lib/auth/router/provider/uirouter/hook.mjs +1 -1
  47. package/esm2022/lib/auth/router/provider/uirouter/redirect.mjs +1 -1
  48. package/esm2022/lib/auth/router/provider/uirouter/role.hook.mjs +1 -1
  49. package/esm2022/lib/auth/router/provider/uirouter/state.hook.mjs +1 -1
  50. package/esm2022/lib/auth/router/state/auth.router.state.module.mjs +10 -9
  51. package/esm2022/lib/auth/router/state/auth.router.state.providers.mjs +23 -0
  52. package/esm2022/lib/auth/router/state/effect/auth.router.state.effect.mjs +4 -4
  53. package/esm2022/lib/auth/router/state/index.mjs +2 -1
  54. package/esm2022/lib/auth/state/effect/auth.effect.mjs +5 -5
  55. package/esm2022/lib/button/action/action.button.directive.mjs +9 -12
  56. package/esm2022/lib/button/action/action.button.trigger.directive.mjs +7 -6
  57. package/esm2022/lib/button/button.directive.mjs +51 -60
  58. package/esm2022/lib/button/button.loading.directive.mjs +19 -20
  59. package/esm2022/lib/button/button.mjs +3 -3
  60. package/esm2022/lib/button/button.module.mjs +16 -8
  61. package/esm2022/lib/button/router/button.segue.directive.mjs +8 -7
  62. package/esm2022/lib/context/context.directive.mjs +7 -6
  63. package/esm2022/lib/context/context.mjs +8 -5
  64. package/esm2022/lib/context/context.module.mjs +9 -10
  65. package/esm2022/lib/context/context.providers.mjs +12 -0
  66. package/esm2022/lib/context/context.service.mjs +3 -3
  67. package/esm2022/lib/context/index.mjs +2 -1
  68. package/esm2022/lib/environment/environment.mjs +6 -0
  69. package/esm2022/lib/environment/environment.providers.mjs +19 -0
  70. package/esm2022/lib/environment/environment.service.mjs +30 -0
  71. package/esm2022/lib/environment/index.mjs +4 -3
  72. package/esm2022/lib/filter/filter.abstract.connector.directive.mjs +4 -4
  73. package/esm2022/lib/filter/filter.abstract.source.directive.mjs +31 -20
  74. package/esm2022/lib/filter/filter.connect.source.directive.mjs +6 -5
  75. package/esm2022/lib/filter/filter.connector.directive.mjs +6 -5
  76. package/esm2022/lib/filter/filter.map.connector.directive.mjs +12 -18
  77. package/esm2022/lib/filter/filter.map.directive.mjs +6 -5
  78. package/esm2022/lib/filter/filter.map.instance.directive.mjs +13 -10
  79. package/esm2022/lib/filter/filter.map.source.directive.mjs +22 -18
  80. package/esm2022/lib/filter/filter.module.mjs +8 -10
  81. package/esm2022/lib/filter/filter.source.directive.mjs +6 -5
  82. package/esm2022/lib/injection/injection.array.component.mjs +18 -31
  83. package/esm2022/lib/injection/injection.component.mjs +17 -23
  84. package/esm2022/lib/injection/injection.component.module.mjs +13 -9
  85. package/esm2022/lib/injection/injection.context.directive.mjs +7 -6
  86. package/esm2022/lib/injection/injection.context.forward.directive.mjs +3 -3
  87. package/esm2022/lib/injection/injection.directive.mjs +4 -4
  88. package/esm2022/lib/injection/injection.instance.mjs +7 -4
  89. package/esm2022/lib/injection/injection.mjs +1 -1
  90. package/esm2022/lib/injection/injection.rxjs.mjs +1 -1
  91. package/esm2022/lib/ngrx/store.lockset.mjs +6 -6
  92. package/esm2022/lib/pipe/async/asobservable.pipe.mjs +8 -5
  93. package/esm2022/lib/pipe/async/async.pipe.module.mjs +10 -7
  94. package/esm2022/lib/pipe/date/date.pipe.module.mjs +29 -8
  95. package/esm2022/lib/pipe/date/datedayrange.pipe.mjs +9 -5
  96. package/esm2022/lib/pipe/date/datedaytimerange.pipe.mjs +9 -5
  97. package/esm2022/lib/pipe/date/datedistance.pipe.mjs +9 -5
  98. package/esm2022/lib/pipe/date/dateformatdistance.pipe.mjs +9 -5
  99. package/esm2022/lib/pipe/date/datefromtoformat.pipe.mjs +9 -5
  100. package/esm2022/lib/pipe/date/daterangedistance.pipe.mjs +9 -5
  101. package/esm2022/lib/pipe/date/datetimerange.pipe.mjs +9 -5
  102. package/esm2022/lib/pipe/date/datetimerangeonly.pipe.mjs +9 -5
  103. package/esm2022/lib/pipe/date/datetimerangeonlydistance.pipe.mjs +9 -5
  104. package/esm2022/lib/pipe/date/minutesstring.pipe.mjs +9 -5
  105. package/esm2022/lib/pipe/date/systemdatetotargetdate.pipe.mjs +9 -5
  106. package/esm2022/lib/pipe/date/targetdatetosystemdate.pipe.mjs +9 -5
  107. package/esm2022/lib/pipe/date/timedistance.pipe.mjs +17 -9
  108. package/esm2022/lib/pipe/date/timezoneabbreviation.pipe.mjs +9 -5
  109. package/esm2022/lib/pipe/date/tojsdate.pipe.mjs +9 -5
  110. package/esm2022/lib/pipe/date/tominutes.pipe.mjs +9 -5
  111. package/esm2022/lib/pipe/misc/misc.pipe.module.mjs +12 -7
  112. package/esm2022/lib/pipe/misc/prettyjson.pipe.mjs +8 -5
  113. package/esm2022/lib/pipe/pipe.module.mjs +13 -6
  114. package/esm2022/lib/pipe/value/cuttext.pipe.mjs +9 -5
  115. package/esm2022/lib/pipe/value/dollar.pipe.mjs +9 -5
  116. package/esm2022/lib/pipe/value/getvalue.pipe.mjs +9 -7
  117. package/esm2022/lib/pipe/value/value.pipe.module.mjs +16 -8
  118. package/esm2022/lib/router/anchor/anchor.directive.mjs +12 -5
  119. package/esm2022/lib/router/anchor/anchor.mjs +7 -20
  120. package/esm2022/lib/router/anchor/clickable.mjs +1 -1
  121. package/esm2022/lib/router/auth/hook/id.hook.mjs +1 -1
  122. package/esm2022/lib/router/model/id.param.redirect.mjs +1 -1
  123. package/esm2022/lib/router/model/model.module.mjs +15 -9
  124. package/esm2022/lib/router/model/model.router.id.directive.mjs +6 -5
  125. package/esm2022/lib/router/model/model.router.key.directive.mjs +6 -5
  126. package/esm2022/lib/router/model/model.router.uid.directive.mjs +6 -5
  127. package/esm2022/lib/router/router/provider/angular/angular.router.service.mjs +4 -4
  128. package/esm2022/lib/router/router/provider/angular/angular.router.service.module.mjs +7 -6
  129. package/esm2022/lib/router/router/provider/uirouter/index.mjs +2 -1
  130. package/esm2022/lib/router/router/provider/uirouter/uirouter.router.service.mjs +5 -5
  131. package/esm2022/lib/router/router/provider/uirouter/uirouter.router.service.module.mjs +8 -5
  132. package/esm2022/lib/router/router/provider/uirouter/uirouter.router.service.providers.mjs +24 -0
  133. package/esm2022/lib/router/router/service/router.service.rxjs.mjs +1 -1
  134. package/esm2022/lib/router/router/transition/transition.directive.mjs +3 -3
  135. package/esm2022/lib/router/router/transition/transition.watcher.directive.mjs +4 -4
  136. package/esm2022/lib/router/router/util/route.default.mjs +1 -1
  137. package/esm2022/lib/router/segue.mjs +1 -1
  138. package/esm2022/lib/storage/index.mjs +2 -2
  139. package/esm2022/lib/storage/storage.accessor.simple.factory.mjs +3 -3
  140. package/esm2022/lib/storage/storage.accessor.simple.mjs +1 -1
  141. package/esm2022/lib/storage/storage.object.localstorage.mjs +1 -1
  142. package/esm2022/lib/storage/storage.providers.mjs +41 -0
  143. package/esm2022/lib/subscription/subscription.directive.mjs +7 -7
  144. package/esm2022/lib/util/view.mjs +9 -1
  145. package/esm2022/lib/view/if.directive.mjs +4 -4
  146. package/fesm2022/dereekb-dbx-core.mjs +2483 -2234
  147. package/fesm2022/dereekb-dbx-core.mjs.map +1 -1
  148. package/lib/action/action.module.d.ts +5 -3
  149. package/lib/action/action.store.d.ts +18 -9
  150. package/lib/action/action.store.source.d.ts +1 -0
  151. package/lib/action/directive/auto/action.automodify.directive.d.ts +4 -6
  152. package/lib/action/directive/auto/action.autotrigger.directive.d.ts +15 -32
  153. package/lib/action/directive/auto/index.d.ts +0 -1
  154. package/lib/action/directive/context/action.directive.d.ts +1 -1
  155. package/lib/action/directive/context/action.source.directive.d.ts +3 -7
  156. package/lib/action/directive/debug/action.logger.directive.d.ts +1 -1
  157. package/lib/action/directive/map/action.map.d.ts +31 -1
  158. package/lib/action/directive/map/action.map.directive.d.ts +4 -24
  159. package/lib/action/directive/map/action.map.key.directive.d.ts +3 -3
  160. package/lib/action/directive/map/action.map.source.directive.d.ts +2 -2
  161. package/lib/action/directive/map/action.map.utility.d.ts +48 -0
  162. package/lib/action/directive/map/action.map.working.disable.directive.d.ts +4 -4
  163. package/lib/action/directive/map/index.d.ts +1 -0
  164. package/lib/action/directive/state/action.disabled.directive.d.ts +1 -1
  165. package/lib/action/directive/state/action.disableonsuccess.directive.d.ts +1 -1
  166. package/lib/action/directive/state/action.enforce.modified.directive.d.ts +1 -1
  167. package/lib/action/directive/state/action.handler.directive.d.ts +12 -13
  168. package/lib/action/directive/state/action.handler.instance.d.ts +4 -4
  169. package/lib/action/directive/state/action.presuccess.directive.d.ts +1 -1
  170. package/lib/action/directive/state/action.success.directive.d.ts +1 -1
  171. package/lib/action/directive/state/action.success.handler.directive.d.ts +2 -5
  172. package/lib/action/directive/state/action.value.directive.d.ts +10 -5
  173. package/lib/action/directive/state/action.value.stream.directive.d.ts +11 -11
  174. package/lib/action/directive/state/action.value.trigger.directive.d.ts +23 -17
  175. package/lib/action/directive/state/action.value.trigger.instance.d.ts +28 -17
  176. package/lib/action/directive/state/{action.working.component.d.ts → action.working.directive.d.ts} +1 -1
  177. package/lib/action/directive/state/index.d.ts +2 -1
  178. package/lib/auth/auth.module.d.ts +8 -1
  179. package/lib/auth/auth.providers.d.ts +12 -0
  180. package/lib/auth/auth.role.any.directive.d.ts +7 -7
  181. package/lib/auth/auth.role.has.directive.d.ts +7 -7
  182. package/lib/auth/auth.role.not.directive.d.ts +7 -7
  183. package/lib/auth/auth.state.providers.d.ts +7 -0
  184. package/lib/auth/index.d.ts +2 -1
  185. package/lib/auth/router/auth.router.providers.d.ts +18 -0
  186. package/lib/auth/router/index.d.ts +1 -0
  187. package/lib/auth/router/state/auth.router.state.module.d.ts +4 -2
  188. package/lib/auth/router/state/auth.router.state.providers.d.ts +19 -0
  189. package/lib/auth/router/state/index.d.ts +1 -0
  190. package/lib/auth/state/action/auth.action.d.ts +3 -3
  191. package/lib/auth/state/action/user.action.d.ts +4 -4
  192. package/lib/auth/state/effect/auth.effect.d.ts +9 -9
  193. package/lib/auth/state/reducer/user.reducer.d.ts +1 -1
  194. package/lib/button/action/action.button.directive.d.ts +3 -4
  195. package/lib/button/action/action.button.trigger.directive.d.ts +2 -2
  196. package/lib/button/button.d.ts +55 -14
  197. package/lib/button/button.directive.d.ts +25 -18
  198. package/lib/button/button.loading.directive.d.ts +7 -9
  199. package/lib/button/button.module.d.ts +9 -1
  200. package/lib/button/router/button.segue.directive.d.ts +4 -3
  201. package/lib/context/context.d.ts +7 -4
  202. package/lib/context/context.directive.d.ts +1 -1
  203. package/lib/context/context.module.d.ts +4 -2
  204. package/lib/context/context.providers.d.ts +7 -0
  205. package/lib/context/index.d.ts +1 -0
  206. package/lib/context/state/action/data.action.d.ts +2 -2
  207. package/lib/context/state/reducer/data.reducer.d.ts +1 -1
  208. package/lib/environment/environment.providers.d.ts +8 -0
  209. package/lib/environment/index.d.ts +3 -2
  210. package/lib/filter/filter.abstract.connector.directive.d.ts +1 -1
  211. package/lib/filter/filter.abstract.source.directive.d.ts +14 -10
  212. package/lib/filter/filter.connect.source.directive.d.ts +1 -1
  213. package/lib/filter/filter.connector.directive.d.ts +1 -1
  214. package/lib/filter/filter.map.connector.directive.d.ts +6 -6
  215. package/lib/filter/filter.map.directive.d.ts +1 -1
  216. package/lib/filter/filter.map.instance.directive.d.ts +4 -5
  217. package/lib/filter/filter.map.source.directive.d.ts +13 -6
  218. package/lib/filter/filter.module.d.ts +1 -2
  219. package/lib/filter/filter.source.directive.d.ts +1 -1
  220. package/lib/injection/injection.array.component.d.ts +3 -9
  221. package/lib/injection/injection.component.d.ts +8 -4
  222. package/lib/injection/injection.component.module.d.ts +8 -3
  223. package/lib/injection/injection.context.directive.d.ts +2 -2
  224. package/lib/injection/injection.d.ts +8 -8
  225. package/lib/injection/injection.directive.d.ts +4 -3
  226. package/lib/injection/injection.instance.d.ts +5 -4
  227. package/lib/pipe/async/asobservable.pipe.d.ts +1 -1
  228. package/lib/pipe/async/async.pipe.module.d.ts +4 -1
  229. package/lib/pipe/date/date.pipe.module.d.ts +22 -1
  230. package/lib/pipe/date/datedayrange.pipe.d.ts +1 -1
  231. package/lib/pipe/date/datedaytimerange.pipe.d.ts +1 -1
  232. package/lib/pipe/date/datedistance.pipe.d.ts +1 -1
  233. package/lib/pipe/date/dateformatdistance.pipe.d.ts +2 -2
  234. package/lib/pipe/date/datefromtoformat.pipe.d.ts +2 -2
  235. package/lib/pipe/date/daterangedistance.pipe.d.ts +1 -1
  236. package/lib/pipe/date/datetimerange.pipe.d.ts +1 -1
  237. package/lib/pipe/date/datetimerangeonly.pipe.d.ts +1 -1
  238. package/lib/pipe/date/datetimerangeonlydistance.pipe.d.ts +1 -1
  239. package/lib/pipe/date/minutesstring.pipe.d.ts +1 -1
  240. package/lib/pipe/date/systemdatetotargetdate.pipe.d.ts +1 -1
  241. package/lib/pipe/date/targetdatetosystemdate.pipe.d.ts +1 -1
  242. package/lib/pipe/date/timedistance.pipe.d.ts +2 -2
  243. package/lib/pipe/date/timezoneabbreviation.pipe.d.ts +1 -1
  244. package/lib/pipe/date/tojsdate.pipe.d.ts +1 -1
  245. package/lib/pipe/date/tominutes.pipe.d.ts +1 -1
  246. package/lib/pipe/misc/misc.pipe.module.d.ts +6 -1
  247. package/lib/pipe/misc/prettyjson.pipe.d.ts +1 -1
  248. package/lib/pipe/pipe.module.d.ts +6 -1
  249. package/lib/pipe/value/cuttext.pipe.d.ts +1 -1
  250. package/lib/pipe/value/dollar.pipe.d.ts +1 -1
  251. package/lib/pipe/value/getvalue.pipe.d.ts +2 -2
  252. package/lib/pipe/value/value.pipe.module.d.ts +9 -1
  253. package/lib/router/anchor/anchor.d.ts +26 -28
  254. package/lib/router/anchor/anchor.directive.d.ts +12 -6
  255. package/lib/router/anchor/clickable.d.ts +3 -3
  256. package/lib/router/model/model.module.d.ts +8 -1
  257. package/lib/router/model/model.router.id.directive.d.ts +1 -1
  258. package/lib/router/model/model.router.key.directive.d.ts +1 -1
  259. package/lib/router/model/model.router.uid.directive.d.ts +1 -1
  260. package/lib/router/router/provider/angular/angular.router.service.d.ts +2 -1
  261. package/lib/router/router/provider/uirouter/index.d.ts +1 -0
  262. package/lib/router/router/provider/uirouter/uirouter.router.service.d.ts +2 -1
  263. package/lib/router/router/provider/uirouter/uirouter.router.service.module.d.ts +3 -0
  264. package/lib/router/router/provider/uirouter/uirouter.router.service.providers.d.ts +7 -0
  265. package/lib/router/router/transition/transition.watcher.directive.d.ts +1 -1
  266. package/lib/storage/index.d.ts +1 -1
  267. package/lib/storage/storage.providers.d.ts +13 -0
  268. package/lib/subscription/subscription.directive.d.ts +8 -8
  269. package/lib/util/view.d.ts +8 -0
  270. package/package.json +8 -8
  271. package/esm2022/lib/action/directive/state/action.working.component.mjs +0 -34
  272. package/esm2022/lib/auth/auth.state.module.mjs +0 -22
  273. package/esm2022/lib/environment/service/environment.mjs +0 -6
  274. package/esm2022/lib/environment/service/environment.service.mjs +0 -33
  275. package/esm2022/lib/storage/storage.module.mjs +0 -41
  276. package/lib/auth/auth.state.module.d.ts +0 -8
  277. package/lib/storage/storage.module.d.ts +0 -10
  278. /package/lib/environment/{service/environment.d.ts → environment.d.ts} +0 -0
  279. /package/lib/environment/{service/environment.service.d.ts → environment.service.d.ts} +0 -0
@@ -17,10 +17,12 @@ import * as i15 from "./directive/debug/action.logger.directive";
17
17
  import * as i16 from "./directive/state/action.presuccess.directive";
18
18
  import * as i17 from "./directive/state/action.success.directive";
19
19
  import * as i18 from "./directive/state/action.success.handler.directive";
20
- import * as i19 from "./directive/state/action.working.component";
21
- import * as i20 from "@angular/common";
20
+ import * as i19 from "./directive/state/action.working.directive";
21
+ /**
22
+ * Contains all base DbxAction components.
23
+ */
22
24
  export declare class DbxCoreActionModule {
23
25
  static ɵfac: i0.ɵɵFactoryDeclaration<DbxCoreActionModule, never>;
24
- static ɵmod: i0.ɵɵNgModuleDeclaration<DbxCoreActionModule, [typeof i1.DbxActionDirective, typeof i2.DbxActionContextMapDirective, typeof i3.DbxActionFromMapDirective, typeof i4.DbxActionMapSourceDirective, typeof i5.DbxActionMapWorkingDisableDirective, typeof i6.DbxActionSourceDirective, typeof i7.DbxActionHandlerDirective, typeof i7.DbxActionHandlerValueDirective, typeof i8.DbxActionDisabledDirective, typeof i9.DbxActionDisabledOnSuccessDirective, typeof i10.DbxActionEnforceModifiedDirective, typeof i11.DbxActionAutoTriggerDirective, typeof i12.dbxActionValueStreamDirective, typeof i13.DbxActionAutoModifyDirective, typeof i14.DbxActionValueDirective, typeof i15.DbxActionContextLoggerDirective, typeof i16.DbxActionPreSuccessDirective, typeof i17.DbxActionHasSuccessDirective, typeof i18.DbxActionSuccessHandlerDirective, typeof i19.DbxActionIsWorkingDirective], [typeof i20.CommonModule], [typeof i1.DbxActionDirective, typeof i2.DbxActionContextMapDirective, typeof i3.DbxActionFromMapDirective, typeof i4.DbxActionMapSourceDirective, typeof i5.DbxActionMapWorkingDisableDirective, typeof i6.DbxActionSourceDirective, typeof i7.DbxActionHandlerDirective, typeof i7.DbxActionHandlerValueDirective, typeof i8.DbxActionDisabledDirective, typeof i9.DbxActionDisabledOnSuccessDirective, typeof i10.DbxActionEnforceModifiedDirective, typeof i11.DbxActionAutoTriggerDirective, typeof i12.dbxActionValueStreamDirective, typeof i13.DbxActionAutoModifyDirective, typeof i14.DbxActionValueDirective, typeof i15.DbxActionContextLoggerDirective, typeof i16.DbxActionPreSuccessDirective, typeof i17.DbxActionHasSuccessDirective, typeof i18.DbxActionSuccessHandlerDirective, typeof i19.DbxActionIsWorkingDirective]>;
26
+ static ɵmod: i0.ɵɵNgModuleDeclaration<DbxCoreActionModule, never, [typeof i1.DbxActionDirective, typeof i2.DbxActionContextMapDirective, typeof i3.DbxActionFromMapDirective, typeof i4.DbxActionMapSourceDirective, typeof i5.DbxActionMapWorkingDisableDirective, typeof i6.DbxActionSourceDirective, typeof i7.DbxActionHandlerDirective, typeof i7.DbxActionHandlerValueDirective, typeof i8.DbxActionDisabledDirective, typeof i9.DbxActionDisabledOnSuccessDirective, typeof i10.DbxActionEnforceModifiedDirective, typeof i11.DbxActionAutoTriggerDirective, typeof i12.DbxActionValueStreamDirective, typeof i13.DbxActionAutoModifyDirective, typeof i14.DbxActionValueDirective, typeof i15.DbxActionContextLoggerDirective, typeof i16.DbxActionPreSuccessDirective, typeof i17.DbxActionHasSuccessDirective, typeof i18.DbxActionSuccessHandlerDirective, typeof i19.DbxActionIsWorkingDirective], [typeof i1.DbxActionDirective, typeof i2.DbxActionContextMapDirective, typeof i3.DbxActionFromMapDirective, typeof i4.DbxActionMapSourceDirective, typeof i5.DbxActionMapWorkingDisableDirective, typeof i6.DbxActionSourceDirective, typeof i7.DbxActionHandlerDirective, typeof i7.DbxActionHandlerValueDirective, typeof i8.DbxActionDisabledDirective, typeof i9.DbxActionDisabledOnSuccessDirective, typeof i10.DbxActionEnforceModifiedDirective, typeof i11.DbxActionAutoTriggerDirective, typeof i12.DbxActionValueStreamDirective, typeof i13.DbxActionAutoModifyDirective, typeof i14.DbxActionValueDirective, typeof i15.DbxActionContextLoggerDirective, typeof i16.DbxActionPreSuccessDirective, typeof i17.DbxActionHasSuccessDirective, typeof i18.DbxActionSuccessHandlerDirective, typeof i19.DbxActionIsWorkingDirective]>;
25
27
  static ɵinj: i0.ɵɵInjectorDeclaration<DbxCoreActionModule>;
26
28
  }
@@ -17,28 +17,31 @@ export declare function actionContextHasNoErrorAndIsModifiedAndCanTrigger(state:
17
17
  export declare function loadingStateForActionContextState<O = unknown>(state: ActionContextState<unknown, O>): LoadingState<O>;
18
18
  export declare function loadingStateTypeForActionContextState(state: ActionContextState): LoadingStateType;
19
19
  export interface ActionContextState<T = unknown, O = unknown> {
20
- actionState: DbxActionState;
21
- isModified: boolean;
20
+ readonly actionState: DbxActionState;
21
+ /**
22
+ * Whether or not this action is flagged as having been modified.
23
+ */
24
+ readonly isModified: boolean;
22
25
  /**
23
26
  * Value that is set after a triggered action. Not to be confused with result.
24
27
  */
25
- value?: Maybe<T>;
28
+ readonly value?: Maybe<T>;
26
29
  /**
27
30
  * Resolved result value.
28
31
  */
29
- result?: Maybe<O>;
32
+ readonly result?: Maybe<O>;
30
33
  /**
31
34
  * Rejected error, if available.
32
35
  */
33
- error?: Maybe<ReadableError>;
36
+ readonly error?: Maybe<ReadableError>;
34
37
  /**
35
38
  * Current disabled state.
36
39
  */
37
- disabled?: BooleanStringKeyArray;
40
+ readonly disabled?: BooleanStringKeyArray;
38
41
  /**
39
42
  * Number of consecutive errors that have occured.
40
43
  */
41
- errorCount?: number;
44
+ readonly errorCount?: number;
42
45
  }
43
46
  export declare class ActionContextStore<T = unknown, O = unknown> extends ComponentStore<ActionContextState<T, O>> implements OnDestroy {
44
47
  readonly lockSet: LockSet;
@@ -130,11 +133,17 @@ export declare class ActionContextStore<T = unknown, O = unknown> extends Compon
130
133
  /**
131
134
  * Adds a disabled reason.
132
135
  */
133
- readonly disable: (() => void) | ((observableOrValue: string | void | Observable<string | void>) => import("rxjs").Subscription);
136
+ readonly disable: (() => void) | ((observableOrValue: string | void | Observable<string | void | undefined> | undefined) => import("rxjs").Subscription);
134
137
  /**
135
138
  * Removes a disabled reason.
136
139
  */
137
- readonly enable: (() => void) | ((observableOrValue: string | void | Observable<string | void>) => import("rxjs").Subscription);
140
+ readonly enable: (() => void) | ((observableOrValue: string | void | Observable<string | void | undefined> | undefined) => import("rxjs").Subscription);
141
+ /**
142
+ * Triggers the modified state, if not disabled.
143
+ *
144
+ * Equivalent to calling setIsModified() with opposite input.
145
+ */
146
+ readonly setIsSame: (() => void) | ((observableOrValue: boolean | void | Observable<boolean | void>) => import("rxjs").Subscription);
138
147
  /**
139
148
  * Triggers the modified state, if not disabled.
140
149
  */
@@ -61,6 +61,7 @@ export declare class DbxActionContextStoreSourceInstance<T = unknown, O = unknow
61
61
  get errorCountSinceLastSuccess$(): Observable<number>;
62
62
  enable(key?: DbxActionDisabledKey, enable?: boolean): void;
63
63
  disable(key?: DbxActionDisabledKey, disable?: boolean): void;
64
+ setIsSame(isSame?: boolean | Observable<boolean> | Observable<void>): void;
64
65
  setIsModified(isModified?: boolean | Observable<boolean> | Observable<void>): void;
65
66
  trigger(): void;
66
67
  triggerWithValue(value: T | Observable<T>): void;
@@ -1,15 +1,13 @@
1
1
  import { OnInit, OnDestroy } from '@angular/core';
2
2
  import { AbstractSubscriptionDirective } from '../../../subscription';
3
+ import { Observable } from 'rxjs';
3
4
  import { DbxActionContextStoreSourceInstance } from '../../action.store.source';
4
- import { type Maybe } from '@dereekb/util';
5
5
  import * as i0 from "@angular/core";
6
6
  export declare class DbxActionAutoModifyDirective<T, O> extends AbstractSubscriptionDirective implements OnInit, OnDestroy {
7
7
  readonly source: DbxActionContextStoreSourceInstance<T, O>;
8
- private readonly _autoModifyEnabled;
9
- get autoModifyEnabled(): boolean;
10
- set autoModifyEnabled(autoModifyEnabled: Maybe<boolean | ''>);
8
+ readonly autoModifyEnabled: import("@angular/core").InputSignalWithTransform<boolean, string | boolean>;
9
+ readonly markAsModified$: Observable<void>;
11
10
  ngOnInit(): void;
12
- ngOnDestroy(): void;
13
11
  static ɵfac: i0.ɵɵFactoryDeclaration<DbxActionAutoModifyDirective<any, any>, never>;
14
- static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionAutoModifyDirective<any, any>, "[dbxActionAutoModify]", never, { "autoModifyEnabled": { "alias": "dbxActionAutoModify"; "required": false; }; }, {}, never, never, false, never>;
12
+ static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionAutoModifyDirective<any, any>, "dbxActionAutoModify, [dbxActionAutoModify]", never, { "autoModifyEnabled": { "alias": "dbxActionAutoModify"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
15
13
  }
@@ -1,4 +1,4 @@
1
- import { OnInit, OnDestroy } from '@angular/core';
1
+ import { OnInit, OnDestroy, Signal } from '@angular/core';
2
2
  import { AbstractSubscriptionDirective } from '../../../subscription';
3
3
  import { Observable } from 'rxjs';
4
4
  import { DbxActionContextStoreSourceInstance } from '../../action.store.source';
@@ -11,33 +11,17 @@ import * as i0 from "@angular/core";
11
11
  */
12
12
  export declare class DbxActionAutoTriggerDirective<T = unknown, O = unknown> extends AbstractSubscriptionDirective implements OnInit, OnDestroy {
13
13
  readonly source: DbxActionContextStoreSourceInstance<T, O>;
14
- private readonly _triggerEnabled;
15
- private readonly _triggerLimit;
16
- private readonly _trigger;
17
- /**
18
- * How much to throttle the auto-triggering.
19
- */
20
- get triggerEnabled(): boolean;
21
- set triggerEnabled(triggerEnabled: Maybe<boolean> | '');
22
- triggerDebounce: number;
23
- triggerThrottle: number;
24
- triggerErrorThrottle: number;
25
- maxErrorsForThrottle: number;
26
- /**
27
- * Optional input to override both triggerDebounce and triggerThrottle.
28
- *
29
- * Used in forms that are simple.
30
- */
31
- set fastTrigger(fastTrigger: Maybe<boolean> | '');
32
- /**
33
- * Optional input to override both triggerDebounce and triggerThrottle to be 0.
34
- *
35
- * Used in forms that generally return a single value.
36
- */
37
- set instantTrigger(instantTrigger: Maybe<boolean> | '');
38
- get triggerLimit(): Maybe<number>;
39
- set triggerLimit(triggerLimit: Maybe<number>);
40
- private _triggerCount;
14
+ readonly triggerDebounce: import("@angular/core").InputSignal<Maybe<number>>;
15
+ readonly triggerThrottle: import("@angular/core").InputSignal<Maybe<number>>;
16
+ readonly triggerErrorThrottle: import("@angular/core").InputSignalWithTransform<number, Maybe<number>>;
17
+ readonly maxErrorsForThrottle: import("@angular/core").InputSignalWithTransform<number, Maybe<number>>;
18
+ readonly triggerLimit: import("@angular/core").InputSignal<Maybe<number>>;
19
+ readonly triggerEnabled: import("@angular/core").InputSignalWithTransform<boolean, Maybe<string | boolean>>;
20
+ readonly useFastTriggerPreset: import("@angular/core").InputSignalWithTransform<boolean, Maybe<string | boolean>>;
21
+ readonly useInstantTriggerPreset: import("@angular/core").InputSignalWithTransform<boolean, Maybe<string | boolean>>;
22
+ readonly triggerDebounceSignal: Signal<number>;
23
+ readonly triggerThrottleSignal: Signal<number>;
24
+ readonly triggerCountSignal: import("@angular/core").WritableSignal<number>;
41
25
  readonly _errorCount$: Observable<number>;
42
26
  readonly _triggerCount$: Observable<number>;
43
27
  /**
@@ -45,11 +29,10 @@ export declare class DbxActionAutoTriggerDirective<T = unknown, O = unknown> ext
45
29
  */
46
30
  readonly triggerCount$: Observable<number>;
47
31
  private readonly _isTriggerLimited$;
48
- readonly isTriggerLimited$: Observable<boolean>;
49
- readonly trigger$: Observable<void>;
50
- get isEnabled(): boolean;
32
+ readonly isTriggerAllowedToRun$: Observable<boolean>;
33
+ readonly automaticTrigger$: Observable<void>;
51
34
  ngOnInit(): void;
52
35
  ngOnDestroy(): void;
53
36
  static ɵfac: i0.ɵɵFactoryDeclaration<DbxActionAutoTriggerDirective<any, any>, never>;
54
- static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionAutoTriggerDirective<any, any>, "dbxActionAutoTrigger, [dbxActionAutoTrigger]", never, { "triggerEnabled": { "alias": "dbxActionAutoTrigger"; "required": false; }; "triggerDebounce": { "alias": "triggerDebounce"; "required": false; }; "triggerThrottle": { "alias": "triggerThrottle"; "required": false; }; "triggerErrorThrottle": { "alias": "triggerErrorThrottle"; "required": false; }; "fastTrigger": { "alias": "fastTrigger"; "required": false; }; "instantTrigger": { "alias": "instantTrigger"; "required": false; }; "triggerLimit": { "alias": "triggerLimit"; "required": false; }; }, {}, never, never, false, never>;
37
+ static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionAutoTriggerDirective<any, any>, "dbxActionAutoTrigger,[dbxActionAutoTrigger]", never, { "triggerDebounce": { "alias": "triggerDebounce"; "required": false; "isSignal": true; }; "triggerThrottle": { "alias": "triggerThrottle"; "required": false; "isSignal": true; }; "triggerErrorThrottle": { "alias": "triggerErrorThrottle"; "required": false; "isSignal": true; }; "maxErrorsForThrottle": { "alias": "maxErrorsForThrottle"; "required": false; "isSignal": true; }; "triggerLimit": { "alias": "triggerLimit"; "required": false; "isSignal": true; }; "triggerEnabled": { "alias": "dbxActionAutoTrigger"; "required": false; "isSignal": true; }; "useFastTriggerPreset": { "alias": "useFastTriggerPreset"; "required": false; "isSignal": true; }; "useInstantTriggerPreset": { "alias": "useInstantTriggerPreset"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
55
38
  }
@@ -1,3 +1,2 @@
1
1
  export * from './action.automodify.directive';
2
2
  export * from './action.autotrigger.directive';
3
- export * from '../state/action.value.stream.directive';
@@ -8,5 +8,5 @@ export declare class DbxActionDirective<T = unknown, O = unknown> extends DbxAct
8
8
  constructor();
9
9
  ngOnDestroy(): void;
10
10
  static ɵfac: i0.ɵɵFactoryDeclaration<DbxActionDirective<any, any>, never>;
11
- static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionDirective<any, any>, "dbx-action,[dbxAction],dbx-action-context,[dbxActionContext]", ["action", "dbxAction"], {}, {}, never, never, false, never>;
11
+ static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionDirective<any, any>, "dbx-action,[dbxAction],dbx-action-context,[dbxActionContext]", ["action", "dbxAction"], {}, {}, never, never, true, never>;
12
12
  }
@@ -1,16 +1,12 @@
1
- import { OnDestroy } from '@angular/core';
2
1
  import { type Maybe } from '@dereekb/util';
3
2
  import { SecondaryActionContextStoreSource, ActionContextStoreSource } from '../../action.store.source';
4
3
  import * as i0 from "@angular/core";
5
4
  /**
6
5
  * Directive that provides a DbxActionSourceDirective that is passed in.
7
6
  */
8
- export declare class DbxActionSourceDirective implements SecondaryActionContextStoreSource, OnDestroy {
9
- private _source;
7
+ export declare class DbxActionSourceDirective implements SecondaryActionContextStoreSource {
8
+ readonly dbxActionSource: import("@angular/core").InputSignal<Maybe<ActionContextStoreSource<unknown, unknown>>>;
10
9
  readonly store$: import("rxjs").Observable<import("@dereekb/dbx-core").ActionContextStore<unknown, unknown>>;
11
- ngOnDestroy(): void;
12
- get source(): Maybe<ActionContextStoreSource>;
13
- set source(source: Maybe<ActionContextStoreSource>);
14
10
  static ɵfac: i0.ɵɵFactoryDeclaration<DbxActionSourceDirective, never>;
15
- static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionSourceDirective, "[dbxActionSource]", never, { "source": { "alias": "dbxActionSource"; "required": false; }; }, {}, never, never, false, never>;
11
+ static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionSourceDirective, "[dbxActionSource]", never, { "dbxActionSource": { "alias": "dbxActionSource"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
16
12
  }
@@ -9,5 +9,5 @@ export declare class DbxActionContextLoggerDirective extends AbstractSubscriptio
9
9
  readonly source: DbxActionContextStoreSourceInstance<any, any>;
10
10
  ngOnInit(): void;
11
11
  static ɵfac: i0.ɵɵFactoryDeclaration<DbxActionContextLoggerDirective, never>;
12
- static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionContextLoggerDirective, "[dbxActionLogger],[dbxActionContextLogger]", never, {}, {}, never, never, false, never>;
12
+ static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionContextLoggerDirective, "[dbxActionLogger],[dbxActionContextLogger]", never, {}, {}, never, never, true, never>;
13
13
  }
@@ -1,13 +1,43 @@
1
+ import { Observable } from 'rxjs';
1
2
  import { ActionContextStoreSource } from '../../action.store.source';
3
+ import { Destroyable } from '@dereekb/util';
4
+ /**
5
+ * Arbitrary string used to identify an action.
6
+ */
2
7
  export type ActionKey = string;
3
8
  /**
4
9
  * Map that returns sources for ActionKey values.
5
10
  */
6
- export declare abstract class ActionContextStoreSourceMap<T = unknown, O = unknown> {
11
+ export declare abstract class ActionContextStoreSourceMap<T = unknown, O = unknown> implements Destroyable {
12
+ /**
13
+ * Returns the read-only map of action keys to sources.
14
+ */
15
+ abstract readonly actionKeySourceMap$: Observable<Map<ActionKey, ActionContextStoreSource<T, O>>>;
7
16
  /**
8
17
  * Returns a ActionContextStoreSource for the input action key.
9
18
  *
10
19
  * @param key Action key to retrieve the source for.
11
20
  */
12
21
  abstract sourceForKey(key: ActionKey): ActionContextStoreSource<T, O>;
22
+ /**
23
+ * Adds the store source for the input key.
24
+ * @param key Action key to add the source for.
25
+ * @param source Store source to add.
26
+ */
27
+ abstract addStoreSource(key: ActionKey, source: ActionContextStoreSource<T, O>): void;
28
+ /**
29
+ * Removes the store source for the input key.
30
+ * @param key Action key to remove the source for.
31
+ */
32
+ abstract removeStoreSource(key: ActionKey): void;
33
+ /**
34
+ * Destroys the map.
35
+ */
36
+ abstract destroy(): void;
13
37
  }
38
+ /**
39
+ * Creates a new ActionContextStoreSourceMap.
40
+ *
41
+ * @returns A new ActionContextStoreSourceMap.
42
+ */
43
+ export declare function actionContextStoreSourceMap<T = unknown, O = unknown>(): ActionContextStoreSourceMap<T, O>;
@@ -1,34 +1,14 @@
1
1
  import { OnDestroy } from '@angular/core';
2
- import { Observable } from 'rxjs';
3
- import { ActionContextStoreSource } from '../../action.store.source';
4
- import { ActionContextStore } from '../../action.store';
5
- import { ActionContextStoreSourceMap, ActionKey } from './action.map';
2
+ import { ActionContextStoreSourceMap } from './action.map';
6
3
  import * as i0 from "@angular/core";
7
4
  /**
8
5
  * Context used for providing actions based on the action key.
9
6
  *
10
7
  * This is useful for passing action contexts around via the providers instead of explicit injection.
11
8
  */
12
- export declare class DbxActionContextMapDirective implements ActionContextStoreSourceMap, OnDestroy {
13
- private readonly _map;
14
- readonly map$: Observable<Map<string, ActionContextStoreSource<unknown, unknown>>>;
15
- readonly areAnyWorking$: Observable<boolean>;
16
- get map(): Map<ActionKey, ActionContextStoreSource>;
17
- sourceForKey(key: ActionKey): ActionContextStoreSource<unknown, unknown>;
18
- addStoreSource(key: ActionKey, source: ActionContextStoreSource): void;
19
- removeStore(key: ActionKey): void;
9
+ export declare class DbxActionContextMapDirective implements OnDestroy {
10
+ readonly actionContextStoreSourceMap: ActionContextStoreSourceMap<any, any>;
20
11
  ngOnDestroy(): void;
21
- checkAnyAre(mapFn: (input: ActionContextStore) => Observable<boolean>, emptyArrayValue?: boolean): Observable<boolean>;
22
- reduceFromAllSources<O, R>(mapFn: (input: ActionContextStore) => Observable<O>, reduceFn: (values: O[]) => R): Observable<R>;
23
- fromAllSources<O>(mapFn: (input: ActionContextStore) => Observable<O>): Observable<O[]>;
24
12
  static ɵfac: i0.ɵɵFactoryDeclaration<DbxActionContextMapDirective, never>;
25
- static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionContextMapDirective, "[dbxActionContextMap]", ["actionMap"], {}, {}, never, never, false, never>;
26
- }
27
- export declare class DbxActionContextMapDirectiveSourceInstance implements ActionContextStoreSource {
28
- private readonly _parent;
29
- private readonly _key;
30
- readonly store$: Observable<ActionContextStore>;
31
- constructor(parent: DbxActionContextMapDirective, key: ActionKey);
32
- get parent(): DbxActionContextMapDirective;
33
- get key(): string;
13
+ static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionContextMapDirective, "[dbxActionContextMap]", ["actionMap"], {}, {}, never, never, true, never>;
34
14
  }
@@ -7,12 +7,12 @@ import * as i0 from "@angular/core";
7
7
  * Directive that provides a ActionContextStoreSource using the input key and DbxActionContextMapDirective.
8
8
  */
9
9
  export declare class DbxActionFromMapDirective implements SecondaryActionContextStoreSource, OnDestroy {
10
- private readonly _map;
10
+ private readonly _actionContextStoreSourceMap;
11
11
  private readonly _key;
12
- readonly store$: import("rxjs").Observable<import("@dereekb/dbx-core").ActionContextStore<unknown, unknown>>;
12
+ readonly store$: import("rxjs").Observable<import("@dereekb/dbx-core").ActionContextStore<any, any>>;
13
13
  ngOnDestroy(): void;
14
14
  get key(): Maybe<ActionKey>;
15
15
  set key(key: Maybe<ActionKey>);
16
16
  static ɵfac: i0.ɵɵFactoryDeclaration<DbxActionFromMapDirective, never>;
17
- static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionFromMapDirective, "[dbxActionFromMap]", never, { "key": { "alias": "dbxActionFromMap"; "required": false; }; }, {}, never, never, false, never>;
17
+ static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionFromMapDirective, "[dbxActionFromMap]", never, { "key": { "alias": "dbxActionFromMap"; "required": false; }; }, {}, never, never, true, never>;
18
18
  }
@@ -6,7 +6,7 @@ import * as i0 from "@angular/core";
6
6
  * Used to communicate with an dbxActionMap and set the ActionContextStore to the store based on the key.
7
7
  */
8
8
  export declare class DbxActionMapSourceDirective implements OnDestroy {
9
- private readonly _map;
9
+ private readonly _actionContextStoreSourceMap;
10
10
  readonly source: ActionContextStoreSource<any, any>;
11
11
  private _key;
12
12
  ngOnDestroy(): void;
@@ -14,5 +14,5 @@ export declare class DbxActionMapSourceDirective implements OnDestroy {
14
14
  private _addToStore;
15
15
  private _removeFromToStore;
16
16
  static ɵfac: i0.ɵɵFactoryDeclaration<DbxActionMapSourceDirective, never>;
17
- static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionMapSourceDirective, "[dbxActionMapSource]", never, { "key": { "alias": "dbxActionMapSource"; "required": false; }; }, {}, never, never, false, never>;
17
+ static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionMapSourceDirective, "[dbxActionMapSource]", never, { "key": { "alias": "dbxActionMapSource"; "required": false; }; }, {}, never, never, true, never>;
18
18
  }
@@ -0,0 +1,48 @@
1
+ import { IsCheckFunction, ObservableOrValue } from '@dereekb/rxjs';
2
+ import { Observable } from 'rxjs';
3
+ import { ActionContextStore } from '../../action.store';
4
+ import { ActionContextStoreSourceMap, ActionKey } from './action.map';
5
+ import { ActionContextStoreSource } from '../../action.store.source';
6
+ /**
7
+ * Utility interface that provides a set of functions to read from an ActionContextStoreSourceMap.
8
+ */
9
+ export interface ActionContextStoreSourceMapReader<T = unknown, O = unknown> {
10
+ /**
11
+ * The input key source map.
12
+ */
13
+ readonly actionKeySourceMap$: Observable<Map<ActionKey, ActionContextStoreSource<T, O>>>;
14
+ /**
15
+ * Checks if any of the stores in the map match the input checkFunction.
16
+ *
17
+ * @param checkFunction Function to apply to each store.
18
+ * @param emptyArrayValue Value to return if the map is empty.
19
+ */
20
+ checkAny(checkFunction: IsCheckFunction<ActionContextStore<T, O>>, emptyArrayValue?: boolean): Observable<boolean>;
21
+ /**
22
+ * Reduces a value from all stores in the map.
23
+ *
24
+ * @param mapFn Function to apply to each store.
25
+ * @param reduceFn Function to apply to the results of the mapFn.
26
+ */
27
+ reduceFromAllSources<X, Y>(mapFn: (input: ActionContextStore<T, O>) => Observable<X>, reduceFn: (values: X[]) => Y): Observable<Y>;
28
+ /**
29
+ * Reads a value from each store in the map and returns an array of the results.
30
+ *
31
+ * @param mapFn Function to apply to each store.
32
+ */
33
+ fromAllSources<Y>(mapFn: (input: ActionContextStore<T, O>) => Observable<Y>): Observable<Y[]>;
34
+ }
35
+ /**
36
+ * Creates a new ActionContextStoreSourceMapReader from the input.
37
+
38
+ * @param actionKeySourceMap$
39
+ */
40
+ export declare function actionContextStoreSourceMapReader<T = unknown, O = unknown>(actionKeySourceMap$: ObservableOrValue<Map<ActionKey, ActionContextStoreSource<T, O>>>): ActionContextStoreSourceMapReader<T, O>;
41
+ /**
42
+ * Returns an Observable of the results of the mapFn for each source in the actionKeySourceMap$.
43
+ *
44
+ * @param actionKeySourceMap$ Observable of the action key source map.
45
+ * @param mapFn Function to apply to each source.
46
+ * @returns Observable of the results of the mapFn for each source.
47
+ */
48
+ export declare function fromAllActionContextStoreSourceMapSources<O>(actionKeySourceMap$: ObservableOrValue<ActionContextStoreSourceMap>, mapFn: (input: ActionContextStore) => Observable<O>): Observable<O[]>;
@@ -2,18 +2,18 @@ import { OnInit, OnDestroy } from '@angular/core';
2
2
  import { type Maybe } from '@dereekb/util';
3
3
  import { AbstractSubscriptionDirective } from '../../../subscription';
4
4
  import { DbxActionContextStoreSourceInstance } from '../../action.store.source';
5
- import { DbxActionDisabledKey } from '../../action';
6
5
  import * as i0 from "@angular/core";
7
6
  export declare const DEFAULT_ACTION_MAP_WORKING_DISABLED_KEY = "action_map_working_disable";
8
7
  /**
9
8
  * Used to communicate with an dbxActionMap and set the ActionContextStore to be disabled if any other element in the map is working.
10
9
  */
11
10
  export declare class DbxActionMapWorkingDisableDirective extends AbstractSubscriptionDirective implements OnInit, OnDestroy {
12
- private readonly _map;
11
+ private readonly _actionContextStoreSourceMap;
13
12
  readonly source: DbxActionContextStoreSourceInstance<any, any>;
14
- disabledKey: Maybe<DbxActionDisabledKey>;
13
+ readonly disabledKey: import("@angular/core").InputSignal<Maybe<string>>;
14
+ readonly areAnySourcesWorking$: import("rxjs").Observable<boolean>;
15
15
  ngOnInit(): void;
16
16
  ngOnDestroy(): void;
17
17
  static ɵfac: i0.ɵɵFactoryDeclaration<DbxActionMapWorkingDisableDirective, never>;
18
- static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionMapWorkingDisableDirective, "[dbxActionMapWorkingDisable]", never, { "disabledKey": { "alias": "dbxActionMapWorkingDisable"; "required": false; }; }, {}, never, never, false, never>;
18
+ static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionMapWorkingDisableDirective, "[dbxActionMapWorkingDisable]", never, { "disabledKey": { "alias": "dbxActionMapWorkingDisable"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
19
19
  }
@@ -2,4 +2,5 @@ export * from './action.map.directive';
2
2
  export * from './action.map.key.directive';
3
3
  export * from './action.map.source.directive';
4
4
  export * from './action.map';
5
+ export * from './action.map.utility';
5
6
  export * from './action.map.working.disable.directive';
@@ -16,5 +16,5 @@ export declare class DbxActionDisabledDirective<T, O> extends AbstractSubscripti
16
16
  get disabled(): boolean;
17
17
  set disabled(disabled: Maybe<boolean | ''>);
18
18
  static ɵfac: i0.ɵɵFactoryDeclaration<DbxActionDisabledDirective<any, any>, never>;
19
- static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionDisabledDirective<any, any>, "[dbxActionDisabled]", never, { "disabled": { "alias": "dbxActionDisabled"; "required": false; }; }, {}, never, never, false, never>;
19
+ static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionDisabledDirective<any, any>, "[dbxActionDisabled]", never, { "disabled": { "alias": "dbxActionDisabled"; "required": false; }; }, {}, never, never, true, never>;
20
20
  }
@@ -16,5 +16,5 @@ export declare class DbxActionDisabledOnSuccessDirective<T, O> extends AbstractS
16
16
  get disabled(): boolean;
17
17
  set disabled(disabled: Maybe<boolean | ''>);
18
18
  static ɵfac: i0.ɵɵFactoryDeclaration<DbxActionDisabledOnSuccessDirective<any, any>, never>;
19
- static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionDisabledOnSuccessDirective<any, any>, "[dbxActionDisabledOnSuccess]", never, { "disabled": { "alias": "dbxActionDisabledOnSuccess"; "required": false; }; }, {}, never, never, false, never>;
19
+ static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionDisabledOnSuccessDirective<any, any>, "[dbxActionDisabledOnSuccess]", never, { "disabled": { "alias": "dbxActionDisabledOnSuccess"; "required": false; }; }, {}, never, never, true, never>;
20
20
  }
@@ -15,5 +15,5 @@ export declare class DbxActionEnforceModifiedDirective extends AbstractSubscript
15
15
  get enabled(): boolean;
16
16
  set enabled(enabled: Maybe<boolean | ''>);
17
17
  static ɵfac: i0.ɵɵFactoryDeclaration<DbxActionEnforceModifiedDirective, never>;
18
- static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionEnforceModifiedDirective, "[dbxActionEnforceModified]", never, { "enabled": { "alias": "dbxActionEnforceModified"; "required": false; }; }, {}, never, never, false, never>;
18
+ static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionEnforceModifiedDirective, "[dbxActionEnforceModified]", never, { "enabled": { "alias": "dbxActionEnforceModified"; "required": false; }; }, {}, never, never, true, never>;
19
19
  }
@@ -1,4 +1,4 @@
1
- import { OnDestroy, OnInit } from '@angular/core';
1
+ import { OnDestroy } from '@angular/core';
2
2
  import { DbxActionContextStoreSourceInstance } from '../../action.store.source';
3
3
  import { FactoryWithInput, GetterOrValue, type Maybe } from '@dereekb/util';
4
4
  import { DbxActionHandlerInstance } from './action.handler.instance';
@@ -7,30 +7,29 @@ import * as i0 from "@angular/core";
7
7
  /**
8
8
  * Abstract directive that wraps and handles a DbxActionHandlerInstance lifecycle.
9
9
  */
10
- export declare abstract class AbstractDbxActionHandlerDirective<T = unknown, O = unknown> implements OnInit, OnDestroy {
10
+ export declare abstract class AbstractDbxActionHandlerDirective<T = unknown, O = unknown> implements OnDestroy {
11
11
  readonly source: DbxActionContextStoreSourceInstance<T, O>;
12
- protected _dbxActionHandlerInstance: DbxActionHandlerInstance<T, O>;
13
- ngOnInit(): void;
12
+ protected readonly _dbxActionHandlerInstance: DbxActionHandlerInstance<T, O>;
13
+ constructor();
14
14
  ngOnDestroy(): void;
15
15
  static ɵfac: i0.ɵɵFactoryDeclaration<AbstractDbxActionHandlerDirective<any, any>, never>;
16
16
  static ɵdir: i0.ɵɵDirectiveDeclaration<AbstractDbxActionHandlerDirective<any, any>, never, never, {}, {}, never, never, false, never>;
17
17
  }
18
18
  /**
19
- * Directive that wraps and controls a DbxActionHandlerInstance.
19
+ * Directive that passes a Work function to handle a valueReady$ event from an action context.
20
20
  */
21
21
  export declare class DbxActionHandlerDirective<T = unknown, O = unknown> extends AbstractDbxActionHandlerDirective<T, O> {
22
- get handlerFunction(): Maybe<Work<T, O>>;
23
- set handlerFunction(handlerFunction: Maybe<Work<T, O>>);
22
+ readonly handlerFunction: import("@angular/core").InputSignal<Maybe<Work<T, O>>>;
23
+ protected readonly _handlerFunctionEffect: import("@angular/core").EffectRef;
24
24
  static ɵfac: i0.ɵɵFactoryDeclaration<DbxActionHandlerDirective<any, any>, never>;
25
- static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionHandlerDirective<any, any>, "[dbxActionHandler]", never, { "handlerFunction": { "alias": "dbxActionHandler"; "required": false; }; }, {}, never, never, false, never>;
25
+ static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionHandlerDirective<any, any>, "[dbxActionHandler]", never, { "handlerFunction": { "alias": "dbxActionHandler"; "required": true; "isSignal": true; }; }, {}, never, never, true, never>;
26
26
  }
27
27
  /**
28
- * Directive that passes
28
+ * Directive that passes a value to handle a valueReady$ event from an action context.
29
29
  */
30
30
  export declare class DbxActionHandlerValueDirective<T = unknown, O = unknown> extends AbstractDbxActionHandlerDirective<T, O> {
31
- get handlerValue(): Maybe<GetterOrValue<O> | FactoryWithInput<O, T>>;
32
- set handlerValue(handlerValue: Maybe<GetterOrValue<O> | FactoryWithInput<O, T>>);
33
- ngOnInit(): void;
31
+ readonly handlerValue: import("@angular/core").InputSignal<Maybe<GetterOrValue<O> | FactoryWithInput<O, T>>>;
32
+ protected readonly _handlerValueEffect: import("@angular/core").EffectRef;
34
33
  static ɵfac: i0.ɵɵFactoryDeclaration<DbxActionHandlerValueDirective<any, any>, never>;
35
- static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionHandlerValueDirective<any, any>, "[dbxActionHandlerValue]", never, { "handlerValue": { "alias": "dbxActionHandlerValue"; "required": false; }; }, {}, never, never, false, never>;
34
+ static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionHandlerValueDirective<any, any>, "[dbxActionHandlerValue]", never, { "handlerValue": { "alias": "dbxActionHandlerValue"; "required": true; "isSignal": true; }; }, {}, never, never, true, never>;
36
35
  }
@@ -11,12 +11,12 @@ export declare class DbxActionHandlerInstance<T = unknown, O = unknown> implemen
11
11
  private readonly _handlerFunction;
12
12
  private readonly _handlerValue;
13
13
  readonly handlerFunction$: import("rxjs").Observable<Work<T, O>>;
14
- get handlerFunction(): Maybe<Work<T, O>>;
15
- set handlerFunction(handlerFunction: Maybe<Work<T, O>>);
16
- get handlerValue(): Maybe<GetterOrValue<O> | FactoryWithInput<O, T>>;
17
- set handlerValue(handlerValue: Maybe<GetterOrValue<O> | FactoryWithInput<O, T>>);
18
14
  constructor(source: DbxActionContextStoreSourceInstance<T, O>);
19
15
  get source(): DbxActionContextStoreSourceInstance<T, O>;
16
+ get handlerFunction(): Maybe<Work<T, O>>;
17
+ get handlerValue(): Maybe<GetterOrValue<O> | FactoryWithInput<O, T>>;
18
+ setHandlerFunction(handlerFunction: Maybe<Work<T, O>>): void;
19
+ setHandlerValue(handlerValue: Maybe<GetterOrValue<O> | FactoryWithInput<O, T>>): void;
20
20
  init(): void;
21
21
  destroy(): void;
22
22
  }
@@ -10,5 +10,5 @@ export declare class DbxActionPreSuccessDirective extends AbstractIfDirective {
10
10
  hideFor?: Maybe<number> | '';
11
11
  readonly show$: import("rxjs").Observable<boolean>;
12
12
  static ɵfac: i0.ɵɵFactoryDeclaration<DbxActionPreSuccessDirective, never>;
13
- static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionPreSuccessDirective, "[dbxActionPreSuccess]", never, { "hideFor": { "alias": "dbxActionPreSuccess"; "required": false; }; }, {}, never, never, false, never>;
13
+ static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionPreSuccessDirective, "[dbxActionPreSuccess]", never, { "hideFor": { "alias": "dbxActionPreSuccess"; "required": false; }; }, {}, never, never, true, never>;
14
14
  }
@@ -11,5 +11,5 @@ export declare class DbxActionHasSuccessDirective extends AbstractIfDirective im
11
11
  hideAfter?: Maybe<number> | '';
12
12
  readonly show$: import("rxjs").Observable<boolean>;
13
13
  static ɵfac: i0.ɵɵFactoryDeclaration<DbxActionHasSuccessDirective, never>;
14
- static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionHasSuccessDirective, "[dbxActionHasSuccess]", never, { "hideAfter": { "alias": "dbxActionHasSuccess"; "required": false; }; }, {}, never, never, false, never>;
14
+ static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionHasSuccessDirective, "[dbxActionHasSuccess]", never, { "hideAfter": { "alias": "dbxActionHasSuccess"; "required": false; }; }, {}, never, never, true, never>;
15
15
  }
@@ -12,12 +12,9 @@ export type DbxActionSuccessHandlerFunction<O = unknown> = (value: O) => void;
12
12
  */
13
13
  export declare class DbxActionSuccessHandlerDirective<T, O> extends AbstractSubscriptionDirective implements OnInit, OnDestroy {
14
14
  readonly source: DbxActionContextStoreSourceInstance<T, O>;
15
- private readonly _successFunction;
15
+ readonly dbxActionSuccessHandler: import("@angular/core").InputSignal<Maybe<DbxActionSuccessHandlerFunction<O>>>;
16
16
  readonly successFunction$: import("rxjs").Observable<DbxActionSuccessHandlerFunction<O>>;
17
17
  ngOnInit(): void;
18
- ngOnDestroy(): void;
19
- get successFunction(): Maybe<DbxActionSuccessHandlerFunction<O>>;
20
- set successFunction(successFunction: Maybe<DbxActionSuccessHandlerFunction<O>>);
21
18
  static ɵfac: i0.ɵɵFactoryDeclaration<DbxActionSuccessHandlerDirective<any, any>, never>;
22
- static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionSuccessHandlerDirective<any, any>, "[dbxActionSuccessHandler]", never, { "successFunction": { "alias": "dbxActionSuccessHandler"; "required": false; }; }, {}, never, never, false, never>;
19
+ static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionSuccessHandlerDirective<any, any>, "[dbxActionSuccessHandler]", never, { "dbxActionSuccessHandler": { "alias": "dbxActionSuccessHandler"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
23
20
  }
@@ -1,5 +1,6 @@
1
1
  import { OnInit, OnDestroy } from '@angular/core';
2
2
  import { Maybe, GetterOrValue } from '@dereekb/util';
3
+ import { Observable } from 'rxjs';
3
4
  import { AbstractSubscriptionDirective } from '../../../subscription';
4
5
  import { DbxActionContextStoreSourceInstance } from '../../action.store.source';
5
6
  import * as i0 from "@angular/core";
@@ -7,16 +8,20 @@ import * as i0 from "@angular/core";
7
8
  * Directive that provides a default value when triggered.
8
9
  *
9
10
  * No value is required, allowing the directive to automatically call readyValue.
11
+ *
12
+ * The valueOrFunction will filter on null/undefined input and wait until the input value is non-null.
13
+ *
14
+ * Use a getter if null/undefined values should be passed to the action.
10
15
  */
11
16
  export declare class DbxActionValueDirective<T, O> extends AbstractSubscriptionDirective implements OnInit, OnDestroy {
17
+ readonly valueOrFunction: import("@angular/core").InputSignal<Maybe<"" | GetterOrValue<T>>>;
12
18
  readonly source: DbxActionContextStoreSourceInstance<T, O>;
13
- private readonly _valueOrFunction;
14
- readonly valueOrFunction$: import("rxjs").Observable<GetterOrValue<T>>;
19
+ private readonly _valueOrFunctionOverride;
20
+ readonly valueOrFunction$: Observable<GetterOrValue<T>>;
15
21
  constructor();
16
22
  ngOnInit(): void;
23
+ setValueOrFunction(value: Maybe<GetterOrValue<T>>): void;
17
24
  ngOnDestroy(): void;
18
- get valueOrFunction(): Maybe<GetterOrValue<T>>;
19
- set valueOrFunction(valueOrFunction: Maybe<GetterOrValue<T>>);
20
25
  static ɵfac: i0.ɵɵFactoryDeclaration<DbxActionValueDirective<any, any>, never>;
21
- static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionValueDirective<any, any>, "[dbxActionValue]", never, { "valueOrFunction": { "alias": "dbxActionValue"; "required": false; }; }, {}, never, never, false, never>;
26
+ static ɵdir: i0.ɵɵDirectiveDeclaration<DbxActionValueDirective<any, any>, "dbxActionValue,[dbxActionValue]", never, { "valueOrFunction": { "alias": "dbxActionValue"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
22
27
  }