Skip to content

Commit

Permalink
mini-video-recorder: Display (scrolling) stream name if already selected
Browse files Browse the repository at this point in the history
  • Loading branch information
rafaellehmkuhl committed Jan 30, 2024
1 parent 2828fb0 commit 7d9f6e0
Showing 1 changed file with 19 additions and 1 deletion.
20 changes: 19 additions & 1 deletion src/components/mini-widgets/MiniVideoRecorder.vue
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,10 @@
@click="toggleRecording()"
/>
<template v-if="!isRecording">
<FontAwesomeIcon icon="fa-solid fa-video" class="h-6 text-slate-100" />
<div v-if="nameSelectedStream" class="flex flex-col max-w-[50%] scroll-container">
<div class="text-xs text-white select-none scroll-text">{{ nameSelectedStream }}</div>
</div>
<FontAwesomeIcon v-else icon="fa-solid fa-video" class="h-6 text-slate-100" />
</template>
<div v-else class="w-16 text-justify text-slate-100">
{{ timePassedString }}
Expand Down Expand Up @@ -210,4 +213,19 @@ watch(isRecording, () => {
box-shadow: 0 0 0 0 rgba(255, 82, 82, 0);
}
}
.scroll-container {
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.scroll-text {
transform: translateX(0%);
transition: transform 1s linear;
}
.scroll-text:hover {
transform: translateX(-100%);
}
</style>

0 comments on commit 7d9f6e0

Please sign in to comment.