Add button to copy current token #130

Merged
jsegarra merged 4 commits from 6098_lilium_token_copy into dev 2024-01-02 09:21:32 +00:00
1 changed files with 12 additions and 1 deletions
Showing only changes of commit bce4551847 - Show all commits

View File

@ -81,6 +81,10 @@ function logout() {
session.destroy();
router.push('/login');
}
function copyUserToken(){
navigator.clipboard.writeText(session.getToken());
}
</script>
<template>
@ -122,7 +126,8 @@ function logout() {
<div class="text-subtitle1 q-mt-md">
<strong>{{ user.nickname }}</strong>
</div>
<div class="text-subtitle3 text-grey-7 q-mb-xs">@{{ user.name }}</div>
<div class="text-subtitle3 text-grey-7 q-mb-xs copyUserToken" @click="copyUserToken()" >@{{ user.name }}
</div>
<QBtn
id="logout"
@ -143,4 +148,10 @@ function logout() {
.panel {
width: 150px;
}
.copyUserToken {
&:hover{
cursor: alias;
}
}
</style>