-
Notifications
You must be signed in to change notification settings - Fork 905
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
NTP / FTX fix group #9074
NTP / FTX fix group #9074
Conversation
@petemill I filed one more issue about FTX widget - brave/brave-browser#16358 |
I think I won't solve that one, or will solve it later. I didn't feel we needed to save this as a preference yet:
|
I filed that issue after seeing binance widget saves it in prefs. |
@@ -295,6 +295,7 @@ class NewTabPage extends React.Component<Props, State> { | |||
} | |||
|
|||
toggleShowFTX = () => { | |||
this.props.actions.ftx.disconnect() |
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.
I should apply this also to cryptodotcom widget :)
…s (due to not opted-in yet)
1507781
to
652a92d
Compare
…of setting all individual widget prefs
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.
++
VLOG(1) << "Migrating hide widget pref..."; | ||
// If all the widgets are off, assume user wants no future widgets. | ||
bool all_were_off = true; | ||
for (auto* const pref_name : kWidgetPrefNames) { |
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.
nit: we can use std::all_of
here
const bool all_were_off = std::all_of(std::begin(kWidgetPrefNames), std::end(kWidgetPrefNames), [prefs](const char* const pref_names) {
...
});
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.
great tip, thanks!
Android CI fail known unrelated issue. |
Verification passed on
FTX.Zero.Balance.mov
FTX.Hide.widget.mov
NTP.Click.through.mov
Brave.News.mov |
Verification passed on
FTX.Zero.Balance.mov
FTX.Hide.widget.mov
NTP.Click.through.mov
Brave.News.mov |
Fixes for New Tab Page, especially the FTX widget:
Submitter Checklist:
QA/Yes
orQA/No
;release-notes/include
orrelease-notes/exclude
;OS/...
) to the associated issuenpm run test -- brave_browser_tests
,npm run test -- brave_unit_tests
,npm run lint
,npm run gn_check
,npm run tslint
git rebase master
(if needed)Reviewer Checklist:
gn
After-merge Checklist:
changes has landed on