making a folding panel like this
the requirement is that after clicking on the title, the down arrow on the right will be expanded and icon will switch up to the up arrow
. The problem withis that every icon I expand will switch up and down together.
but my goal is to switch as long as the one I click on, not all of them.
beginner VUE wants to ask how to solve this problem
my program looks like this (only part of it is retrieved)
<i v-bind:class="{ "el-icon-arrow-down" : isA, "el-icon-arrow-up": !isA}" @click="onClick()"></i>
js
data() {
return {isA: true}
},
methods:{
onClick(inputKey) {this.isA = !this.isA;},
}