1 | export declare const BLOCKSTACK_HANDLER = "blockstack";
|
2 | export declare function nextYear(): Date;
|
3 | export declare function nextMonth(): Date;
|
4 | export declare function nextHour(): Date;
|
5 | export declare function megabytesToBytes(megabytes: number): number;
|
6 | export declare function getAesCbcOutputLength(inputByteLength: number): number;
|
7 | export declare function getBase64OutputLength(inputByteLength: number): number;
|
8 | export declare function updateQueryStringParameter(uri: string, key: string, value: string): string;
|
9 | export declare function isLaterVersion(v1: string, v2: string): boolean;
|
10 | export declare function makeUUID4(): string;
|
11 | export declare function isSameOriginAbsoluteUrl(uri1: string, uri2: string): boolean;
|
12 | export declare function getGlobalScope(): Window;
|
13 | interface GetGlobalObjectOptions {
|
14 | throwIfUnavailable?: boolean;
|
15 | usageDesc?: string;
|
16 | returnEmptyObject?: boolean;
|
17 | }
|
18 | export declare function getGlobalObject<K extends Extract<keyof Window, string>>(name: K, { throwIfUnavailable, usageDesc, returnEmptyObject }?: GetGlobalObjectOptions): Window[K] | undefined;
|
19 | export declare function getGlobalObjects<K extends Extract<keyof Window, string>>(names: K[], { throwIfUnavailable, usageDesc, returnEmptyObject }?: GetGlobalObjectOptions): Pick<Window, K>;
|
20 | declare type BN = import('bn.js');
|
21 | export declare type IntegerType = number | string | bigint | Uint8Array | BN;
|
22 | export declare function intToBytes(value: IntegerType, signed: boolean, byteLength: number): Uint8Array;
|
23 | export declare function intToBigInt(value: IntegerType, signed: boolean): bigint;
|
24 | export declare function with0x(value: string): string;
|
25 | export declare function hexToBigInt(hex: string): bigint;
|
26 | export declare function intToHex(integer: IntegerType, lengthBytes?: number): string;
|
27 | export declare function hexToInt(hex: string): number;
|
28 | export declare function bigIntToBytes(value: bigint, length?: number): Uint8Array;
|
29 | export declare function toTwos(value: bigint, width: bigint): bigint;
|
30 | export declare function fromTwos(value: bigint, width: bigint): bigint;
|
31 | export declare function bytesToHex(uint8a: Uint8Array): string;
|
32 | export declare function hexToBytes(hex: string): Uint8Array;
|
33 | export declare function utf8ToBytes(str: string): Uint8Array;
|
34 | export declare function bytesToUtf8(arr: Uint8Array): string;
|
35 | export declare function asciiToBytes(str: string): Uint8Array;
|
36 | export declare function bytesToAscii(arr: Uint8Array): string;
|
37 | export declare function octetsToBytes(numbers: number[]): Uint8Array;
|
38 | export declare function toBytes(data: Uint8Array | string): Uint8Array;
|
39 | export declare function concatBytes(...arrays: Uint8Array[]): Uint8Array;
|
40 | export declare function concatArray(elements: (Uint8Array | number[] | number)[]): Uint8Array;
|
41 | export declare function isInstance(object: any, type: any): boolean;
|
42 | export {};
|