copy button

This commit is contained in:
tykayn 2021-02-09 22:16:02 +01:00
parent 4df2e00cbe
commit 760bde7e30
3 changed files with 10 additions and 1 deletions

View File

@ -1,5 +1,7 @@
<button (click)="copy()" class="btn btn--primary btn--outline" id="copyLink">
<i class="fa fa-copy" aria-hidden="true"></i>
{{ 'admin.copy_link' | translate }}
<span *ngIf="displayLabelButton">
{{ 'admin.copy_link' | translate }}
</span>
<span *ngIf="displayContentToCopy"> " {{ textToCopy }}" </span>
</button>

View File

@ -11,6 +11,7 @@ import { ToastService } from '../../../../core/services/toast.service';
export class CopyTextComponent implements OnInit {
@Input() public textToCopy: string;
public displayContentToCopy = false;
@Input() public displayLabelButton = true;
constructor(private _clipboardService: ClipboardService, private toastService: ToastService) {}

View File

@ -15,6 +15,12 @@
box-shadow: $dark-lavender 0 0 10px;
}
.is-boxed {
border: 1px solid #ddd;
padding: 1em;
margin: 1em 0;
}
.nobold {
font-weight: normal;
}