@proton/wrap-constants 0.2.193 → 0.3.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/index.cjs +2421 -0
- package/dist/index.d.cts +2604 -0
- package/dist/index.d.mts +2076 -12743
- package/dist/index.mjs +2232 -2758
- package/package.json +29 -15
- package/src/coins.ts +1 -1
- package/src/parsers/actions.ts +88 -65
- package/src/parsers/address.ts +22 -22
- package/src/parsers/auth.ts +2 -2
- package/src/parsers/deposit.ts +4 -10
- package/src/parsers/dex.ts +49 -33
- package/src/parsers/login.ts +7 -8
- package/src/parsers/pool.ts +1 -1
- package/src/parsers/withdraw.ts +31 -31
- package/src/parsers/wrap.ts +31 -31
- package/dist/index.d.ts +0 -13271
- package/dist/index.js +0 -2957
package/src/parsers/wrap.ts
CHANGED
|
@@ -1,41 +1,41 @@
|
|
|
1
|
-
import * as z from
|
|
2
|
-
import { ExtendedAssetParser } from
|
|
1
|
+
import * as z from "zod";
|
|
2
|
+
import { ExtendedAssetParser } from "./base";
|
|
3
3
|
|
|
4
4
|
export enum Status {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
5
|
+
PENDING = "pending",
|
|
6
|
+
SUCCESS = "success",
|
|
7
|
+
FAIL = "fail",
|
|
8
|
+
PROCESSING = "processing",
|
|
9
9
|
}
|
|
10
10
|
|
|
11
11
|
export const wrapStartParser = z.object({
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
})
|
|
12
|
+
balance: ExtendedAssetParser,
|
|
13
|
+
id: z.string(),
|
|
14
|
+
txid: z.string(),
|
|
15
|
+
chain: z.string(),
|
|
16
|
+
deposit_address: z.string(),
|
|
17
|
+
confirmations: z.number(),
|
|
18
|
+
});
|
|
19
19
|
|
|
20
|
-
export type WrapStart = z.infer<typeof wrapStartParser
|
|
20
|
+
export type WrapStart = z.infer<typeof wrapStartParser>;
|
|
21
21
|
|
|
22
22
|
export const wrapSetConfParser = z.object({
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
})
|
|
26
|
-
export type WrapSetConf = z.infer<typeof wrapSetConfParser
|
|
23
|
+
wrap_hash: z.string(),
|
|
24
|
+
confirmations: z.number(),
|
|
25
|
+
});
|
|
26
|
+
export type WrapSetConf = z.infer<typeof wrapSetConfParser>;
|
|
27
27
|
|
|
28
28
|
export const wrapParser = z.object({
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
})
|
|
41
|
-
export type Wrap = z.infer<typeof wrapParser
|
|
29
|
+
index: z.number(),
|
|
30
|
+
proton_account: z.string(),
|
|
31
|
+
balance: ExtendedAssetParser,
|
|
32
|
+
id: z.string(),
|
|
33
|
+
txid: z.string(),
|
|
34
|
+
chain: z.string(),
|
|
35
|
+
deposit_address: z.string(),
|
|
36
|
+
status: z.enum(Status),
|
|
37
|
+
finish_txid: z.string(),
|
|
38
|
+
wrap_hash: z.string(),
|
|
39
|
+
confirmations: z.number(),
|
|
40
|
+
});
|
|
41
|
+
export type Wrap = z.infer<typeof wrapParser>;
|