Monday, May 20, 2024
 Popular · Latest · Hot · Upcoming
171
rated 0 times [  176] [ 5]  / answers: 1 / hits: 39357  / 5 Years ago, wed, february 27, 2019, 12:00:00

Here's my Vuetify code for using list:



<v-list>
<v-list-tile
v-for=user in users
:key=user.id
avatar
@click=
>

<v-list-tile-content>
<v-list-tile-title v-text=user.name></v-list-tile-title>
</v-list-tile-content>

<v-btn icon>
<v-icon>edit</v-icon>
</v-btn>
</v-list-tile>
</v-list>


The problem is, that I have over 100 users and the list is not scrollable by default. Is there any trait that helps with it?


More From » css

 Answers
25

I achieved this by giving the style of max-height: 100px and adding vuetify class overflow-y-auto to <v-list></v-list>



For eg:



<v-list
style=max-height: 100px
class=overflow-y-auto
>
<template
v-for=user in users
>
<v-list-tile
:key=user.id
avatar
@click=
>
<v-list-tile-content>
<v-list-tile-title v-text=user.name></v-list-tile-title>
</v-list-tile-content>
<v-btn icon>
<v-icon>edit</v-icon>
</v-btn>
</v-list-tile>
</template>
</v-list>

[#52522] Saturday, February 23, 2019, 5 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
hakeemabramh

Total Points: 234
Total Questions: 109
Total Answers: 109

Location: Romania
Member since Mon, Jun 6, 2022
2 Years ago
;