Files
Yi.Framework/Yi.Vue2.x/src/layouts/default/widgets/Notifications.vue
2022-04-26 01:34:47 +08:00

63 lines
1.2 KiB
Vue
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<template>
<v-menu
bottom
left
offset-y
origin="top right"
transition="scale-transition"
>
<template v-slot:activator="{ attrs, on }">
<v-btn
class="ml-2"
min-width="0"
text
v-bind="attrs"
v-on="on"
>
<v-badge
bordered
color="red"
overlap
>
<template v-slot:badge>
<span>5</span>
</template>
<v-icon>mdi-bell</v-icon>
</v-badge>
</v-btn>
</template>
<v-list
flat
nav
>
<app-bar-item
v-for="(n, i) in notifications"
:key="i"
link
>
<v-list-item-content>
<v-list-item-title>{{ n }} </v-list-item-title>
</v-list-item-content>
</app-bar-item>
</v-list>
</v-menu>
</template>
<script>
export default {
name: 'DefaultNotifications',
data: () => ({
notifications: [
'临时消息1请检查邮箱',
'临时消息2请检查邮箱',
'临时消息3请检查邮箱',
'临时消息4请检查邮箱',
'临时消息5请检查邮箱',
],
}),
}
</script>