Commit b10575a
authored
chore(predict): Removes mandatory terms of services modal (#22454)
<!--
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**
- Removes the mandatory terms of service modal
<!--
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?
-->
## **Changelog**
<!--
If this PR is not End-User-Facing and should not show up in the
CHANGELOG, you can choose to either:
1. Write `CHANGELOG entry: null`
2. Label with `no-changelog`
If this PR is End-User-Facing, please write a short User-Facing
description in the past tense like:
`CHANGELOG entry: Added a new tab for users to see their NFTs`
`CHANGELOG entry: Fixed a bug that was causing some NFTs to flicker`
(This helps the Release Engineer do their job more quickly and
accurately)
-->
CHANGELOG entry: null
## **Related issues**
Fixes:
[PRED-297](https://consensyssoftware.atlassian.net/browse/PRED-297)
## **Manual testing steps**
```gherkin
Feature: my feature name
Scenario: user [verb for user action]
Given [describe expected initial app state]
When user [verb for user action]
Then [describe expected outcome]
```
## **Screenshots/Recordings**
<!-- If applicable, add screenshots and/or recordings to visualize the
before and after of your change. -->
### **Before**
<!-- [screenshots/recordings] -->
### **After**
<!-- [screenshots/recordings] -->
## **Pre-merge author checklist**
- [x] I’ve followed [MetaMask Contributor
Docs](https://github.com/MetaMask/contributor-docs) and [MetaMask Mobile
Coding
Standards](https://github.com/MetaMask/metamask-mobile/blob/main/.github/guidelines/CODING_GUIDELINES.md).
- [x] I've completed the PR template to the best of my ability
- [x] I’ve included tests if applicable
- [x] I’ve documented my code using [JSDoc](https://jsdoc.app/) format
if applicable
- [x] I’ve applied the right labels on the PR (see [labeling
guidelines](https://github.com/MetaMask/metamask-mobile/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.
[PRED-297]:
https://consensyssoftware.atlassian.net/browse/PRED-297?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ
<!-- CURSOR_SUMMARY -->
---
> [!NOTE]
> Removes the Predict ToS consent modal and agreement tracking,
simplifying buy/sell flows and pruning related controller APIs, types,
selectors, and tests.
>
> - **UI (Predict)**:
> - Remove `PredictConsentSheet` component and all references from
`PredictBuyPreview` and `PredictSellPreview`; orders now proceed
directly.
> - Keep inline disclaimer with "Learn more" link; no modal gating.
> - **Controller**:
> - Delete `acceptAgreement` API from `PredictController` and all
usages.
> - **Hooks**:
> - Remove `usePredictAgreement` hook and its tests.
> - **Types/Selectors**:
> - Simplify `PredictAccountMeta` to `{ isOnboarded: boolean }`; drop
`acceptedToS` and `AcceptAgreementParams`.
> - Update selectors/tests to reflect removal of `acceptedToS`.
> - **Tests**:
> - Remove consent-related tests and mocks across buy/sell previews and
consent sheet; adjust flows to assert direct order placement.
>
> <sup>Written by [Cursor
Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit
8c727d0. This will update automatically
on new commits. Configure
[here](https://cursor.com/dashboard?tab=bugbot).</sup>
<!-- /CURSOR_SUMMARY -->1 parent 440bb05 commit b10575a
File tree
13 files changed
+11
-1831
lines changed- app/components/UI/Predict
- components/PredictConsentSheet
- controllers
- hooks
- selectors/predictController
- types
- views
- PredictBuyPreview
- PredictSellPreview
13 files changed
+11
-1831
lines changedLines changed: 0 additions & 631 deletions
This file was deleted.
Lines changed: 0 additions & 116 deletions
This file was deleted.
Lines changed: 0 additions & 2 deletions
This file was deleted.
Lines changed: 0 additions & 239 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1568 | 1568 | | |
1569 | 1569 | | |
1570 | 1570 | | |
1571 | | - | |
1572 | 1571 | | |
1573 | 1572 | | |
1574 | 1573 | | |
| |||
4632 | 4631 | | |
4633 | 4632 | | |
4634 | 4633 | | |
4635 | | - | |
4636 | | - | |
4637 | | - | |
4638 | | - | |
4639 | | - | |
4640 | | - | |
4641 | | - | |
4642 | | - | |
4643 | | - | |
4644 | | - | |
4645 | | - | |
4646 | | - | |
4647 | | - | |
4648 | | - | |
4649 | | - | |
4650 | | - | |
4651 | | - | |
4652 | | - | |
4653 | | - | |
4654 | | - | |
4655 | | - | |
4656 | | - | |
4657 | | - | |
4658 | | - | |
4659 | | - | |
4660 | | - | |
4661 | | - | |
4662 | | - | |
4663 | | - | |
4664 | | - | |
4665 | | - | |
4666 | | - | |
4667 | | - | |
4668 | | - | |
4669 | | - | |
4670 | | - | |
4671 | | - | |
4672 | | - | |
4673 | | - | |
4674 | | - | |
4675 | | - | |
4676 | | - | |
4677 | | - | |
4678 | | - | |
4679 | | - | |
4680 | | - | |
4681 | | - | |
4682 | | - | |
4683 | | - | |
4684 | | - | |
4685 | | - | |
4686 | | - | |
4687 | | - | |
4688 | | - | |
4689 | | - | |
4690 | | - | |
4691 | | - | |
4692 | | - | |
4693 | | - | |
4694 | | - | |
4695 | | - | |
4696 | | - | |
4697 | | - | |
4698 | | - | |
4699 | | - | |
4700 | | - | |
4701 | | - | |
4702 | | - | |
4703 | | - | |
4704 | | - | |
4705 | | - | |
4706 | | - | |
4707 | | - | |
4708 | | - | |
4709 | | - | |
4710 | | - | |
4711 | | - | |
4712 | | - | |
4713 | | - | |
4714 | | - | |
4715 | | - | |
4716 | | - | |
4717 | | - | |
4718 | | - | |
4719 | | - | |
4720 | | - | |
4721 | | - | |
4722 | | - | |
4723 | | - | |
4724 | | - | |
4725 | | - | |
4726 | | - | |
4727 | | - | |
4728 | | - | |
4729 | | - | |
4730 | | - | |
4731 | | - | |
4732 | | - | |
4733 | | - | |
4734 | | - | |
4735 | | - | |
4736 | | - | |
4737 | | - | |
4738 | | - | |
4739 | | - | |
4740 | | - | |
4741 | | - | |
4742 | | - | |
4743 | | - | |
4744 | | - | |
4745 | | - | |
4746 | | - | |
4747 | | - | |
4748 | | - | |
4749 | | - | |
4750 | | - | |
4751 | | - | |
4752 | | - | |
4753 | | - | |
4754 | | - | |
4755 | | - | |
4756 | | - | |
4757 | | - | |
4758 | | - | |
4759 | | - | |
4760 | | - | |
4761 | | - | |
4762 | | - | |
4763 | | - | |
4764 | | - | |
4765 | | - | |
4766 | | - | |
4767 | | - | |
4768 | | - | |
4769 | | - | |
4770 | | - | |
4771 | | - | |
4772 | | - | |
4773 | | - | |
4774 | | - | |
4775 | | - | |
4776 | | - | |
4777 | | - | |
4778 | | - | |
4779 | | - | |
4780 | | - | |
4781 | | - | |
4782 | | - | |
4783 | | - | |
4784 | | - | |
4785 | | - | |
4786 | | - | |
4787 | | - | |
4788 | | - | |
4789 | | - | |
4790 | | - | |
4791 | | - | |
4792 | | - | |
4793 | | - | |
4794 | | - | |
4795 | | - | |
4796 | | - | |
4797 | | - | |
4798 | | - | |
4799 | | - | |
4800 | | - | |
4801 | | - | |
4802 | | - | |
4803 | | - | |
4804 | | - | |
4805 | | - | |
4806 | | - | |
4807 | | - | |
4808 | | - | |
4809 | | - | |
4810 | | - | |
4811 | | - | |
4812 | | - | |
4813 | | - | |
4814 | | - | |
4815 | | - | |
4816 | | - | |
4817 | | - | |
4818 | | - | |
4819 | | - | |
4820 | | - | |
4821 | | - | |
4822 | | - | |
4823 | | - | |
4824 | | - | |
4825 | | - | |
4826 | | - | |
4827 | | - | |
4828 | | - | |
4829 | | - | |
4830 | | - | |
4831 | | - | |
4832 | | - | |
4833 | | - | |
4834 | | - | |
4835 | | - | |
4836 | | - | |
4837 | | - | |
4838 | | - | |
4839 | | - | |
4840 | | - | |
4841 | | - | |
4842 | | - | |
4843 | | - | |
4844 | | - | |
4845 | | - | |
4846 | | - | |
4847 | | - | |
4848 | | - | |
4849 | | - | |
4850 | | - | |
4851 | | - | |
4852 | | - | |
4853 | | - | |
4854 | | - | |
4855 | | - | |
4856 | | - | |
4857 | | - | |
4858 | | - | |
4859 | | - | |
4860 | | - | |
4861 | | - | |
4862 | | - | |
4863 | | - | |
4864 | | - | |
4865 | | - | |
4866 | | - | |
4867 | | - | |
4868 | | - | |
4869 | | - | |
4870 | | - | |
4871 | | - | |
4872 | | - | |
4873 | 4634 | | |
0 commit comments