Chromium Code Reviews| Index: chrome/browser/resources/settings/controls/controlled_button.html |
| diff --git a/chrome/browser/resources/settings/controls/controlled_button.html b/chrome/browser/resources/settings/controls/controlled_button.html |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..8626343fcbcaee5962ed2b7309306c9cd998c450 |
| --- /dev/null |
| +++ b/chrome/browser/resources/settings/controls/controlled_button.html |
| @@ -0,0 +1,26 @@ |
| +<link rel="import" href="chrome://resources/html/polymer.html"> |
| +<link rel="import" href="chrome://resources/polymer/v1_0/paper-button/paper-button.html"> |
| +<link rel="import" href="chrome://resources/cr_elements/policy/cr_policy_pref_behavior.html"> |
| +<link rel="import" href="chrome://resources/cr_elements/policy/cr_policy_pref_indicator.html"> |
| +<link rel="import" href="/controls/pref_control_behavior.html"> |
| +<link rel="import" href="/settings_shared_css.html"> |
| + |
| +<dom-module id="controlled-button"> |
| + <link rel="import" type="css" href="chrome://resources/cr_elements/shared.css"> |
| + <template> |
| + <style include="settings-shared"> |
| + cr-policy-pref-indicator { |
| + -webkit-margin-start: var(--checkbox-spacing); |
| + } |
| + </style> |
| + |
| + <paper-button disabled="[[disabled_]]"> |
|
stevenjb
2016/07/26 16:19:34
'disabled_' confused me for a bit, maybe 'prefDisa
Dan Beam
2016/07/26 19:36:50
I actually changed to "disabled" as it matches a :
|
| + <content></content> |
| + </paper-button> |
| + |
| + <template is="dom-if" if="[[disabled_]]"> |
| + <cr-policy-pref-indicator pref="[[pref]]"></cr-policy-pref-indicator> |
| + </template> |
| + </template> |
| + <script src="/controls/controlled_button.js"></script> |
| +</dom-module> |