UI: Copy button visible on hover
This commit is contained in:
parent
fba360a237
commit
0dd8161790
@ -161,9 +161,10 @@
|
||||
<ng-container matColumnDef="key">
|
||||
<mat-header-cell *matHeaderCellDef mat-sort-header style="width: 40%"> {{ 'attribute.key' | translate }} </mat-header-cell>
|
||||
<mat-cell *matCellDef="let attribute">
|
||||
<div fxLayout="row" style="align-items: center">
|
||||
<div class="attribute" fxLayout="row" style="align-items: center">
|
||||
<span class="ellipsis">{{ attribute.key }}</span>
|
||||
<tb-copy-button
|
||||
class="attribute-copy"
|
||||
[disabled]="isLoading$ | async"
|
||||
[copyText]="attribute.key"
|
||||
tooltipText="{{ 'attribute.copy-key' | translate }}"
|
||||
@ -181,9 +182,10 @@
|
||||
class="tb-value-cell"
|
||||
(click)="editAttribute($event, attribute)">
|
||||
<div fxFlex fxLayout="row" style="align-items: center">
|
||||
<div fxFlex fxLayout="row" style="overflow: hidden; align-items: center;">
|
||||
<div class="attribute" fxFlex fxLayout="row" style="overflow: hidden; align-items: center;">
|
||||
<span class="ellipsis">{{attribute.value | tbJson}}</span>
|
||||
<tb-copy-button
|
||||
class="attribute-copy"
|
||||
[disabled]="isLoading$ | async"
|
||||
[copyText]="attribute.value | tbJson"
|
||||
tooltipText="{{ 'attribute.copy-value' | translate }}"
|
||||
|
||||
@ -51,6 +51,7 @@
|
||||
overflow: auto;
|
||||
.mat-mdc-table {
|
||||
table-layout: fixed;
|
||||
min-width: 450px;
|
||||
}
|
||||
}
|
||||
|
||||
@ -70,6 +71,17 @@
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
.attribute-copy {
|
||||
visibility: hidden;
|
||||
transition: visibility 0.2s;
|
||||
}
|
||||
|
||||
.attribute:hover {
|
||||
.attribute-copy {
|
||||
visibility: visible;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user