import type { TSchema, SchemaOptions } from '../schema/index'; import type { AssertRest, AssertType, UnionToTuple } from '../helpers/index'; import type { TMappedResult } from '../mapped/index'; import { type TUnion } from '../union/index'; import { type Static } from '../static/index'; import { type TNever } from '../never/index'; import { type TUnionEvaluated } from '../union/index'; import { type TTemplateLiteral } from '../template-literal/index'; import { type TExtractFromMappedResult } from './extract-from-mapped-result'; import { type TExtractFromTemplateLiteral } from './extract-from-template-literal'; type TExtractRest = AssertRest> extends Static ? L[K] : never; }[number]>> extends infer R extends TSchema[] ? TUnionEvaluated : never; export type TExtract = (L extends TUnion ? TExtractRest : L extends U ? L : TNever); /** `[Json]` Constructs a type by extracting from type all union members that are assignable to union */ export declare function Extract(type: L, union: R, options?: SchemaOptions): TExtractFromMappedResult; /** `[Json]` Constructs a type by extracting from type all union members that are assignable to union */ export declare function Extract(type: L, union: R, options?: SchemaOptions): TExtractFromTemplateLiteral; /** `[Json]` Constructs a type by extracting from type all union members that are assignable to union */ export declare function Extract(type: L, union: R, options?: SchemaOptions): TExtract; export {};