<v-row justify="space-around">
<v-avatar color="indigo" size="36">
<span class="white--text headline">36</span>
</v-avatar>
<v-avatar color="teal" size="48">
<span class="white--text headline">48</span>
</v-avatar>
<v-avatar color="orange" size="62">
<span class="white--text headline">62</span>
</v-avatar>
</v-row>
The size
prop allows you to define the height and width of v-avatar
. This prop scales both evenly with an aspect ratio of 1. height
and width
props will override this prop.
<v-card
class="mx-auto"
max-width="434"
tile
>
<v-img
height="100%"
src="/media/stock-600x400/img-32.jpg"
>
<v-row
align="end"
class="fill-height"
>
<v-col
align-self="start"
class="pa-0"
cols="12"
>
<v-avatar
class="profile"
color="grey"
size="164"
tile
>
<v-img src="/media/users/300_21.jpg"></v-img>
</v-avatar>
</v-col>
<v-col class="py-0">
<v-list-item
color="rgba(0, 0, 0, .4)"
dark
>
<v-list-item-content>
<v-list-item-title class="title">Sarah Obrien</v-list-item-title>
<v-list-item-subtitle>Network Engineer</v-list-item-subtitle>
</v-list-item-content>
</v-list-item>
</v-col>
</v-row>
</v-img>
</v-card>
Using the tile
prop, we can create a sleek hard-lined profile card.
<v-row justify="space-around">
<v-avatar color="indigo">
<v-icon dark>mdi-account-circle</v-icon>
</v-avatar>
<v-avatar>
<img
src="/media/users/100_4.jpg"
alt="Sean"
>
</v-avatar>
<v-avatar color="red">
<span class="white--text headline">CJ</span>
</v-avatar>
</v-row>
The v-avatar
default slot will accept the v-icon
component, an image, or text. Mix and match these with other props to create something unique.
Combining an avatar with other components allows you to build beautiful user interfaces right out of the box.