@ngxs/store 3.7.3-dev.master-740d0c2 → 3.7.3-dev.master-8834f50
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/ngxs-store-operators.umd.js +13 -12
- package/bundles/ngxs-store-operators.umd.js.map +1 -1
- package/bundles/ngxs-store-operators.umd.min.js +1 -1
- package/bundles/ngxs-store-operators.umd.min.js.map +1 -1
- package/esm2015/operators/append.js +3 -3
- package/esm2015/operators/compose.js +1 -1
- package/esm2015/operators/iif.js +1 -1
- package/esm2015/operators/index.js +1 -1
- package/esm2015/operators/insert-item.js +3 -3
- package/esm2015/operators/patch.js +4 -5
- package/esm2015/operators/update-item.js +7 -5
- package/esm2015/operators/utils.js +1 -1
- package/esm5/operators/append.js +3 -3
- package/esm5/operators/compose.js +1 -1
- package/esm5/operators/iif.js +1 -1
- package/esm5/operators/index.js +1 -1
- package/esm5/operators/insert-item.js +3 -3
- package/esm5/operators/patch.js +4 -5
- package/esm5/operators/update-item.js +7 -5
- package/esm5/operators/utils.js +1 -1
- package/fesm2015/ngxs-store-operators.js +13 -12
- package/fesm2015/ngxs-store-operators.js.map +1 -1
- package/fesm5/ngxs-store-operators.js +13 -12
- package/fesm5/ngxs-store-operators.js.map +1 -1
- package/operators/append.d.ts +2 -2
- package/operators/compose.d.ts +2 -1
- package/operators/iif.d.ts +2 -2
- package/operators/index.d.ts +1 -1
- package/operators/insert-item.d.ts +2 -2
- package/operators/ngxs-store-operators.metadata.json +1 -1
- package/operators/patch.d.ts +2 -6
- package/operators/update-item.d.ts +2 -2
- package/operators/utils.d.ts +2 -1
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { StateOperator } from '@ngxs/store';
|
|
2
|
-
import { RepairType } from './utils';
|
|
2
|
+
import { RepairType, NoInfer } from './utils';
|
|
3
3
|
import { Predicate } from './internals';
|
|
4
4
|
/**
|
|
5
5
|
* @param selector - Index of item in the array or a predicate function
|
|
@@ -7,4 +7,4 @@ import { Predicate } from './internals';
|
|
|
7
7
|
* @param operatorOrValue - New value under the `selector` index or a
|
|
8
8
|
* function that can be applied to an existing value
|
|
9
9
|
*/
|
|
10
|
-
export declare function updateItem<T>(selector: number | Predicate<T
|
|
10
|
+
export declare function updateItem<T>(selector: number | NoInfer<Predicate<T>>, operatorOrValue: NoInfer<T> | NoInfer<StateOperator<T>>): StateOperator<RepairType<T>[]>;
|
package/operators/utils.d.ts
CHANGED
|
@@ -6,4 +6,5 @@ export declare function isPredicate<T>(value: Predicate<T> | boolean | number):
|
|
|
6
6
|
export declare function isNumber(value: any): value is number;
|
|
7
7
|
export declare function invalidIndex(index: number): boolean;
|
|
8
8
|
export declare function isNil<T>(value: T | null | undefined): value is null | undefined;
|
|
9
|
-
export declare type RepairType<T> = T extends true ? boolean :
|
|
9
|
+
export declare type RepairType<T> = T extends true ? boolean : T extends false ? boolean : T;
|
|
10
|
+
export declare type NoInfer<T> = T extends infer S ? S : never;
|
package/package.json
CHANGED