@abp/ng.core 7.0.1 → 7.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm2020/lib/abstracts/auth-response.model.mjs +2 -0
- package/esm2020/lib/abstracts/auth.service.mjs +6 -3
- package/esm2020/lib/abstracts/index.mjs +2 -1
- package/esm2020/lib/abstracts/ng-model.component.mjs +1 -1
- package/esm2020/lib/clients/http.client.mjs +34 -0
- package/esm2020/lib/clients/index.mjs +2 -0
- package/esm2020/lib/components/dynamic-layout.component.mjs +6 -4
- package/esm2020/lib/components/replaceable-route-container.component.mjs +1 -1
- package/esm2020/lib/directives/debounce.directive.mjs +1 -1
- package/esm2020/lib/directives/for.directive.mjs +20 -12
- package/esm2020/lib/directives/form-submit.directive.mjs +2 -2
- package/esm2020/lib/directives/replaceable-template.directive.mjs +9 -5
- package/esm2020/lib/directives/stop-propagation.directive.mjs +2 -2
- package/esm2020/lib/handlers/routes.handler.mjs +9 -7
- package/esm2020/lib/interceptors/api.interceptor.mjs +3 -2
- package/esm2020/lib/models/auth.mjs +1 -1
- package/esm2020/lib/models/dtos.mjs +6 -6
- package/esm2020/lib/models/environment.mjs +1 -1
- package/esm2020/lib/models/session.mjs +1 -1
- package/esm2020/lib/providers/include-localization-resources.provider.mjs +2 -2
- package/esm2020/lib/providers/locale.provider.mjs +6 -2
- package/esm2020/lib/proxy/pages/abp/multi-tenancy/abp-tenant.service.mjs +1 -1
- package/esm2020/lib/proxy/volo/abp/asp-net-core/mvc/api-exploring/abp-api-definition.service.mjs +1 -1
- package/esm2020/lib/proxy/volo/abp/asp-net-core/mvc/application-configurations/abp-application-configuration.service.mjs +1 -1
- package/esm2020/lib/proxy/volo/abp/asp-net-core/mvc/application-configurations/abp-application-localization.service.mjs +2 -2
- package/esm2020/lib/proxy/volo/abp/http/modeling/models.mjs +1 -1
- package/esm2020/lib/proxy/volo/abp/localization/models.mjs +1 -1
- package/esm2020/lib/services/config-state.service.mjs +4 -1
- package/esm2020/lib/services/dom-insertion.service.mjs +6 -4
- package/esm2020/lib/services/environment.service.mjs +5 -5
- package/esm2020/lib/services/http-wait.service.mjs +4 -1
- package/esm2020/lib/services/lazy-load.service.mjs +6 -4
- package/esm2020/lib/services/localization.service.mjs +7 -7
- package/esm2020/lib/services/multi-tenancy.service.mjs +1 -1
- package/esm2020/lib/services/permission.service.mjs +1 -1
- package/esm2020/lib/services/replaceable-components.service.mjs +1 -1
- package/esm2020/lib/services/resource-wait.service.mjs +2 -2
- package/esm2020/lib/services/rest.service.mjs +2 -3
- package/esm2020/lib/services/router-events.service.mjs +2 -2
- package/esm2020/lib/services/routes.service.mjs +2 -2
- package/esm2020/lib/services/session-state.service.mjs +1 -1
- package/esm2020/lib/services/subscription.service.mjs +4 -2
- package/esm2020/lib/strategies/content-security.strategy.mjs +4 -2
- package/esm2020/lib/strategies/content.strategy.mjs +6 -2
- package/esm2020/lib/strategies/context.strategy.mjs +1 -1
- package/esm2020/lib/strategies/cross-origin.strategy.mjs +4 -2
- package/esm2020/lib/strategies/loading.strategy.mjs +1 -1
- package/esm2020/lib/tokens/http-context.token.mjs +3 -0
- package/esm2020/lib/tokens/include-localization-resources.token.mjs +2 -2
- package/esm2020/lib/tokens/index.mjs +2 -1
- package/esm2020/lib/tokens/localization.token.mjs +1 -1
- package/esm2020/lib/tokens/set-token-response-to-storage.token.mjs +4 -1
- package/esm2020/lib/utils/common-utils.mjs +4 -1
- package/esm2020/lib/utils/date-utils.mjs +3 -3
- package/esm2020/lib/utils/environment-utils.mjs +2 -2
- package/esm2020/lib/utils/factory-utils.mjs +2 -2
- package/esm2020/lib/utils/internal-store-utils.mjs +2 -1
- package/esm2020/lib/utils/lazy-load-utils.mjs +2 -2
- package/esm2020/lib/utils/localization-utils.mjs +1 -1
- package/esm2020/lib/utils/multi-tenancy-utils.mjs +7 -4
- package/esm2020/lib/utils/object-utils.mjs +1 -1
- package/esm2020/lib/utils/route-utils.mjs +2 -2
- package/esm2020/lib/utils/tree-utils.mjs +1 -1
- package/esm2020/lib/validators/range.validator.mjs +1 -1
- package/esm2020/lib/validators/required.validator.mjs +1 -1
- package/esm2020/lib/validators/string-length.validator.mjs +1 -1
- package/esm2020/lib/validators/username.validator.mjs +2 -2
- package/esm2020/locale/utils/register-locale.mjs +2 -2
- package/esm2020/public-api.mjs +2 -1
- package/esm2020/testing/lib/services/mock-permission.service.mjs +1 -1
- package/esm2020/testing/lib/services/mock-rest.service.mjs +2 -2
- package/fesm2015/abp-ng.core-locale.mjs +1 -1
- package/fesm2015/abp-ng.core-locale.mjs.map +1 -1
- package/fesm2015/abp-ng.core-testing.mjs.map +1 -1
- package/fesm2015/abp-ng.core.mjs +163 -75
- package/fesm2015/abp-ng.core.mjs.map +1 -1
- package/fesm2020/abp-ng.core-locale.mjs +1 -1
- package/fesm2020/abp-ng.core-locale.mjs.map +1 -1
- package/fesm2020/abp-ng.core-testing.mjs.map +1 -1
- package/fesm2020/abp-ng.core.mjs +153 -71
- package/fesm2020/abp-ng.core.mjs.map +1 -1
- package/lib/abstracts/auth-response.model.d.ts +10 -0
- package/lib/abstracts/auth.service.d.ts +4 -1
- package/lib/abstracts/index.d.ts +1 -0
- package/lib/abstracts/ng-model.component.d.ts +4 -4
- package/lib/clients/http.client.d.ts +11 -0
- package/lib/clients/index.d.ts +1 -0
- package/lib/components/dynamic-layout.component.d.ts +2 -2
- package/lib/components/replaceable-route-container.component.d.ts +1 -1
- package/lib/directives/for.directive.d.ts +6 -6
- package/lib/directives/form-submit.directive.d.ts +1 -1
- package/lib/models/auth.d.ts +4 -1
- package/lib/models/dtos.d.ts +11 -11
- package/lib/models/environment.d.ts +3 -1
- package/lib/models/session.d.ts +1 -1
- package/lib/providers/include-localization-resources.provider.d.ts +1 -1
- package/lib/proxy/volo/abp/http/modeling/models.d.ts +1 -1
- package/lib/proxy/volo/abp/localization/models.d.ts +1 -0
- package/lib/services/config-state.service.d.ts +5 -3
- package/lib/services/dom-insertion.service.d.ts +1 -1
- package/lib/services/environment.service.d.ts +1 -1
- package/lib/services/localization.service.d.ts +5 -2
- package/lib/services/multi-tenancy.service.d.ts +1 -1
- package/lib/services/permission.service.d.ts +2 -2
- package/lib/services/replaceable-components.service.d.ts +2 -2
- package/lib/services/rest.service.d.ts +1 -1
- package/lib/services/router-events.service.d.ts +2 -2
- package/lib/services/routes.service.d.ts +3 -1
- package/lib/services/session-state.service.d.ts +1 -1
- package/lib/services/subscription.service.d.ts +1 -1
- package/lib/strategies/cross-origin.strategy.d.ts +2 -2
- package/lib/tokens/http-context.token.d.ts +2 -0
- package/lib/tokens/include-localization-resources.token.d.ts +1 -1
- package/lib/tokens/index.d.ts +1 -0
- package/lib/tokens/localization.token.d.ts +2 -2
- package/lib/tokens/set-token-response-to-storage.token.d.ts +3 -0
- package/lib/utils/common-utils.d.ts +9 -8
- package/lib/utils/factory-utils.d.ts +3 -1
- package/lib/utils/localization-utils.d.ts +1 -1
- package/lib/utils/object-utils.d.ts +2 -1
- package/lib/utils/route-utils.d.ts +2 -2
- package/lib/utils/tree-utils.d.ts +3 -3
- package/package.json +3 -3
- package/public-api.d.ts +1 -0
|
@@ -1,12 +1,13 @@
|
|
|
1
|
+
import { HttpHeaders } from '@angular/common/http';
|
|
1
2
|
import { Params } from '@angular/router';
|
|
2
3
|
import { Observable } from 'rxjs';
|
|
3
4
|
import { LoginParams } from '../models/auth';
|
|
5
|
+
import { AbpAuthResponse } from './auth-response.model';
|
|
4
6
|
import * as i0 from "@angular/core";
|
|
5
7
|
/**
|
|
6
8
|
* Abstract service for Authentication.
|
|
7
9
|
*/
|
|
8
10
|
export declare class AuthService implements IAuthService {
|
|
9
|
-
constructor();
|
|
10
11
|
private warningMessage;
|
|
11
12
|
init(): Promise<any>;
|
|
12
13
|
login(params: LoginParams): Observable<any>;
|
|
@@ -14,6 +15,7 @@ export declare class AuthService implements IAuthService {
|
|
|
14
15
|
navigateToLogin(queryParams?: Params): void;
|
|
15
16
|
get isInternalAuth(): boolean;
|
|
16
17
|
get isAuthenticated(): boolean;
|
|
18
|
+
loginUsingGrant(grantType: string, parameters: object, headers?: HttpHeaders): Promise<AbpAuthResponse>;
|
|
17
19
|
static ɵfac: i0.ɵɵFactoryDeclaration<AuthService, never>;
|
|
18
20
|
static ɵprov: i0.ɵɵInjectableDeclaration<AuthService>;
|
|
19
21
|
}
|
|
@@ -24,4 +26,5 @@ export interface IAuthService {
|
|
|
24
26
|
logout(queryParams?: Params): Observable<any>;
|
|
25
27
|
navigateToLogin(queryParams?: Params): void;
|
|
26
28
|
login(params: LoginParams): Observable<any>;
|
|
29
|
+
loginUsingGrant(grantType: string, parameters: object, headers?: HttpHeaders): Promise<AbpAuthResponse>;
|
|
27
30
|
}
|
package/lib/abstracts/index.d.ts
CHANGED
|
@@ -5,10 +5,10 @@ export declare class AbstractNgModelComponent<T = any, U = T> implements Control
|
|
|
5
5
|
injector: Injector;
|
|
6
6
|
protected _value: T;
|
|
7
7
|
protected cdRef: ChangeDetectorRef;
|
|
8
|
-
onChange
|
|
9
|
-
onTouched
|
|
10
|
-
disabled
|
|
11
|
-
readonly
|
|
8
|
+
onChange?: (value: T) => void;
|
|
9
|
+
onTouched?: () => void;
|
|
10
|
+
disabled?: boolean;
|
|
11
|
+
readonly?: boolean;
|
|
12
12
|
valueFn: (value: U, previousValue?: T) => T;
|
|
13
13
|
valueLimitFn: (value: T, previousValue?: T) => any;
|
|
14
14
|
set value(value: T);
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { HttpClient, HttpRequest } from '@angular/common/http';
|
|
2
|
+
import { Observable } from 'rxjs';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
export declare class ExternalHttpClient extends HttpClient {
|
|
5
|
+
#private;
|
|
6
|
+
request(first: string | HttpRequest<any>, url?: string, options?: RequestOptions): Observable<any>;
|
|
7
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ExternalHttpClient, never>;
|
|
8
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<ExternalHttpClient>;
|
|
9
|
+
}
|
|
10
|
+
declare type RequestOptions = Parameters<HttpClient['request']>[2];
|
|
11
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './http.client';
|
|
@@ -10,8 +10,8 @@ export declare class DynamicLayoutComponent {
|
|
|
10
10
|
private replaceableComponents;
|
|
11
11
|
private subscription;
|
|
12
12
|
private routerEvents;
|
|
13
|
-
layout
|
|
14
|
-
layoutKey
|
|
13
|
+
layout?: Type<any>;
|
|
14
|
+
layoutKey?: eLayoutType;
|
|
15
15
|
readonly layouts: Map<string, string>;
|
|
16
16
|
isLayoutVisible: boolean;
|
|
17
17
|
private router;
|
|
@@ -9,7 +9,7 @@ export declare class ReplaceableRouteContainerComponent implements OnInit {
|
|
|
9
9
|
private subscription;
|
|
10
10
|
defaultComponent: Type<any>;
|
|
11
11
|
componentKey: string;
|
|
12
|
-
externalComponent
|
|
12
|
+
externalComponent?: Type<any>;
|
|
13
13
|
constructor(route: ActivatedRoute, replaceableComponents: ReplaceableComponentsService, subscription: SubscriptionService);
|
|
14
14
|
ngOnInit(): void;
|
|
15
15
|
static ɵfac: i0.ɵɵFactoryDeclaration<ReplaceableRouteContainerComponent, never>;
|
|
@@ -13,13 +13,13 @@ export declare class ForDirective implements OnChanges {
|
|
|
13
13
|
private vcRef;
|
|
14
14
|
private differs;
|
|
15
15
|
items: any[];
|
|
16
|
-
orderBy
|
|
17
|
-
orderDir
|
|
18
|
-
filterBy
|
|
16
|
+
orderBy?: string;
|
|
17
|
+
orderDir?: 'ASC' | 'DESC';
|
|
18
|
+
filterBy?: string;
|
|
19
19
|
filterVal: any;
|
|
20
|
-
trackBy
|
|
21
|
-
compareBy
|
|
22
|
-
emptyRef
|
|
20
|
+
trackBy?: TrackByFunction<any>;
|
|
21
|
+
compareBy?: CompareFn;
|
|
22
|
+
emptyRef?: TemplateRef<any>;
|
|
23
23
|
private differ;
|
|
24
24
|
private isShowEmptyRef;
|
|
25
25
|
get compareFn(): CompareFn;
|
|
@@ -11,7 +11,7 @@ export declare class FormSubmitDirective implements OnInit {
|
|
|
11
11
|
private cdRef;
|
|
12
12
|
private subscription;
|
|
13
13
|
debounce: number;
|
|
14
|
-
notValidateOnSubmit
|
|
14
|
+
notValidateOnSubmit?: string | boolean;
|
|
15
15
|
markAsDirtyWhenSubmit: boolean;
|
|
16
16
|
readonly ngSubmit: EventEmitter<any>;
|
|
17
17
|
executedNgSubmit: boolean;
|
package/lib/models/auth.d.ts
CHANGED
|
@@ -7,5 +7,8 @@ export interface LoginParams {
|
|
|
7
7
|
redirectUrl?: string;
|
|
8
8
|
}
|
|
9
9
|
export declare type PipeToLoginFn = (params: Pick<LoginParams, 'redirectUrl' | 'rememberMe'>, injector: Injector) => UnaryFunction<any, any>;
|
|
10
|
-
|
|
10
|
+
/**
|
|
11
|
+
* @deprecated The interface should not be used anymore.
|
|
12
|
+
*/
|
|
13
|
+
export declare type SetTokenResponseToStorageFn<T = any> = (tokenRes: T) => void;
|
|
11
14
|
export declare type CheckAuthenticationStateFn = (injector: Injector) => void;
|
package/lib/models/dtos.d.ts
CHANGED
|
@@ -55,15 +55,15 @@ export declare class FullAuditedEntityWithUserDto<TUserDto, TPrimaryKey = string
|
|
|
55
55
|
constructor(initialValues?: Partial<FullAuditedEntityWithUserDto<TUserDto, TPrimaryKey>>);
|
|
56
56
|
}
|
|
57
57
|
export declare class ExtensibleObject {
|
|
58
|
-
extraProperties
|
|
58
|
+
extraProperties?: ABP.Dictionary<any>;
|
|
59
59
|
constructor(initialValues?: Partial<ExtensibleObject>);
|
|
60
60
|
}
|
|
61
61
|
export declare class ExtensibleEntityDto<TKey = string> extends ExtensibleObject {
|
|
62
|
-
id
|
|
62
|
+
id?: TKey;
|
|
63
63
|
constructor(initialValues?: Partial<ExtensibleEntityDto<TKey>>);
|
|
64
64
|
}
|
|
65
65
|
export declare class ExtensibleCreationAuditedEntityDto<TPrimaryKey = string> extends ExtensibleEntityDto<TPrimaryKey> {
|
|
66
|
-
creationTime
|
|
66
|
+
creationTime?: Date | string;
|
|
67
67
|
creatorId?: string;
|
|
68
68
|
constructor(initialValues?: Partial<ExtensibleCreationAuditedEntityDto<TPrimaryKey>>);
|
|
69
69
|
}
|
|
@@ -73,23 +73,23 @@ export declare class ExtensibleAuditedEntityDto<TPrimaryKey = string> extends Ex
|
|
|
73
73
|
constructor(initialValues?: Partial<ExtensibleAuditedEntityDto<TPrimaryKey>>);
|
|
74
74
|
}
|
|
75
75
|
export declare class ExtensibleAuditedEntityWithUserDto<TPrimaryKey = string, TUserDto = any> extends ExtensibleAuditedEntityDto<TPrimaryKey> {
|
|
76
|
-
creator
|
|
77
|
-
lastModifier
|
|
76
|
+
creator?: TUserDto;
|
|
77
|
+
lastModifier?: TUserDto;
|
|
78
78
|
constructor(initialValues?: Partial<ExtensibleAuditedEntityWithUserDto<TPrimaryKey>>);
|
|
79
79
|
}
|
|
80
80
|
export declare class ExtensibleCreationAuditedEntityWithUserDto<TPrimaryKey = string, TUserDto = any> extends ExtensibleCreationAuditedEntityDto<TPrimaryKey> {
|
|
81
|
-
creator
|
|
81
|
+
creator?: TUserDto;
|
|
82
82
|
constructor(initialValues?: Partial<ExtensibleCreationAuditedEntityWithUserDto<TPrimaryKey>>);
|
|
83
83
|
}
|
|
84
84
|
export declare class ExtensibleFullAuditedEntityDto<TPrimaryKey = string> extends ExtensibleAuditedEntityDto<TPrimaryKey> {
|
|
85
|
-
isDeleted
|
|
85
|
+
isDeleted?: boolean;
|
|
86
86
|
deleterId?: string;
|
|
87
|
-
deletionTime
|
|
87
|
+
deletionTime?: Date | string;
|
|
88
88
|
constructor(initialValues?: Partial<ExtensibleFullAuditedEntityDto<TPrimaryKey>>);
|
|
89
89
|
}
|
|
90
90
|
export declare class ExtensibleFullAuditedEntityWithUserDto<TPrimaryKey = string, TUserDto = any> extends ExtensibleFullAuditedEntityDto<TPrimaryKey> {
|
|
91
|
-
creator
|
|
92
|
-
lastModifier
|
|
93
|
-
deleter
|
|
91
|
+
creator?: TUserDto;
|
|
92
|
+
lastModifier?: TUserDto;
|
|
93
|
+
deleter?: TUserDto;
|
|
94
94
|
constructor(initialValues?: Partial<ExtensibleFullAuditedEntityWithUserDto<TPrimaryKey>>);
|
|
95
95
|
}
|
|
@@ -18,8 +18,10 @@ export interface ApplicationInfo {
|
|
|
18
18
|
baseUrl?: string;
|
|
19
19
|
logoUrl?: string;
|
|
20
20
|
}
|
|
21
|
-
export interface
|
|
21
|
+
export interface HasAdditional {
|
|
22
22
|
[key: string]: string;
|
|
23
|
+
}
|
|
24
|
+
export interface ApiConfig extends Partial<HasAdditional> {
|
|
23
25
|
url: string;
|
|
24
26
|
rootNamespace?: string;
|
|
25
27
|
}
|
package/lib/models/session.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { Provider } from
|
|
1
|
+
import { Provider } from '@angular/core';
|
|
2
2
|
export declare const IncludeLocalizationResourcesProvider: Provider;
|
|
@@ -21,7 +21,7 @@ export interface ControllerApiDescriptionModel {
|
|
|
21
21
|
controllerName?: string;
|
|
22
22
|
controllerGroupName?: string;
|
|
23
23
|
isRemoteService: boolean;
|
|
24
|
-
|
|
24
|
+
isIntegrationService: boolean;
|
|
25
25
|
apiVersion?: string;
|
|
26
26
|
type?: string;
|
|
27
27
|
interfaces: ControllerInterfaceApiDescriptionModel[];
|
|
@@ -352,8 +352,8 @@ export declare class ConfigStateService {
|
|
|
352
352
|
};
|
|
353
353
|
}>;
|
|
354
354
|
refreshLocalization(lang: string): Observable<null>;
|
|
355
|
-
getOne
|
|
356
|
-
getOne(key:
|
|
355
|
+
getOne$<K extends keyof ApplicationConfigurationDto>(key: K): Observable<ApplicationConfigurationDto[K]>;
|
|
356
|
+
getOne<K extends keyof ApplicationConfigurationDto>(key: K): ApplicationConfigurationDto[K];
|
|
357
357
|
getAll$(): Observable<ApplicationConfigurationDto>;
|
|
358
358
|
getAll(): ApplicationConfigurationDto;
|
|
359
359
|
getDeep$(keys: string[] | string): Observable<any>;
|
|
@@ -361,7 +361,9 @@ export declare class ConfigStateService {
|
|
|
361
361
|
getFeature(key: string): string;
|
|
362
362
|
getFeature$(key: string): Observable<string>;
|
|
363
363
|
getFeatures(keys: string[]): {};
|
|
364
|
-
getFeatures$(keys: string[]): Observable<{
|
|
364
|
+
getFeatures$(keys: string[]): Observable<{
|
|
365
|
+
[key: string]: string;
|
|
366
|
+
} | undefined>;
|
|
365
367
|
getSetting(key: string): string;
|
|
366
368
|
getSetting$(key: string): Observable<string>;
|
|
367
369
|
getSettings(keyword?: string): Record<string, string>;
|
|
@@ -2,7 +2,7 @@ import { ContentStrategy } from '../strategies/content.strategy';
|
|
|
2
2
|
import * as i0 from "@angular/core";
|
|
3
3
|
export declare class DomInsertionService {
|
|
4
4
|
private readonly inserted;
|
|
5
|
-
insertContent<T extends HTMLScriptElement | HTMLStyleElement>(contentStrategy: ContentStrategy<T>): T;
|
|
5
|
+
insertContent<T extends HTMLScriptElement | HTMLStyleElement>(contentStrategy: ContentStrategy<T>): T | undefined;
|
|
6
6
|
removeContent(element: HTMLScriptElement | HTMLStyleElement): void;
|
|
7
7
|
has(content: string): boolean;
|
|
8
8
|
static ɵfac: i0.ɵɵFactoryDeclaration<DomInsertionService, never>;
|
|
@@ -93,7 +93,7 @@ export declare class EnvironmentService {
|
|
|
93
93
|
}) => Slice, filterFn?: (x: Slice) => boolean) => Observable<Slice>;
|
|
94
94
|
getEnvironment$(): Observable<Environment>;
|
|
95
95
|
getEnvironment(): Environment;
|
|
96
|
-
getApiUrl(key: string): string;
|
|
96
|
+
getApiUrl(key: string | undefined): string;
|
|
97
97
|
getApiUrl$(key: string): Observable<string>;
|
|
98
98
|
setState(environment: Environment): void;
|
|
99
99
|
getIssuer(): string;
|
|
@@ -2,6 +2,7 @@ import { Injector } from '@angular/core';
|
|
|
2
2
|
import { Observable } from 'rxjs';
|
|
3
3
|
import { ABP } from '../models/common';
|
|
4
4
|
import { LocalizationWithDefault } from '../models/localization';
|
|
5
|
+
import { ApplicationLocalizationResourceDto } from '../proxy/volo/abp/asp-net-core/mvc/application-configurations/models';
|
|
5
6
|
import { ConfigStateService } from './config-state.service';
|
|
6
7
|
import { SessionStateService } from './session-state.service';
|
|
7
8
|
import * as i0 from "@angular/core";
|
|
@@ -41,11 +42,13 @@ export declare class LocalizationService {
|
|
|
41
42
|
* @param interpolateParams Values to intepolate.
|
|
42
43
|
*/
|
|
43
44
|
instant(key: string | LocalizationWithDefault, ...interpolateParams: string[]): string;
|
|
44
|
-
localize(resourceName: string, key: string, defaultValue: string): Observable<string>;
|
|
45
|
-
localizeSync(resourceName: string, key: string, defaultValue: string): string;
|
|
45
|
+
localize(resourceName: string, key: string, defaultValue: string): Observable<string | null>;
|
|
46
|
+
localizeSync(resourceName: string, key: string, defaultValue: string): string | null;
|
|
46
47
|
localizeWithFallback(resourceNames: string[], keys: string[], defaultValue: string): Observable<string>;
|
|
47
48
|
localizeWithFallbackSync(resourceNames: string[], keys: string[], defaultValue: string): string;
|
|
48
49
|
private getLocalization;
|
|
49
50
|
static ɵfac: i0.ɵɵFactoryDeclaration<LocalizationService, [null, null, { optional: true; skipSelf: true; }, null]>;
|
|
50
51
|
static ɵprov: i0.ɵɵInjectableDeclaration<LocalizationService>;
|
|
51
52
|
}
|
|
53
|
+
export declare type LegacyLanguageDto = Record<string, Record<string, string>>;
|
|
54
|
+
export declare type ResourceDto = Record<string, ApplicationLocalizationResourceDto>;
|
|
@@ -10,7 +10,7 @@ export declare class MultiTenancyService {
|
|
|
10
10
|
private tenantService;
|
|
11
11
|
private configStateService;
|
|
12
12
|
tenantKey: string;
|
|
13
|
-
domainTenant: CurrentTenantDto;
|
|
13
|
+
domainTenant: CurrentTenantDto | null;
|
|
14
14
|
isTenantBoxVisible: boolean;
|
|
15
15
|
apiName: string;
|
|
16
16
|
private setTenantToState;
|
|
@@ -6,10 +6,10 @@ export declare class PermissionService {
|
|
|
6
6
|
protected configState: ConfigStateService;
|
|
7
7
|
constructor(configState: ConfigStateService);
|
|
8
8
|
getGrantedPolicy$(key: string): import("rxjs").Observable<boolean>;
|
|
9
|
-
getGrantedPolicy(key: string): boolean;
|
|
9
|
+
getGrantedPolicy(key: string | undefined): boolean;
|
|
10
10
|
filterItemsByPolicy<T extends ABP.HasPolicy>(items: Array<T>): T[];
|
|
11
11
|
filterItemsByPolicy$<T extends ABP.HasPolicy>(items: Array<T>): import("rxjs").Observable<T[]>;
|
|
12
|
-
protected isPolicyGranted(key: string, grantedPolicies: Record<string, boolean>): boolean;
|
|
12
|
+
protected isPolicyGranted(key: string | undefined, grantedPolicies: Record<string, boolean>): boolean;
|
|
13
13
|
protected getStream(): import("rxjs").Observable<Record<string, boolean>>;
|
|
14
14
|
protected getSnapshot(): Record<string, boolean>;
|
|
15
15
|
protected mapToPolicies(applicationConfiguration: ApplicationConfigurationDto): Record<string, boolean>;
|
|
@@ -12,8 +12,8 @@ export declare class ReplaceableComponentsService {
|
|
|
12
12
|
get onUpdate$(): Observable<ReplaceableComponents.ReplaceableComponent[]>;
|
|
13
13
|
constructor(ngZone: NgZone, router: Router);
|
|
14
14
|
add(replaceableComponent: ReplaceableComponents.ReplaceableComponent, reload?: boolean): void;
|
|
15
|
-
get(replaceableComponentKey: string): ReplaceableComponents.ReplaceableComponent;
|
|
16
|
-
get$(replaceableComponentKey: string): Observable<ReplaceableComponents.ReplaceableComponent>;
|
|
15
|
+
get(replaceableComponentKey: string): ReplaceableComponents.ReplaceableComponent | undefined;
|
|
16
|
+
get$(replaceableComponentKey: string): Observable<ReplaceableComponents.ReplaceableComponent | undefined>;
|
|
17
17
|
static ɵfac: i0.ɵɵFactoryDeclaration<ReplaceableComponentsService, never>;
|
|
18
18
|
static ɵprov: i0.ɵɵInjectableDeclaration<ReplaceableComponentsService>;
|
|
19
19
|
}
|
|
@@ -11,7 +11,7 @@ export declare class RestService {
|
|
|
11
11
|
protected environment: EnvironmentService;
|
|
12
12
|
protected httpErrorReporter: HttpErrorReporterService;
|
|
13
13
|
constructor(options: ABP.Root, http: HttpClient, environment: EnvironmentService, httpErrorReporter: HttpErrorReporterService);
|
|
14
|
-
protected getApiFromStore(apiName: string): string;
|
|
14
|
+
protected getApiFromStore(apiName: string | undefined): string;
|
|
15
15
|
handleError(err: any): Observable<any>;
|
|
16
16
|
request<T, R>(request: HttpRequest<T> | Rest.Request<T>, config?: Rest.Config, api?: string): Observable<R>;
|
|
17
17
|
private getParams;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Type } from '@angular/core';
|
|
2
|
-
import { NavigationCancel, NavigationEnd, NavigationError, NavigationStart, Router, RouterEvent } from '@angular/router';
|
|
2
|
+
import { NavigationCancel, NavigationEnd, NavigationError, NavigationStart, Router, RouterEvent, Event } from '@angular/router';
|
|
3
3
|
import * as i0 from "@angular/core";
|
|
4
4
|
export declare const NavigationEvent: {
|
|
5
5
|
Cancel: typeof NavigationCancel;
|
|
@@ -17,7 +17,7 @@ export declare class RouterEvents {
|
|
|
17
17
|
Error: typeof NavigationError;
|
|
18
18
|
Start: typeof NavigationStart;
|
|
19
19
|
}[Key]> : never : never>;
|
|
20
|
-
getAllEvents(): import("rxjs").Observable<
|
|
20
|
+
getAllEvents(): import("rxjs").Observable<Event>;
|
|
21
21
|
getAllNavigationEvents(): import("rxjs").Observable<NavigationStart | NavigationEnd | NavigationCancel | NavigationError>;
|
|
22
22
|
static ɵfac: i0.ɵɵFactoryDeclaration<RouterEvents, never>;
|
|
23
23
|
static ɵprov: i0.ɵɵInjectableDeclaration<RouterEvents>;
|
|
@@ -3,7 +3,9 @@ import { Observable } from 'rxjs';
|
|
|
3
3
|
import { ABP } from '../models/common';
|
|
4
4
|
import { TreeNode } from '../utils/tree-utils';
|
|
5
5
|
import * as i0 from "@angular/core";
|
|
6
|
-
export declare abstract class AbstractTreeService<T extends
|
|
6
|
+
export declare abstract class AbstractTreeService<T extends {
|
|
7
|
+
[key: string | number | symbol]: any;
|
|
8
|
+
}> {
|
|
7
9
|
abstract id: string;
|
|
8
10
|
abstract parentId: string;
|
|
9
11
|
abstract hide: (item: T) => boolean;
|
|
@@ -18,7 +18,7 @@ export declare class SessionStateService {
|
|
|
18
18
|
getLanguage$(): import("rxjs").Observable<string>;
|
|
19
19
|
getTenant(): CurrentTenantDto;
|
|
20
20
|
getTenant$(): import("rxjs").Observable<CurrentTenantDto>;
|
|
21
|
-
setTenant(tenant: CurrentTenantDto): void;
|
|
21
|
+
setTenant(tenant: CurrentTenantDto | null): void;
|
|
22
22
|
setLanguage(language: string): void;
|
|
23
23
|
static ɵfac: i0.ɵɵFactoryDeclaration<SessionStateService, never>;
|
|
24
24
|
static ɵprov: i0.ɵɵInjectableDeclaration<SessionStateService>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { OnDestroy } from '@angular/core';
|
|
2
|
-
import { Subscription } from 'rxjs';
|
|
3
2
|
import type { Observable, PartialObserver } from 'rxjs';
|
|
3
|
+
import { Subscription } from 'rxjs';
|
|
4
4
|
import * as i0 from "@angular/core";
|
|
5
5
|
export declare class SubscriptionService implements OnDestroy {
|
|
6
6
|
private subscription;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
export declare class CrossOriginStrategy {
|
|
2
|
-
crossorigin: 'anonymous' | 'use-credentials';
|
|
2
|
+
crossorigin: 'anonymous' | 'use-credentials' | null;
|
|
3
3
|
integrity?: string;
|
|
4
|
-
constructor(crossorigin: 'anonymous' | 'use-credentials', integrity?: string);
|
|
4
|
+
constructor(crossorigin: 'anonymous' | 'use-credentials' | null, integrity?: string);
|
|
5
5
|
setCrossOrigin<T extends HTMLElement>(element: T): void;
|
|
6
6
|
}
|
|
7
7
|
export declare class NoCrossOriginStrategy extends CrossOriginStrategy {
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { InjectionToken } from
|
|
1
|
+
import { InjectionToken } from '@angular/core';
|
|
2
2
|
export declare const INCUDE_LOCALIZATION_RESOURCES_TOKEN: InjectionToken<boolean>;
|
package/lib/tokens/index.d.ts
CHANGED
|
@@ -2,5 +2,5 @@ import { InjectionToken } from '@angular/core';
|
|
|
2
2
|
import { BehaviorSubject } from 'rxjs';
|
|
3
3
|
import { ABP } from '../models/common';
|
|
4
4
|
export declare const LOCALIZATIONS: InjectionToken<unknown>;
|
|
5
|
-
export declare function localizationContributor(localizations
|
|
6
|
-
export declare const localizations$: BehaviorSubject<
|
|
5
|
+
export declare function localizationContributor(localizations?: ABP.Localization[]): void;
|
|
6
|
+
export declare const localizations$: BehaviorSubject<ABP.Localization[]>;
|
|
@@ -1,3 +1,6 @@
|
|
|
1
1
|
import { InjectionToken } from '@angular/core';
|
|
2
2
|
import { SetTokenResponseToStorageFn } from '../models';
|
|
3
|
+
/**
|
|
4
|
+
* @deprecated The token should not be used anymore.
|
|
5
|
+
*/
|
|
3
6
|
export declare const SET_TOKEN_RESPONSE_TO_STORAGE_FN_KEY: InjectionToken<SetTokenResponseToStorageFn<any>>;
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
export declare function noop(): () => void;
|
|
2
2
|
export declare function isUndefinedOrEmptyString(value: unknown): boolean;
|
|
3
|
-
export declare function isNullOrUndefined(obj:
|
|
4
|
-
export declare function isNullOrEmpty(obj:
|
|
5
|
-
export declare function exists(obj:
|
|
6
|
-
export declare function isObject(obj:
|
|
7
|
-
export declare function isArray(obj:
|
|
8
|
-
export declare function isObjectAndNotArray(obj:
|
|
9
|
-
export declare function isNode(obj:
|
|
10
|
-
export declare function isObjectAndNotArrayNotNode(obj:
|
|
3
|
+
export declare function isNullOrUndefined<T>(obj: T): boolean;
|
|
4
|
+
export declare function isNullOrEmpty<T>(obj: T): boolean;
|
|
5
|
+
export declare function exists<T>(obj: T): obj is T;
|
|
6
|
+
export declare function isObject<T>(obj: T): boolean;
|
|
7
|
+
export declare function isArray<T>(obj: T): boolean;
|
|
8
|
+
export declare function isObjectAndNotArray<T>(obj: T): boolean;
|
|
9
|
+
export declare function isNode<T>(obj: T): boolean;
|
|
10
|
+
export declare function isObjectAndNotArrayNotNode<T>(obj: T): boolean;
|
|
11
|
+
export declare function checkHasProp<T>(object: T, key: string | keyof T): key is keyof T;
|
|
@@ -6,4 +6,6 @@ export declare class LazyModuleFactory<T> extends NgModuleFactory<T> {
|
|
|
6
6
|
constructor(moduleWithProviders: ModuleWithProviders<T>);
|
|
7
7
|
create(parentInjector: Injector | null): NgModuleRef<T>;
|
|
8
8
|
}
|
|
9
|
-
export declare function featuresFactory(configState: ConfigStateService, featureKeys: string[], mapFn?: (features:
|
|
9
|
+
export declare function featuresFactory(configState: ConfigStateService, featureKeys: string[], mapFn?: (features: {
|
|
10
|
+
[key: string]: string;
|
|
11
|
+
}) => any): import("rxjs").Observable<any>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ApplicationLocalizationConfigurationDto } from '../proxy/volo/abp/asp-net-core/mvc/application-configurations/models';
|
|
2
2
|
export declare function getLocaleDirection(locale: string): 'ltr' | 'rtl';
|
|
3
|
-
export declare function createLocalizer(localization: ApplicationLocalizationConfigurationDto): (resourceName: string, key: string, defaultValue: string) => string;
|
|
3
|
+
export declare function createLocalizer(localization: ApplicationLocalizationConfigurationDto): (resourceName: string, key: string, defaultValue: string | null) => string;
|
|
4
4
|
export declare function createLocalizerWithFallback(localization: ApplicationLocalizationConfigurationDto): (resourceNames: string[], keys: string[], defaultValue: string) => string;
|
|
5
5
|
export declare function createLocalizationPipeKeyGenerator(localization: ApplicationLocalizationConfigurationDto): (resourceNames: string[], keys: string[], defaultKey: string | undefined) => string;
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
import { DeepPartial } from '../models';
|
|
2
|
+
export declare function deepMerge<T>(target: DeepPartial<T> | T, source: DeepPartial<T> | T): DeepPartial<T> | T;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { NgZone } from '@angular/core';
|
|
2
|
-
import { Router } from
|
|
2
|
+
import { Router } from "@angular/router";
|
|
3
3
|
import { ABP } from '../models/common';
|
|
4
4
|
import { RoutesService } from '../services/routes.service';
|
|
5
5
|
import { TreeNode } from './tree-utils';
|
|
6
|
-
export declare function findRoute(routesService: RoutesService, path: string): TreeNode<ABP.Route
|
|
6
|
+
export declare function findRoute(routesService: RoutesService, path: string): TreeNode<ABP.Route> | null;
|
|
7
7
|
export declare function getRoutePath(router: Router, url?: string): string;
|
|
8
8
|
export declare function reloadRoute(router: Router, ngZone: NgZone): void;
|
|
@@ -7,7 +7,7 @@ export declare class BaseTreeNode<T extends object> {
|
|
|
7
7
|
}
|
|
8
8
|
export declare function createTreeFromList<T extends object, R>(list: T[], keySelector: (item: T) => NodeKey, parentKeySelector: typeof keySelector, valueMapper: (item: T) => R): R[];
|
|
9
9
|
export declare function createMapFromList<T extends object, R>(list: T[], keySelector: (item: T) => NodeKey, valueMapper: (item: T) => R): Map<NodeKey, R>;
|
|
10
|
-
export declare function createTreeNodeFilterCreator<T extends object>(key: keyof T, mapperFn: (value: any) => string): (search: string) => (nodes: TreeNode<T>[], matches?:
|
|
10
|
+
export declare function createTreeNodeFilterCreator<T extends object>(key: keyof T, mapperFn: (value: any) => string): (search: string) => (nodes: TreeNode<T>[], matches?: TreeNode<T>[]) => TreeNode<T>[];
|
|
11
11
|
export declare type TreeNode<T extends object> = {
|
|
12
12
|
[K in keyof T]: T[K];
|
|
13
13
|
} & {
|
|
@@ -15,5 +15,5 @@ export declare type TreeNode<T extends object> = {
|
|
|
15
15
|
isLeaf: boolean;
|
|
16
16
|
parent?: TreeNode<T>;
|
|
17
17
|
};
|
|
18
|
-
declare type NodeKey = number | string | symbol | undefined | null;
|
|
19
|
-
export
|
|
18
|
+
export declare type NodeKey = number | string | symbol | undefined | null;
|
|
19
|
+
export declare type NodeValue<T extends object, F extends (...args: any) => any> = F extends undefined ? TreeNode<T> : ReturnType<F>;
|
package/package.json
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@abp/ng.core",
|
|
3
|
-
"version": "7.0.
|
|
3
|
+
"version": "7.0.3",
|
|
4
4
|
"homepage": "https://abp.io",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
7
7
|
"url": "https://github.com/abpframework/abp.git"
|
|
8
8
|
},
|
|
9
9
|
"dependencies": {
|
|
10
|
-
"@abp/utils": "~7.0.
|
|
10
|
+
"@abp/utils": "~7.0.3",
|
|
11
11
|
"angular-oauth2-oidc": "^15.0.1",
|
|
12
12
|
"just-clone": "^6.1.1",
|
|
13
|
-
"just-compare": "^
|
|
13
|
+
"just-compare": "^2.3.0",
|
|
14
14
|
"ts-toolbelt": "6.15.4",
|
|
15
15
|
"tslib": "^2.0.0"
|
|
16
16
|
},
|
package/public-api.d.ts
CHANGED