stxer 0.8.0 → 0.9.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/CHANGELOG.md +23 -0
- package/README.md +3 -3
- package/dist/ast.d.ts +1 -1
- package/dist/stxer.cjs.development.js +3 -1
- package/dist/stxer.cjs.development.js.map +1 -1
- package/dist/stxer.cjs.production.min.js +1 -1
- package/dist/stxer.cjs.production.min.js.map +1 -1
- package/dist/stxer.esm.js +3 -1
- package/dist/stxer.esm.js.map +1 -1
- package/dist/types.d.ts +3 -3
- package/package.json +23 -22
- package/src/ast.ts +1 -1
- package/src/simulation.ts +3 -1
- package/src/types.ts +5 -3
package/dist/types.d.ts
CHANGED
|
@@ -108,13 +108,13 @@ export interface ClarityAbiNonFungibleToken {
|
|
|
108
108
|
name: string;
|
|
109
109
|
type: ClarityAbiType;
|
|
110
110
|
}
|
|
111
|
-
export type ClarityEpoch = 'Epoch10' | 'Epoch20' | 'Epoch2_05' | 'Epoch21' | 'Epoch22' | 'Epoch23' | 'Epoch24' | 'Epoch25' | 'Epoch30' | 'Epoch31' | 'Epoch32' | 'Epoch33' | 'Epoch34' | 'Epoch35';
|
|
111
|
+
export type ClarityEpoch = 'Epoch10' | 'Epoch20' | 'Epoch2_05' | 'Epoch21' | 'Epoch22' | 'Epoch23' | 'Epoch24' | 'Epoch25' | 'Epoch30' | 'Epoch31' | 'Epoch32' | 'Epoch33' | 'Epoch34' | 'Epoch35' | 'Epoch40';
|
|
112
112
|
/**
|
|
113
113
|
* Wire-format Clarity version name as emitted by the stxer AST parser
|
|
114
114
|
* (`/contracts:parse-ast`). Used in {@link ClarityAbi.clarity_version}.
|
|
115
115
|
*
|
|
116
116
|
* **Distinct from the numeric `ClarityVersion` enum re-exported by
|
|
117
|
-
* `@stacks/transactions`** (1..
|
|
117
|
+
* `@stacks/transactions`** (1..6), which is what the SDK builder
|
|
118
118
|
* methods (`addContractDeploy`, `makeUnsignedContractDeploy`, etc.)
|
|
119
119
|
* accept. To build transactions:
|
|
120
120
|
*
|
|
@@ -126,7 +126,7 @@ export type ClarityEpoch = 'Epoch10' | 'Epoch20' | 'Epoch2_05' | 'Epoch21' | 'Ep
|
|
|
126
126
|
* import type { ClarityVersionName } from 'stxer';
|
|
127
127
|
* if (abi.clarity_version === 'Clarity5') { ... }
|
|
128
128
|
*/
|
|
129
|
-
export type ClarityVersionName = 'Clarity1' | 'Clarity2' | 'Clarity3' | 'Clarity4' | 'Clarity5';
|
|
129
|
+
export type ClarityVersionName = 'Clarity1' | 'Clarity2' | 'Clarity3' | 'Clarity4' | 'Clarity5' | 'Clarity6';
|
|
130
130
|
/** @deprecated Renamed to {@link ClarityVersionName} in 0.8.0 to avoid collision with `@stacks/transactions`'s numeric `ClarityVersion` enum. Re-exported for back-compat — will be removed in a future major. */
|
|
131
131
|
export type ClarityVersion = ClarityVersionName;
|
|
132
132
|
export interface ClarityAbi {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "stxer",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.9.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"author": "Kyle Fang",
|
|
6
6
|
"repository": {
|
|
@@ -17,6 +17,22 @@
|
|
|
17
17
|
"!dist/sample",
|
|
18
18
|
"CHANGELOG.md"
|
|
19
19
|
],
|
|
20
|
+
"scripts": {
|
|
21
|
+
"analyze": "size-limit --why",
|
|
22
|
+
"build": "dts build",
|
|
23
|
+
"lint": "biome check .",
|
|
24
|
+
"prepare": "dts build",
|
|
25
|
+
"size": "size-limit",
|
|
26
|
+
"start": "dts watch",
|
|
27
|
+
"test": "dts test",
|
|
28
|
+
"sample:counter": "tsx src/sample/counter.ts",
|
|
29
|
+
"sample:read": "tsx src/sample/read.ts",
|
|
30
|
+
"sample:instant": "tsx src/sample/instant.ts",
|
|
31
|
+
"sample:failure-modes": "tsx src/sample/failure-modes.ts",
|
|
32
|
+
"sample:batch-categories": "tsx src/sample/batch-categories.ts",
|
|
33
|
+
"sample:verify-types": "tsx src/sample/verify-types.ts",
|
|
34
|
+
"sample:vitest": "vitest run"
|
|
35
|
+
},
|
|
20
36
|
"husky": {
|
|
21
37
|
"hooks": {
|
|
22
38
|
"pre-commit": "dts lint && biome check ."
|
|
@@ -45,39 +61,24 @@
|
|
|
45
61
|
}
|
|
46
62
|
],
|
|
47
63
|
"devDependencies": {
|
|
48
|
-
"@biomejs/biome": "2.
|
|
64
|
+
"@biomejs/biome": "2.5.5",
|
|
49
65
|
"@size-limit/preset-small-lib": "12.1.0",
|
|
50
66
|
"@tsconfig/recommended": "^1.0.13",
|
|
51
67
|
"@types/node": "25.6.0",
|
|
52
68
|
"dts-cli": "^2.0.5",
|
|
53
69
|
"husky": "^9.1.7",
|
|
54
70
|
"size-limit": "12.1.0",
|
|
55
|
-
"tsx": "^4.
|
|
71
|
+
"tsx": "^4.23.1",
|
|
56
72
|
"typescript": "5.9.3",
|
|
57
|
-
"vitest": "^4.1.
|
|
73
|
+
"vitest": "^4.1.10"
|
|
58
74
|
},
|
|
59
75
|
"dependencies": {
|
|
60
76
|
"@noble/hashes": "^2.2.0",
|
|
61
|
-
"@stacks/network": "^7.
|
|
77
|
+
"@stacks/network": "^7.5.0",
|
|
62
78
|
"@stacks/stacks-blockchain-api-types": "^7.14.1",
|
|
63
|
-
"@stacks/transactions": "7.
|
|
79
|
+
"@stacks/transactions": "7.5.0",
|
|
64
80
|
"c32check": "^2.0.0",
|
|
65
81
|
"clarity-abi": "^0.1.0",
|
|
66
82
|
"ts-clarity": "^0.1.1"
|
|
67
|
-
},
|
|
68
|
-
"scripts": {
|
|
69
|
-
"analyze": "size-limit --why",
|
|
70
|
-
"build": "dts build",
|
|
71
|
-
"lint": "biome check .",
|
|
72
|
-
"size": "size-limit",
|
|
73
|
-
"start": "dts watch",
|
|
74
|
-
"test": "dts test",
|
|
75
|
-
"sample:counter": "tsx src/sample/counter.ts",
|
|
76
|
-
"sample:read": "tsx src/sample/read.ts",
|
|
77
|
-
"sample:instant": "tsx src/sample/instant.ts",
|
|
78
|
-
"sample:failure-modes": "tsx src/sample/failure-modes.ts",
|
|
79
|
-
"sample:batch-categories": "tsx src/sample/batch-categories.ts",
|
|
80
|
-
"sample:verify-types": "tsx src/sample/verify-types.ts",
|
|
81
|
-
"sample:vitest": "vitest run"
|
|
82
83
|
}
|
|
83
|
-
}
|
|
84
|
+
}
|
package/src/ast.ts
CHANGED
|
@@ -50,7 +50,7 @@ export async function getContractAST(
|
|
|
50
50
|
export interface ParseContractOptions extends AstOptions {
|
|
51
51
|
sourceCode: string;
|
|
52
52
|
contractId: string;
|
|
53
|
-
clarityVersion?: '1' | '2' | '3' | '4' | '5';
|
|
53
|
+
clarityVersion?: '1' | '2' | '3' | '4' | '5' | '6';
|
|
54
54
|
epoch?: ClarityEpoch;
|
|
55
55
|
}
|
|
56
56
|
|
package/src/simulation.ts
CHANGED
package/src/types.ts
CHANGED
|
@@ -124,14 +124,15 @@ export type ClarityEpoch =
|
|
|
124
124
|
| 'Epoch32'
|
|
125
125
|
| 'Epoch33'
|
|
126
126
|
| 'Epoch34'
|
|
127
|
-
| 'Epoch35'
|
|
127
|
+
| 'Epoch35'
|
|
128
|
+
| 'Epoch40';
|
|
128
129
|
|
|
129
130
|
/**
|
|
130
131
|
* Wire-format Clarity version name as emitted by the stxer AST parser
|
|
131
132
|
* (`/contracts:parse-ast`). Used in {@link ClarityAbi.clarity_version}.
|
|
132
133
|
*
|
|
133
134
|
* **Distinct from the numeric `ClarityVersion` enum re-exported by
|
|
134
|
-
* `@stacks/transactions`** (1..
|
|
135
|
+
* `@stacks/transactions`** (1..6), which is what the SDK builder
|
|
135
136
|
* methods (`addContractDeploy`, `makeUnsignedContractDeploy`, etc.)
|
|
136
137
|
* accept. To build transactions:
|
|
137
138
|
*
|
|
@@ -148,7 +149,8 @@ export type ClarityVersionName =
|
|
|
148
149
|
| 'Clarity2'
|
|
149
150
|
| 'Clarity3'
|
|
150
151
|
| 'Clarity4'
|
|
151
|
-
| 'Clarity5'
|
|
152
|
+
| 'Clarity5'
|
|
153
|
+
| 'Clarity6';
|
|
152
154
|
|
|
153
155
|
/** @deprecated Renamed to {@link ClarityVersionName} in 0.8.0 to avoid collision with `@stacks/transactions`'s numeric `ClarityVersion` enum. Re-exported for back-compat — will be removed in a future major. */
|
|
154
156
|
export type ClarityVersion = ClarityVersionName;
|