I've encountered an issue with transitioning content shifts. My data array is displayed in different areas of the DOM based on the state
.
The main idea:
OPEN
- feedback 1 [ complete ]
- feedback 2 [ complete ]
- feedback 3 [ complete ]
CLOSED
Goal: When "close" is clicked, feedback should fade out from OPEN and appear under the CLOSED section.
What I attempted: Rendering "Closed" items with a transition effect:
<transition name="fade">
<v-row v-if="feedbackItem.state ==='closed'" v-for="feedbackItem in closedTasks" :key="feedbackItem.id">
<p>
{{ feedbackItem.feedback }}
</p>
</v-row>
</transition>
<style>
.fade-enter-active, .fade-leave-active {
transition: opacity .5s;
}
.fade-enter, .fade-leave-to {
opacity: 0;
}
</style>
However, the desired result is not achieved (no visible transition), and elements under "Closed" are hidden if there are multiple closed items. It seems related to how the computed item lists are rendered. The line
v-if="feedbackItem.state ==='closed'"
might be causing the problem. Any suggestions on how to achieve the desired outcome or what could be done differently?
Codepen link for experimentation: here.
Thank you to anyone taking a moment to help figure this out!