@nu-art/ts-common 0.99.23 → 0.99.26

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nu-art/ts-common",
3
- "version": "0.99.23",
3
+ "version": "0.99.26",
4
4
  "description": "js and ts infra",
5
5
  "keywords": [
6
6
  "TacB0sS",
package/utils/types.d.ts CHANGED
@@ -16,6 +16,12 @@ export declare type RequireOptionals<T extends ObjectTS, Keys extends OptionalKe
16
16
  export declare type RequireOneOptional<T extends ObjectTS, Keys extends OptionalKeys<T> = OptionalKeys<T>> = Pick<T, Exclude<keyof T, Keys>> & {
17
17
  [K in Keys]-?: Required<Pick<T, K>> & Partial<Record<Exclude<Keys, K>, undefined>>;
18
18
  }[Keys];
19
+ export declare type RequireAtLeastOne<T, Keys extends keyof T = keyof T> = Pick<T, Exclude<keyof T, Keys>> & {
20
+ [K in Keys]-?: Required<Pick<T, K>> & Partial<Pick<T, Exclude<Keys, K>>>;
21
+ }[Keys];
22
+ export declare type RequireOnlyOne<T, Keys extends keyof T = keyof T> = Pick<T, Exclude<keyof T, Keys>> & {
23
+ [K in Keys]-?: Required<Pick<T, K>> & Partial<Record<Exclude<Keys, K>, undefined>>;
24
+ }[Keys];
19
25
  export declare type Constructor<T> = new (...args: any) => T;
20
26
  export declare type ArrayType<T extends any[]> = T extends (infer I)[] ? I : never;
21
27
  export declare type PartialProperties<T, K extends keyof T> = Omit<T, K> & Partial<Pick<T, K>>;
@@ -1 +1 @@
1
- {"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/main/utils/types.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;GAgBG;;;AAoEU,QAAA,IAAI,GAAG,CAAC;AACrB,CAAC,CAAC,EAAE,CAAC"}
1
+ {"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/main/utils/types.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;GAgBG;;;AAmFU,QAAA,IAAI,GAAG,CAAC;AACrB,CAAC,CAAC,EAAE,CAAC"}