From c1b9f8b7b301d71bedcf07607306c72757fcf4e4 Mon Sep 17 00:00:00 2001 From: "Rob Moore (MakerX)" Date: Wed, 4 Sep 2024 18:41:55 +0800 Subject: [PATCH] PR review --- docs/capabilities/app.md | 6 +++--- docs/code/classes/types_composer.default.md | 2 +- docs/code/modules/index.md | 2 +- src/app-deploy.ts | 3 --- src/app.ts | 2 +- src/types/composer.ts | 2 +- 6 files changed, 7 insertions(+), 10 deletions(-) diff --git a/docs/capabilities/app.md b/docs/capabilities/app.md index d74fa549..5f4d714c 100644 --- a/docs/capabilities/app.md +++ b/docs/capabilities/app.md @@ -38,7 +38,7 @@ When [sending transactions directly via AlgorandClient](./algorand-client.md#sen - `decodeError: Error` - If there was a decoding error the above 2 values will be `undefined` and this will have the error - Update and create calls extend [`SendAppUpdateTransactionResult`](../code/modules/types_transaction.md#sendappupdatetransactionresult), which has: - `compiledApproval: CompiledTeal | undefined` - The compilation result of approval, if approval program was supplied as a string and thus compiled by algod - - `compiledClear: CompiledTeal | undefined` - The compilation result of approval, if clear state program was supplied as a string and thus compiled by algod + - `compiledClear: CompiledTeal | undefined` - The compilation result of clear state, if clear state program was supplied as a string and thus compiled by algod - Create calls extend [`SendAppCreateTransactionResult`](../code/modules/types_transaction.md#sendappcreatetransactionresult), which has: - `appId: bigint` - The id of the created app - `appAddress: string` - The Algorand address of the account associated with the app @@ -304,7 +304,7 @@ await algorand.send.appCallMethodCall({ ### Global state -To access and parse global state you can use the following staticc method from [`AppManager`](#appmanager): +To access and parse global state you can use the following static method from [`AppManager`](#appmanager): - [`AppManager.decodeAppState(state)`](../code/classes/types_app_manager.AppManager.md#decodeappstate) - Takes the raw response from the algod API for global state and returns a friendly generic object keyed by the UTF-8 value of the key @@ -349,7 +349,7 @@ To access and parse box values and names for an app you can use the following me - [`appManager.getBoxValues(appId: bigint, boxNames: BoxIdentifier[])`](../code/modules/index.md#getboxvalues) - Returns the binary values of the given box names for the given app ID - [`appManager.getBoxValueFromABIType(request: {appId: bigint, boxName: BoxIdentifier, type: algosdk.ABIType}})`](../code/modules/index.md#getboxvaluefromabitype) - Returns the parsed ABI value of the given box name for the given app ID for the provided ABI type - [`appManager.getBoxValuesFromABIType(request: {appId: bigint, boxNames: BoxIdentifier[], type: algosdk.ABIType})`](../code/modules/index.md#getboxvaluesfromabitype) - Returns the parsed ABI values of the given box names for the given app ID for the provided ABI type -- [`AppManager.getBoxReference(boxId)`](../code/modules/index.md#getboxreference) - Returns an `algosdk.BoxReference` representation of the given [box identifier / reference](#box-references), which is useful when constructing a raw `algosdk.Transaction` +- [`AppManager.getBoxReference(boxId)`](../code/modules/index.md#getboxreference) - Returns a `algosdk.BoxReference` representation of the given [box identifier / reference](#box-references), which is useful when constructing a raw `algosdk.Transaction` ```typescript const appId = 12345n diff --git a/docs/code/classes/types_composer.default.md b/docs/code/classes/types_composer.default.md index 8ded6f16..55712539 100644 --- a/docs/code/classes/types_composer.default.md +++ b/docs/code/classes/types_composer.default.md @@ -929,7 +929,7 @@ Builds an ABI method call transaction and any other associated transactions repr | :------ | :------ | :------ | | `params` | [`AppCreateMethodCall`](../modules/types_composer.md#appcreatemethodcall) \| [`AppUpdateMethodCall`](../modules/types_composer.md#appupdatemethodcall) \| [`AppCallMethodCall`](../modules/types_composer.md#appcallmethodcall) | - | | `suggestedParams` | `SuggestedParams` | - | -| `includeSigner` | `boolean` | Whether to include the actual signer for the transactions. If you are just building transactions without signers yet then set this to `true`. | +| `includeSigner` | `boolean` | Whether to include the actual signer for the transactions. If you are just building transactions without signers yet then set this to `false`. | #### Returns diff --git a/docs/code/modules/index.md b/docs/code/modules/index.md index ece1d48e..7bc0d708 100644 --- a/docs/code/modules/index.md +++ b/docs/code/modules/index.md @@ -1754,7 +1754,7 @@ The `algosdk.OnApplicationComplete` Use `algosdk.OnApplicationComplete` directly instead. -Returns an `algosdk.OnApplicationComplete` for the given onCompleteAction. +Returns a `algosdk.OnApplicationComplete` for the given onCompleteAction. If given `undefined` will return `OnApplicationComplete.NoOpOC`. diff --git a/src/app-deploy.ts b/src/app-deploy.ts index decec1d6..07e830d6 100644 --- a/src/app-deploy.ts +++ b/src/app-deploy.ts @@ -27,11 +27,8 @@ import AlgoKitComposer, { } from './types/composer' import { Arc2TransactionNote, ConfirmedTransactionResult, ConfirmedTransactionResults, SendTransactionFrom } from './types/transaction' import Algodv2 = algosdk.Algodv2 -import AtomicTransactionComposer = algosdk.AtomicTransactionComposer -import getApplicationAddress = algosdk.getApplicationAddress import Indexer = algosdk.Indexer import modelsv2 = algosdk.modelsv2 -import TransactionType = algosdk.TransactionType /** * @deprecated Use `algorand.appDeployer.deploy` instead. diff --git a/src/app.ts b/src/app.ts index db844db7..b1557906 100644 --- a/src/app.ts +++ b/src/app.ts @@ -140,7 +140,7 @@ export async function updateApp( /** * @deprecated Use `algosdk.OnApplicationComplete` directly instead. * - * Returns an `algosdk.OnApplicationComplete` for the given onCompleteAction. + * Returns a `algosdk.OnApplicationComplete` for the given onCompleteAction. * * If given `undefined` will return `OnApplicationComplete.NoOpOC`. * diff --git a/src/types/composer.ts b/src/types/composer.ts index 5460304b..e2cd2c4c 100644 --- a/src/types/composer.ts +++ b/src/types/composer.ts @@ -777,7 +777,7 @@ export default class AlgoKitComposer { /** * Builds an ABI method call transaction and any other associated transactions represented in the ABI args. * @param includeSigner Whether to include the actual signer for the transactions. - * If you are just building transactions without signers yet then set this to `true`. + * If you are just building transactions without signers yet then set this to `false`. */ private async buildMethodCall( params: AppCallMethodCall | AppCreateMethodCall | AppUpdateMethodCall,