@otim/sdk-core 0.0.2 → 0.0.4-alpha.0
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/dist/.tsbuildinfo +1 -1
- package/dist/abi-DW6AS0eM.d.mts +339 -0
- package/dist/abi-DW6AS0eM.d.mts.map +1 -0
- package/dist/abi-OUq-mx1W.d.cts +339 -0
- package/dist/abi-OUq-mx1W.d.cts.map +1 -0
- package/dist/account/index.cjs +1 -1
- package/dist/account/index.d.cts +5 -3
- package/dist/account/index.d.mts +5 -3
- package/dist/account/index.mjs +1 -1
- package/dist/{account-Bwm5PTcc.cjs → account-CRvC_dXT.cjs} +8 -3
- package/dist/account-CRvC_dXT.cjs.map +1 -0
- package/dist/{account-p4sxzIt3.mjs → account-D1NVta26.mjs} +8 -3
- package/dist/account-D1NVta26.mjs.map +1 -0
- package/dist/authorization-6anhDdQX.d.cts +210 -0
- package/dist/authorization-6anhDdQX.d.cts.map +1 -0
- package/dist/authorization-DnNpWjxB.d.mts +210 -0
- package/dist/authorization-DnNpWjxB.d.mts.map +1 -0
- package/dist/clients/index.cjs +3 -2
- package/dist/clients/index.d.cts +3 -3
- package/dist/clients/index.d.mts +3 -3
- package/dist/clients/index.mjs +2 -2
- package/dist/{clients-DBRhkU4y.cjs → clients-BCyzdTLc.cjs} +90 -127
- package/dist/clients-BCyzdTLc.cjs.map +1 -0
- package/dist/{clients-DMKeLhcJ.mjs → clients-Bn4BUElo.mjs} +83 -126
- package/dist/clients-Bn4BUElo.mjs.map +1 -0
- package/dist/config/index.d.cts +2 -2
- package/dist/config/index.d.mts +2 -2
- package/dist/context/index.d.cts +4 -1
- package/dist/context/index.d.mts +4 -1
- package/dist/{index-DW_zBRKz.d.mts → index-BQMXYh9N.d.cts} +2 -13
- package/dist/index-BQMXYh9N.d.cts.map +1 -0
- package/dist/{index-B4fkcFy5.d.mts → index-C5c51xs0.d.mts} +5 -8
- package/dist/index-C5c51xs0.d.mts.map +1 -0
- package/dist/{index-DK-40z4V.d.cts → index-C8H-BPGH.d.cts} +5 -8
- package/dist/index-C8H-BPGH.d.cts.map +1 -0
- package/dist/{index-De8OZ-Be.d.cts → index-Ce_qYSJj.d.cts} +30 -36
- package/dist/index-Ce_qYSJj.d.cts.map +1 -0
- package/dist/{index-e5BLgzcW.d.mts → index-CiyyA-wd.d.mts} +30 -36
- package/dist/index-CiyyA-wd.d.mts.map +1 -0
- package/dist/{index-BnP8vpJJ.d.cts → index-CnjY7cyS.d.mts} +2 -13
- package/dist/index-CnjY7cyS.d.mts.map +1 -0
- package/dist/{index-CcCMIBgF.d.mts → index-DWE1xfOE.d.mts} +4 -1
- package/dist/index-DWE1xfOE.d.mts.map +1 -0
- package/dist/{index-UnaahQgb.d.cts → index-D_7CTJDl.d.mts} +2 -2
- package/dist/{index-C4N2Xixk.d.mts.map → index-D_7CTJDl.d.mts.map} +1 -1
- package/dist/{index-C1HSAemv.d.cts → index-GSspyLr3.d.cts} +4 -1
- package/dist/index-GSspyLr3.d.cts.map +1 -0
- package/dist/{index-C4N2Xixk.d.mts → index-lW-Oor1B.d.cts} +2 -2
- package/dist/{index-UnaahQgb.d.cts.map → index-lW-Oor1B.d.cts.map} +1 -1
- package/dist/index.cjs +5 -4
- package/dist/index.d.cts +9 -8
- package/dist/index.d.mts +9 -8
- package/dist/index.mjs +3 -3
- package/dist/rpc-BDoNl1Sp.d.cts +6885 -0
- package/dist/rpc-BDoNl1Sp.d.cts.map +1 -0
- package/dist/rpc-CygBD_f7.d.mts +6885 -0
- package/dist/rpc-CygBD_f7.d.mts.map +1 -0
- package/dist/utils/index.d.cts +3 -3
- package/dist/utils/index.d.mts +3 -3
- package/package.json +5 -5
- package/dist/abi-Bd3X6gV9.d.mts +0 -154
- package/dist/abi-Bd3X6gV9.d.mts.map +0 -1
- package/dist/abi-CQuxrNCU.d.cts +0 -154
- package/dist/abi-CQuxrNCU.d.cts.map +0 -1
- package/dist/account-Bwm5PTcc.cjs.map +0 -1
- package/dist/account-p4sxzIt3.mjs.map +0 -1
- package/dist/clients-DBRhkU4y.cjs.map +0 -1
- package/dist/clients-DMKeLhcJ.mjs.map +0 -1
- package/dist/index-B4fkcFy5.d.mts.map +0 -1
- package/dist/index-BnP8vpJJ.d.cts.map +0 -1
- package/dist/index-C1HSAemv.d.cts.map +0 -1
- package/dist/index-CcCMIBgF.d.mts.map +0 -1
- package/dist/index-DK-40z4V.d.cts.map +0 -1
- package/dist/index-DW_zBRKz.d.mts.map +0 -1
- package/dist/index-De8OZ-Be.d.cts.map +0 -1
- package/dist/index-e5BLgzcW.d.mts.map +0 -1
- package/dist/misc-CX4pLJaA.d.mts +0 -42
- package/dist/misc-CX4pLJaA.d.mts.map +0 -1
- package/dist/misc-CpZxSPCP.d.cts +0 -42
- package/dist/misc-CpZxSPCP.d.cts.map +0 -1
package/dist/misc-CX4pLJaA.d.mts
DELETED
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
//#region ../../node_modules/.pnpm/viem@2.39.3_bufferutil@4.0.9_typescript@5.9.3_utf-8-validate@5.0.10_zod@4.1.12/node_modules/viem/_types/types/utils.d.ts
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* @description Combines members of an intersection into a readable type.
|
|
5
|
-
*
|
|
6
|
-
* @see {@link https://twitter.com/mattpocockuk/status/1622730173446557697?s=20&t=NdpAcmEFXY01xkqU3KO0Mg}
|
|
7
|
-
* @example
|
|
8
|
-
* Prettify<{ a: string } & { b: string } & { c: number, d: bigint }>
|
|
9
|
-
* => { a: string, b: string, c: number, d: bigint }
|
|
10
|
-
*/
|
|
11
|
-
type Prettify<T> = { [K in keyof T]: T[K] } & {};
|
|
12
|
-
type ExactPartial<type> = { [key in keyof type]?: type[key] | undefined };
|
|
13
|
-
type OneOf<union extends object, fallback extends object | undefined = undefined, keys extends KeyofUnion<union> = KeyofUnion<union>> = union extends infer item ? Prettify<item & { [key in Exclude<keys, keyof item>]?: fallback extends object ? key extends keyof fallback ? fallback[key] : undefined : undefined }> : never;
|
|
14
|
-
type KeyofUnion<type> = type extends type ? keyof type : never;
|
|
15
|
-
/**
|
|
16
|
-
* Loose version of {@link Omit}
|
|
17
|
-
* @internal
|
|
18
|
-
*/
|
|
19
|
-
//#endregion
|
|
20
|
-
//#region ../../node_modules/.pnpm/viem@2.39.3_bufferutil@4.0.9_typescript@5.9.3_utf-8-validate@5.0.10_zod@4.1.12/node_modules/viem/_types/types/misc.d.ts
|
|
21
|
-
type Hex = `0x${string}`;
|
|
22
|
-
type SignatureLegacy<bigintType = bigint> = {
|
|
23
|
-
r: Hex;
|
|
24
|
-
s: Hex;
|
|
25
|
-
v: bigintType;
|
|
26
|
-
};
|
|
27
|
-
type Signature<numberType = number, bigintType = bigint> = OneOf<SignatureLegacy | {
|
|
28
|
-
r: Hex;
|
|
29
|
-
s: Hex;
|
|
30
|
-
/** @deprecated use `yParity`. */
|
|
31
|
-
v: bigintType;
|
|
32
|
-
yParity?: numberType | undefined;
|
|
33
|
-
} | {
|
|
34
|
-
r: Hex;
|
|
35
|
-
s: Hex;
|
|
36
|
-
/** @deprecated use `yParity`. */
|
|
37
|
-
v?: bigintType | undefined;
|
|
38
|
-
yParity: numberType;
|
|
39
|
-
}>;
|
|
40
|
-
//#endregion
|
|
41
|
-
export { Signature as n, ExactPartial as r, Hex as t };
|
|
42
|
-
//# sourceMappingURL=misc-CX4pLJaA.d.mts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"misc-CX4pLJaA.d.mts","names":["symbol","Branded","T","U","Filter","P","Acc","F","Rest","IsNarrowable","IsNever","Mutable","type","key","Or","Head","Tail","IsUndefined","MaybePromise","Promise","MaybeRequired","required","ExactRequired","Assign","Assign_","K","NoInfer","NoUndefined","Omit","keys","Exclude","Pick","PartialBy","ExactPartial","Prettify","Evaluate","RequiredBy","Some","array","value","rest","ValueOf","UnionToTuple","union","last","LastInUnion","UnionToIntersection","l","i","IsUnion","union2","MaybePartial","enabled","OneOf","fallback","KeyofUnion","item","LooseOmit","UnionEvaluate","UnionLooseOmit","UnionOmit","UnionPick","UnionPartialBy","UnionRequiredBy","OneOf","ByteArray","Uint8Array","Hex","Hash","LogTopic","SignableMessage","SignatureLegacy","bigintType","Signature","numberType","CompactSignature"],"sources":["../../../node_modules/.pnpm/viem@2.39.3_bufferutil@4.0.9_typescript@5.9.3_utf-8-validate@5.0.10_zod@4.1.12/node_modules/viem/_types/types/utils.d.ts","../../../node_modules/.pnpm/viem@2.39.3_bufferutil@4.0.9_typescript@5.9.3_utf-8-validate@5.0.10_zod@4.1.12/node_modules/viem/_types/types/misc.d.ts"],"sourcesContent":["declare const symbol: unique symbol;\n/**\n * Creates a branded type of {@link T} with the brand {@link U}.\n *\n * @param T - Type to brand\n * @param U - Label\n * @returns Branded type\n *\n * @example\n * type Result = Branded<string, 'foo'>\n * // ^? type Result = string & { [symbol]: 'foo' }\n */\nexport type Branded<T, U> = T & {\n [symbol]: U;\n};\n/**\n * Filters out all members of {@link T} that are not {@link P}\n *\n * @param T - Items to filter\n * @param P - Type to filter out\n * @returns Filtered items\n *\n * @example\n * type Result = Filter<['a', 'b', 'c'], 'b'>\n * // ^? type Result = ['a', 'c']\n */\nexport type Filter<T extends readonly unknown[], P, Acc extends readonly unknown[] = []> = T extends readonly [infer F, ...infer Rest extends readonly unknown[]] ? [F] extends [P] ? Filter<Rest, P, [...Acc, F]> : Filter<Rest, P, Acc> : readonly [...Acc];\n/**\n * @description Checks if {@link T} can be narrowed further than {@link U}\n * @param T - Type to check\n * @param U - Type to against\n * @example\n * type Result = IsNarrowable<'foo', string>\n * // ^? true\n */\nexport type IsNarrowable<T, U> = IsNever<(T extends U ? true : false) & (U extends T ? false : true)> extends true ? false : true;\n/**\n * @description Checks if {@link T} is `never`\n * @param T - Type to check\n * @example\n * type Result = IsNever<never>\n * // ^? type Result = true\n */\nexport type IsNever<T> = [T] extends [never] ? true : false;\n/** Removes `readonly` from all properties of an object. */\nexport type Mutable<type extends object> = {\n -readonly [key in keyof type]: type[key];\n};\n/**\n * @description Evaluates boolean \"or\" condition for {@link T} properties.\n * @param T - Type to check\n *\n * * @example\n * type Result = Or<[false, true, false]>\n * // ^? type Result = true\n *\n * @example\n * type Result = Or<[false, false, false]>\n * // ^? type Result = false\n */\nexport type Or<T extends readonly unknown[]> = T extends readonly [\n infer Head,\n ...infer Tail\n] ? Head extends true ? true : Or<Tail> : false;\n/**\n * @description Checks if {@link T} is `undefined`\n * @param T - Type to check\n * @example\n * type Result = IsUndefined<undefined>\n * // ^? type Result = true\n */\nexport type IsUndefined<T> = [undefined] extends [T] ? true : false;\nexport type MaybePromise<T> = T | Promise<T>;\n/**\n * @description Makes attributes on the type T required if required is true.\n *\n * @example\n * MaybeRequired<{ a: string, b?: number }, true>\n * => { a: string, b: number }\n *\n * MaybeRequired<{ a: string, b?: number }, false>\n * => { a: string, b?: number }\n */\nexport type MaybeRequired<T, required extends boolean> = required extends true ? ExactRequired<T> : T;\n/**\n * @description Assigns the properties of U onto T.\n *\n * @example\n * Assign<{ a: string, b: number }, { a: undefined, c: boolean }>\n * => { a: undefined, b: number, c: boolean }\n */\nexport type Assign<T, U> = Assign_<T, U> & U;\ntype Assign_<T, U> = {\n [K in keyof T as K extends keyof U ? U[K] extends void ? never : K : K]: K extends keyof U ? U[K] : T[K];\n};\nexport type NoInfer<type> = [type][type extends any ? 0 : never];\n/**\n * @description Constructs a type by excluding `undefined` from `T`.\n *\n * @example\n * NoUndefined<string | undefined>\n * => string\n *\n * @internal\n */\nexport type NoUndefined<T> = T extends undefined ? never : T;\n/** Strict version of built-in Omit type */\nexport type Omit<type, keys extends keyof type> = Pick<type, Exclude<keyof type, keys>>;\n/**\n * @description Creates a type that is a partial of T, but with the required keys K.\n *\n * @example\n * PartialBy<{ a: string, b: number }, 'a'>\n * => { a?: string, b: number }\n */\nexport type PartialBy<T, K extends keyof T> = Omit<T, K> & ExactPartial<Pick<T, K>>;\n/**\n * @description Combines members of an intersection into a readable type.\n *\n * @see {@link https://twitter.com/mattpocockuk/status/1622730173446557697?s=20&t=NdpAcmEFXY01xkqU3KO0Mg}\n * @example\n * Prettify<{ a: string } & { b: string } & { c: number, d: bigint }>\n * => { a: string, b: string, c: number, d: bigint }\n */\nexport type Prettify<T> = {\n [K in keyof T]: T[K];\n} & {};\n/** @internal */\nexport type Evaluate<type> = {\n [key in keyof type]: type[key];\n} & {};\n/**\n * @description Creates a type that is T with the required keys K.\n *\n * @example\n * RequiredBy<{ a?: string, b: number }, 'a'>\n * => { a: string, b: number }\n */\nexport type RequiredBy<T, K extends keyof T> = Omit<T, K> & ExactRequired<Pick<T, K>>;\n/**\n * @description Returns truthy if `array` contains `value`.\n *\n * @example\n * Some<[1, 2, 3], 2>\n * => true\n */\nexport type Some<array extends readonly unknown[], value> = array extends readonly [value, ...unknown[]] ? true : array extends readonly [unknown, ...infer rest] ? Some<rest, value> : false;\n/**\n * @description Creates a type that extracts the values of T.\n *\n * @example\n * ValueOf<{ a: string, b: number }>\n * => string | number\n *\n * @internal\n */\nexport type ValueOf<T> = T[keyof T];\nexport type UnionToTuple<union, last = LastInUnion<union>> = [union] extends [never] ? [] : [...UnionToTuple<Exclude<union, last>>, last];\ntype LastInUnion<U> = UnionToIntersection<U extends unknown ? (x: U) => 0 : never> extends (x: infer l) => 0 ? l : never;\ntype UnionToIntersection<union> = (union extends unknown ? (arg: union) => 0 : never) extends (arg: infer i) => 0 ? i : never;\nexport type IsUnion<union, union2 = union> = union extends union2 ? ([union2] extends [union] ? false : true) : never;\nexport type MaybePartial<type, enabled extends boolean | undefined> = enabled extends true ? Prettify<ExactPartial<type>> : type;\nexport type ExactPartial<type> = {\n [key in keyof type]?: type[key] | undefined;\n};\nexport type ExactRequired<type> = {\n [P in keyof type]-?: Exclude<type[P], undefined>;\n};\nexport type OneOf<union extends object, fallback extends object | undefined = undefined, keys extends KeyofUnion<union> = KeyofUnion<union>> = union extends infer item ? Prettify<item & {\n [key in Exclude<keys, keyof item>]?: fallback extends object ? key extends keyof fallback ? fallback[key] : undefined : undefined;\n}> : never;\ntype KeyofUnion<type> = type extends type ? keyof type : never;\n/**\n * Loose version of {@link Omit}\n * @internal\n */\nexport type LooseOmit<type, keys extends string> = Pick<type, Exclude<keyof type, keys>>;\nexport type UnionEvaluate<type> = type extends object ? Prettify<type> : type;\nexport type UnionLooseOmit<type, keys extends string> = type extends any ? LooseOmit<type, keys> : never;\n/**\n * @description Construct a type with the properties of union type T except for those in type K.\n * @example\n * type Result = UnionOmit<{ a: string, b: number } | { a: string, b: undefined, c: number }, 'a'>\n * => { b: number } | { b: undefined, c: number }\n */\nexport type UnionOmit<type, keys extends keyof type> = type extends any ? Omit<type, keys> : never;\n/**\n * @description Construct a type with the properties of union type T except for those in type K.\n * @example\n * type Result = UnionOmit<{ a: string, b: number } | { a: string, b: undefined, c: number }, 'a'>\n * => { b: number } | { b: undefined, c: number }\n */\nexport type UnionPick<type, keys extends keyof type> = type extends any ? Pick<type, keys> : never;\n/**\n * @description Creates a type that is a partial of T, but with the required keys K.\n *\n * @example\n * PartialBy<{ a: string, b: number } | { a: string, b: undefined, c: number }, 'a'>\n * => { a?: string, b: number } | { a?: string, b: undefined, c: number }\n */\nexport type UnionPartialBy<T, K extends keyof T> = T extends any ? PartialBy<T, K> : never;\n/**\n * @description Creates a type that is T with the required keys K.\n *\n * @example\n * RequiredBy<{ a?: string, b: number } | { a?: string, c?: number }, 'a'>\n * => { a: string, b: number } | { a: string, c?: number }\n */\nexport type UnionRequiredBy<T, K extends keyof T> = T extends any ? RequiredBy<T, K> : never;\nexport {};\n//# sourceMappingURL=utils.d.ts.map","import type { OneOf } from './utils.js';\nexport type ByteArray = Uint8Array;\nexport type Hex = `0x${string}`;\nexport type Hash = `0x${string}`;\nexport type LogTopic = Hex | Hex[] | null;\nexport type SignableMessage = string | {\n /** Raw data representation of the message. */\n raw: Hex | ByteArray;\n};\nexport type SignatureLegacy<bigintType = bigint> = {\n r: Hex;\n s: Hex;\n v: bigintType;\n};\nexport type Signature<numberType = number, bigintType = bigint> = OneOf<SignatureLegacy | {\n r: Hex;\n s: Hex;\n /** @deprecated use `yParity`. */\n v: bigintType;\n yParity?: numberType | undefined;\n} | {\n r: Hex;\n s: Hex;\n /** @deprecated use `yParity`. */\n v?: bigintType | undefined;\n yParity: numberType;\n}>;\nexport type CompactSignature = {\n r: Hex;\n yParityAndS: Hex;\n};\n//# sourceMappingURL=misc.d.ts.map"],"x_google_ignoreList":[0,1],"mappings":";;;;;;;;;;KA4HYkC,4BACIhC,IAAIA,EAAEuB;KAqCVQ,qCACMrB,QAAQA,KAAKC;KAKnBwC,0FAA0FE,WAAWZ,SAASY,WAAWZ,UAAUA,2BAA2BT,SAASsB,iBACvK1B,QAAQD,YAAY2B,SAASF,0BAA0BzC,kBAAkByC,WAAWA,SAASzC;KAEpG0C,mBAAmB3C,aAAaA,aAAaA;;;;;;;AA9ClCV,KC3HJiE,GAAAA,GD2HIjE,KAAAA,MAAAA,EAAAA;AAsCeW,KC1JnB0D,eD0JmB1D,CAAAA,aAAAA,MAAAA,CAAAA,GAAAA;EAAG,CAAA,ECzJ3BsD,GDyJ2B;EAKtBd,CAAAA,EC7JLc,GD6JKd;EAAqGV,CAAAA,EC5J1G6B,UD4J0G7B;CAAXY;AAA+BZ,KC1JzH8B,SD0JyH9B,CAAAA,aAAAA,MAAAA,EAAAA,aAAAA,MAAAA,CAAAA,GC1JnEqB,KD0JmErB,CC1J7D4B,eD0J6D5B,GAAAA;EAAXY,CAAAA,ECzJnHY,GDyJmHZ;EAAqBZ,CAAAA,ECxJxIwB,GDwJwIxB;EAAoCa;EAC/J3B,CAAAA,ECvJb2C,UDuJa3C;EAAY2B,OAAAA,CAAAA,ECtJlBkB,UDsJkBlB,GAAAA,SAAAA;CAApB1B,GAAAA;EAA6BwB,CAAAA,ECpJlCa,GDoJkCb;EAA0BzC,CAAAA,ECnJ5DsD,GDmJ4DtD;EAAkByC;EAAWA,CAAAA,CAAAA,ECjJxFkB,UDiJwFlB,GAAAA,SAAAA;EAASzC,OAAAA,EChJ5F6D,UDgJ4F7D;CADiEqB,CAAAA"}
|
package/dist/misc-CpZxSPCP.d.cts
DELETED
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
//#region ../../node_modules/.pnpm/viem@2.39.3_bufferutil@4.0.9_typescript@5.9.3_utf-8-validate@5.0.10_zod@4.1.12/node_modules/viem/_types/types/utils.d.ts
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* @description Combines members of an intersection into a readable type.
|
|
5
|
-
*
|
|
6
|
-
* @see {@link https://twitter.com/mattpocockuk/status/1622730173446557697?s=20&t=NdpAcmEFXY01xkqU3KO0Mg}
|
|
7
|
-
* @example
|
|
8
|
-
* Prettify<{ a: string } & { b: string } & { c: number, d: bigint }>
|
|
9
|
-
* => { a: string, b: string, c: number, d: bigint }
|
|
10
|
-
*/
|
|
11
|
-
type Prettify<T> = { [K in keyof T]: T[K] } & {};
|
|
12
|
-
type ExactPartial<type> = { [key in keyof type]?: type[key] | undefined };
|
|
13
|
-
type OneOf<union extends object, fallback extends object | undefined = undefined, keys extends KeyofUnion<union> = KeyofUnion<union>> = union extends infer item ? Prettify<item & { [key in Exclude<keys, keyof item>]?: fallback extends object ? key extends keyof fallback ? fallback[key] : undefined : undefined }> : never;
|
|
14
|
-
type KeyofUnion<type> = type extends type ? keyof type : never;
|
|
15
|
-
/**
|
|
16
|
-
* Loose version of {@link Omit}
|
|
17
|
-
* @internal
|
|
18
|
-
*/
|
|
19
|
-
//#endregion
|
|
20
|
-
//#region ../../node_modules/.pnpm/viem@2.39.3_bufferutil@4.0.9_typescript@5.9.3_utf-8-validate@5.0.10_zod@4.1.12/node_modules/viem/_types/types/misc.d.ts
|
|
21
|
-
type Hex = `0x${string}`;
|
|
22
|
-
type SignatureLegacy<bigintType = bigint> = {
|
|
23
|
-
r: Hex;
|
|
24
|
-
s: Hex;
|
|
25
|
-
v: bigintType;
|
|
26
|
-
};
|
|
27
|
-
type Signature<numberType = number, bigintType = bigint> = OneOf<SignatureLegacy | {
|
|
28
|
-
r: Hex;
|
|
29
|
-
s: Hex;
|
|
30
|
-
/** @deprecated use `yParity`. */
|
|
31
|
-
v: bigintType;
|
|
32
|
-
yParity?: numberType | undefined;
|
|
33
|
-
} | {
|
|
34
|
-
r: Hex;
|
|
35
|
-
s: Hex;
|
|
36
|
-
/** @deprecated use `yParity`. */
|
|
37
|
-
v?: bigintType | undefined;
|
|
38
|
-
yParity: numberType;
|
|
39
|
-
}>;
|
|
40
|
-
//#endregion
|
|
41
|
-
export { Signature as n, ExactPartial as r, Hex as t };
|
|
42
|
-
//# sourceMappingURL=misc-CpZxSPCP.d.cts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"misc-CpZxSPCP.d.cts","names":["symbol","Branded","T","U","Filter","P","Acc","F","Rest","IsNarrowable","IsNever","Mutable","type","key","Or","Head","Tail","IsUndefined","MaybePromise","Promise","MaybeRequired","required","ExactRequired","Assign","Assign_","K","NoInfer","NoUndefined","Omit","keys","Exclude","Pick","PartialBy","ExactPartial","Prettify","Evaluate","RequiredBy","Some","array","value","rest","ValueOf","UnionToTuple","union","last","LastInUnion","UnionToIntersection","l","i","IsUnion","union2","MaybePartial","enabled","OneOf","fallback","KeyofUnion","item","LooseOmit","UnionEvaluate","UnionLooseOmit","UnionOmit","UnionPick","UnionPartialBy","UnionRequiredBy","OneOf","ByteArray","Uint8Array","Hex","Hash","LogTopic","SignableMessage","SignatureLegacy","bigintType","Signature","numberType","CompactSignature"],"sources":["../../../node_modules/.pnpm/viem@2.39.3_bufferutil@4.0.9_typescript@5.9.3_utf-8-validate@5.0.10_zod@4.1.12/node_modules/viem/_types/types/utils.d.ts","../../../node_modules/.pnpm/viem@2.39.3_bufferutil@4.0.9_typescript@5.9.3_utf-8-validate@5.0.10_zod@4.1.12/node_modules/viem/_types/types/misc.d.ts"],"sourcesContent":["declare const symbol: unique symbol;\n/**\n * Creates a branded type of {@link T} with the brand {@link U}.\n *\n * @param T - Type to brand\n * @param U - Label\n * @returns Branded type\n *\n * @example\n * type Result = Branded<string, 'foo'>\n * // ^? type Result = string & { [symbol]: 'foo' }\n */\nexport type Branded<T, U> = T & {\n [symbol]: U;\n};\n/**\n * Filters out all members of {@link T} that are not {@link P}\n *\n * @param T - Items to filter\n * @param P - Type to filter out\n * @returns Filtered items\n *\n * @example\n * type Result = Filter<['a', 'b', 'c'], 'b'>\n * // ^? type Result = ['a', 'c']\n */\nexport type Filter<T extends readonly unknown[], P, Acc extends readonly unknown[] = []> = T extends readonly [infer F, ...infer Rest extends readonly unknown[]] ? [F] extends [P] ? Filter<Rest, P, [...Acc, F]> : Filter<Rest, P, Acc> : readonly [...Acc];\n/**\n * @description Checks if {@link T} can be narrowed further than {@link U}\n * @param T - Type to check\n * @param U - Type to against\n * @example\n * type Result = IsNarrowable<'foo', string>\n * // ^? true\n */\nexport type IsNarrowable<T, U> = IsNever<(T extends U ? true : false) & (U extends T ? false : true)> extends true ? false : true;\n/**\n * @description Checks if {@link T} is `never`\n * @param T - Type to check\n * @example\n * type Result = IsNever<never>\n * // ^? type Result = true\n */\nexport type IsNever<T> = [T] extends [never] ? true : false;\n/** Removes `readonly` from all properties of an object. */\nexport type Mutable<type extends object> = {\n -readonly [key in keyof type]: type[key];\n};\n/**\n * @description Evaluates boolean \"or\" condition for {@link T} properties.\n * @param T - Type to check\n *\n * * @example\n * type Result = Or<[false, true, false]>\n * // ^? type Result = true\n *\n * @example\n * type Result = Or<[false, false, false]>\n * // ^? type Result = false\n */\nexport type Or<T extends readonly unknown[]> = T extends readonly [\n infer Head,\n ...infer Tail\n] ? Head extends true ? true : Or<Tail> : false;\n/**\n * @description Checks if {@link T} is `undefined`\n * @param T - Type to check\n * @example\n * type Result = IsUndefined<undefined>\n * // ^? type Result = true\n */\nexport type IsUndefined<T> = [undefined] extends [T] ? true : false;\nexport type MaybePromise<T> = T | Promise<T>;\n/**\n * @description Makes attributes on the type T required if required is true.\n *\n * @example\n * MaybeRequired<{ a: string, b?: number }, true>\n * => { a: string, b: number }\n *\n * MaybeRequired<{ a: string, b?: number }, false>\n * => { a: string, b?: number }\n */\nexport type MaybeRequired<T, required extends boolean> = required extends true ? ExactRequired<T> : T;\n/**\n * @description Assigns the properties of U onto T.\n *\n * @example\n * Assign<{ a: string, b: number }, { a: undefined, c: boolean }>\n * => { a: undefined, b: number, c: boolean }\n */\nexport type Assign<T, U> = Assign_<T, U> & U;\ntype Assign_<T, U> = {\n [K in keyof T as K extends keyof U ? U[K] extends void ? never : K : K]: K extends keyof U ? U[K] : T[K];\n};\nexport type NoInfer<type> = [type][type extends any ? 0 : never];\n/**\n * @description Constructs a type by excluding `undefined` from `T`.\n *\n * @example\n * NoUndefined<string | undefined>\n * => string\n *\n * @internal\n */\nexport type NoUndefined<T> = T extends undefined ? never : T;\n/** Strict version of built-in Omit type */\nexport type Omit<type, keys extends keyof type> = Pick<type, Exclude<keyof type, keys>>;\n/**\n * @description Creates a type that is a partial of T, but with the required keys K.\n *\n * @example\n * PartialBy<{ a: string, b: number }, 'a'>\n * => { a?: string, b: number }\n */\nexport type PartialBy<T, K extends keyof T> = Omit<T, K> & ExactPartial<Pick<T, K>>;\n/**\n * @description Combines members of an intersection into a readable type.\n *\n * @see {@link https://twitter.com/mattpocockuk/status/1622730173446557697?s=20&t=NdpAcmEFXY01xkqU3KO0Mg}\n * @example\n * Prettify<{ a: string } & { b: string } & { c: number, d: bigint }>\n * => { a: string, b: string, c: number, d: bigint }\n */\nexport type Prettify<T> = {\n [K in keyof T]: T[K];\n} & {};\n/** @internal */\nexport type Evaluate<type> = {\n [key in keyof type]: type[key];\n} & {};\n/**\n * @description Creates a type that is T with the required keys K.\n *\n * @example\n * RequiredBy<{ a?: string, b: number }, 'a'>\n * => { a: string, b: number }\n */\nexport type RequiredBy<T, K extends keyof T> = Omit<T, K> & ExactRequired<Pick<T, K>>;\n/**\n * @description Returns truthy if `array` contains `value`.\n *\n * @example\n * Some<[1, 2, 3], 2>\n * => true\n */\nexport type Some<array extends readonly unknown[], value> = array extends readonly [value, ...unknown[]] ? true : array extends readonly [unknown, ...infer rest] ? Some<rest, value> : false;\n/**\n * @description Creates a type that extracts the values of T.\n *\n * @example\n * ValueOf<{ a: string, b: number }>\n * => string | number\n *\n * @internal\n */\nexport type ValueOf<T> = T[keyof T];\nexport type UnionToTuple<union, last = LastInUnion<union>> = [union] extends [never] ? [] : [...UnionToTuple<Exclude<union, last>>, last];\ntype LastInUnion<U> = UnionToIntersection<U extends unknown ? (x: U) => 0 : never> extends (x: infer l) => 0 ? l : never;\ntype UnionToIntersection<union> = (union extends unknown ? (arg: union) => 0 : never) extends (arg: infer i) => 0 ? i : never;\nexport type IsUnion<union, union2 = union> = union extends union2 ? ([union2] extends [union] ? false : true) : never;\nexport type MaybePartial<type, enabled extends boolean | undefined> = enabled extends true ? Prettify<ExactPartial<type>> : type;\nexport type ExactPartial<type> = {\n [key in keyof type]?: type[key] | undefined;\n};\nexport type ExactRequired<type> = {\n [P in keyof type]-?: Exclude<type[P], undefined>;\n};\nexport type OneOf<union extends object, fallback extends object | undefined = undefined, keys extends KeyofUnion<union> = KeyofUnion<union>> = union extends infer item ? Prettify<item & {\n [key in Exclude<keys, keyof item>]?: fallback extends object ? key extends keyof fallback ? fallback[key] : undefined : undefined;\n}> : never;\ntype KeyofUnion<type> = type extends type ? keyof type : never;\n/**\n * Loose version of {@link Omit}\n * @internal\n */\nexport type LooseOmit<type, keys extends string> = Pick<type, Exclude<keyof type, keys>>;\nexport type UnionEvaluate<type> = type extends object ? Prettify<type> : type;\nexport type UnionLooseOmit<type, keys extends string> = type extends any ? LooseOmit<type, keys> : never;\n/**\n * @description Construct a type with the properties of union type T except for those in type K.\n * @example\n * type Result = UnionOmit<{ a: string, b: number } | { a: string, b: undefined, c: number }, 'a'>\n * => { b: number } | { b: undefined, c: number }\n */\nexport type UnionOmit<type, keys extends keyof type> = type extends any ? Omit<type, keys> : never;\n/**\n * @description Construct a type with the properties of union type T except for those in type K.\n * @example\n * type Result = UnionOmit<{ a: string, b: number } | { a: string, b: undefined, c: number }, 'a'>\n * => { b: number } | { b: undefined, c: number }\n */\nexport type UnionPick<type, keys extends keyof type> = type extends any ? Pick<type, keys> : never;\n/**\n * @description Creates a type that is a partial of T, but with the required keys K.\n *\n * @example\n * PartialBy<{ a: string, b: number } | { a: string, b: undefined, c: number }, 'a'>\n * => { a?: string, b: number } | { a?: string, b: undefined, c: number }\n */\nexport type UnionPartialBy<T, K extends keyof T> = T extends any ? PartialBy<T, K> : never;\n/**\n * @description Creates a type that is T with the required keys K.\n *\n * @example\n * RequiredBy<{ a?: string, b: number } | { a?: string, c?: number }, 'a'>\n * => { a: string, b: number } | { a: string, c?: number }\n */\nexport type UnionRequiredBy<T, K extends keyof T> = T extends any ? RequiredBy<T, K> : never;\nexport {};\n//# sourceMappingURL=utils.d.ts.map","import type { OneOf } from './utils.js';\nexport type ByteArray = Uint8Array;\nexport type Hex = `0x${string}`;\nexport type Hash = `0x${string}`;\nexport type LogTopic = Hex | Hex[] | null;\nexport type SignableMessage = string | {\n /** Raw data representation of the message. */\n raw: Hex | ByteArray;\n};\nexport type SignatureLegacy<bigintType = bigint> = {\n r: Hex;\n s: Hex;\n v: bigintType;\n};\nexport type Signature<numberType = number, bigintType = bigint> = OneOf<SignatureLegacy | {\n r: Hex;\n s: Hex;\n /** @deprecated use `yParity`. */\n v: bigintType;\n yParity?: numberType | undefined;\n} | {\n r: Hex;\n s: Hex;\n /** @deprecated use `yParity`. */\n v?: bigintType | undefined;\n yParity: numberType;\n}>;\nexport type CompactSignature = {\n r: Hex;\n yParityAndS: Hex;\n};\n//# sourceMappingURL=misc.d.ts.map"],"x_google_ignoreList":[0,1],"mappings":";;;;;;;;;;KA4HYkC,4BACIhC,IAAIA,EAAEuB;KAqCVQ,qCACMrB,QAAQA,KAAKC;KAKnBwC,0FAA0FE,WAAWZ,SAASY,WAAWZ,UAAUA,2BAA2BT,SAASsB,iBACvK1B,QAAQD,YAAY2B,SAASF,0BAA0BzC,kBAAkByC,WAAWA,SAASzC;KAEpG0C,mBAAmB3C,aAAaA,aAAaA;;;;;;;AA9ClCV,KC3HJiE,GAAAA,GD2HIjE,KAAAA,MAAAA,EAAAA;AAsCeW,KC1JnB0D,eD0JmB1D,CAAAA,aAAAA,MAAAA,CAAAA,GAAAA;EAAG,CAAA,ECzJ3BsD,GDyJ2B;EAKtBd,CAAAA,EC7JLc,GD6JKd;EAAqGV,CAAAA,EC5J1G6B,UD4J0G7B;CAAXY;AAA+BZ,KC1JzH8B,SD0JyH9B,CAAAA,aAAAA,MAAAA,EAAAA,aAAAA,MAAAA,CAAAA,GC1JnEqB,KD0JmErB,CC1J7D4B,eD0J6D5B,GAAAA;EAAXY,CAAAA,ECzJnHY,GDyJmHZ;EAAqBZ,CAAAA,ECxJxIwB,GDwJwIxB;EAAoCa;EAC/J3B,CAAAA,ECvJb2C,UDuJa3C;EAAY2B,OAAAA,CAAAA,ECtJlBkB,UDsJkBlB,GAAAA,SAAAA;CAApB1B,GAAAA;EAA6BwB,CAAAA,ECpJlCa,GDoJkCb;EAA0BzC,CAAAA,ECnJ5DsD,GDmJ4DtD;EAAkByC;EAAWA,CAAAA,CAAAA,ECjJxFkB,UDiJwFlB,GAAAA,SAAAA;EAASzC,OAAAA,EChJ5F6D,UDgJ4F7D;CADiEqB,CAAAA"}
|