Skip to content

Commit

Permalink
refactor: remove circular dependency from confirm-alert-model.tsx (#…
Browse files Browse the repository at this point in the history
…30453)

This PR solves an issue with circular dependencies. It does not change
the behavior of the application. It only rearranges functions/files to
avoid circular references.

<!--
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**


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

## **Related issues**

Fixes:

## **Manual testing steps**

1. Go to this page...
2.
3.

## **Screenshots/Recordings**


### **Before**


### **After**


## **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/main/.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/main/.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.
-->
  • Loading branch information
davidmurdoch authored Feb 20, 2025
1 parent e96b5db commit eaa9b51
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 8 deletions.
8 changes: 1 addition & 7 deletions development/circular-deps.jsonc
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,4 @@
// - To prevent new circular dependencies, ensure your changes don't add new cycles
// - For more information contact the Extension Platform team.

[
[
"ui/components/app/alert-system/confirm-alert-modal/confirm-alert-modal.tsx",
"ui/components/app/alert-system/confirm-alert-modal/index.tsx",
"ui/pages/confirmations/components/confirm/footer/footer.tsx"
]
]
[]
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ import { AlertModal } from '../alert-modal';
import { AcknowledgeCheckboxBase } from '../alert-modal/alert-modal';
import { MultipleAlertModal } from '../multiple-alert-modal';
import { MetaMetricsEventLocation } from '../../../../../shared/constants/metametrics';
import { OnCancelHandler } from '../../../../pages/confirmations/components/confirm/footer/footer';
import type { OnCancelHandler } from '../../../../pages/confirmations/components/confirm/footer/footer';

export type ConfirmAlertModalProps = {
/** Callback function that is called when the cancel button is clicked. */
Expand Down

0 comments on commit eaa9b51

Please sign in to comment.