summaryrefslogtreecommitdiffstats
path: root/polygerrit-ui/app/elements/shared/gr-account-label/gr-account-label.html
diff options
context:
space:
mode:
Diffstat (limited to 'polygerrit-ui/app/elements/shared/gr-account-label/gr-account-label.html')
-rw-r--r--polygerrit-ui/app/elements/shared/gr-account-label/gr-account-label.html22
1 files changed, 16 insertions, 6 deletions
diff --git a/polygerrit-ui/app/elements/shared/gr-account-label/gr-account-label.html b/polygerrit-ui/app/elements/shared/gr-account-label/gr-account-label.html
index 21f4c3e10d..bdf37bfa04 100644
--- a/polygerrit-ui/app/elements/shared/gr-account-label/gr-account-label.html
+++ b/polygerrit-ui/app/elements/shared/gr-account-label/gr-account-label.html
@@ -1,4 +1,5 @@
<!--
+@license
Copyright (C) 2016 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
@@ -19,6 +20,7 @@ limitations under the License.
<link rel="import" href="../../../bower_components/polymer/polymer.html">
<link rel="import" href="../../../styles/shared-styles.html">
<link rel="import" href="../gr-avatar/gr-avatar.html">
+<link rel="import" href="../gr-limited-text/gr-limited-text.html">
<link rel="import" href="../gr-rest-api-interface/gr-rest-api-interface.html">
<dom-module id="gr-account-label">
@@ -37,10 +39,17 @@ limitations under the License.
vertical-align: -.25em;
}
.text {
- @apply(--gr-account-label-text-style);
+ @apply --gr-account-label-text-style;
}
.text:hover {
- @apply(--gr-account-label-text-hover-style);
+ @apply --gr-account-label-text-hover-style;
+ }
+ .email,
+ .showEmail .name {
+ display: none;
+ }
+ .showEmail .email {
+ display: inline-block;
}
</style>
<span>
@@ -48,13 +57,14 @@ limitations under the License.
<gr-avatar account="[[account]]"
image-size="[[avatarImageSize]]"></gr-avatar>
</template>
- <span class="text">
- <span>[[_computeName(account, _serverConfig)]]</span>
- <span hidden$="[[!_computeShowEmail(showEmail, account)]]">
+ <span class$="text [[_computeShowEmailClass(account)]]">
+ <span class="name">
+ [[_computeName(account, _serverConfig)]]</span>
+ <span class="email">
[[_computeEmailStr(account)]]
</span>
<template is="dom-if" if="[[account.status]]">
- <span>([[account.status]])</span>
+ (<gr-limited-text limit="10" text="[[account.status]]"></gr-limited-text>)
</template>
</span>
</span>