@kuzntsv/uikit 1.0.60 → 1.0.62

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.
@@ -1,5 +1,5 @@
1
1
  import * as i0 from "@angular/core";
2
- import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Directive, ElementRef, HostListener, Injectable, InjectionToken, NgZone, Pipe, computed, effect, inject, input, linkedSignal, makeEnvironmentProviders, model, output, signal, viewChild } from "@angular/core";
2
+ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Directive, ElementRef, HostListener, Injectable, InjectionToken, Injector, NgZone, Pipe, computed, effect, inject, input, linkedSignal, makeEnvironmentProviders, model, output, runInInjectionContext, signal, viewChild } from "@angular/core";
3
3
  import { Router, RouterLink } from "@angular/router";
4
4
  import { ReplaySubject, Subject, Subscription, filter, finalize, forkJoin, map, of, startWith, switchMap, take, tap } from "rxjs";
5
5
  import { API_NAME, AuthService, HIDE_ROLE_MARKER, NotificationService, RoleService, UIKIT_NOTIFICATION_TOKEN } from "@kuzntsv/uikit";
@@ -2736,6 +2736,7 @@ i0.ɵɵngDeclareClassMetadata({
2736
2736
  });
2737
2737
  var BaseSignalPageClass = class BaseSignalPageClass {
2738
2738
  dialog = inject(MatDialog);
2739
+ injector = inject(Injector);
2739
2740
  entityService;
2740
2741
  entityEditComponent;
2741
2742
  extraData;
@@ -2763,13 +2764,13 @@ var BaseSignalPageClass = class BaseSignalPageClass {
2763
2764
  allowMultiSelect = false;
2764
2765
  selected = [];
2765
2766
  dataResource = computed(() => {
2766
- this.tableState();
2767
- this.filters();
2768
- return this.fnGetData();
2767
+ const currentState = this.tableState();
2768
+ const currentFilters = this.filters();
2769
+ return runInInjectionContext(this.injector, () => this.fnGetData(currentState, currentFilters));
2769
2770
  }, ...ngDevMode ? [{ debugName: "dataResource" }] : /* istanbul ignore next */ []);
2770
2771
  countResource = computed(() => {
2771
- this.filters();
2772
- return this.fnGetCount();
2772
+ const currentFilters = this.filters();
2773
+ return runInInjectionContext(this.injector, () => this.fnGetCount(currentFilters));
2773
2774
  }, ...ngDevMode ? [{ debugName: "countResource" }] : /* istanbul ignore next */ []);
2774
2775
  data = computed(() => {
2775
2776
  const rawData = this.dataResource()?.value() || [];