style: change vue v-for loops

This commit is contained in:
Alex 2022-05-07 17:05:45 +12:00
parent d273a8cad1
commit f3333c0ae3
2 changed files with 13 additions and 10 deletions

View File

@ -15,8 +15,12 @@
</v-btn>
</template>
<template v-for="(comment, index) in comments">
<v-list-item :key="index" class="px-0">
<div
v-for="(comment, index) in comments"
:key="index"
class="commentElement"
>
<v-list-item class="px-0">
<component
v-if="getComponents()[Object.keys(comment)[0]]"
:is="Object.keys(comment)[0]"
@ -25,11 +29,8 @@
@showReplies="openReply"
></component>
</v-list-item>
<v-divider
v-if="getComponents()[Object.keys(comment)[0]]"
:key="index"
></v-divider>
</template>
<v-divider v-if="getComponents()[Object.keys(comment)[0]]"></v-divider>
</div>
<div class="loading" v-if="loading">
<v-sheet

View File

@ -15,9 +15,11 @@
<template>
<comment-thread-renderer :comment="parentComment" />
<v-divider></v-divider>
<template v-for="index in 10">
<comment-thread-renderer :comment="parentComment" v-bind:key="index" />
</template>
<comment-thread-renderer
v-for="index in 10"
v-bind:key="index"
:comment="parentComment"
/>
</template>
</dialog-base>
</template>