Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(277)

Unified Diff: ui/webui/resources/cr_elements/policy/cr_policy_indicator_behavior.js

Issue 1947533002: Material WebUI: create shared icon file. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase fix Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: ui/webui/resources/cr_elements/policy/cr_policy_indicator_behavior.js
diff --git a/ui/webui/resources/cr_elements/policy/cr_policy_indicator_behavior.js b/ui/webui/resources/cr_elements/policy/cr_policy_indicator_behavior.js
index dc474f0a72d1ffb9795e31ce80ad14e4987e356f..7220bac6fed6e48069ddeb6db5b71db6604a2a72 100644
--- a/ui/webui/resources/cr_elements/policy/cr_policy_indicator_behavior.js
+++ b/ui/webui/resources/cr_elements/policy/cr_policy_indicator_behavior.js
@@ -30,27 +30,32 @@ var CrPolicyIndicatorBehavior = {
/**
* @param {CrPolicyIndicatorType} type
- * @return {string} The iron-icons icon name.
+ * @return {string} The iron-icon icon name.
* @private
*/
getPolicyIndicatorIcon: function(type) {
+ var icon = '';
switch (type) {
case CrPolicyIndicatorType.NONE:
- return '';
+ return icon;
case CrPolicyIndicatorType.PRIMARY_USER:
- return 'social:group';
+ icon = 'group';
+ break;
case CrPolicyIndicatorType.OWNER:
- return 'social:person';
+ icon = 'person';
+ break;
case CrPolicyIndicatorType.USER_POLICY:
case CrPolicyIndicatorType.DEVICE_POLICY:
- return 'social:domain';
- case CrPolicyIndicatorType.EXTENSION:
- return 'extension';
case CrPolicyIndicatorType.RECOMMENDED:
- return 'social:domain';
+ icon = 'domain';
+ break;
+ case CrPolicyIndicatorType.EXTENSION:
+ icon = 'extension';
+ break;
+ default:
+ assertNotReached();
}
- assertNotReached();
- return '';
+ return 'cr-icons:' + icon;
},
/**

Powered by Google App Engine
This is Rietveld 408576698