Commit 43d09d7e authored by dschuyler's avatar dschuyler Committed by Commit bot

[MD settings] add sub-label to Show Home Button check box

BUG=589630

Review URL: https://codereview.chromium.org/1798133002

Cr-Commit-Position: refs/heads/master@{#381754}
parent ac97d6e1
......@@ -49,6 +49,7 @@
</div>
<div class="settings-box two-line">
<settings-checkbox class="start" i18n-values="label:showHomeButton"
sub-label="[[getShowHomeSubLabel_(prefs.homepage_is_newtabpage.value, prefs.homepage.value)]]"
pref="{{prefs.browser.show_home_button}}">
</settings-checkbox>
</div>
......
......@@ -129,6 +129,18 @@ Polymer({
this.setResetThemeEnabled.bind(this));
},
/**
* @param {boolean} isNtp Whether to use the NTP as the home page.
* @param {string} homepage If not using NTP, use this URL.
* @return {string} The sub-label.
* @private
*/
getShowHomeSubLabel_: function(isNtp, homepage) {
if (isNtp)
return this.i18n('homePageNtp');
return homepage || this.i18n('exampleDotCom');
},
/**
* @param {boolean} enabled Whether the theme reset is available.
*/
......
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