@stemy/ngx-utils 10.3.0 → 10.3.4
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 +26 -15
- 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/directives/pagination.directive.js +6 -4
- package/esm2015/ngx-utils/services/api.service.js +5 -5
- package/esm2015/ngx-utils/services/base-http.service.js +6 -6
- package/esm2015/ngx-utils/utils/array.utils.js +13 -3
- package/fesm2015/stemy-ngx-utils.js +26 -14
- package/fesm2015/stemy-ngx-utils.js.map +1 -1
- package/ngx-utils/services/api.service.d.ts +2 -2
- package/ngx-utils/services/base-http.service.d.ts +2 -2
- package/ngx-utils/utils/array.utils.d.ts +5 -4
- package/package.json +1 -1
|
@@ -4,8 +4,8 @@ import { IPaginationData } from "../common-types";
|
|
|
4
4
|
export declare class ApiService extends BaseHttpService implements IApiService {
|
|
5
5
|
get name(): string;
|
|
6
6
|
url(url: string): string;
|
|
7
|
-
get(url: string, options?: IRequestOptions): Promise<any>;
|
|
8
|
-
delete(url: string, options?: IRequestOptions): Promise<any>;
|
|
7
|
+
get(url: string, options?: IRequestOptions, body?: any): Promise<any>;
|
|
8
|
+
delete(url: string, options?: IRequestOptions, body?: any): Promise<any>;
|
|
9
9
|
post(url: string, body?: any, options?: IRequestOptions): Promise<any>;
|
|
10
10
|
put(url: string, body?: any, options?: IRequestOptions): Promise<any>;
|
|
11
11
|
patch(url: string, body?: any, options?: IRequestOptions): Promise<any>;
|
|
@@ -21,8 +21,8 @@ export declare class BaseHttpService implements IHttpService {
|
|
|
21
21
|
url(url: string): string;
|
|
22
22
|
createUrl(url: string, params: IHttpParams): string;
|
|
23
23
|
makeListParams(page: number, itemsPerPage: number, orderBy?: string, orderDescending?: boolean, filter?: string): IHttpParams;
|
|
24
|
-
protected getPromise(url: string, options?: IRequestOptions): HttpPromise;
|
|
25
|
-
protected deletePromise(url: string, options?: IRequestOptions): HttpPromise;
|
|
24
|
+
protected getPromise(url: string, options?: IRequestOptions, body?: any): HttpPromise;
|
|
25
|
+
protected deletePromise(url: string, options?: IRequestOptions, body?: any): HttpPromise;
|
|
26
26
|
protected postPromise(url: string, body?: any, options?: IRequestOptions): HttpPromise;
|
|
27
27
|
protected putPromise(url: string, body?: any, options?: IRequestOptions): HttpPromise;
|
|
28
28
|
protected patchPromise(url: string, body?: any, options?: IRequestOptions): HttpPromise;
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
export declare class ArrayUtils {
|
|
2
2
|
static has(arr: any[], ...items: any[]): boolean;
|
|
3
3
|
static match(arr: any[], str: string): boolean;
|
|
4
|
-
static any(arr:
|
|
5
|
-
static move(arr:
|
|
4
|
+
static any<T>(arr: T[], cb: (item: T) => boolean): boolean;
|
|
5
|
+
static move<T>(arr: T[], oldIndex: number, newIndex: number): T[];
|
|
6
6
|
static reversed(arr: any[]): any[];
|
|
7
|
-
static min(arr:
|
|
8
|
-
static max(arr:
|
|
7
|
+
static min<T>(arr: T[], cb: (item: T, index?: number) => number): T;
|
|
8
|
+
static max<T>(arr: T[], cb: (item: T, index?: number) => number): T;
|
|
9
|
+
static chunk<T>(arr: T[], size: number): Array<T[]>;
|
|
9
10
|
}
|