@solana/transactions 2.0.0-experimental.2bae733 → 2.0.0-experimental.2f6fdd4

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.
Files changed (52) hide show
  1. package/dist/index.browser.cjs +204 -68
  2. package/dist/index.browser.cjs.map +1 -1
  3. package/dist/index.browser.js +196 -67
  4. package/dist/index.browser.js.map +1 -1
  5. package/dist/index.development.js +264 -125
  6. package/dist/index.development.js.map +1 -1
  7. package/dist/index.native.js +196 -65
  8. package/dist/index.native.js.map +1 -1
  9. package/dist/index.node.cjs +206 -68
  10. package/dist/index.node.cjs.map +1 -1
  11. package/dist/index.node.js +196 -65
  12. package/dist/index.node.js.map +1 -1
  13. package/dist/index.production.min.js +11 -6
  14. package/dist/types/accounts.d.ts +1 -1
  15. package/dist/types/accounts.d.ts.map +1 -0
  16. package/dist/types/blockhash.d.ts +9 -1
  17. package/dist/types/blockhash.d.ts.map +1 -0
  18. package/dist/types/compile-address-table-lookups.d.ts +1 -1
  19. package/dist/types/compile-address-table-lookups.d.ts.map +1 -0
  20. package/dist/types/compile-header.d.ts.map +1 -0
  21. package/dist/types/compile-instructions.d.ts +1 -1
  22. package/dist/types/compile-instructions.d.ts.map +1 -0
  23. package/dist/types/compile-lifetime-token.d.ts.map +1 -0
  24. package/dist/types/compile-static-accounts.d.ts +1 -1
  25. package/dist/types/compile-static-accounts.d.ts.map +1 -0
  26. package/dist/types/compile-transaction.d.ts +11 -0
  27. package/dist/types/compile-transaction.d.ts.map +1 -0
  28. package/dist/types/create-transaction.d.ts.map +1 -0
  29. package/dist/types/durable-nonce.d.ts +18 -6
  30. package/dist/types/durable-nonce.d.ts.map +1 -0
  31. package/dist/types/fee-payer.d.ts +1 -1
  32. package/dist/types/fee-payer.d.ts.map +1 -0
  33. package/dist/types/index.d.ts +1 -0
  34. package/dist/types/index.d.ts.map +1 -0
  35. package/dist/types/instructions.d.ts.map +1 -0
  36. package/dist/types/message.d.ts.map +1 -0
  37. package/dist/types/serializers/address-table-lookup.d.ts.map +1 -0
  38. package/dist/types/serializers/header.d.ts.map +1 -0
  39. package/dist/types/serializers/instruction.d.ts.map +1 -0
  40. package/dist/types/serializers/message.d.ts.map +1 -0
  41. package/dist/types/serializers/transaction-version.d.ts.map +1 -0
  42. package/dist/types/serializers/transaction.d.ts +6 -0
  43. package/dist/types/serializers/transaction.d.ts.map +1 -0
  44. package/dist/types/serializers/unimplemented.d.ts.map +1 -0
  45. package/dist/types/signatures.d.ts +3 -4
  46. package/dist/types/signatures.d.ts.map +1 -0
  47. package/dist/types/types.d.ts.map +1 -0
  48. package/dist/types/unsigned-transaction.d.ts +4 -0
  49. package/dist/types/unsigned-transaction.d.ts.map +1 -0
  50. package/dist/types/wire-transaction.d.ts +6 -0
  51. package/dist/types/wire-transaction.d.ts.map +1 -0
  52. package/package.json +12 -16
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC;AAC5B,cAAc,sBAAsB,CAAC;AACrC,cAAc,iBAAiB,CAAC;AAChC,cAAc,aAAa,CAAC;AAC5B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,cAAc,CAAC;AAC7B,cAAc,SAAS,CAAC;AACxB,cAAc,oBAAoB,CAAC"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"instructions.d.ts","sourceRoot":"","sources":["../../src/instructions.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,0BAA0B,EAAE,MAAM,cAAc,CAAC;AAC1D,OAAO,EAAE,eAAe,EAAE,MAAM,SAAS,CAAC;AAG1C,wBAAgB,4BAA4B,CAAC,YAAY,SAAS,eAAe,EAC7E,WAAW,EAAE,YAAY,CAAC,cAAc,CAAC,CAAC,MAAM,CAAC,EACjD,WAAW,EAAE,YAAY,GAAG,CAAC,YAAY,GAAG,0BAA0B,CAAC,GACxE,YAAY,GAAG,IAAI,CAAC,YAAY,EAA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G,qBAAqB,GAAG,wBAAwB,CAAC;AAE/E,KAAK,qBAAqB,GAAG,mBAAmB,GAC5C,QAAQ,CAAC;IACL,OAAO,EAAE,QAAQ,CAAC;CACrB,CAAC,CAAC;AAEP,KAAK,wBAAwB,GAAG,mBAAmB,GAC/C,QAAQ,CAAC;IACL,mBAAmB,CAAC,EAAE,UAAU,CAAC,OAAO,8BAA8B,CAAC,CAAC;IACxE,OAAO,EAAE,MAAM,CAAC;CACnB,CAAC,CAAC;AAEP,wBAAgB,cAAc,CAC1B,WAAW,EAAE,qBAAqB,GAAG,QAAQ,CAAC;IAAE,OAAO,EAAE,QAAQ,CAAA;CAAE,CAAC,GACrE,qBAAqB,CAAC;AACzB,wBAAgB,cAAc,CAAC,WAAW,EAAE,qBAAqB,GAAG,wBAAwB,CAAC"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"address-table-lookup.d.ts","sourceRoot":"","sources":["../../../src/serializers/address-table-lookup.ts"],"names":[],"mappings":"AAAA,OAAO,EAAS,UAAU,EAAiD,MAAM,sCAAsC,CAAC;AAGxH,OAAO,EAAE,8BAA8B,EAAE,MAAM,kCAAkC,CAAC;AAElF,KAAK,kBAAkB,GAAG,UAAU,CAAC,OAAO,8BAA8B,CAAC,CAAC,MAAM,CAAC,CAAC;AAEpF,wBAAgB,0BAA0B,IAAI,UAAU,CAAC,kBAAkB,CAAC,CAkD3E"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"header.d.ts","sourceRoot":"","sources":["../../../src/serializers/header.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAc,MAAM,sCAAsC,CAAC;AAE9E,OAAO,EAAE,wBAAwB,EAAE,MAAM,mBAAmB,CAAC;AAE7D,KAAK,aAAa,GAAG,UAAU,CAAC,OAAO,wBAAwB,CAAC,CAAC;AAEjE,wBAAgB,qBAAqB,IAAI,UAAU,CAAC,aAAa,CAAC,CA4CjE"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"instruction.d.ts","sourceRoot":"","sources":["../../../src/serializers/instruction.ts"],"names":[],"mappings":"AAAA,OAAO,EAA+B,UAAU,EAAwB,MAAM,sCAAsC,CAAC;AAErH,OAAO,EAAE,uBAAuB,EAAE,MAAM,yBAAyB,CAAC;AAElE,KAAK,WAAW,GAAG,UAAU,CAAC,OAAO,uBAAuB,CAAC,CAAC,MAAM,CAAC,CAAC;AAEtE,wBAAgB,mBAAmB,IAAI,UAAU,CAAC,WAAW,CAAC,CAgE7D"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"message.d.ts","sourceRoot":"","sources":["../../../src/serializers/message.ts"],"names":[],"mappings":"AAAA,OAAO,EAIH,UAAU,EAKb,MAAM,sCAAsC,CAAC;AAG9C,OAAO,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AA6F7C,wBAAgB,yBAAyB,IAAI,UAAU,CAAC,eAAe,CAAC,CAMvE;AAED,wBAAgB,yBAAyB,IAAI,UAAU,CAAC,eAAe,CAAC,CAMvE;AAED,wBAAgB,uBAAuB,IAAI,UAAU,CAAC,eAAe,CAAC,CAMrE"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"transaction-version.d.ts","sourceRoot":"","sources":["../../../src/serializers/transaction-version.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,sCAAsC,CAAC;AAElE,OAAO,EAAE,kBAAkB,EAAE,MAAM,UAAU,CAAC;AAiC9C,wBAAgB,4BAA4B,IAAI,UAAU,CAAC,kBAAkB,CAAC,CAM7E;AAED,wBAAgB,4BAA4B,IAAI,UAAU,CAAC,kBAAkB,CAAC,CAM7E;AAED,wBAAgB,0BAA0B,IAAI,UAAU,CAAC,kBAAkB,CAAC,CAM3E"}
@@ -0,0 +1,6 @@
1
+ import { Serializer } from '@metaplex-foundation/umi-serializers';
2
+ import { getCompiledTransaction } from '../compile-transaction';
3
+ type SerializableTransaction = Parameters<typeof getCompiledTransaction>[0];
4
+ export declare function getTransactionEncoder(): Serializer<SerializableTransaction>;
5
+ export {};
6
+ //# sourceMappingURL=transaction.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"transaction.d.ts","sourceRoot":"","sources":["../../../src/serializers/transaction.ts"],"names":[],"mappings":"AAAA,OAAO,EAAgB,UAAU,EAAoB,MAAM,sCAAsC,CAAC;AAElG,OAAO,EAAE,sBAAsB,EAAE,MAAM,wBAAwB,CAAC;AAUhE,KAAK,uBAAuB,GAAG,UAAU,CAAC,OAAO,sBAAsB,CAAC,CAAC,CAAC,CAAC,CAAC;AAgB5E,wBAAgB,qBAAqB,IAAI,UAAU,CAAC,uBAAuB,CAAC,CAM3E"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"unimplemented.d.ts","sourceRoot":"","sources":["../../../src/serializers/unimplemented.ts"],"names":[],"mappings":"AAOA,wBAAgB,uBAAuB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,KAAK,CAIjE;AAED,wBAAgB,uBAAuB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,KAAK,CAIjE"}
@@ -1,12 +1,11 @@
1
- import { Base58EncodedAddress, Ed25519Signature } from '@solana/keys';
1
+ import { Base58EncodedAddress } from '@solana/addresses';
2
+ import { Ed25519Signature } from '@solana/keys';
2
3
  import { compileMessage } from './message';
3
4
  export interface IFullySignedTransaction extends ITransactionWithSignatures {
4
5
  readonly __fullySignedTransaction: unique symbol;
5
6
  }
6
7
  export interface ITransactionWithSignatures {
7
- readonly signatures: {
8
- readonly [publicKey: Base58EncodedAddress]: Ed25519Signature;
9
- };
8
+ readonly signatures: Readonly<Record<Base58EncodedAddress, Ed25519Signature>>;
10
9
  }
11
10
  export declare function signTransaction<TTransaction extends Parameters<typeof compileMessage>[0]>(keyPair: CryptoKeyPair, transaction: TTransaction | (TTransaction & ITransactionWithSignatures)): Promise<TTransaction & ITransactionWithSignatures>;
12
11
  //# sourceMappingURL=signatures.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"signatures.d.ts","sourceRoot":"","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eAAe,GAChC,QAAQ,CAAC;IACL,YAAY,EAAE,SAAS,YAAY,EAAE,CAAC;IACtC,OAAO,EAAE,CAAC,CAAC;CACd,CAAC,CAAC;AAEP,MAAM,MAAM,WAAW,GAAG,iBAAiB,GAAG,aAAa,CAAC;AAC5D,MAAM,MAAM,kBAAkB,GAAG,QAAQ,GAAG,CAAC,CAAC"}
@@ -0,0 +1,4 @@
1
+ import { ITransactionWithSignatures } from '.';
2
+ import { BaseTransaction } from './types';
3
+ export declare function getUnsignedTransaction<TTransaction extends BaseTransaction>(transaction: TTransaction | (TTransaction & ITransactionWithSignatures)): TTransaction | Omit<TTransaction & ITransactionWithSignatures, keyof ITransactionWithSignatures>;
4
+ //# sourceMappingURL=unsigned-transaction.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"unsigned-transaction.d.ts","sourceRoot":"","sources":["../../src/unsigned-transaction.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,0BAA0B,EAAE,MAAM,GAAG,CAAC;AAC/C,OAAO,EAAE,eAAe,EAAE,MAAM,SAAS,CAAC;AAE1C,wBAAgB,sBAAsB,CAAC,YAAY,SAAS,eAAe,EACvE,WAAW,EAAE,YAAY,GAAG,CAAC,YAAY,GAAG,0BAA0B,CAAC,GACxE,YAAY,GAAG,IAAI,CAAC,YAAY,GAAG,0BAA0B,EAAE,MAAM,0BAA0B,CAAC,CAWlG"}
@@ -0,0 +1,6 @@
1
+ import { getTransactionEncoder } from './serializers/transaction';
2
+ export type Base64EncodedWireTransaction = string & {
3
+ readonly __base64EncodedWireTransaction: unique symbol;
4
+ };
5
+ export declare function getBase64EncodedWireTransaction(transaction: Parameters<ReturnType<typeof getTransactionEncoder>['serialize']>[0]): Base64EncodedWireTransaction;
6
+ //# sourceMappingURL=wire-transaction.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"wire-transaction.d.ts","sourceRoot":"","sources":["../../src/wire-transaction.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,qBAAqB,EAAE,MAAM,2BAA2B,CAAC;AAElE,MAAM,MAAM,4BAA4B,GAAG,MAAM,GAAG;IAChD,QAAQ,CAAC,8BAA8B,EAAE,OAAO,MAAM,CAAC;CAC1D,CAAC;AAEF,wBAAgB,+BAA+B,CAC3C,WAAW,EAAE,UAAU,CAAC,UAAU,CAAC,OAAO,qBAAqB,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC,GAClF,4BAA4B,CAO9B"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@solana/transactions",
3
- "version": "2.0.0-experimental.2bae733",
3
+ "version": "2.0.0-experimental.2f6fdd4",
4
4
  "description": "Helpers for creating and serializing transactions",
5
5
  "exports": {
6
6
  "browser": {
@@ -46,31 +46,27 @@
46
46
  "maintained node versions"
47
47
  ],
48
48
  "dependencies": {
49
- "@metaplex-foundation/umi-serializers": "^0.8.2",
50
- "@solana/keys": "2.0.0-experimental.2bae733"
49
+ "@metaplex-foundation/umi-serializers": "^0.8.5",
50
+ "@solana/addresses": "2.0.0-experimental.2f6fdd4",
51
+ "@solana/keys": "2.0.0-experimental.2f6fdd4"
51
52
  },
52
53
  "devDependencies": {
53
54
  "@solana/eslint-config-solana": "^1.0.2",
54
- "@swc/core": "^1.3.18",
55
- "@swc/jest": "^0.2.23",
56
- "@types/jest": "^29.5.2",
57
- "@typescript-eslint/eslint-plugin": "^6.0.0",
58
- "@typescript-eslint/parser": "^6.0.0",
55
+ "@swc/jest": "^0.2.28",
56
+ "@types/jest": "^29.5.3",
57
+ "@typescript-eslint/eslint-plugin": "^6.3.0",
58
+ "@typescript-eslint/parser": "^6.3.0",
59
59
  "agadoo": "^3.0.0",
60
60
  "eslint": "^8.45.0",
61
61
  "eslint-plugin-sort-keys-fix": "^1.1.2",
62
62
  "jest": "^29.6.1",
63
- "jest-runner-eslint": "^2.0.0",
63
+ "jest-runner-eslint": "^2.1.0",
64
64
  "jest-runner-prettier": "^1.0.0",
65
- "postcss": "^8.4.12",
66
- "prettier": "^2.7.1",
67
- "ts-node": "^10.9.1",
68
- "tsup": "6.7.0",
65
+ "prettier": "^2.8",
66
+ "tsup": "7.2.0",
69
67
  "typescript": "^5.1.6",
70
68
  "version-from-git": "^1.1.1",
71
- "@solana/instructions": "2.0.0-experimental.2bae733",
72
- "@solana/keys": "2.0.0-experimental.2bae733",
73
- "@solana/rpc-core": "2.0.0-experimental.2bae733",
69
+ "@solana/instructions": "2.0.0-experimental.2f6fdd4",
74
70
  "build-scripts": "0.0.0",
75
71
  "test-config": "0.0.0",
76
72
  "test-matchers": "0.0.0",