Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Add firstTimeInteraction to transactionMeta #4895

Merged

Conversation

OGPoyraz
Copy link
Member

@OGPoyraz OGPoyraz commented Nov 5, 2024

Explanation

This PR adds firstTimeInteraction to transactionMeta by calling https://primitives.api.cx.metamask.io/ API
relationships endpoint.
For more information please see docs here: https://primitives.api.cx.metamask.io/docs#/Account%20%7C%20Relationships/IndexedChainDataAPIController_getAccountAddressRelationship

References

Related to: https://github.com/MetaMask/MetaMask-planning/issues/3040

Changelog

@metamask/transaction-controller

  • ADDED: Add firstTimeInteraction to transactionMeta
    • This field is getting filled by calling https://primitives.api.cx.metamask.io relationships endpoint.

Checklist

  • I've updated the test suite for new or updated code as appropriate
  • I've updated documentation (JSDoc, Markdown, etc.) for new or updated code as appropriate
  • I've highlighted breaking changes using the "BREAKING" category above as appropriate
  • I've prepared draft pull requests for clients and consumer packages to resolve any breaking changes

@OGPoyraz
Copy link
Member Author

OGPoyraz commented Nov 5, 2024

@metamaskbot publish-preview

Copy link
Contributor

github-actions bot commented Nov 5, 2024

Preview builds have been published. See these instructions for more information about preview builds.

Expand for full list of packages and versions.
{
  "@metamask-previews/accounts-controller": "18.2.3-preview-35c9c85",
  "@metamask-previews/address-book-controller": "6.0.1-preview-35c9c85",
  "@metamask-previews/announcement-controller": "7.0.1-preview-35c9c85",
  "@metamask-previews/approval-controller": "7.1.1-preview-35c9c85",
  "@metamask-previews/assets-controllers": "42.0.0-preview-35c9c85",
  "@metamask-previews/base-controller": "7.0.2-preview-35c9c85",
  "@metamask-previews/build-utils": "3.0.1-preview-35c9c85",
  "@metamask-previews/chain-controller": "0.1.3-preview-35c9c85",
  "@metamask-previews/composable-controller": "9.0.1-preview-35c9c85",
  "@metamask-previews/controller-utils": "11.4.2-preview-35c9c85",
  "@metamask-previews/ens-controller": "15.0.0-preview-35c9c85",
  "@metamask-previews/eth-json-rpc-provider": "4.1.6-preview-35c9c85",
  "@metamask-previews/gas-fee-controller": "22.0.0-preview-35c9c85",
  "@metamask-previews/json-rpc-engine": "10.0.1-preview-35c9c85",
  "@metamask-previews/json-rpc-middleware-stream": "8.0.5-preview-35c9c85",
  "@metamask-previews/keyring-controller": "17.3.1-preview-35c9c85",
  "@metamask-previews/logging-controller": "6.0.1-preview-35c9c85",
  "@metamask-previews/message-manager": "11.0.1-preview-35c9c85",
  "@metamask-previews/multichain": "0.0.0-preview-35c9c85",
  "@metamask-previews/name-controller": "8.0.1-preview-35c9c85",
  "@metamask-previews/network-controller": "22.0.1-preview-35c9c85",
  "@metamask-previews/notification-controller": "7.0.0-preview-35c9c85",
  "@metamask-previews/notification-services-controller": "0.12.1-preview-35c9c85",
  "@metamask-previews/permission-controller": "11.0.3-preview-35c9c85",
  "@metamask-previews/permission-log-controller": "3.0.1-preview-35c9c85",
  "@metamask-previews/phishing-controller": "12.3.0-preview-35c9c85",
  "@metamask-previews/polling-controller": "12.0.1-preview-35c9c85",
  "@metamask-previews/preferences-controller": "13.2.0-preview-35c9c85",
  "@metamask-previews/profile-sync-controller": "0.9.7-preview-35c9c85",
  "@metamask-previews/queued-request-controller": "7.0.0-preview-35c9c85",
  "@metamask-previews/rate-limit-controller": "6.0.1-preview-35c9c85",
  "@metamask-previews/selected-network-controller": "19.0.0-preview-35c9c85",
  "@metamask-previews/signature-controller": "21.0.0-preview-35c9c85",
  "@metamask-previews/transaction-controller": "38.2.0-preview-35c9c85",
  "@metamask-previews/user-operation-controller": "17.0.0-preview-35c9c85"
}

@OGPoyraz
Copy link
Member Author

@metamaskbot publish-preview

Copy link
Contributor

Preview builds have been published. See these instructions for more information about preview builds.

Expand for full list of packages and versions.
{
  "@metamask-previews/accounts-controller": "18.2.3-preview-3f52b814",
  "@metamask-previews/address-book-controller": "6.0.1-preview-3f52b814",
  "@metamask-previews/announcement-controller": "7.0.1-preview-3f52b814",
  "@metamask-previews/approval-controller": "7.1.1-preview-3f52b814",
  "@metamask-previews/assets-controllers": "42.0.0-preview-3f52b814",
  "@metamask-previews/base-controller": "7.0.2-preview-3f52b814",
  "@metamask-previews/build-utils": "3.0.1-preview-3f52b814",
  "@metamask-previews/chain-controller": "0.1.3-preview-3f52b814",
  "@metamask-previews/composable-controller": "9.0.1-preview-3f52b814",
  "@metamask-previews/controller-utils": "11.4.2-preview-3f52b814",
  "@metamask-previews/ens-controller": "15.0.0-preview-3f52b814",
  "@metamask-previews/eth-json-rpc-provider": "4.1.6-preview-3f52b814",
  "@metamask-previews/gas-fee-controller": "22.0.0-preview-3f52b814",
  "@metamask-previews/json-rpc-engine": "10.0.1-preview-3f52b814",
  "@metamask-previews/json-rpc-middleware-stream": "8.0.5-preview-3f52b814",
  "@metamask-previews/keyring-controller": "17.3.1-preview-3f52b814",
  "@metamask-previews/logging-controller": "6.0.1-preview-3f52b814",
  "@metamask-previews/message-manager": "11.0.1-preview-3f52b814",
  "@metamask-previews/multichain": "0.0.0-preview-3f52b814",
  "@metamask-previews/name-controller": "8.0.1-preview-3f52b814",
  "@metamask-previews/network-controller": "22.0.1-preview-3f52b814",
  "@metamask-previews/notification-controller": "7.0.0-preview-3f52b814",
  "@metamask-previews/notification-services-controller": "0.12.1-preview-3f52b814",
  "@metamask-previews/permission-controller": "11.0.3-preview-3f52b814",
  "@metamask-previews/permission-log-controller": "3.0.1-preview-3f52b814",
  "@metamask-previews/phishing-controller": "12.3.0-preview-3f52b814",
  "@metamask-previews/polling-controller": "12.0.1-preview-3f52b814",
  "@metamask-previews/preferences-controller": "13.2.0-preview-3f52b814",
  "@metamask-previews/profile-sync-controller": "0.9.7-preview-3f52b814",
  "@metamask-previews/queued-request-controller": "7.0.0-preview-3f52b814",
  "@metamask-previews/rate-limit-controller": "6.0.1-preview-3f52b814",
  "@metamask-previews/selected-network-controller": "19.0.0-preview-3f52b814",
  "@metamask-previews/signature-controller": "21.0.0-preview-3f52b814",
  "@metamask-previews/transaction-controller": "38.2.0-preview-3f52b814",
  "@metamask-previews/user-operation-controller": "17.0.0-preview-3f52b814"
}

@OGPoyraz
Copy link
Member Author

@metamaskbot publish-preview

Copy link
Contributor

Preview builds have been published. See these instructions for more information about preview builds.

Expand for full list of packages and versions.
{
  "@metamask-previews/accounts-controller": "19.0.0-preview-fefbd325",
  "@metamask-previews/address-book-controller": "6.0.1-preview-fefbd325",
  "@metamask-previews/announcement-controller": "7.0.1-preview-fefbd325",
  "@metamask-previews/approval-controller": "7.1.1-preview-fefbd325",
  "@metamask-previews/assets-controllers": "43.0.0-preview-fefbd325",
  "@metamask-previews/base-controller": "7.0.2-preview-fefbd325",
  "@metamask-previews/build-utils": "3.0.1-preview-fefbd325",
  "@metamask-previews/chain-controller": "0.1.3-preview-fefbd325",
  "@metamask-previews/composable-controller": "9.0.1-preview-fefbd325",
  "@metamask-previews/controller-utils": "11.4.3-preview-fefbd325",
  "@metamask-previews/ens-controller": "15.0.0-preview-fefbd325",
  "@metamask-previews/eth-json-rpc-provider": "4.1.6-preview-fefbd325",
  "@metamask-previews/gas-fee-controller": "22.0.1-preview-fefbd325",
  "@metamask-previews/json-rpc-engine": "10.0.1-preview-fefbd325",
  "@metamask-previews/json-rpc-middleware-stream": "8.0.5-preview-fefbd325",
  "@metamask-previews/keyring-controller": "18.0.0-preview-fefbd325",
  "@metamask-previews/logging-controller": "6.0.2-preview-fefbd325",
  "@metamask-previews/message-manager": "11.0.1-preview-fefbd325",
  "@metamask-previews/multichain": "0.0.0-preview-fefbd325",
  "@metamask-previews/name-controller": "8.0.1-preview-fefbd325",
  "@metamask-previews/network-controller": "22.0.2-preview-fefbd325",
  "@metamask-previews/notification-controller": "7.0.0-preview-fefbd325",
  "@metamask-previews/notification-services-controller": "0.13.0-preview-fefbd325",
  "@metamask-previews/permission-controller": "11.0.3-preview-fefbd325",
  "@metamask-previews/permission-log-controller": "3.0.1-preview-fefbd325",
  "@metamask-previews/phishing-controller": "12.3.0-preview-fefbd325",
  "@metamask-previews/polling-controller": "12.0.1-preview-fefbd325",
  "@metamask-previews/preferences-controller": "14.0.0-preview-fefbd325",
  "@metamask-previews/profile-sync-controller": "1.0.0-preview-fefbd325",
  "@metamask-previews/queued-request-controller": "7.0.1-preview-fefbd325",
  "@metamask-previews/rate-limit-controller": "6.0.1-preview-fefbd325",
  "@metamask-previews/selected-network-controller": "19.0.0-preview-fefbd325",
  "@metamask-previews/signature-controller": "22.0.0-preview-fefbd325",
  "@metamask-previews/transaction-controller": "39.0.0-preview-fefbd325",
  "@metamask-previews/user-operation-controller": "18.0.0-preview-fefbd325"
}

@OGPoyraz OGPoyraz marked this pull request as ready for review November 13, 2024 11:19
@OGPoyraz OGPoyraz requested a review from a team as a code owner November 13, 2024 11:19
@OGPoyraz OGPoyraz force-pushed the 3040-alert-for-when-interacting-with-an-address-for-the-first-time branch from fefbd32 to 1045211 Compare November 14, 2024 12:04
@OGPoyraz
Copy link
Member Author

@metamaskbot publish-preview

Copy link
Contributor

Preview builds have been published. See these instructions for more information about preview builds.

Expand for full list of packages and versions.
{
  "@metamask-previews/accounts-controller": "19.0.0-preview-af392506",
  "@metamask-previews/address-book-controller": "6.0.1-preview-af392506",
  "@metamask-previews/announcement-controller": "7.0.1-preview-af392506",
  "@metamask-previews/approval-controller": "7.1.1-preview-af392506",
  "@metamask-previews/assets-controllers": "44.0.0-preview-af392506",
  "@metamask-previews/base-controller": "7.0.2-preview-af392506",
  "@metamask-previews/build-utils": "3.0.1-preview-af392506",
  "@metamask-previews/chain-controller": "0.1.3-preview-af392506",
  "@metamask-previews/composable-controller": "9.0.1-preview-af392506",
  "@metamask-previews/controller-utils": "11.4.3-preview-af392506",
  "@metamask-previews/ens-controller": "15.0.0-preview-af392506",
  "@metamask-previews/eth-json-rpc-provider": "4.1.6-preview-af392506",
  "@metamask-previews/gas-fee-controller": "22.0.1-preview-af392506",
  "@metamask-previews/json-rpc-engine": "10.0.1-preview-af392506",
  "@metamask-previews/json-rpc-middleware-stream": "8.0.5-preview-af392506",
  "@metamask-previews/keyring-controller": "18.0.0-preview-af392506",
  "@metamask-previews/logging-controller": "6.0.2-preview-af392506",
  "@metamask-previews/message-manager": "11.0.1-preview-af392506",
  "@metamask-previews/multichain": "0.0.0-preview-af392506",
  "@metamask-previews/name-controller": "8.0.1-preview-af392506",
  "@metamask-previews/network-controller": "22.0.2-preview-af392506",
  "@metamask-previews/notification-controller": "7.0.0-preview-af392506",
  "@metamask-previews/notification-services-controller": "0.13.0-preview-af392506",
  "@metamask-previews/permission-controller": "11.0.3-preview-af392506",
  "@metamask-previews/permission-log-controller": "3.0.1-preview-af392506",
  "@metamask-previews/phishing-controller": "12.3.0-preview-af392506",
  "@metamask-previews/polling-controller": "12.0.1-preview-af392506",
  "@metamask-previews/preferences-controller": "14.0.0-preview-af392506",
  "@metamask-previews/profile-sync-controller": "1.0.1-preview-af392506",
  "@metamask-previews/queued-request-controller": "7.0.1-preview-af392506",
  "@metamask-previews/rate-limit-controller": "6.0.1-preview-af392506",
  "@metamask-previews/selected-network-controller": "19.0.0-preview-af392506",
  "@metamask-previews/signature-controller": "22.0.0-preview-af392506",
  "@metamask-previews/transaction-controller": "39.0.0-preview-af392506",
  "@metamask-previews/user-operation-controller": "18.0.0-preview-af392506"
}

@OGPoyraz
Copy link
Member Author

@metamaskbot publish-preview

Copy link
Contributor

Preview builds have been published. See these instructions for more information about preview builds.

Expand for full list of packages and versions.
{
  "@metamask-previews/accounts-controller": "19.0.0-preview-61d7fc25",
  "@metamask-previews/address-book-controller": "6.0.1-preview-61d7fc25",
  "@metamask-previews/announcement-controller": "7.0.1-preview-61d7fc25",
  "@metamask-previews/approval-controller": "7.1.1-preview-61d7fc25",
  "@metamask-previews/assets-controllers": "44.1.0-preview-61d7fc25",
  "@metamask-previews/base-controller": "7.0.2-preview-61d7fc25",
  "@metamask-previews/build-utils": "3.0.1-preview-61d7fc25",
  "@metamask-previews/chain-controller": "0.1.3-preview-61d7fc25",
  "@metamask-previews/composable-controller": "9.0.1-preview-61d7fc25",
  "@metamask-previews/controller-utils": "11.4.3-preview-61d7fc25",
  "@metamask-previews/ens-controller": "15.0.0-preview-61d7fc25",
  "@metamask-previews/eth-json-rpc-provider": "4.1.6-preview-61d7fc25",
  "@metamask-previews/gas-fee-controller": "22.0.1-preview-61d7fc25",
  "@metamask-previews/json-rpc-engine": "10.0.1-preview-61d7fc25",
  "@metamask-previews/json-rpc-middleware-stream": "8.0.5-preview-61d7fc25",
  "@metamask-previews/keyring-controller": "18.0.0-preview-61d7fc25",
  "@metamask-previews/logging-controller": "6.0.2-preview-61d7fc25",
  "@metamask-previews/message-manager": "11.0.1-preview-61d7fc25",
  "@metamask-previews/multichain": "0.0.0-preview-61d7fc25",
  "@metamask-previews/name-controller": "8.0.1-preview-61d7fc25",
  "@metamask-previews/network-controller": "22.0.2-preview-61d7fc25",
  "@metamask-previews/notification-controller": "7.0.0-preview-61d7fc25",
  "@metamask-previews/notification-services-controller": "0.13.0-preview-61d7fc25",
  "@metamask-previews/permission-controller": "11.0.3-preview-61d7fc25",
  "@metamask-previews/permission-log-controller": "3.0.1-preview-61d7fc25",
  "@metamask-previews/phishing-controller": "12.3.0-preview-61d7fc25",
  "@metamask-previews/polling-controller": "12.0.1-preview-61d7fc25",
  "@metamask-previews/preferences-controller": "14.0.0-preview-61d7fc25",
  "@metamask-previews/profile-sync-controller": "1.0.2-preview-61d7fc25",
  "@metamask-previews/queued-request-controller": "7.0.1-preview-61d7fc25",
  "@metamask-previews/rate-limit-controller": "6.0.1-preview-61d7fc25",
  "@metamask-previews/selected-network-controller": "19.0.0-preview-61d7fc25",
  "@metamask-previews/signature-controller": "22.0.0-preview-61d7fc25",
  "@metamask-previews/transaction-controller": "39.1.0-preview-61d7fc25",
  "@metamask-previews/user-operation-controller": "18.0.0-preview-61d7fc25"
}

@OGPoyraz
Copy link
Member Author

@metamaskbot publish-preview

Copy link
Contributor

Preview builds have been published. See these instructions for more information about preview builds.

Expand for full list of packages and versions.
{
  "@metamask-previews/accounts-controller": "19.0.0-preview-dc7114cb",
  "@metamask-previews/address-book-controller": "6.0.1-preview-dc7114cb",
  "@metamask-previews/announcement-controller": "7.0.1-preview-dc7114cb",
  "@metamask-previews/approval-controller": "7.1.1-preview-dc7114cb",
  "@metamask-previews/assets-controllers": "44.1.0-preview-dc7114cb",
  "@metamask-previews/base-controller": "7.0.2-preview-dc7114cb",
  "@metamask-previews/build-utils": "3.0.1-preview-dc7114cb",
  "@metamask-previews/chain-controller": "0.1.3-preview-dc7114cb",
  "@metamask-previews/composable-controller": "9.0.1-preview-dc7114cb",
  "@metamask-previews/controller-utils": "11.4.3-preview-dc7114cb",
  "@metamask-previews/ens-controller": "15.0.0-preview-dc7114cb",
  "@metamask-previews/eth-json-rpc-provider": "4.1.6-preview-dc7114cb",
  "@metamask-previews/gas-fee-controller": "22.0.1-preview-dc7114cb",
  "@metamask-previews/json-rpc-engine": "10.0.1-preview-dc7114cb",
  "@metamask-previews/json-rpc-middleware-stream": "8.0.5-preview-dc7114cb",
  "@metamask-previews/keyring-controller": "18.0.0-preview-dc7114cb",
  "@metamask-previews/logging-controller": "6.0.2-preview-dc7114cb",
  "@metamask-previews/message-manager": "11.0.1-preview-dc7114cb",
  "@metamask-previews/multichain": "0.0.0-preview-dc7114cb",
  "@metamask-previews/name-controller": "8.0.1-preview-dc7114cb",
  "@metamask-previews/network-controller": "22.0.2-preview-dc7114cb",
  "@metamask-previews/notification-controller": "7.0.0-preview-dc7114cb",
  "@metamask-previews/notification-services-controller": "0.13.0-preview-dc7114cb",
  "@metamask-previews/permission-controller": "11.0.3-preview-dc7114cb",
  "@metamask-previews/permission-log-controller": "3.0.1-preview-dc7114cb",
  "@metamask-previews/phishing-controller": "12.3.0-preview-dc7114cb",
  "@metamask-previews/polling-controller": "12.0.1-preview-dc7114cb",
  "@metamask-previews/preferences-controller": "14.0.0-preview-dc7114cb",
  "@metamask-previews/profile-sync-controller": "1.0.2-preview-dc7114cb",
  "@metamask-previews/queued-request-controller": "7.0.1-preview-dc7114cb",
  "@metamask-previews/rate-limit-controller": "6.0.1-preview-dc7114cb",
  "@metamask-previews/selected-network-controller": "19.0.0-preview-dc7114cb",
  "@metamask-previews/signature-controller": "22.0.0-preview-dc7114cb",
  "@metamask-previews/transaction-controller": "39.1.0-preview-dc7114cb",
  "@metamask-previews/user-operation-controller": "18.0.0-preview-dc7114cb"
}

@OGPoyraz
Copy link
Member Author

@metamaskbot publish-preview

Copy link
Contributor

Preview builds have been published. See these instructions for more information about preview builds.

Expand for full list of packages and versions.
{
  "@metamask-previews/accounts-controller": "19.0.0-preview-608079df",
  "@metamask-previews/address-book-controller": "6.0.1-preview-608079df",
  "@metamask-previews/announcement-controller": "7.0.1-preview-608079df",
  "@metamask-previews/approval-controller": "7.1.1-preview-608079df",
  "@metamask-previews/assets-controllers": "44.1.0-preview-608079df",
  "@metamask-previews/base-controller": "7.0.2-preview-608079df",
  "@metamask-previews/build-utils": "3.0.1-preview-608079df",
  "@metamask-previews/chain-controller": "0.1.3-preview-608079df",
  "@metamask-previews/composable-controller": "9.0.1-preview-608079df",
  "@metamask-previews/controller-utils": "11.4.3-preview-608079df",
  "@metamask-previews/ens-controller": "15.0.0-preview-608079df",
  "@metamask-previews/eth-json-rpc-provider": "4.1.6-preview-608079df",
  "@metamask-previews/gas-fee-controller": "22.0.1-preview-608079df",
  "@metamask-previews/json-rpc-engine": "10.0.1-preview-608079df",
  "@metamask-previews/json-rpc-middleware-stream": "8.0.5-preview-608079df",
  "@metamask-previews/keyring-controller": "18.0.0-preview-608079df",
  "@metamask-previews/logging-controller": "6.0.2-preview-608079df",
  "@metamask-previews/message-manager": "11.0.1-preview-608079df",
  "@metamask-previews/multichain": "0.0.0-preview-608079df",
  "@metamask-previews/name-controller": "8.0.1-preview-608079df",
  "@metamask-previews/network-controller": "22.0.2-preview-608079df",
  "@metamask-previews/notification-controller": "7.0.0-preview-608079df",
  "@metamask-previews/notification-services-controller": "0.13.0-preview-608079df",
  "@metamask-previews/permission-controller": "11.0.3-preview-608079df",
  "@metamask-previews/permission-log-controller": "3.0.1-preview-608079df",
  "@metamask-previews/phishing-controller": "12.3.0-preview-608079df",
  "@metamask-previews/polling-controller": "12.0.1-preview-608079df",
  "@metamask-previews/preferences-controller": "14.0.0-preview-608079df",
  "@metamask-previews/profile-sync-controller": "1.0.2-preview-608079df",
  "@metamask-previews/queued-request-controller": "7.0.1-preview-608079df",
  "@metamask-previews/rate-limit-controller": "6.0.1-preview-608079df",
  "@metamask-previews/selected-network-controller": "19.0.0-preview-608079df",
  "@metamask-previews/signature-controller": "22.0.0-preview-608079df",
  "@metamask-previews/transaction-controller": "39.1.0-preview-608079df",
  "@metamask-previews/user-operation-controller": "18.0.0-preview-608079df"
}

@OGPoyraz OGPoyraz enabled auto-merge (squash) November 25, 2024 11:42
@OGPoyraz OGPoyraz merged commit 0d4c785 into main Nov 25, 2024
120 checks passed
@OGPoyraz OGPoyraz deleted the 3040-alert-for-when-interacting-with-an-address-for-the-first-time branch November 25, 2024 11:43
@OGPoyraz OGPoyraz mentioned this pull request Nov 25, 2024
OGPoyraz added a commit that referenced this pull request Nov 25, 2024
## Changes

## `transaction-controller`

### Added

- Add `firstTimeInteraction` to transaction meta
([#4895](#4895))
- This is a boolean value that indicates whether the transaction is the
first time the user has interacted with it.
Prithpal-Sooriya pushed a commit that referenced this pull request Nov 25, 2024
## Changes

## `transaction-controller`

### Added

- Add `firstTimeInteraction` to transaction meta
([#4895](#4895))
- This is a boolean value that indicates whether the transaction is the
first time the user has interacted with it.
github-merge-queue bot pushed a commit to MetaMask/metamask-extension that referenced this pull request Nov 26, 2024
<!--
Please submit this PR as a draft initially.
Do not mark it as "Ready for review" until the template has been
completely filled out, and PR status checks have passed at least once.
-->

## **Description**

<!--
Write a short description of the changes included in this pull request,
also include relevant motivation and context. Have in mind the following
questions:
1. What is the reason for the change?
2. What is the improvement/solution?
-->

This PR implements first time interaction feature where it shows an
alert if you interact with the address for the first time.
Information of the first time interaction is fetched in the transaction
controller when the transaction is added to the state.

Core PR: MetaMask/core#4895

[![Open in GitHub
Codespaces](https://github.com/codespaces/badge.svg)](https://codespaces.new/MetaMask/metamask-extension/pull/28435?quickstart=1)

## **Related issues**

Fixes: MetaMask/MetaMask-planning#3040

## **Manual testing steps**

1. Go to test dapp
2. Use send legacy transaction - make sure you interact here with your
account for the first time
3. See warning

## **Screenshots/Recordings**

<!-- If applicable, add screenshots and/or recordings to visualize the
before and after of your change. -->

### **Before**

<!-- [screenshots/recordings] -->

### **After**

![Screenshot 2024-11-13 at 11 51
14](https://github.com/user-attachments/assets/6cc1f481-788c-4945-b190-1448c5a03141)

![Screenshot 2024-11-13 at 11 51
19](https://github.com/user-attachments/assets/98413caa-ef43-4877-a37d-ea0a6da1397f)


## **Pre-merge author checklist**

- [ ] I've followed [MetaMask Contributor
Docs](https://github.com/MetaMask/contributor-docs) and [MetaMask
Extension Coding
Standards](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/CODING_GUIDELINES.md).
- [ ] I've completed the PR template to the best of my ability
- [ ] I’ve included tests if applicable
- [ ] I’ve documented my code using [JSDoc](https://jsdoc.app/) format
if applicable
- [ ] I’ve applied the right labels on the PR (see [labeling
guidelines](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/LABELING_GUIDELINES.md)).
Not required for external contributors.

## **Pre-merge reviewer checklist**

- [ ] I've manually tested the PR (e.g. pull and build branch, run the
app, test code being changed).
- [ ] I confirm that this PR addresses all acceptance criteria described
in the ticket it closes and includes the necessary testing evidence such
as recordings and or screenshots.
github-merge-queue bot pushed a commit to MetaMask/metamask-extension that referenced this pull request Nov 26, 2024
<!--
Please submit this PR as a draft initially.
Do not mark it as "Ready for review" until the template has been
completely filled out, and PR status checks have passed at least once.
-->

## **Description**

<!--
Write a short description of the changes included in this pull request,
also include relevant motivation and context. Have in mind the following
questions:
1. What is the reason for the change?
2. What is the improvement/solution?
-->

This PR implements first time interaction feature where it shows an
alert if you interact with the address for the first time.
Information of the first time interaction is fetched in the transaction
controller when the transaction is added to the state.

Core PR: MetaMask/core#4895

[![Open in GitHub
Codespaces](https://github.com/codespaces/badge.svg)](https://codespaces.new/MetaMask/metamask-extension/pull/28435?quickstart=1)

## **Related issues**

Fixes: MetaMask/MetaMask-planning#3040

## **Manual testing steps**

1. Go to test dapp
2. Use send legacy transaction - make sure you interact here with your
account for the first time
3. See warning

## **Screenshots/Recordings**

<!-- If applicable, add screenshots and/or recordings to visualize the
before and after of your change. -->

### **Before**

<!-- [screenshots/recordings] -->

### **After**

![Screenshot 2024-11-13 at 11 51
14](https://github.com/user-attachments/assets/6cc1f481-788c-4945-b190-1448c5a03141)

![Screenshot 2024-11-13 at 11 51
19](https://github.com/user-attachments/assets/98413caa-ef43-4877-a37d-ea0a6da1397f)


## **Pre-merge author checklist**

- [ ] I've followed [MetaMask Contributor
Docs](https://github.com/MetaMask/contributor-docs) and [MetaMask
Extension Coding
Standards](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/CODING_GUIDELINES.md).
- [ ] I've completed the PR template to the best of my ability
- [ ] I’ve included tests if applicable
- [ ] I’ve documented my code using [JSDoc](https://jsdoc.app/) format
if applicable
- [ ] I’ve applied the right labels on the PR (see [labeling
guidelines](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/LABELING_GUIDELINES.md)).
Not required for external contributors.

## **Pre-merge reviewer checklist**

- [ ] I've manually tested the PR (e.g. pull and build branch, run the
app, test code being changed).
- [ ] I confirm that this PR addresses all acceptance criteria described
in the ticket it closes and includes the necessary testing evidence such
as recordings and or screenshots.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants