export type JsonCdc = { type: L; value: T; }; type JsonCdcLabel> = X extends JsonCdc ? L : never; export interface TypeDescriptor> { label: JsonCdcLabel; asArgument: (x: T) => V; asInjection: (x: T) => T; } export type TypeDescriptorInput>> = X extends TypeDescriptor> ? T : never; export interface PathValue { domain: "storage" | "private" | "public"; identifier: string; } /** * @deprecated Reference values cannot be imported into the Cadence interpreter, will be removed in future versions */ export interface ReferenceValue { type: string; address: string; } /** * @deprecated will be removed in v2.0.0 */ export declare const Identity: { label: string; asArgument: (v: T) => T; asInjection: (v: T) => T; }; export declare const UInt: TypeDescriptor; export declare const Int: TypeDescriptor; export declare const UInt8: TypeDescriptor; export declare const Int8: TypeDescriptor; export declare const UInt16: TypeDescriptor; export declare const Int16: TypeDescriptor; export declare const UInt32: TypeDescriptor; export declare const Int32: TypeDescriptor; export declare const UInt64: TypeDescriptor; export declare const Int64: TypeDescriptor; export declare const UInt128: TypeDescriptor; export declare const Int128: TypeDescriptor; export declare const UInt256: TypeDescriptor; export declare const Int256: TypeDescriptor; export declare const Word8: TypeDescriptor; export declare const Word16: TypeDescriptor; export declare const Word32: TypeDescriptor; export declare const Word64: TypeDescriptor; export declare const Word128: TypeDescriptor; export declare const Word256: TypeDescriptor; export declare const UFix64: TypeDescriptor; export declare const Fix64: TypeDescriptor; export declare const UFix128: TypeDescriptor; export declare const Fix128: TypeDescriptor; export declare const String: TypeDescriptor; export declare const Character: TypeDescriptor; export declare const Bool: TypeDescriptor; export declare const Address: TypeDescriptor; export declare const Void: TypeDescriptor; export declare const Optional: >(children: T) => TypeDescriptor | null | undefined, { type: string; value: any; }>; /** * @deprecated Reference values cannot be imported into the Cadence interpreter, will be removed in future versions */ export declare const Reference: TypeDescriptor; export declare const _Array: >(children?: T[] | T) => TypeDescriptor[], { type: string; value: any[]; }>; export { _Array as Array }; export declare const Dictionary: , V extends TypeDescriptor>(children?: { key: K; value: V; }[] | { key: K; value: V; }) => TypeDescriptor<{ key: TypeDescriptorInput; value: TypeDescriptorInput; }[] | { key: TypeDescriptorInput; value: TypeDescriptorInput; }, { type: string; value: { key: any; value: any; }[]; }>; export declare const Event: >(id: string, fields?: { value: V; }[] | { value: V; }) => TypeDescriptor<{ fields: { name: string; value: TypeDescriptorInput; }[]; }, { type: string; value: { id: string; fields: { name: string; value: any; }[]; }; }>; export declare const Resource: >(id: string, fields?: { value: V; }[] | { value: V; }) => TypeDescriptor<{ fields: { name: string; value: TypeDescriptorInput; }[]; }, { type: string; value: { id: string; fields: { name: string; value: any; }[]; }; }>; export declare const Struct: >(id: string, fields?: { value: V; }[] | { value: V; }) => TypeDescriptor<{ fields: { name: string; value: TypeDescriptorInput; }[]; }, { type: string; value: { id: string; fields: { name: string; value: any; }[]; }; }>; export declare const Enum: >(id: string, fields?: { value: V; }[] | { value: V; }) => TypeDescriptor<{ fields: { name: string; value: TypeDescriptorInput; }[]; }, { type: string; value: { id: string; fields: { name: string; value: any; }[]; }; }>; export declare const Path: TypeDescriptor; /** * InclusiveRange type * * @param t - A TypeDescriptor for the type of the range, must be a number (UInt32, Int32, etc.) * @returns A TypeDescriptor for an InclusiveRange of the given type * * @example * ```javascript * import * as fcl from "@onflow/fcl" * import {InclusiveRange, UInt32} from "@onflow/types" * * const someArg = fcl.arg({start: 1, end: 5, step: 1}, InclusiveRange(UInt32)) * ``` */ export declare const InclusiveRange: >(t: T) => TypeDescriptor<{ start: TypeDescriptorInput; end: TypeDescriptorInput; step: TypeDescriptorInput; }, { type: string; value: { start: any; end: any; step: any; }; }>;