Merge "Fix display of gr-commit-info in inline header"

This commit is contained in:
Kasper Nilsson
2017-12-14 23:04:11 +00:00
committed by Gerrit Code Review
2 changed files with 17 additions and 12 deletions

View File

@@ -219,6 +219,9 @@ limitations under the License.
.text { .text {
white-space: pre; white-space: pre;
} }
gr-commit-info {
display: inline-block;
}
@media screen and (min-width: 80em) { @media screen and (min-width: 80em) {
.commitMessage { .commitMessage {
max-width: var(--commit-message-max-width, 100ch); max-width: var(--commit-message-max-width, 100ch);

View File

@@ -21,22 +21,24 @@ limitations under the License.
<dom-module id="gr-commit-info"> <dom-module id="gr-commit-info">
<template> <template>
<style include="shared-styles"> <style include="shared-styles">
:host { .container {
align-items: center; align-items: center;
display: flex; display: flex;
} }
</style> </style>
<template is="dom-if" if="[[_showWebLink]]"> <div class="container">
<a target="_blank" rel="noopener" <template is="dom-if" if="[[_showWebLink]]">
href$="[[_webLink]]">[[_computeShortHash(commitInfo)]]</a> <a target="_blank" rel="noopener"
</template> href$="[[_webLink]]">[[_computeShortHash(commitInfo)]]</a>
<template is="dom-if" if="[[!_showWebLink]]"> </template>
[[_computeShortHash(commitInfo)]] <template is="dom-if" if="[[!_showWebLink]]">
</template> [[_computeShortHash(commitInfo)]]
<gr-copy-clipboard </template>
hide-input <gr-copy-clipboard
text="[[commitInfo.commit]]"> hide-input
</gr-copy-clipboard> text="[[commitInfo.commit]]">
</gr-copy-clipboard>
</div>
</template> </template>
<script src="gr-commit-info.js"></script> <script src="gr-commit-info.js"></script>
</dom-module> </dom-module>