Skip to content

Commit 3bcd0f4

Browse files
authored
feat: promote readable permissions actions (#91)
* Promote EIP-7715 and EIP-7710 actions from experimental. They are now exported via @metamask/smart-accounts-kit/actions. * Update remaining documentation references to Delegation Toolkit. * Fix linting errors - import order
1 parent a4e8bba commit 3bcd0f4

16 files changed

Lines changed: 70 additions & 77 deletions

CONTRIBUTING.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,14 +47,14 @@ yarn e2etest
4747

4848
# Contributing
4949

50-
In order to make changes to the Delegation Toolkit, ensure that you:
50+
In order to make changes to the Smart Accounts Kit, ensure that you:
5151

5252
- Create a fork of the SDK, and name your branch in a descriptive way - ideally follow the [conventional commits](https://www.conventionalcommits.org) naming standard.
5353
- Create a pull request that describes the changes you are making and follow the [pull request guidelines](https://github.com/MetaMask/contributor-docs/blob/main/docs/pull-requests.md).
5454
- Thoroughly test your code, including unit tests, and (where apprioriate) end-to-end integration tests.
5555
- Follow [secure coding standards](https://github.com/MetaMask/contributor-docs/blob/main/docs/secure-coding-guidelines.md).
5656

57-
To learn more about contributing to the Delegation Toolkit, see the MetaMask [contributing guidelines](https://github.com/MetaMask/contributor-docs).
57+
To learn more about contributing to the Smart Accounts Kit, see the MetaMask [contributing guidelines](https://github.com/MetaMask/contributor-docs).
5858

5959
## Delegation Framework contracts
6060

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ This monorepo consists of a suite of tools to enable developers to build using t
88
- `/delegation-abis` has collection of ABIs corresponding to a specific version of the [Delegation Framework](https://github.com/metamask/delegation-framework).
99
- `/delegation-deployments` contains deployments for different versions of the [Delegation Framework](https://github.com/metamask/delegation-framework).
1010
- `/smart-accounts-kit` has utilities for creating a [DeleGator SCA](https://github.com/MetaMask/delegation-framework/blob/main/documents/DeleGatorCore.md#metamasks-delegatorcore) know as MetaMask smart account, setting up delegations, and redeeming them.
11-
- `/delegator-e2e` has end-to-end tests for the Delegation Toolkit.
11+
- `/delegator-e2e` has end-to-end tests for the Smart Accounts Kit.
1212
- `./shared` contains basic shared resources for configuring and testing the packages.
1313

1414
## Getting Started

packages/7715-permission-types/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ Package with types as defined in [ERC-7715](https://eip.tools/eip/7715). This pa
44

55
## Installation
66

7-
This package is normally installed as part of the Delegation Toolkit (@metamask/smart-accounts-kit) which is part of this monorepo.
7+
This package is normally installed as part of the Smart Accounts Kit (@metamask/smart-accounts-kit) which is part of this monorepo.
88

99
In order to install this package standalone:
1010

packages/delegation-abis/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ A collection of ABIs for the [Delegation Framework](https://github.com/metamask/
44

55
## Installation
66

7-
This package is normally installed as part of the Delegation Toolkit (@metamask/smart-accounts-kit) which is part of this monorepo.
7+
This package is normally installed as part of the Smart Accounts Kit (@metamask/smart-accounts-kit) which is part of this monorepo.
88

99
In order to install this package standalone:
1010

@@ -51,7 +51,7 @@ git pull
5151

5252
### 2. Generate the ABIs
5353

54-
The `generate.sh` script will build the contracts, outputting ABIs and generate typescript files containing the ABIs. The typescript files are how the ABIs are used within the toolkit.
54+
The `generate.sh` script will build the contracts, outputting ABIs and generate typescript files containing the ABIs. The typescript files are how the ABIs are used within the Smart Accounts Kit.
5555

5656
```bash
5757
./scripts/generate.sh

packages/delegation-deployments/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ A history of [Delegation Framework](https://github.com/metamask/delegation-frame
44

55
## Installation
66

7-
This package is normally installed as part of the Delegation Toolkit (@metamask/smart-accounts-kit) which is part of this monorepo.
7+
This package is normally installed as part of the Smart Accounts Kit (@metamask/smart-accounts-kit) which is part of this monorepo.
88

99
In order to install this package standalone:
1010

packages/delegator-e2e/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# DeleGator e2e
22

3-
End-to-end integration tests for the Delegation Toolkit. It uses local chain, bundler and paymaster made available via [Pimlico's local testing docker compose](https://docs.pimlico.io/permissionless/how-to/local-testing).
3+
End-to-end integration tests for the Smart Accounts Kit. It uses local chain, bundler and paymaster made available via [Pimlico's local testing docker compose](https://docs.pimlico.io/permissionless/how-to/local-testing).
44

55
## Requirements
66

packages/delegator-e2e/test/experimental/erc7710sendTransactionWithDelegation.test.ts renamed to packages/delegator-e2e/test/actions/erc7710sendTransactionWithDelegation.test.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,8 @@ import {
1717
type MetaMaskSmartAccount,
1818
type Delegation,
1919
} from '@metamask/smart-accounts-kit';
20-
import { erc7710WalletActions } from '@metamask/smart-accounts-kit/experimental';
20+
import { erc7710WalletActions } from '@metamask/smart-accounts-kit/actions';
2121
import { generatePrivateKey, privateKeyToAccount } from 'viem/accounts';
22-
import type { Hex } from 'viem';
2322
import {
2423
Address,
2524
createWalletClient,

packages/delegator-e2e/test/experimental/erc7710sendUserOperationWithDelegation.test.ts renamed to packages/delegator-e2e/test/actions/erc7710sendUserOperationWithDelegation.test.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,10 @@ import {
1818
createDelegation,
1919
type Delegation,
2020
} from '@metamask/smart-accounts-kit';
21-
import { erc7710BundlerActions } from '@metamask/smart-accounts-kit/experimental';
21+
import { erc7710BundlerActions } from '@metamask/smart-accounts-kit/actions';
2222
import { generatePrivateKey, privateKeyToAccount } from 'viem/accounts';
2323
import {
24-
createClient,
24+
createPublicClient,
2525
Address,
2626
getContract,
2727
Hex,
@@ -43,7 +43,7 @@ beforeEach(async () => {
4343
const alice = privateKeyToAccount(generatePrivateKey());
4444
const bob = privateKeyToAccount(generatePrivateKey());
4545

46-
const client = createClient({ transport, chain });
46+
const client = createPublicClient({ transport, chain });
4747

4848
aliceSmartAccount = await toMetaMaskSmartAccount({
4949
client,

packages/smart-accounts-kit/src/experimental/erc7710RedeemDelegationAction.ts renamed to packages/smart-accounts-kit/src/actions/erc7710RedeemDelegationAction.ts

File renamed without changes.

packages/smart-accounts-kit/src/experimental/erc7715RequestExecutionPermissionsAction.ts renamed to packages/smart-accounts-kit/src/actions/erc7715RequestExecutionPermissionsAction.ts

File renamed without changes.

0 commit comments

Comments
 (0)