-
Notifications
You must be signed in to change notification settings - Fork 5k
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: Move ENABLE_CONFIRMATION_REDESIGN feature flag to the developer settings page #25520
Conversation
CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes. |
@@ -91,6 +96,13 @@ const DeveloperOptionsTab = () => { | |||
setIsServiceWorkerKeptAlive(value); | |||
}; | |||
|
|||
const handleToggleEnableConfirmationsRedesign = async ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
perhaps setConfirmationsRedesignEnabled
as we're setting instead of toggling?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we toggle on the UI, happy to rename if necessary
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is totally optional but the reason I think set
is a better fit here is that toggle
functions are usually associated with flipping the value independently of what it is at the moment.
for example
const toggleEnableConfirmationsRedesign = async (): Promise<void> => {
const previousValue = useSelector(isRedesignedConfirmationsFeatureEnabled);
await dispatch(setRedesignedConfirmationsDeveloperEnabled(!previousValue));
await setIsRedesignedConfirmationsFeatureEnabled(!previousValue);
}
However, in this case the function is receiving an explicit value as an argument, so it seems to be a set
function.
In other words, there is indeed a feature toggle, but the function is not toggling, it's setting.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
Builds ready [5736f66]
Page Load Metrics (46 ± 9 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
Builds ready [5736f66]
Page Load Metrics (46 ± 9 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## develop #25520 +/- ##
========================================
Coverage 69.67% 69.67%
========================================
Files 1401 1402 +1
Lines 49628 49652 +24
Branches 13713 13720 +7
========================================
+ Hits 34577 34594 +17
- Misses 15051 15058 +7 ☔ View full report in Codecov by Sentry. |
Builds ready [f32ec89]
Page Load Metrics (324 ± 293 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
Builds ready [ad9e3c2]
Page Load Metrics (172 ± 202 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
test/e2e/tests/confirmations/transactions/contract-interaction-redesign.spec.ts
Show resolved
Hide resolved
Builds ready [cd543bb]
Page Load Metrics (240 ± 236 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
"developerOptionsEnableConfirmationsRedesignDescription": { | ||
"message": "Enables or disables the confirmations redesign feature currently in development" | ||
}, | ||
"developerOptionsEnableConfirmationsRedesignTitle": { | ||
"message": "Confirmations Redesign" | ||
}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we can actually remove the locales here. Or I can follow-up to remove them to not block this PR.
It was discussed that we do not need to support i18n in the Developer Options Settings since this is internal
ticket to remove translations:
#24412
da6a204
Quality Gate passedIssues Measures |
Builds ready [50b45b5]
Page Load Metrics (135 ± 151 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
Description
Related issues
Fixes: #2620
Manual testing steps
Screenshots/Recordings
Before
After
Pre-merge author checklist
Pre-merge reviewer checklist