@acorex/core 6.5.13 → 6.5.14

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 (143) hide show
  1. package/karma.conf.js +32 -0
  2. package/ng-package.json +10 -0
  3. package/package.json +13 -33
  4. package/src/lib/classes/base-page.class.ts +29 -0
  5. package/src/lib/classes/color.class.ts +61 -0
  6. package/src/lib/classes/datetime.class.ts +373 -0
  7. package/src/lib/classes/menu.class.ts +37 -0
  8. package/{lib/classes/navigator.class.d.ts → src/lib/classes/navigator.class.ts} +1 -1
  9. package/{lib/classes/popup.class.d.ts → src/lib/classes/popup.class.ts} +2 -0
  10. package/src/lib/classes/promise.class.ts +25 -0
  11. package/src/lib/classes/select.class.ts +7 -0
  12. package/src/lib/core.module.ts +21 -0
  13. package/src/lib/error/error.module.ts +13 -0
  14. package/src/lib/error/error.service.ts +23 -0
  15. package/src/lib/error/index.ts +3 -0
  16. package/{lib/events/keyboard.d.ts → src/lib/events/keyboard.ts} +3 -0
  17. package/{lib/http/http-error.class.d.ts → src/lib/http/http-error.class.ts} +2 -2
  18. package/{lib/http/http-events.interceptor.d.ts → src/lib/http/http-events.interceptor.ts} +7 -3
  19. package/{lib/http/http-request.class.d.ts → src/lib/http/http-request.class.ts} +5 -5
  20. package/src/lib/http/http-result.class.ts +34 -0
  21. package/src/lib/http/http.module.ts +25 -0
  22. package/src/lib/http/http.service.ts +159 -0
  23. package/{esm2020 → src}/lib/locale/en.json +6 -6
  24. package/{esm2020 → src}/lib/locale/fa.json +7 -7
  25. package/src/lib/pipe/datetime.pipe.ts +20 -0
  26. package/src/lib/pipe/htmlToText.pipe.ts +18 -0
  27. package/src/lib/platform/index.ts +1 -0
  28. package/src/lib/platform/platform.service.ts +211 -0
  29. package/src/lib/services/config.ts +36 -0
  30. package/src/lib/services/event.service.ts +31 -0
  31. package/src/lib/services/navigator.service.ts +8 -0
  32. package/src/lib/services/storage.service.ts +11 -0
  33. package/src/lib/translator/translator.module.ts +19 -0
  34. package/src/lib/translator/translator.pipe.ts +22 -0
  35. package/src/lib/translator/translator.service.ts +19 -0
  36. package/src/lib/translator/translator.ts +31 -0
  37. package/src/lib/utils/array/array-util.ts +140 -0
  38. package/src/lib/utils/html/html-util.ts +264 -0
  39. package/src/lib/utils/html/html.module.ts +11 -0
  40. package/src/lib/utils/math/math-util.ts +5 -0
  41. package/src/lib/utils/object/object-util.ts +87 -0
  42. package/src/lib/utils/render/on-demand-preload-strategy.service.ts +25 -0
  43. package/src/lib/utils/render/render.service.ts +110 -0
  44. package/src/lib/utils/render/rendering.module.ts +25 -0
  45. package/src/lib/utils/scroll/scroll.directive.ts +35 -0
  46. package/src/lib/utils/scroll/scroll.module.ts +11 -0
  47. package/src/lib/utils/separator/separator.module.ts +11 -0
  48. package/src/lib/utils/separator/separator.pipe.ts +27 -0
  49. package/{public-api.d.ts → src/public-api.ts} +10 -0
  50. package/src/test.ts +28 -0
  51. package/tsconfig.lib.json +25 -0
  52. package/tsconfig.lib.prod.json +6 -0
  53. package/tsconfig.spec.json +18 -0
  54. package/tslint.json +17 -0
  55. package/acorex-core.d.ts +0 -5
  56. package/esm2020/acorex-core.mjs +0 -5
  57. package/esm2020/lib/classes/base-page.class.mjs +0 -28
  58. package/esm2020/lib/classes/color.class.mjs +0 -49
  59. package/esm2020/lib/classes/datetime.class.mjs +0 -314
  60. package/esm2020/lib/classes/menu.class.mjs +0 -27
  61. package/esm2020/lib/classes/navigator.class.mjs +0 -2
  62. package/esm2020/lib/classes/popup.class.mjs +0 -2
  63. package/esm2020/lib/classes/promise.class.mjs +0 -19
  64. package/esm2020/lib/classes/sectionlist.class.mjs +0 -2
  65. package/esm2020/lib/classes/select.class.mjs +0 -3
  66. package/esm2020/lib/core.module.mjs +0 -27
  67. package/esm2020/lib/error/error.class.mjs +0 -2
  68. package/esm2020/lib/error/error.module.mjs +0 -19
  69. package/esm2020/lib/error/error.service.mjs +0 -21
  70. package/esm2020/lib/events/keyboard.mjs +0 -2
  71. package/esm2020/lib/http/http-error.class.mjs +0 -2
  72. package/esm2020/lib/http/http-events.interceptor.mjs +0 -3
  73. package/esm2020/lib/http/http-request.class.mjs +0 -2
  74. package/esm2020/lib/http/http-result.class.mjs +0 -21
  75. package/esm2020/lib/http/http.module.mjs +0 -37
  76. package/esm2020/lib/http/http.service.mjs +0 -145
  77. package/esm2020/lib/pipe/datetime.pipe.mjs +0 -25
  78. package/esm2020/lib/pipe/htmlToText.pipe.mjs +0 -25
  79. package/esm2020/lib/platform/index.mjs +0 -2
  80. package/esm2020/lib/platform/platform.service.mjs +0 -138
  81. package/esm2020/lib/services/config.mjs +0 -29
  82. package/esm2020/lib/services/event.service.mjs +0 -36
  83. package/esm2020/lib/services/navigator.service.mjs +0 -10
  84. package/esm2020/lib/services/storage.service.mjs +0 -16
  85. package/esm2020/lib/translator/translator.mjs +0 -26
  86. package/esm2020/lib/translator/translator.module.mjs +0 -25
  87. package/esm2020/lib/translator/translator.pipe.mjs +0 -24
  88. package/esm2020/lib/translator/translator.service.mjs +0 -21
  89. package/esm2020/lib/utils/array/array-util.mjs +0 -133
  90. package/esm2020/lib/utils/html/html-util.mjs +0 -192
  91. package/esm2020/lib/utils/html/html.module.mjs +0 -19
  92. package/esm2020/lib/utils/math/math-util.mjs +0 -6
  93. package/esm2020/lib/utils/object/object-util.mjs +0 -83
  94. package/esm2020/lib/utils/render/on-demand-preload-strategy.service.mjs +0 -20
  95. package/esm2020/lib/utils/render/render.service.mjs +0 -103
  96. package/esm2020/lib/utils/render/rendering.module.mjs +0 -35
  97. package/esm2020/lib/utils/scroll/scroll.directive.mjs +0 -54
  98. package/esm2020/lib/utils/scroll/scroll.module.mjs +0 -19
  99. package/esm2020/lib/utils/separator/separator.module.mjs +0 -19
  100. package/esm2020/lib/utils/separator/separator.pipe.mjs +0 -33
  101. package/esm2020/public-api.mjs +0 -44
  102. package/fesm2015/acorex-core.mjs +0 -2262
  103. package/fesm2015/acorex-core.mjs.map +0 -1
  104. package/fesm2020/acorex-core.mjs +0 -2258
  105. package/fesm2020/acorex-core.mjs.map +0 -1
  106. package/lib/classes/base-page.class.d.ts +0 -13
  107. package/lib/classes/color.class.d.ts +0 -17
  108. package/lib/classes/datetime.class.d.ts +0 -63
  109. package/lib/classes/menu.class.d.ts +0 -34
  110. package/lib/classes/promise.class.d.ts +0 -7
  111. package/lib/classes/select.class.d.ts +0 -7
  112. package/lib/core.module.d.ts +0 -9
  113. package/lib/error/error.module.d.ts +0 -7
  114. package/lib/error/error.service.d.ts +0 -13
  115. package/lib/http/http-result.class.d.ts +0 -11
  116. package/lib/http/http.module.d.ts +0 -10
  117. package/lib/http/http.service.d.ts +0 -23
  118. package/lib/pipe/datetime.pipe.d.ts +0 -8
  119. package/lib/pipe/htmlToText.pipe.d.ts +0 -7
  120. package/lib/platform/index.d.ts +0 -1
  121. package/lib/platform/platform.service.d.ts +0 -25
  122. package/lib/services/config.d.ts +0 -9
  123. package/lib/services/event.service.d.ts +0 -9
  124. package/lib/services/navigator.service.d.ts +0 -8
  125. package/lib/services/storage.service.d.ts +0 -7
  126. package/lib/translator/translator.d.ts +0 -9
  127. package/lib/translator/translator.module.d.ts +0 -8
  128. package/lib/translator/translator.pipe.d.ts +0 -8
  129. package/lib/translator/translator.service.d.ts +0 -8
  130. package/lib/utils/array/array-util.d.ts +0 -6
  131. package/lib/utils/html/html-util.d.ts +0 -62
  132. package/lib/utils/html/html.module.d.ts +0 -8
  133. package/lib/utils/math/math-util.d.ts +0 -3
  134. package/lib/utils/object/object-util.d.ts +0 -7
  135. package/lib/utils/render/on-demand-preload-strategy.service.d.ts +0 -10
  136. package/lib/utils/render/render.service.d.ts +0 -18
  137. package/lib/utils/render/rendering.module.d.ts +0 -8
  138. package/lib/utils/scroll/scroll.directive.d.ts +0 -18
  139. package/lib/utils/scroll/scroll.module.d.ts +0 -8
  140. package/lib/utils/separator/separator.module.d.ts +0 -8
  141. package/lib/utils/separator/separator.pipe.d.ts +0 -8
  142. /package/{lib/classes/sectionlist.class.d.ts → src/lib/classes/sectionlist.class.ts} +0 -0
  143. /package/{lib/error/error.class.d.ts → src/lib/error/error.class.ts} +0 -0
@@ -1,8 +0,0 @@
1
- import { AXNavigatorParam } from '../classes/navigator.class';
2
- import * as i0 from "@angular/core";
3
- export declare abstract class AXNavigator {
4
- abstract navigate(params: AXNavigatorParam): any;
5
- abstract popup(params: AXNavigatorParam): any;
6
- static ɵfac: i0.ɵɵFactoryDeclaration<AXNavigator, never>;
7
- static ɵprov: i0.ɵɵInjectableDeclaration<AXNavigator>;
8
- }
@@ -1,7 +0,0 @@
1
- import * as i0 from "@angular/core";
2
- export declare class AXStorageService {
3
- get(key: string): any;
4
- set(key: string, value: any): void;
5
- static ɵfac: i0.ɵɵFactoryDeclaration<AXStorageService, never>;
6
- static ɵprov: i0.ɵɵInjectableDeclaration<AXStorageService>;
7
- }
@@ -1,9 +0,0 @@
1
- import { Observable } from 'rxjs';
2
- export declare class AXTranslator {
3
- private static lang;
4
- private static dataChangeSubject;
5
- static get onChange(): Observable<any>;
6
- static load(lang: string, value: any): void;
7
- static use(lang: string): void;
8
- static get(key: string, lang?: string): string;
9
- }
@@ -1,8 +0,0 @@
1
- import * as i0 from "@angular/core";
2
- import * as i1 from "./translator.pipe";
3
- export declare class AXTranslatorModule {
4
- constructor();
5
- static ɵfac: i0.ɵɵFactoryDeclaration<AXTranslatorModule, never>;
6
- static ɵmod: i0.ɵɵNgModuleDeclaration<AXTranslatorModule, [typeof i1.AXTranslatorPipe], never, [typeof i1.AXTranslatorPipe]>;
7
- static ɵinj: i0.ɵɵInjectorDeclaration<AXTranslatorModule>;
8
- }
@@ -1,8 +0,0 @@
1
- import { PipeTransform } from '@angular/core';
2
- import * as i0 from "@angular/core";
3
- export declare class AXTranslatorPipe implements PipeTransform {
4
- constructor();
5
- transform(value: string, lang?: string): string;
6
- static ɵfac: i0.ɵɵFactoryDeclaration<AXTranslatorPipe, never>;
7
- static ɵpipe: i0.ɵɵPipeDeclaration<AXTranslatorPipe, "trans">;
8
- }
@@ -1,8 +0,0 @@
1
- import * as i0 from "@angular/core";
2
- export declare class AXTranslatorService {
3
- load(lang: string, value: any): void;
4
- use(lang: string): void;
5
- get(key: string, lang?: string): string;
6
- static ɵfac: i0.ɵɵFactoryDeclaration<AXTranslatorService, never>;
7
- static ɵprov: i0.ɵɵInjectableDeclaration<AXTranslatorService>;
8
- }
@@ -1,6 +0,0 @@
1
- export declare class AXArrayUtil {
2
- static pickRandom(array: any[]): any;
3
- static insert(array: any[], index: any, ...rest: any[]): any[];
4
- static range(min: number, max: number): number[];
5
- static filter(array: any[], filters: any[]): any[];
6
- }
@@ -1,62 +0,0 @@
1
- export declare type AXPlacement = 'top-start' | 'top-middle' | 'top-end' | 'center-start' | 'center-end' | 'bottom-start' | 'bottom-middle' | 'bottom-end';
2
- export interface AXIPoint {
3
- x: number;
4
- y: number;
5
- }
6
- export interface AXConnectedPosition {
7
- originX: 'start' | 'center' | 'end';
8
- originY: 'top' | 'center' | 'bottom';
9
- overlayX: 'start' | 'center' | 'end';
10
- overlayY: 'top' | 'center' | 'bottom';
11
- weight?: number;
12
- offsetX?: number;
13
- offsetY?: number;
14
- }
15
- export declare class AXPoint implements AXIPoint {
16
- x: number;
17
- y: number;
18
- constructor(x: number, y: number);
19
- }
20
- export interface AXClientRecCtor {
21
- left?: number;
22
- top?: number;
23
- width?: number;
24
- height?: number;
25
- bottom?: number;
26
- right?: number;
27
- }
28
- export declare class AXClientRec implements AXClientRecCtor {
29
- private _left;
30
- get left(): number;
31
- set left(v: number);
32
- private _top;
33
- get top(): number;
34
- set top(v: number);
35
- private _right;
36
- get right(): number;
37
- set right(v: number);
38
- private _bottom;
39
- get bottom(): number;
40
- set bottom(v: number);
41
- private _width;
42
- get width(): number;
43
- set width(v: number);
44
- private _height;
45
- get height(): number;
46
- set height(v: number);
47
- constructor(rec: AXClientRecCtor);
48
- intersect(rec: AXClientRecCtor): boolean;
49
- }
50
- export declare class AXHtmlUtil {
51
- static getBoundingRectPoint(el: HTMLElement, placement: AXPlacement): AXPoint;
52
- static isInRecPoint(pos: AXIPoint, rec: AXClientRecCtor): boolean;
53
- static isInElementBound(pos: AXIPoint, element: HTMLElement): boolean;
54
- static getDimensions(): {
55
- width: number;
56
- height: number;
57
- };
58
- static getOffsetRight(elem: HTMLElement): number;
59
- static getUID(): string;
60
- static getRelatedPosition(source: HTMLElement, placement: AXPlacement, target: HTMLElement, alignment: AXPlacement): AXIPoint;
61
- static collision(a: HTMLElement, b: HTMLElement): boolean;
62
- }
@@ -1,8 +0,0 @@
1
- import * as i0 from "@angular/core";
2
- import * as i1 from "../../pipe/htmlToText.pipe";
3
- import * as i2 from "@angular/common";
4
- export declare class AXHtmlModule {
5
- static ɵfac: i0.ɵɵFactoryDeclaration<AXHtmlModule, never>;
6
- static ɵmod: i0.ɵɵNgModuleDeclaration<AXHtmlModule, [typeof i1.AXHtmlToTextPipe], [typeof i2.CommonModule], [typeof i1.AXHtmlToTextPipe]>;
7
- static ɵinj: i0.ɵɵInjectorDeclaration<AXHtmlModule>;
8
- }
@@ -1,3 +0,0 @@
1
- export declare class AXMathUtil {
2
- static randomRange(min: number, max: number): number;
3
- }
@@ -1,7 +0,0 @@
1
- export declare class AXObjectUtil {
2
- static deepJSONClone(obj: any): any;
3
- static deepCopy(obj: any): any;
4
- }
5
- export declare function AXFetchProp(obj: any, prop: string): any;
6
- export declare function getPropByPath(obj: any, path: any, defaultVal?: any): any;
7
- export declare function setPropByPath(obj: any, path: any, value: any): any;
@@ -1,10 +0,0 @@
1
- import { Subject } from 'rxjs';
2
- import * as i0 from "@angular/core";
3
- export declare class AXOnDemandPreloadService {
4
- subject: Subject<string>;
5
- tmp: string;
6
- constructor();
7
- startPreload(routePath: string): void;
8
- static ɵfac: i0.ɵɵFactoryDeclaration<AXOnDemandPreloadService, never>;
9
- static ɵprov: i0.ɵɵInjectableDeclaration<AXOnDemandPreloadService>;
10
- }
@@ -1,18 +0,0 @@
1
- import { ApplicationRef, ComponentFactoryResolver, ComponentRef, Injector, Type, Compiler } from '@angular/core';
2
- import { Router, Route } from '@angular/router';
3
- import { AXOnDemandPreloadService } from './on-demand-preload-strategy.service';
4
- import * as i0 from "@angular/core";
5
- export declare class AXRenderService {
6
- private appRef;
7
- private router;
8
- private componentFactoryResolver;
9
- private compiler;
10
- private modulePreloadService;
11
- private injector;
12
- constructor(appRef: ApplicationRef, router: Router, componentFactoryResolver: ComponentFactoryResolver, compiler: Compiler, modulePreloadService: AXOnDemandPreloadService, injector: Injector);
13
- appendComponent<T>(componentClass: Type<T>, options?: any, location?: Element): ComponentRef<any>;
14
- findLoadedComponentByRoute(path: string, timeoutTime?: number): Promise<Route>;
15
- private _findLoadedComponentByRoute;
16
- static ɵfac: i0.ɵɵFactoryDeclaration<AXRenderService, never>;
17
- static ɵprov: i0.ɵɵInjectableDeclaration<AXRenderService>;
18
- }
@@ -1,8 +0,0 @@
1
- import { AXOnDemandPreloadService } from './on-demand-preload-strategy.service';
2
- import * as i0 from "@angular/core";
3
- export declare function getOnDemandPreloadServiceFactory(): AXOnDemandPreloadService;
4
- export declare class AXRenderingModule {
5
- static ɵfac: i0.ɵɵFactoryDeclaration<AXRenderingModule, never>;
6
- static ɵmod: i0.ɵɵNgModuleDeclaration<AXRenderingModule, never, never, never>;
7
- static ɵinj: i0.ɵɵInjectorDeclaration<AXRenderingModule>;
8
- }
@@ -1,18 +0,0 @@
1
- import { ElementRef } from '@angular/core';
2
- import * as i0 from "@angular/core";
3
- export declare class AXHorizontalScrollDirective {
4
- private el;
5
- constructor(el: ElementRef<HTMLElement>);
6
- scrollValue: number;
7
- onMouseWheel(e: any): void;
8
- static ɵfac: i0.ɵɵFactoryDeclaration<AXHorizontalScrollDirective, never>;
9
- static ɵdir: i0.ɵɵDirectiveDeclaration<AXHorizontalScrollDirective, "[horizontalScroll]", never, { "scrollValue": "horizontalScroll"; }, {}, never>;
10
- }
11
- export declare class AXVerticalScrollDirective {
12
- private el;
13
- constructor(el: ElementRef<HTMLElement>);
14
- scrollValue: number;
15
- onMouseWheel(e: any): void;
16
- static ɵfac: i0.ɵɵFactoryDeclaration<AXVerticalScrollDirective, never>;
17
- static ɵdir: i0.ɵɵDirectiveDeclaration<AXVerticalScrollDirective, "[verticalScroll]", never, { "scrollValue": "verticalScroll"; }, {}, never>;
18
- }
@@ -1,8 +0,0 @@
1
- import * as i0 from "@angular/core";
2
- import * as i1 from "./scroll.directive";
3
- import * as i2 from "@angular/common";
4
- export declare class AXScrollModule {
5
- static ɵfac: i0.ɵɵFactoryDeclaration<AXScrollModule, never>;
6
- static ɵmod: i0.ɵɵNgModuleDeclaration<AXScrollModule, [typeof i1.AXHorizontalScrollDirective, typeof i1.AXVerticalScrollDirective], [typeof i2.CommonModule], [typeof i1.AXHorizontalScrollDirective, typeof i1.AXVerticalScrollDirective]>;
7
- static ɵinj: i0.ɵɵInjectorDeclaration<AXScrollModule>;
8
- }
@@ -1,8 +0,0 @@
1
- import * as i0 from "@angular/core";
2
- import * as i1 from "./separator.pipe";
3
- import * as i2 from "@angular/common";
4
- export declare class AXSeparatorModule {
5
- static ɵfac: i0.ɵɵFactoryDeclaration<AXSeparatorModule, never>;
6
- static ɵmod: i0.ɵɵNgModuleDeclaration<AXSeparatorModule, [typeof i1.AXSeparatorPipe], [typeof i2.CommonModule], [typeof i1.AXSeparatorPipe]>;
7
- static ɵinj: i0.ɵɵInjectorDeclaration<AXSeparatorModule>;
8
- }
@@ -1,8 +0,0 @@
1
- import { PipeTransform } from '@angular/core';
2
- import * as i0 from "@angular/core";
3
- export declare class AXSeparatorPipe implements PipeTransform {
4
- transform(value: number | string, currency?: string, decimal?: number, locale?: string): string;
5
- static ɵfac: i0.ɵɵFactoryDeclaration<AXSeparatorPipe, never>;
6
- static ɵpipe: i0.ɵɵPipeDeclaration<AXSeparatorPipe, "separator">;
7
- static ɵprov: i0.ɵɵInjectableDeclaration<AXSeparatorPipe>;
8
- }