inferred-types 0.53.8 → 0.53.10

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.
@@ -15754,7 +15754,7 @@ declare function createFnWithProps<TArgs extends readonly unknown[], TReturn ext
15754
15754
  * - unlike the similar `createFnWithProps()`, this utility just
15755
15755
  * expects you to type the function and properties yourself.
15756
15756
  */
15757
- declare function createFnWithPropsExplicit<TFn extends TypedFunction$1, TProps extends Dictionary$1>(fn: TFn, props: TProps): TFn & TProps;
15757
+ declare function createFnWithPropsExplicit<TFn extends TypedFunction$1, TProps extends AnyObject$1>(fn: TFn, props: TProps): TFn & TProps;
15758
15758
 
15759
15759
  /**
15760
15760
  * **defineObj**(literal) -> (wide) -> object
@@ -33757,11 +33757,11 @@ type TruthyReturns<T extends readonly unknown[]> = TupleToUnion<{
33757
33757
  * Tests whether any of the object in T are explicitly missing
33758
33758
  * the property P
33759
33759
  */
33760
- type HasMissingInstance<T extends readonly Record<string, unknown>[], P extends string> = [] extends T ? false : P extends keyof First<T> ? HasMissingInstance<AfterFirst<T>, P> : true;
33760
+ type HasMissingInstance<T extends readonly AnyObject[], P extends string> = [] extends T ? false : P extends keyof First<T> ? HasMissingInstance<AfterFirst<T>, P> : true;
33761
33761
  /**
33762
33762
  * removes objects that do not have the property P
33763
33763
  */
33764
- type RemoveMissing<T extends readonly Record<string, unknown>[], P extends string, R extends readonly Record<string, unknown>[] = []> = [] extends T ? R[number] : RemoveMissing<AfterFirst<T>, P, P extends keyof First<T> ? [
33764
+ type RemoveMissing<T extends readonly AnyObject[], P extends string, R extends readonly AnyObject[] = []> = [] extends T ? R[number] : RemoveMissing<AfterFirst<T>, P, P extends keyof First<T> ? [
33765
33765
  ...R,
33766
33766
  First<T>
33767
33767
  ] : R>;
@@ -33785,7 +33785,7 @@ type RemoveMissing<T extends readonly Record<string, unknown>[], P extends strin
33785
33785
  * type U = UnionFromProp<typeof data, "id">;
33786
33786
  * ```
33787
33787
  */
33788
- type UnionFromProp<T extends readonly Record<string, unknown>[], P extends string> = HasMissingInstance<T, P> extends true ? Get$1<RemoveMissing<T, P>, P> | undefined : Get$1<T[number], P>;
33788
+ type UnionFromProp<T extends readonly AnyObject[], P extends string> = HasMissingInstance<T, P> extends true ? Get$1<RemoveMissing<T, P>, P> | undefined : Get$1<T[number], P>;
33789
33789
 
33790
33790
  type _Keys$2<T extends object> = UnionToTuple$1<keyof RemoveIndexKeys<T>> extends readonly ObjectKey[] ? UnionToTuple$1<keyof RemoveIndexKeys<T>> : never;
33791
33791
  type ProcessObj$1<T extends Container, TKeys extends readonly PropertyKey[], TResults extends Dictionary = EmptyObject> = [] extends TKeys ? TResults : First<TKeys> extends keyof T ? IfNever<T[First<TKeys>], ProcessObj$1<T, AfterFirst<TKeys>, TResults>, ProcessObj$1<T, AfterFirst<TKeys>, First<TKeys> extends keyof T ? TResults extends readonly unknown[] ? [...TResults, T[First<TKeys>]] : TResults extends Dictionary ? TResults & Record<First<TKeys>, T[First<TKeys>]> : never : never>> : never;