OLD | NEW |
(Empty) | |
| 1 // Copyright 2017 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 /** |
| 6 * @fileoverview |
| 7 * `important-site-checkbox` is a checkbox that displays an important site. |
| 8 */ |
| 9 Polymer({ |
| 10 is: 'important-site-checkbox', |
| 11 |
| 12 properties: { |
| 13 /** The ImportantSite associated with this checkbox. */ |
| 14 site: { |
| 15 type: ImportantSite, |
| 16 }, |
| 17 |
| 18 /** Whether this checkbox should be disabled. */ |
| 19 disabled: { |
| 20 type: Boolean, |
| 21 value: false |
| 22 }, |
| 23 }, |
| 24 |
| 25 /** |
| 26 * Returns the icon to use for a given site. |
| 27 * @param {string} site The url of the site to fetch the icon for. |
| 28 * @return {string} The background-image style with the favicon. |
| 29 * @private |
| 30 */ |
| 31 siteIcon_: function(url) { |
| 32 return 'background-image: ' + cr.icon.getFavicon(url); |
| 33 }, |
| 34 |
| 35 }); |
OLD | NEW |