@stemy/ngx-utils 11.0.9 → 11.1.1
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/bundles/stemy-ngx-utils.umd.js +75 -66
- package/bundles/stemy-ngx-utils.umd.js.map +1 -1
- package/bundles/stemy-ngx-utils.umd.min.js +1 -1
- package/bundles/stemy-ngx-utils.umd.min.js.map +1 -1
- package/esm2015/ngx-utils/common-types.js +2 -1
- package/esm2015/ngx-utils/ngx-utils.module.js +6 -2
- package/esm2015/ngx-utils/services/config.service.js +9 -6
- package/esm2015/ngx-utils/services/static-language.service.js +3 -4
- package/esm2015/public_api.js +2 -2
- package/fesm2015/stemy-ngx-utils.js +65 -57
- package/fesm2015/stemy-ngx-utils.js.map +1 -1
- package/ngx-utils/common-types.d.ts +2 -0
- package/ngx-utils/ngx-utils.module.d.ts +1 -1
- package/ngx-utils/services/config.service.d.ts +3 -1
- package/ngx-utils/services/static-language.service.d.ts +3 -4
- package/package.json +1 -1
- package/public_api.d.ts +1 -1
- package/stemy-ngx-utils.metadata.json +1 -1
|
@@ -93,6 +93,7 @@ export interface IPromiseService {
|
|
|
93
93
|
create<T>(executor: (resolve: (value?: T | PromiseLike<T>) => void, reject: (reason?: any) => void) => void): Promise<T>;
|
|
94
94
|
all(promises: Promise<any>[]): Promise<any>;
|
|
95
95
|
resolve<T>(value: T | PromiseLike<T>): Promise<T>;
|
|
96
|
+
reject<T>(value: T | PromiseLike<T>): Promise<T>;
|
|
96
97
|
}
|
|
97
98
|
export declare const PROMISE_SERVICE: InjectionToken<IPromiseService>;
|
|
98
99
|
export interface IAsyncMessage {
|
|
@@ -272,6 +273,7 @@ export interface IConfigService {
|
|
|
272
273
|
export declare const CONFIG_SERVICE: InjectionToken<IConfigService>;
|
|
273
274
|
export declare const BASE_CONFIG: InjectionToken<IConfiguration>;
|
|
274
275
|
export declare const SCRIPT_PARAMS: InjectionToken<any>;
|
|
276
|
+
export declare const ROOT_ELEMENT: InjectionToken<HTMLElement>;
|
|
275
277
|
export declare type ErrorHandlerCallback = (error: string) => any;
|
|
276
278
|
export declare const ERROR_HANDLER: InjectionToken<ErrorHandlerCallback>;
|
|
277
279
|
export declare type AppInitializerFunc = () => Promise<void> | void;
|
|
@@ -49,7 +49,7 @@ import { UnorderedListComponent } from "./components/unordered-list/unordered-li
|
|
|
49
49
|
export declare const pipes: (typeof FilterPipe | typeof FormatNumberPipe | typeof GlobalTemplatePipe | typeof ReducePipe | typeof RoundPipe | typeof SafeHtmlPipe | typeof TranslatePipe)[];
|
|
50
50
|
export declare const directives: (typeof AsyncMethodDirective | typeof BackgroundDirective | typeof DynamicTableTemplateDirective | typeof GlobalTemplateDirective | typeof IconDirective | typeof NgxTemplateOutletDirective | typeof PaginationDirective | typeof PaginationItemDirective | typeof ResourceIfDirective | typeof StickyDirective | typeof UnorderedListItemDirective | typeof UnorderedListTemplateDirective | typeof StickyClassDirective)[];
|
|
51
51
|
export declare const components: (typeof UnorderedListComponent | typeof DynamicTableComponent | typeof PaginationMenuComponent)[];
|
|
52
|
-
export declare const providers: (typeof StateService | typeof AuthGuard | typeof UniversalService | typeof AclService | typeof BaseHttpClient | typeof StorageService | typeof BaseHttpService | typeof StaticAuthService | typeof ConfigService | typeof ErrorHandlerService | typeof EventsService | typeof FormatterService | typeof GlobalTemplateService | typeof IconService | typeof
|
|
52
|
+
export declare const providers: (typeof StateService | typeof AuthGuard | typeof UniversalService | typeof AclService | typeof BaseHttpClient | typeof StorageService | typeof BaseHttpService | typeof StaticAuthService | typeof ConfigService | typeof ErrorHandlerService | typeof EventsService | typeof FormatterService | typeof GlobalTemplateService | typeof IconService | typeof StaticLanguageService | typeof OpenApiService | typeof ConsoleToasterService | typeof TranslatedUrlSerializer | typeof PromiseService | typeof FilterPipe | typeof FormatNumberPipe | typeof GlobalTemplatePipe | typeof ReducePipe | typeof RoundPipe | typeof SafeHtmlPipe | typeof TranslatePipe | typeof DeviceDetectorService | {
|
|
53
53
|
provide: import("@angular/core").InjectionToken<import("@angular/platform-browser").ɵangular_packages_platform_browser_platform_browser_g[]>;
|
|
54
54
|
useClass: typeof ResizeEventPlugin;
|
|
55
55
|
multi: boolean;
|
|
@@ -4,6 +4,8 @@ import { IConfigService, IConfiguration } from "../common-types";
|
|
|
4
4
|
export declare class ConfigService implements IConfigService {
|
|
5
5
|
readonly http: HttpClient;
|
|
6
6
|
readonly universal: UniversalService;
|
|
7
|
+
readonly rootElement: any;
|
|
8
|
+
protected baseConfig: IConfiguration;
|
|
7
9
|
protected loadedConfig: IConfiguration;
|
|
8
10
|
protected scriptParameters: any;
|
|
9
11
|
protected loader: Promise<IConfiguration>;
|
|
@@ -11,7 +13,7 @@ export declare class ConfigService implements IConfigService {
|
|
|
11
13
|
get load(): () => Promise<IConfiguration>;
|
|
12
14
|
get config(): IConfiguration;
|
|
13
15
|
get configUrl(): string;
|
|
14
|
-
constructor(http: HttpClient, universal: UniversalService, baseConfig?: IConfiguration, scriptParams?: any);
|
|
16
|
+
constructor(http: HttpClient, universal: UniversalService, rootElement: any, baseConfig?: IConfiguration, scriptParams?: any);
|
|
15
17
|
protected initService(): void;
|
|
16
18
|
protected loadJson(): Promise<IConfiguration>;
|
|
17
19
|
protected prepareConfig(config: IConfiguration): Promise<IConfiguration>;
|
|
@@ -1,15 +1,14 @@
|
|
|
1
|
-
import { IConfigService, IConfiguration, ILanguageService, ITranslation, ITranslations } from "../common-types";
|
|
1
|
+
import { IConfigService, IConfiguration, ILanguageService, IPromiseService, ITranslation, ITranslations } from "../common-types";
|
|
2
2
|
import { EventsService } from "./events.service";
|
|
3
3
|
import { StorageService } from "./storage.service";
|
|
4
4
|
import { UniversalService } from "./universal.service";
|
|
5
5
|
import { BaseHttpClient } from "./base-http.client";
|
|
6
6
|
import { HttpClient } from "@angular/common/http";
|
|
7
|
-
import { PromiseService } from "./promise.service";
|
|
8
7
|
export declare class StaticLanguageService implements ILanguageService {
|
|
9
8
|
readonly events: EventsService;
|
|
10
9
|
readonly storage: StorageService;
|
|
11
10
|
readonly configs: IConfigService;
|
|
12
|
-
protected promises:
|
|
11
|
+
protected promises: IPromiseService;
|
|
13
12
|
protected client: BaseHttpClient;
|
|
14
13
|
get defaultLanguage(): string;
|
|
15
14
|
get dictionary(): ITranslations;
|
|
@@ -30,7 +29,7 @@ export declare class StaticLanguageService implements ILanguageService {
|
|
|
30
29
|
protected disableTrans: boolean;
|
|
31
30
|
protected languageList: string[];
|
|
32
31
|
protected readonly translations: ITranslations;
|
|
33
|
-
constructor(events: EventsService, storage: StorageService, configs: IConfigService, promises:
|
|
32
|
+
constructor(events: EventsService, storage: StorageService, configs: IConfigService, promises: IPromiseService, client: BaseHttpClient);
|
|
34
33
|
protected initService(): void;
|
|
35
34
|
replaceLanguages(languages: string[]): void;
|
|
36
35
|
addLanguages(languages: string[]): void;
|
package/package.json
CHANGED
package/public_api.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { IResolveFactory, CanvasColor, IIconService, ICON_SERVICE, ITranslation, ITranslations, ILanguageSettings, ILanguageService, LANGUAGE_SERVICE, IAuthService, RouteValidator, IRouteData, IRoute, AUTH_SERVICE, IAclComponent, IPromiseService, PROMISE_SERVICE, IRouteStateInfo, StorageMode, IToasterService, TOASTER_SERVICE, IAsyncMessage, AsyncMethod, UnorederedListTemplate, UnorderedListTemplates, UnorderedListStyle, IAjaxRequestDetails, AjaxRequestCallback, IScriptPromises, IStylePromises, ISearchObservable, FactoryDependencies, ITimer, IExtraProperties, IGroupMap, TranslationQuery, IPageInfo, IPaginationData, PaginationDataLoader, PaginationItemContext, IHttpHeaders, IHttpParams, IRequestOptions, IIssueContext, IProgress, ProgressListener, PromiseExecutor, HttpPromise, IHttpService, EXPRESS_REQUEST, IApiService, API_SERVICE, IOpenApiSchemaProperty, IOpenApiSchema, IOpenApiSchemas, ITableColumns, ITableTemplate, ITableTemplates, TableDataLoader, ResourceIfContext, IConfiguration, IConfigService, CONFIG_SERVICE, BASE_CONFIG, SCRIPT_PARAMS, ErrorHandlerCallback, ERROR_HANDLER, AppInitializerFunc, IModuleConfig, ValuedPromise } from "./ngx-utils/common-types";
|
|
1
|
+
export { IResolveFactory, CanvasColor, IIconService, ICON_SERVICE, ITranslation, ITranslations, ILanguageSettings, ILanguageService, LANGUAGE_SERVICE, IAuthService, RouteValidator, IRouteData, IRoute, AUTH_SERVICE, IAclComponent, IPromiseService, PROMISE_SERVICE, IRouteStateInfo, StorageMode, IToasterService, TOASTER_SERVICE, IAsyncMessage, AsyncMethod, UnorederedListTemplate, UnorderedListTemplates, UnorderedListStyle, IAjaxRequestDetails, AjaxRequestCallback, IScriptPromises, IStylePromises, ISearchObservable, FactoryDependencies, ITimer, IExtraProperties, IGroupMap, TranslationQuery, IPageInfo, IPaginationData, PaginationDataLoader, PaginationItemContext, IHttpHeaders, IHttpParams, IRequestOptions, IIssueContext, IProgress, ProgressListener, PromiseExecutor, HttpPromise, IHttpService, EXPRESS_REQUEST, IApiService, API_SERVICE, IOpenApiSchemaProperty, IOpenApiSchema, IOpenApiSchemas, ITableColumns, ITableTemplate, ITableTemplates, TableDataLoader, ResourceIfContext, IConfiguration, IConfigService, CONFIG_SERVICE, BASE_CONFIG, SCRIPT_PARAMS, ROOT_ELEMENT, ErrorHandlerCallback, ERROR_HANDLER, AppInitializerFunc, IModuleConfig, ValuedPromise } from "./ngx-utils/common-types";
|
|
2
2
|
export { AjaxRequestHandler } from "./ngx-utils/utils/ajax-request-handler";
|
|
3
3
|
export { ObjectUtils } from "./ngx-utils/utils/object.utils";
|
|
4
4
|
export { DateUtils } from "./ngx-utils/utils/date.utils";
|