Commit 7cbf8d00 authored by Thomas Tangl's avatar Thomas Tangl Committed by Commit Bot

[unified-consent] Add top-level master toggle to sync settings

The UI of the top-level master toggle is added to sync settings.

For now the toggle changes whether all data types of sync should
be turned on or only a custom selection (taken over from before).
This should be changed once the unified consent service is implemented.

Bug: 800974
Cq-Include-Trybots: master.tryserver.chromium.linux:closure_compilation
Change-Id: I7eea3059ab90a3e47d9d5306e4a6359efdba0cf5
Reviewed-on: https://chromium-review.googlesource.com/1023934
Commit-Queue: Thomas Tangl <tangltom@chromium.org>
Reviewed-by: default avatarScott Chen <scottchen@chromium.org>
Cr-Commit-Position: refs/heads/master@{#553525}
parent 75a33c8f
......@@ -3029,6 +3029,12 @@
<message name="IDS_SETTINGS_CHANGE_PICTURE_PROFILE_PHOTO" desc="The text on the Google profile photo of the user.">
Google Profile photo
</message>
<message name="IDS_SETTINGS_PEOPLE_SYNC_UNIFIED_CONSENT_TOGGLE_TITLE" desc="The title of the toggle to opt into unified consent and enable all its services.">
Sync and personalize Chrome across you devices
</message>
<message name="IDS_SETTINGS_PEOPLE_SYNC_UNIFIED_CONSENT_TOGGLE_SUBTITLE" desc="The subtitle of the toggle to opt into unified consent and enable all its services.">
Uses content on sites you visit and browser activity and interations.
</message>
<if expr="chromeos">
<message name="IDS_SETTINGS_PEOPLE_CONFIGURE_PIN_CHOOSE_PIN_TITLE" desc="Message shown below the title that tells the user to enter the initial PIN.">
......
......@@ -105,6 +105,21 @@
</settings-sync-account-control>
</template>
</if>
<div class="settings-box first two-line"
hidden="[[!unifiedConsentEnabled]]">
<div class="start">
<div>$i18n{syncUnifiedConsentToggleTitle}</div>
<div class="secondary">$i18n{syncUnifiedConsentToggleSubtitle}</div>
</div>
<!-- For now this toggle only turns on all sync services.
TODO(crbug.com/800974): Add custom function for turning
on all unified consent services.-->
<cr-toggle id="syncAllDataTypesControl"
checked="{{syncPrefs.syncAllDataTypes}}"
on-change="onSyncAllDataTypesChanged_"
aria-labelledby="syncUnifiedConsentToggleTitle">
</cr-toggle>
</div>
<div class="settings-box first two-line" id="sync-section-toggle"
actionable$="[[!syncSectionDisabled_]]"
on-click="toggleExpandButton_"
......
......@@ -1549,6 +1549,10 @@ void AddPeopleStrings(content::WebUIDataSource* html_source, Profile* profile) {
{"syncSignInPrompt", IDS_SETTINGS_SYNC_SIGN_IN_PROMPT},
{"syncSignInPromptSecondary", IDS_SETTINGS_SYNC_SIGN_IN_PROMPT_SECONDARY},
#endif
{"syncUnifiedConsentToggleTitle",
IDS_SETTINGS_PEOPLE_SYNC_UNIFIED_CONSENT_TOGGLE_TITLE},
{"syncUnifiedConsentToggleSubtitle",
IDS_SETTINGS_PEOPLE_SYNC_UNIFIED_CONSENT_TOGGLE_SUBTITLE},
{"syncOverview", IDS_SETTINGS_SYNC_OVERVIEW},
{"syncDisabledByAdministrator",
IDS_SETTINGS_SYNC_DISABLED_BY_ADMINISTRATOR},
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment