Skip to content

Commit

Permalink
feat: bump codegen and add util to encode subaccount creation msg
Browse files Browse the repository at this point in the history
  • Loading branch information
dalechyn committed Feb 21, 2024
1 parent 4a57bed commit 61866cd
Show file tree
Hide file tree
Showing 6 changed files with 29 additions and 8 deletions.
6 changes: 6 additions & 0 deletions .changeset/few-peas-invite.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"@abstract-money/cli": patch
"@abstract-money/core": patch
---

Bump contract versions and add encoding create sub account msg util.
2 changes: 1 addition & 1 deletion packages/cli/src/plugins/react.ts
Original file line number Diff line number Diff line change
Expand Up @@ -254,7 +254,7 @@ export function react(options: ReactOptions = {}): ReactResult {

if (hasAbstractApp)
content.push(
`const ${constantCase(contract.name)}_MODULE_ID = '${
`export const ${constantCase(contract.name)}_MODULE_ID = '${
contract.namespace
}:${contract.name}'`,
)
Expand Down
14 changes: 7 additions & 7 deletions packages/core/abstract.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,31 +4,31 @@ import { registry, vanilla } from '@abstract-money/cli/plugins'
const contractsConfig = [
{
name: 'manager',
version: '0.20.0',
version: '0.21.0',
},
{
name: 'proxy',
version: '0.20.0',
version: '0.21.0',
},
{
name: 'module-factory',
version: '0.20.0',
version: '0.21.0',
},
{
name: 'version-control',
version: '0.20.0',
version: '0.21.0',
},
{
name: 'ans-host',
version: '0.20.0',
version: '0.21.0',
},
{
name: 'account-factory',
version: '0.20.0',
version: '0.21.0',
},
{
name: 'ibc-client',
version: '0.20.0',
version: '0.21.0',
},
]

Expand Down
1 change: 1 addition & 0 deletions packages/core/src/utils/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,4 @@ export * from './errors'
export * from './events'
export * from './helpers'
export * from './authz'
export * from './manager'
13 changes: 13 additions & 0 deletions packages/core/src/utils/manager/encode-create-sub-account-msg.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
import { ManagerMsgComposer } from 'src/codegen/abstract'

export function encodeCreateSubAccountMsg({
sender,
managerAddress,
...rest
}: Parameters<typeof ManagerMsgComposer.prototype.createSubAccount>[0] & {
sender: string
managerAddress: string
}) {
const composer = new ManagerMsgComposer(sender, managerAddress)
return composer.createSubAccount(rest)
}
1 change: 1 addition & 0 deletions packages/core/src/utils/manager/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export * from './encode-create-sub-account-msg'

0 comments on commit 61866cd

Please sign in to comment.