@dereekb/dbx-core 10.1.30 → 11.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 (166) hide show
  1. package/esm2022/lib/action/action.handler.mjs +2 -1
  2. package/esm2022/lib/action/action.holder.mjs +9 -2
  3. package/esm2022/lib/action/action.machine.mjs +7 -6
  4. package/esm2022/lib/action/action.module.mjs +5 -5
  5. package/esm2022/lib/action/action.store.mjs +134 -134
  6. package/esm2022/lib/action/action.store.source.mjs +4 -10
  7. package/esm2022/lib/action/directive/auto/action.automodify.directive.mjs +7 -13
  8. package/esm2022/lib/action/directive/auto/action.autotrigger.directive.mjs +33 -39
  9. package/esm2022/lib/action/directive/context/action.directive.mjs +7 -12
  10. package/esm2022/lib/action/directive/context/action.source.directive.mjs +5 -7
  11. package/esm2022/lib/action/directive/debug/action.logger.directive.mjs +6 -12
  12. package/esm2022/lib/action/directive/map/action.map.directive.mjs +12 -11
  13. package/esm2022/lib/action/directive/map/action.map.key.directive.mjs +8 -11
  14. package/esm2022/lib/action/directive/map/action.map.source.directive.mjs +8 -13
  15. package/esm2022/lib/action/directive/map/action.map.working.disable.directive.mjs +8 -14
  16. package/esm2022/lib/action/directive/state/action.disabled.directive.mjs +8 -14
  17. package/esm2022/lib/action/directive/state/action.disableonsuccess.directive.mjs +8 -14
  18. package/esm2022/lib/action/directive/state/action.enforce.modified.directive.mjs +7 -13
  19. package/esm2022/lib/action/directive/state/action.handler.directive.mjs +11 -16
  20. package/esm2022/lib/action/directive/state/action.handler.instance.mjs +19 -17
  21. package/esm2022/lib/action/directive/state/action.presuccess.directive.mjs +14 -18
  22. package/esm2022/lib/action/directive/state/action.success.directive.mjs +14 -18
  23. package/esm2022/lib/action/directive/state/action.success.handler.directive.mjs +14 -20
  24. package/esm2022/lib/action/directive/state/action.value.directive.mjs +15 -18
  25. package/esm2022/lib/action/directive/state/action.value.stream.directive.mjs +20 -25
  26. package/esm2022/lib/action/directive/state/action.value.trigger.directive.mjs +22 -26
  27. package/esm2022/lib/action/directive/state/action.value.trigger.instance.mjs +6 -4
  28. package/esm2022/lib/action/directive/state/action.working.component.mjs +14 -18
  29. package/esm2022/lib/auth/auth.module.mjs +7 -7
  30. package/esm2022/lib/auth/auth.role.any.directive.mjs +8 -13
  31. package/esm2022/lib/auth/auth.role.has.directive.mjs +8 -13
  32. package/esm2022/lib/auth/auth.role.not.directive.mjs +12 -17
  33. package/esm2022/lib/auth/auth.state.module.mjs +4 -4
  34. package/esm2022/lib/auth/auth.state.service.mjs +7 -10
  35. package/esm2022/lib/auth/router/auth.router.module.mjs +4 -4
  36. package/esm2022/lib/auth/router/auth.router.service.mjs +9 -13
  37. package/esm2022/lib/auth/router/state/auth.router.state.module.mjs +4 -4
  38. package/esm2022/lib/auth/router/state/effect/auth.router.state.effect.mjs +17 -26
  39. package/esm2022/lib/auth/state/effect/auth.effect.mjs +20 -25
  40. package/esm2022/lib/button/action/action.button.directive.mjs +10 -19
  41. package/esm2022/lib/button/action/action.button.trigger.directive.mjs +8 -15
  42. package/esm2022/lib/button/button.directive.mjs +19 -20
  43. package/esm2022/lib/button/button.loading.directive.mjs +8 -14
  44. package/esm2022/lib/button/button.module.mjs +4 -4
  45. package/esm2022/lib/button/router/button.segue.directive.mjs +9 -14
  46. package/esm2022/lib/context/context.directive.mjs +8 -9
  47. package/esm2022/lib/context/context.module.mjs +4 -4
  48. package/esm2022/lib/context/context.service.mjs +7 -10
  49. package/esm2022/lib/context/state/effect/index.mjs +11 -16
  50. package/esm2022/lib/filter/filter.abstract.connector.directive.mjs +5 -7
  51. package/esm2022/lib/filter/filter.abstract.source.directive.mjs +6 -7
  52. package/esm2022/lib/filter/filter.connect.source.directive.mjs +7 -12
  53. package/esm2022/lib/filter/filter.connector.directive.mjs +3 -3
  54. package/esm2022/lib/filter/filter.map.connector.directive.mjs +3 -3
  55. package/esm2022/lib/filter/filter.map.directive.mjs +6 -9
  56. package/esm2022/lib/filter/filter.map.instance.directive.mjs +9 -12
  57. package/esm2022/lib/filter/filter.map.source.directive.mjs +4 -7
  58. package/esm2022/lib/filter/filter.module.mjs +4 -4
  59. package/esm2022/lib/filter/filter.source.directive.mjs +3 -3
  60. package/esm2022/lib/injection/injection.array.component.mjs +8 -10
  61. package/esm2022/lib/injection/injection.component.mjs +4 -4
  62. package/esm2022/lib/injection/injection.component.module.mjs +4 -4
  63. package/esm2022/lib/injection/injection.context.directive.mjs +12 -12
  64. package/esm2022/lib/injection/injection.context.forward.directive.mjs +6 -11
  65. package/esm2022/lib/injection/injection.directive.mjs +6 -9
  66. package/esm2022/lib/injection/injection.instance.mjs +10 -9
  67. package/esm2022/lib/ngrx/store.lockset.mjs +9 -7
  68. package/esm2022/lib/pipe/async/asobservable.pipe.mjs +3 -3
  69. package/esm2022/lib/pipe/async/async.pipe.module.mjs +4 -4
  70. package/esm2022/lib/pipe/date/date.pipe.module.mjs +5 -5
  71. package/esm2022/lib/pipe/date/datedayrange.pipe.mjs +3 -3
  72. package/esm2022/lib/pipe/date/datedaytimerange.pipe.mjs +3 -3
  73. package/esm2022/lib/pipe/date/datedistance.pipe.mjs +3 -3
  74. package/esm2022/lib/pipe/date/dateformatdistance.pipe.mjs +6 -11
  75. package/esm2022/lib/pipe/date/datefromtoformat.pipe.mjs +6 -11
  76. package/esm2022/lib/pipe/date/daterangedistance.pipe.mjs +3 -3
  77. package/esm2022/lib/pipe/date/datetimerange.pipe.mjs +3 -3
  78. package/esm2022/lib/pipe/date/datetimerangeonly.pipe.mjs +3 -3
  79. package/esm2022/lib/pipe/date/datetimerangeonlydistance.pipe.mjs +3 -3
  80. package/esm2022/lib/pipe/date/minutesstring.pipe.mjs +3 -3
  81. package/esm2022/lib/pipe/date/systemdatetotargetdate.pipe.mjs +3 -3
  82. package/esm2022/lib/pipe/date/targetdatetosystemdate.pipe.mjs +3 -3
  83. package/esm2022/lib/pipe/date/timedistance.pipe.mjs +5 -5
  84. package/esm2022/lib/pipe/date/timezoneabbreviation.pipe.mjs +3 -3
  85. package/esm2022/lib/pipe/date/tojsdate.pipe.mjs +3 -3
  86. package/esm2022/lib/pipe/date/tominutes.pipe.mjs +3 -3
  87. package/esm2022/lib/pipe/misc/misc.pipe.module.mjs +4 -4
  88. package/esm2022/lib/pipe/misc/prettyjson.pipe.mjs +3 -3
  89. package/esm2022/lib/pipe/pipe.module.mjs +4 -4
  90. package/esm2022/lib/pipe/value/dollar.pipe.mjs +3 -3
  91. package/esm2022/lib/pipe/value/getvalue.pipe.mjs +5 -5
  92. package/esm2022/lib/pipe/value/value.pipe.module.mjs +4 -4
  93. package/esm2022/lib/router/anchor/anchor.directive.mjs +10 -12
  94. package/esm2022/lib/router/router/provider/angular/angular.router.service.mjs +22 -25
  95. package/esm2022/lib/router/router/provider/angular/angular.router.service.module.mjs +4 -4
  96. package/esm2022/lib/router/router/provider/uirouter/uirouter.router.service.mjs +13 -14
  97. package/esm2022/lib/router/router/provider/uirouter/uirouter.router.service.module.mjs +4 -4
  98. package/esm2022/lib/router/router/transition/transition.directive.mjs +8 -11
  99. package/esm2022/lib/router/router/transition/transition.watcher.directive.mjs +7 -12
  100. package/esm2022/lib/router/router/util/route.default.mjs +6 -5
  101. package/esm2022/lib/router/router/util/route.reader.mjs +42 -42
  102. package/esm2022/lib/storage/storage.accessor.simple.factory.mjs +6 -13
  103. package/esm2022/lib/storage/storage.accessor.simple.mjs +6 -2
  104. package/esm2022/lib/storage/storage.accessor.string.mjs +2 -1
  105. package/esm2022/lib/storage/storage.module.mjs +4 -4
  106. package/esm2022/lib/storage/storage.object.localstorage.mjs +2 -1
  107. package/esm2022/lib/subscription/subscription.directive.mjs +8 -16
  108. package/esm2022/lib/view/if.directive.mjs +9 -12
  109. package/fesm2022/dereekb-dbx-core.mjs +821 -985
  110. package/fesm2022/dereekb-dbx-core.mjs.map +1 -1
  111. package/lib/action/action.handler.d.ts +1 -13
  112. package/lib/action/action.holder.d.ts +2 -2
  113. package/lib/action/action.store.source.d.ts +3 -7
  114. package/lib/action/directive/auto/action.automodify.directive.d.ts +1 -2
  115. package/lib/action/directive/auto/action.autotrigger.directive.d.ts +1 -2
  116. package/lib/action/directive/context/action.directive.d.ts +2 -3
  117. package/lib/action/directive/debug/action.logger.directive.d.ts +2 -3
  118. package/lib/action/directive/map/action.map.directive.d.ts +1 -3
  119. package/lib/action/directive/map/action.map.key.directive.d.ts +1 -3
  120. package/lib/action/directive/map/action.map.source.directive.d.ts +2 -4
  121. package/lib/action/directive/map/action.map.working.disable.directive.d.ts +2 -4
  122. package/lib/action/directive/state/action.disabled.directive.d.ts +2 -3
  123. package/lib/action/directive/state/action.disableonsuccess.directive.d.ts +2 -3
  124. package/lib/action/directive/state/action.enforce.modified.directive.d.ts +3 -4
  125. package/lib/action/directive/state/action.handler.directive.d.ts +1 -2
  126. package/lib/action/directive/state/action.presuccess.directive.d.ts +0 -4
  127. package/lib/action/directive/state/action.success.directive.d.ts +1 -4
  128. package/lib/action/directive/state/action.success.handler.directive.d.ts +4 -5
  129. package/lib/action/directive/state/action.value.directive.d.ts +5 -5
  130. package/lib/action/directive/state/action.value.stream.directive.d.ts +1 -2
  131. package/lib/action/directive/state/action.value.trigger.directive.d.ts +3 -4
  132. package/lib/action/directive/state/action.working.component.d.ts +1 -4
  133. package/lib/auth/auth.module.d.ts +1 -1
  134. package/lib/auth/auth.role.any.directive.d.ts +1 -4
  135. package/lib/auth/auth.role.has.directive.d.ts +1 -4
  136. package/lib/auth/auth.role.not.directive.d.ts +4 -7
  137. package/lib/auth/auth.state.service.d.ts +1 -3
  138. package/lib/auth/router/auth.router.service.d.ts +0 -1
  139. package/lib/auth/router/state/effect/auth.router.state.effect.d.ts +2 -6
  140. package/lib/auth/state/effect/auth.effect.d.ts +2 -5
  141. package/lib/button/action/action.button.directive.d.ts +2 -5
  142. package/lib/button/action/action.button.trigger.directive.d.ts +3 -4
  143. package/lib/button/button.directive.d.ts +7 -8
  144. package/lib/button/button.loading.directive.d.ts +2 -3
  145. package/lib/button/router/button.segue.directive.d.ts +1 -2
  146. package/lib/context/context.directive.d.ts +2 -2
  147. package/lib/context/context.service.d.ts +1 -3
  148. package/lib/context/state/effect/index.d.ts +5 -20
  149. package/lib/filter/filter.connect.source.directive.d.ts +3 -4
  150. package/lib/filter/filter.map.directive.d.ts +1 -2
  151. package/lib/filter/filter.map.instance.directive.d.ts +2 -3
  152. package/lib/injection/injection.array.component.d.ts +0 -1
  153. package/lib/injection/injection.context.directive.d.ts +1 -2
  154. package/lib/injection/injection.context.forward.directive.d.ts +1 -2
  155. package/lib/injection/injection.directive.d.ts +1 -3
  156. package/lib/pipe/date/dateformatdistance.pipe.d.ts +0 -1
  157. package/lib/pipe/date/datefromtoformat.pipe.d.ts +0 -1
  158. package/lib/router/router/provider/angular/angular.router.service.d.ts +0 -1
  159. package/lib/router/router/provider/uirouter/uirouter.router.service.d.ts +1 -1
  160. package/lib/router/router/transition/transition.directive.d.ts +0 -1
  161. package/lib/router/router/transition/transition.watcher.directive.d.ts +1 -3
  162. package/lib/router/router/util/route.reader.d.ts +16 -24
  163. package/lib/storage/storage.accessor.simple.factory.d.ts +0 -1
  164. package/lib/subscription/subscription.directive.d.ts +3 -3
  165. package/lib/view/if.directive.d.ts +3 -4
  166. package/package.json +1 -1
@@ -8,8 +8,13 @@ import * as i0 from "@angular/core";
8
8
  * Abstract button component.
9
9
  */
10
10
  export declare abstract class AbstractDbxButtonDirective extends AbstractSubscriptionDirective implements DbxButton, OnInit, OnDestroy {
11
- private _disabled;
12
- private _working;
11
+ private readonly _disabled;
12
+ private readonly _working;
13
+ /**
14
+ * Pre-interceptor button click.
15
+ */
16
+ protected readonly _buttonClick: Subject<void>;
17
+ protected readonly _buttonInterceptor: BehaviorSubject<Maybe<DbxButtonInterceptor>>;
13
18
  readonly disabled$: import("rxjs").Observable<boolean>;
14
19
  readonly working$: import("rxjs").Observable<boolean>;
15
20
  get disabled(): boolean;
@@ -23,12 +28,6 @@ export declare abstract class AbstractDbxButtonDirective extends AbstractSubscri
23
28
  get buttonDisplayType(): DbxButtonDisplayContentType;
24
29
  readonly buttonClick: EventEmitter<any>;
25
30
  readonly clicked$: import("rxjs").Observable<any>;
26
- constructor();
27
- /**
28
- * Pre-interceptor button click.
29
- */
30
- protected _buttonClick: Subject<void>;
31
- protected _buttonInterceptor: BehaviorSubject<Maybe<DbxButtonInterceptor>>;
32
31
  ngOnInit(): void;
33
32
  ngOnDestroy(): void;
34
33
  /**
@@ -9,13 +9,12 @@ import * as i0 from "@angular/core";
9
9
  * It will be set working when the context is set loading.
10
10
  */
11
11
  export declare class DbxLoadingButtonDirective extends AbstractSubscriptionDirective {
12
- readonly button: DbxButton;
12
+ readonly dbxButton: DbxButton;
13
13
  readonly ngZone: NgZone;
14
- constructor(button: DbxButton, ngZone: NgZone);
15
14
  /**
16
15
  * Sets a LoadingContext that is watched for the loading state.
17
16
  */
18
17
  set context(context: LoadingContext);
19
- static ɵfac: i0.ɵɵFactoryDeclaration<DbxLoadingButtonDirective, [{ host: true; }, null]>;
18
+ static ɵfac: i0.ɵɵFactoryDeclaration<DbxLoadingButtonDirective, never>;
20
19
  static ɵdir: i0.ɵɵDirectiveDeclaration<DbxLoadingButtonDirective, "[dbxLoadingButton]", never, { "context": { "alias": "dbxLoadingButton"; "required": false; }; }, {}, never, never, false, never>;
21
20
  }
@@ -7,11 +7,10 @@ import * as i0 from "@angular/core";
7
7
  export declare class DbxButtonSegueDirective extends AbstractSubscriptionDirective implements OnInit, OnDestroy {
8
8
  readonly dbxButton: DbxButton;
9
9
  readonly dbxRouterService: DbxRouterService;
10
- private _segueRef;
10
+ private readonly _segueRef;
11
11
  readonly segueRef$: import("rxjs").Observable<SegueRef<object>>;
12
12
  get segueRef(): Maybe<SegueRef>;
13
13
  set segueRef(segueRef: Maybe<SegueRef>);
14
- constructor(dbxButton: DbxButton, dbxRouterService: DbxRouterService);
15
14
  ngOnInit(): void;
16
15
  ngOnDestroy(): void;
17
16
  static ɵfac: i0.ɵɵFactoryDeclaration<DbxButtonSegueDirective, never>;
@@ -9,8 +9,8 @@ import * as i0 from "@angular/core";
9
9
  */
10
10
  export declare class DbxAppContextStateDirective extends AbstractSubscriptionDirective implements OnInit, OnDestroy {
11
11
  readonly dbxAppContextStateService: DbxAppContextService;
12
- private _state;
13
- constructor(dbxAppContextStateService: DbxAppContextService);
12
+ private readonly _state;
13
+ constructor();
14
14
  ngOnInit(): void;
15
15
  ngOnDestroy(): void;
16
16
  set state(state: Maybe<DbxAppContextState>);
@@ -1,14 +1,12 @@
1
1
  import { Store } from '@ngrx/store';
2
2
  import { DbxAppContextState } from './context';
3
- import { DbxAppContextFullState } from './state/state';
4
3
  import * as i0 from "@angular/core";
5
4
  /**
6
5
  * State for accessing the app's DbxAppContextState defined within the DbxAppContextFullState for the ngrx store.
7
6
  */
8
7
  export declare class DbxAppContextService {
9
- readonly store: Store<DbxAppContextFullState>;
8
+ readonly store: Store<any>;
10
9
  readonly state$: import("rxjs").Observable<string>;
11
- constructor(store: Store<DbxAppContextFullState>);
12
10
  setState(state: DbxAppContextState): void;
13
11
  resetState(): void;
14
12
  static ɵfac: i0.ɵɵFactoryDeclaration<DbxAppContextService, never>;
@@ -2,33 +2,18 @@ import { OnRunEffects, Actions, EffectNotification } from '@ngrx/effects';
2
2
  import { Store } from '@ngrx/store';
3
3
  import { Observable } from 'rxjs';
4
4
  import { DbxAppContextState } from '../../context';
5
- import { ArrayOrValue } from '@dereekb/util';
5
+ import { IterableOrValue } from '@dereekb/util';
6
6
  /**
7
7
  * Abstract effects class that only runs/allows effects when the DbxAppContextState in the ngrx state matches input activeState value.
8
8
  */
9
9
  export declare abstract class AbstractOnDbxAppContextStateEffects<S = unknown> implements OnRunEffects {
10
+ protected readonly actions$: Actions<any>;
11
+ protected readonly store: Store<any>;
10
12
  /**
11
- * ngrx Actions
13
+ * The set of state(s) to activate on.
12
14
  */
13
- protected readonly actions$: Actions;
14
- /**
15
- * ngrx Store
16
- */
17
- protected readonly store: Store<S>;
18
15
  private _activeStatesSet;
19
- constructor(
20
- /**
21
- * The state(s) to activate on.
22
- */
23
- activeStates: ArrayOrValue<DbxAppContextState>,
24
- /**
25
- * ngrx Actions
26
- */
27
- actions$: Actions,
28
- /**
29
- * ngrx Store
30
- */
31
- store: Store<S>);
16
+ constructor(activeStates: IterableOrValue<DbxAppContextState>);
32
17
  /**
33
18
  * Configures all actions of the sub-class to only activate when the DbxAppContextState in App
34
19
  *
@@ -5,10 +5,9 @@ import * as i0 from "@angular/core";
5
5
  * Connects the host FilterSource to a FilterSourceConnector.
6
6
  */
7
7
  export declare class DbxFilterConnectSourceDirective<F = unknown> implements OnInit {
8
- readonly filterSource: FilterSource<F>;
9
- readonly filterSourceConnector: FilterSourceConnector<F>;
10
- constructor(filterSource: FilterSource<F>, filterSourceConnector: FilterSourceConnector<F>);
8
+ readonly filterSource: FilterSource<any>;
9
+ readonly filterSourceConnector: FilterSourceConnector<any>;
11
10
  ngOnInit(): void;
12
- static ɵfac: i0.ɵɵFactoryDeclaration<DbxFilterConnectSourceDirective<any>, [{ host: true; }, null]>;
11
+ static ɵfac: i0.ɵɵFactoryDeclaration<DbxFilterConnectSourceDirective<any>, never>;
13
12
  static ɵdir: i0.ɵɵDirectiveDeclaration<DbxFilterConnectSourceDirective<any>, "[dbxFilterConnectSource]", never, {}, {}, never, never, false, never>;
14
13
  }
@@ -5,8 +5,7 @@ import * as i0 from "@angular/core";
5
5
  * Direction that provides an FilterMap.
6
6
  */
7
7
  export declare class DbxFilterMapDirective<F> implements OnDestroy {
8
- readonly filterMap: FilterMap<F>;
9
- constructor(filterMap: FilterMap<F>);
8
+ readonly filterMap: FilterMap<any>;
10
9
  ngOnDestroy(): void;
11
10
  static ɵfac: i0.ɵɵFactoryDeclaration<DbxFilterMapDirective<any>, never>;
12
11
  static ɵdir: i0.ɵɵDirectiveDeclaration<DbxFilterMapDirective<any>, "[dbxFilterMap]", ["dbxFilterMap"], {}, {}, never, never, false, never>;
@@ -7,11 +7,10 @@ import * as i0 from "@angular/core";
7
7
  * Provides a FilterSource from a parent FilterMap.
8
8
  */
9
9
  export declare abstract class AbstractDbxFilterMapInstanceDirective<F> implements OnDestroy {
10
- readonly dbxFilterMap: FilterMap<F>;
11
10
  protected _key: BehaviorSubject<Maybe<string>>;
11
+ readonly dbxFilterMap: FilterMap<any>;
12
12
  readonly key$: import("rxjs").Observable<string>;
13
- readonly instance$: import("rxjs").Observable<import("@dereekb/rxjs").FilterMapKeyInstance<F>>;
14
- constructor(dbxFilterMap: FilterMap<F>);
13
+ readonly instance$: import("rxjs").Observable<import("@dereekb/rxjs").FilterMapKeyInstance<any>>;
15
14
  ngOnDestroy(): void;
16
15
  static ɵfac: i0.ɵɵFactoryDeclaration<AbstractDbxFilterMapInstanceDirective<any>, never>;
17
16
  static ɵdir: i0.ɵɵDirectiveDeclaration<AbstractDbxFilterMapInstanceDirective<any>, never, never, {}, {}, never, never, false, never>;
@@ -9,7 +9,6 @@ export declare class DbxInjectionArrayComponent implements OnDestroy {
9
9
  private _entries;
10
10
  readonly entries$: import("rxjs").Observable<DbxInjectionArrayEntry<unknown>[]>;
11
11
  readonly trackByKeyFn: TrackByFunction<DbxInjectionArrayEntry>;
12
- constructor();
13
12
  ngOnDestroy(): void;
14
13
  get entries(): DbxInjectionArrayEntry[];
15
14
  set entries(entries: Maybe<DbxInjectionArrayEntry[]>);
@@ -1,4 +1,4 @@
1
- import { Injector, TemplateRef, ViewContainerRef, OnDestroy, OnInit } from '@angular/core';
1
+ import { OnDestroy, OnInit } from '@angular/core';
2
2
  import { DbxInjectionContext, DbxInjectionContextConfig } from './injection.context';
3
3
  import { DbxInjectionComponentConfig } from './injection';
4
4
  import { Maybe } from '@dereekb/util';
@@ -14,7 +14,6 @@ export declare class DbxInjectionContextDirective<O = unknown> implements DbxInj
14
14
  private _instance;
15
15
  private _embeddedView;
16
16
  private _isDetached;
17
- constructor(_injector: Injector, _templateRef: TemplateRef<O>, _viewContainer: ViewContainerRef);
18
17
  set config(config: Maybe<DbxInjectionComponentConfig<unknown>>);
19
18
  ngOnInit(): void;
20
19
  ngOnDestroy(): void;
@@ -8,9 +8,8 @@ import * as i0 from "@angular/core";
8
8
  */
9
9
  export declare abstract class AbstractForwardDbxInjectionContextDirective implements DbxInjectionContext {
10
10
  readonly dbxInjectionContext: DbxInjectionContext;
11
- constructor(dbxInjectionContext: DbxInjectionContext);
12
11
  showContext<T = unknown, O = unknown>(config: DbxInjectionContextConfig<T, unknown>): Promise<O>;
13
12
  resetContext(): boolean;
14
- static ɵfac: i0.ɵɵFactoryDeclaration<AbstractForwardDbxInjectionContextDirective, [{ host: true; }]>;
13
+ static ɵfac: i0.ɵɵFactoryDeclaration<AbstractForwardDbxInjectionContextDirective, never>;
15
14
  static ɵdir: i0.ɵɵDirectiveDeclaration<AbstractForwardDbxInjectionContextDirective, never, never, {}, {}, never, never, false, never>;
16
15
  }
@@ -1,4 +1,4 @@
1
- import { ViewContainerRef, OnInit, OnDestroy, Injector } from '@angular/core';
1
+ import { ViewContainerRef, OnInit, OnDestroy } from '@angular/core';
2
2
  import { Maybe } from '@dereekb/util';
3
3
  import { DbxInjectionComponentConfig, DbxInjectionTemplateConfig } from './injection';
4
4
  import * as i0 from "@angular/core";
@@ -6,9 +6,7 @@ import * as i0 from "@angular/core";
6
6
  * Abstract directive that injects content based on the configuration into the view.
7
7
  */
8
8
  export declare abstract class AbstractDbxInjectionDirective<T> implements OnInit, OnDestroy {
9
- private readonly _injector;
10
9
  private _instance;
11
- constructor(_injector: Injector);
12
10
  ngOnInit(): void;
13
11
  ngOnDestroy(): void;
14
12
  setConfig(config: Maybe<DbxInjectionComponentConfig<T>>): void;
@@ -6,7 +6,6 @@ import * as i0 from "@angular/core";
6
6
  */
7
7
  export declare class DateFormatDistancePipe implements PipeTransform {
8
8
  private locale;
9
- constructor(locale: string);
10
9
  transform(input: Maybe<DateOrDateString>, format: string, includeSeconds?: boolean): Maybe<string>;
11
10
  static ɵfac: i0.ɵɵFactoryDeclaration<DateFormatDistancePipe, never>;
12
11
  static ɵpipe: i0.ɵɵPipeDeclaration<DateFormatDistancePipe, "dateFormatDistance", false>;
@@ -7,7 +7,6 @@ import * as i0 from "@angular/core";
7
7
  export declare class DateFromToTimePipe implements PipeTransform {
8
8
  private locale;
9
9
  static formatFromTo(input: Maybe<DateOrDateString>, format: string, minutes: number, locale: string): Maybe<string>;
10
- constructor(locale: string);
11
10
  transform(input: Maybe<DateOrDateString>, format: string, minutes: number): Maybe<string>;
12
11
  static ɵfac: i0.ɵɵFactoryDeclaration<DateFromToTimePipe, never>;
13
12
  static ɵpipe: i0.ɵɵPipeDeclaration<DateFromToTimePipe, "dateFromPlusTo", false>;
@@ -13,7 +13,6 @@ export declare class DbxAngularRouterService implements DbxRouterService, DbxRou
13
13
  readonly activatedRoute: ActivatedRoute;
14
14
  readonly params$: Observable<SegueRefRawSegueParams>;
15
15
  readonly transitions$: Observable<DbxRouterTransitionEvent>;
16
- constructor(router: Router, activatedRoute: ActivatedRoute);
17
16
  go(input: ObservableOrValue<SegueRefOrSegueRefRouterLink<NavigationExtras | NavigationBehaviorOptions>>): Promise<boolean>;
18
17
  updateParams(inputParams: ObservableOrValue<SegueRefRawSegueParams>): Promise<boolean>;
19
18
  isActive(segueRef: SegueRefOrSegueRefRouterLink): boolean;
@@ -17,7 +17,7 @@ export declare class DbxUIRouterService implements DbxRouterService, DbxRouterTr
17
17
  readonly params$: Observable<SegueRefRawSegueParams>;
18
18
  private readonly _transitions;
19
19
  readonly transitions$: Observable<DbxRouterTransitionEvent>;
20
- constructor(state: StateService, transitionService: TransitionService, uiRouterGlobals: UIRouterGlobals);
20
+ constructor();
21
21
  ngOnDestroy(): void;
22
22
  get params(): import("@uirouter/core").StateParams;
23
23
  go(input: ObservableOrValue<SegueRefOrSegueRefRouterLink<TransitionOptions>>): Promise<boolean>;
@@ -8,7 +8,6 @@ export declare abstract class AbstractTransitionDirective {
8
8
  protected readonly dbxRouterTransitionService: DbxRouterTransitionService;
9
9
  readonly transitionSuccess$: Observable<import("@dereekb/dbx-core").DbxRouterTransitionEvent>;
10
10
  readonly initAndUpdateOnTransitionSuccess$: Observable<void>;
11
- constructor(dbxRouterTransitionService: DbxRouterTransitionService);
12
11
  static ɵfac: i0.ɵɵFactoryDeclaration<AbstractTransitionDirective, never>;
13
12
  static ɵdir: i0.ɵɵDirectiveDeclaration<AbstractTransitionDirective, never, never, {}, {}, never, never, false, never>;
14
13
  }
@@ -1,16 +1,14 @@
1
1
  import { NgZone, OnDestroy, OnInit } from '@angular/core';
2
- import { DbxRouterTransitionService } from '../service/router.transition.service';
3
2
  import { AbstractTransitionDirective } from './transition.directive';
4
3
  import * as i0 from "@angular/core";
5
4
  /**
6
5
  * Abstract directive that listens to onSuccess transition events and runs a function.
7
6
  */
8
7
  export declare abstract class AbstractTransitionWatcherDirective extends AbstractTransitionDirective implements OnInit, OnDestroy {
9
- protected readonly ngZone: NgZone;
10
8
  private _transitionSub;
9
+ protected readonly ngZone: NgZone;
11
10
  ngOnInit(): void;
12
11
  ngOnDestroy(): void;
13
- constructor(dbxRouterTransitionService: DbxRouterTransitionService, ngZone: NgZone);
14
12
  protected zoneUpdateForSuccessfulTransition(): void;
15
13
  protected abstract updateForSuccessfulTransition(): void;
16
14
  static ɵfac: i0.ɵɵFactoryDeclaration<AbstractTransitionWatcherDirective, never>;
@@ -19,10 +19,13 @@ export interface DbxRouteParamReader<T> {
19
19
  */
20
20
  readonly value$: Observable<Maybe<T>>;
21
21
  /**
22
- * Param key getter/setters.
22
+ * Returns the current param key.
23
23
  */
24
- get paramKey(): string;
25
- set paramKey(paramKey: Maybe<string>);
24
+ getParamKey(): string;
25
+ /**
26
+ * Sets a new param key. If the value is undefined, the param reader will use the default key.
27
+ */
28
+ setParamKey(paramKey: Maybe<string>): void;
26
29
  /**
27
30
  * Sets the default value source.
28
31
  *
@@ -36,29 +39,18 @@ export interface DbxRouteParamReader<T> {
36
39
  */
37
40
  setParamValue(value: MaybeObservableOrValueGetter<T>): void;
38
41
  }
39
- /**
40
- * Utility class used for reading a single value from the DbxRouterService.
41
- */
42
- export declare class DbxRouteParamReaderInstance<T> implements DbxRouteParamReader<T>, Destroyable {
42
+ export interface DbxRouteParamReaderInstance<T> extends DbxRouteParamReader<T>, Destroyable {
43
43
  readonly dbxRouterService: DbxRouterService;
44
- readonly defaultParamKey: string;
45
- readonly defaultValue?: MaybeObservableOrValueGetter<T>;
46
- private _paramKey;
47
44
  readonly paramKey$: Observable<string>;
48
- private _defaultValue;
49
- readonly paramValue$: Observable<Maybe<T>>;
50
45
  readonly nextDefaultValue$: Observable<Maybe<T>>;
51
- readonly defaultValue$: Observable<Maybe<T>>;
52
46
  readonly value$: Observable<Maybe<T>>;
53
- constructor(dbxRouterService: DbxRouterService, defaultParamKey: string, defaultValue?: MaybeObservableOrValueGetter<T>);
54
- destroy(): void;
55
- get paramKey(): string;
56
- set paramKey(paramKey: Maybe<string>);
57
- setDefaultValue(defaultValue: MaybeObservableOrValueGetter<T>): void;
58
- /**
59
- * Convenience function to set the param value on the router.
60
- *
61
- * @param value
62
- */
63
- setParamValue(value: MaybeObservableOrValueGetter<T>): void;
64
47
  }
48
+ /**
49
+ * Creates a new DbxRouteParamReaderInstance from the input.
50
+ *
51
+ * @param dbxRouterService
52
+ * @param defaultParamKey
53
+ * @param defaultValue
54
+ * @returns
55
+ */
56
+ export declare function dbxRouteParamReaderInstance<T>(dbxRouterService: DbxRouterService, defaultParamKey: string, defaultValue?: MaybeObservableOrValueGetter<T>): DbxRouteParamReaderInstance<T>;
@@ -11,7 +11,6 @@ export interface StorageAccessorFactoryConfig<T> extends SimpleStorageAccessorCo
11
11
  */
12
12
  export declare class SimpleStorageAccessorFactory {
13
13
  readonly storageObject: FullStorageObject;
14
- constructor(storageObject: FullStorageObject);
15
14
  createStorageAccessor<T>(config: StorageAccessorFactoryConfig<T>): SimpleStorageAccessor<T>;
16
15
  static ɵfac: i0.ɵɵFactoryDeclaration<SimpleStorageAccessorFactory, never>;
17
16
  static ɵprov: i0.ɵɵInjectableDeclaration<SimpleStorageAccessorFactory>;
@@ -1,15 +1,15 @@
1
1
  import { OnDestroy } from '@angular/core';
2
2
  import { Subscription } from 'rxjs';
3
3
  import { LockSet } from '@dereekb/rxjs';
4
+ import { Maybe } from '@dereekb/util';
4
5
  import * as i0 from "@angular/core";
5
6
  /**
6
7
  * Abstract component that contains a SubscriptionObject and will clean it up automatically.
7
8
  */
8
9
  export declare abstract class AbstractSubscriptionDirective implements OnDestroy {
9
- private _subscriptionObject;
10
- constructor(subscription?: Subscription);
10
+ private readonly _subscriptionObject;
11
11
  ngOnDestroy(): void;
12
- protected set sub(subscription: Subscription | undefined);
12
+ protected set sub(subscription: Maybe<Subscription | undefined>);
13
13
  static ɵfac: i0.ɵɵFactoryDeclaration<AbstractSubscriptionDirective, never>;
14
14
  static ɵdir: i0.ɵɵDirectiveDeclaration<AbstractSubscriptionDirective, never, never, {}, {}, never, never, false, never>;
15
15
  }
@@ -1,4 +1,4 @@
1
- import { OnInit, TemplateRef, ViewContainerRef } from '@angular/core';
1
+ import { OnInit } from '@angular/core';
2
2
  import { Observable } from 'rxjs';
3
3
  import { AbstractSubscriptionDirective } from '../subscription';
4
4
  import * as i0 from "@angular/core";
@@ -6,13 +6,12 @@ import * as i0 from "@angular/core";
6
6
  * Abstract directive class that watches a show$ observable and behaves like *ngIf.
7
7
  */
8
8
  export declare abstract class AbstractIfDirective extends AbstractSubscriptionDirective implements OnInit {
9
- private templateRef;
10
- private viewContainer;
9
+ private readonly _templateRef;
10
+ private readonly _viewContainer;
11
11
  /**
12
12
  * Observable that is watched for showing/hiding.
13
13
  */
14
14
  abstract readonly show$: Observable<boolean>;
15
- constructor(templateRef: TemplateRef<unknown>, viewContainer: ViewContainerRef);
16
15
  ngOnInit(): void;
17
16
  static ɵfac: i0.ɵɵFactoryDeclaration<AbstractIfDirective, never>;
18
17
  static ɵdir: i0.ɵɵDirectiveDeclaration<AbstractIfDirective, never, never, {}, {}, never, never, false, never>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dereekb/dbx-core",
3
- "version": "10.1.30",
3
+ "version": "11.0.0",
4
4
  "peerDependencies": {
5
5
  "@dereekb/util": "*",
6
6
  "@dereekb/rxjs": "*",