-
Notifications
You must be signed in to change notification settings - Fork 904
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Settings UI] Settings toggle requires a pref.
Without a pref the settings toggle shows an error on console that the pref is not valid. Just as upstream does, for example, in personalization_options with metrics reporting toggle, we can fake the pref object. Chromium changes: https://source.chromium.org/chromium/chromium/src/+/a6bb7ccff5ac9a8b1970fda06ce49547c0f41608 commit a6bb7ccff5ac9a8b1970fda06ce49547c0f41608 Author: dpapad <[email protected]> Date: Wed Sep 29 01:18:15 2021 +0000 [Reland] Settings: Convert legacy Behaviors in controls/ folder to Mixins. Original CL was reverted due to a failure in a test that only runs on official builds, which is now addressed. Specifically converting: - CrPolicyPrefBehavior - PrefControlBehavior - SettingsBooleanControlBehavior This is in preparation of further migrating these to TypeScript. Bug: 1234307 https://source.chromium.org/chromium/chromium/src/+/a26b552a4aa82c86ed482269d2a0bb823978f442 commit a26b552a4aa82c86ed482269d2a0bb823978f442 Author: Xiaohui Chen <[email protected]> Date: Mon Feb 7 21:01:05 2022 +0000 settings: add additional validation to pref_control_mixin It seems possible that developer put wrong pref value in html. Add additional validation to catch bad 'string' values. Bug: 1189444
- Loading branch information
Showing
4 changed files
with
93 additions
and
39 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters