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

Side by Side Diff: ui/login/account_picker/md_user_pod_row.js

Issue 2919523005: Add avatar badges and update caps lock icon for new login screen (Closed)
Patch Set: Created 3 years, 6 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 /** 5 /**
6 * @fileoverview User pod row implementation. 6 * @fileoverview User pod row implementation.
7 */ 7 */
8 8
9 cr.define('login', function() { 9 cr.define('login', function() {
10 /** 10 /**
(...skipping 1324 matching lines...) Expand 10 before | Expand all | Expand 10 after
1335 1335
1336 chrome.send('setForceDisableVirtualKeyboard', [visible]); 1336 chrome.send('setForceDisableVirtualKeyboard', [visible]);
1337 }, 1337 },
1338 1338
1339 isPinShown: function() { 1339 isPinShown: function() {
1340 return this.classList.contains('pin-enabled'); 1340 return this.classList.contains('pin-enabled');
1341 }, 1341 },
1342 1342
1343 setUserPodIconType: function(userTypeClass) { 1343 setUserPodIconType: function(userTypeClass) {
1344 this.userTypeIconAreaElement.classList.add(userTypeClass); 1344 this.userTypeIconAreaElement.classList.add(userTypeClass);
1345 this.userTypeIconAreaElement.hidden = false; 1345 // TODO(wzang): Evaluate all icon types other than supervised user and
1346 // switch them to badges per the design spec.
1347 this.userTypeIconAreaElement.hidden = true;
1346 }, 1348 },
1347 1349
1348 isFingerprintIconShown: function() { 1350 isFingerprintIconShown: function() {
1349 return this.fingerprintIconElement && !this.fingerprintIconElement.hidden; 1351 return this.fingerprintIconElement && !this.fingerprintIconElement.hidden;
1350 }, 1352 },
1351 1353
1352 /** 1354 /**
1353 * The user that this pod represents. 1355 * The user that this pod represents.
1354 * @type {!Object} 1356 * @type {!Object}
1355 */ 1357 */
(...skipping 730 matching lines...) Expand 10 before | Expand all | Expand 10 after
2086 if (this.submitButton) { 2088 if (this.submitButton) {
2087 this.submitButton.disabled = isEmpty; 2089 this.submitButton.disabled = isEmpty;
2088 if (this.isFingerprintIconShown()) { 2090 if (this.isFingerprintIconShown()) {
2089 this.submitButton.hidden = isEmpty; 2091 this.submitButton.hidden = isEmpty;
2090 } else { 2092 } else {
2091 this.submitButton.hidden = false; 2093 this.submitButton.hidden = false;
2092 } 2094 }
2093 } 2095 }
2094 this.showError = false; 2096 this.showError = false;
2095 $('bubble').hide(); 2097 $('bubble').hide();
2096 var inputLine = this.querySelector('#input-line'); 2098 this.classList.toggle('input-present', !isEmpty);
2097 if (inputLine) {
2098 if (!isEmpty)
2099 inputLine.setAttribute('active', 'true');
2100 else
2101 inputLine.removeAttribute('active');
2102 }
2103 }, 2099 },
2104 2100
2105 /** 2101 /**
2106 * Handles input event on the password element. 2102 * Handles input event on the password element.
2107 * @param {Event} e Input event. 2103 * @param {Event} e Input event.
2108 */ 2104 */
2109 handleInputChanged_: function(e) { 2105 handleInputChanged_: function(e) {
2110 this.updateInput_(); 2106 this.updateInput_();
2111 }, 2107 },
2112 2108
(...skipping 2361 matching lines...) Expand 10 before | Expand all | Expand 10 after
4474 if (pod && pod.multiProfilesPolicyApplied) { 4470 if (pod && pod.multiProfilesPolicyApplied) {
4475 pod.userTypeBubbleElement.classList.remove('bubble-shown'); 4471 pod.userTypeBubbleElement.classList.remove('bubble-shown');
4476 } 4472 }
4477 } 4473 }
4478 }; 4474 };
4479 4475
4480 return { 4476 return {
4481 PodRow: PodRow 4477 PodRow: PodRow
4482 }; 4478 };
4483 }); 4479 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698