Chromium Code Reviews| Index: chrome/browser/resources/settings/controls/important_site_checkbox.js |
| diff --git a/chrome/browser/resources/settings/controls/important_site_checkbox.js b/chrome/browser/resources/settings/controls/important_site_checkbox.js |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..ebbac1eb7d25d93cf822a8ab5c881e26e52635d1 |
| --- /dev/null |
| +++ b/chrome/browser/resources/settings/controls/important_site_checkbox.js |
| @@ -0,0 +1,29 @@ |
| +// Copyright 2017 The Chromium Authors. All rights reserved. |
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +/** |
| + * @fileoverview |
| + * `important-site-checkbox` is a checkbox that displays an important site. |
|
michaelpg
2017/05/03 21:48:06
again, try to explain what an important site is or
dullweber
2017/05/04 08:31:08
Done.
|
| + */ |
| +Polymer({ |
| + is: 'important-site-checkbox', |
| + |
| + properties: { |
| + /** @type {ImportantSite} */ |
| + site: Object, |
| + |
| + disabled: {type: Boolean, value: false}, |
| + }, |
| + |
| + /** |
| + * Returns the icon to use for a given site. |
| + * @param {string} site The url of the site to fetch the icon for. |
|
michaelpg
2017/05/03 21:48:06
site => url to match parameter (is closure running
dullweber
2017/05/04 08:31:09
fixed and I added it to the closure compilation
|
| + * @return {string} The background-image style with the favicon. |
| + * @private |
| + */ |
| + siteIcon_: function(url) { |
| + return 'background-image: ' + cr.icon.getFavicon(url); |
| + }, |
| + |
|
michaelpg
2017/05/03 21:48:06
nit: remove blank line
dullweber
2017/05/04 08:31:09
Done.
|
| +}); |