add entrance transition

This commit is contained in:
Timi
2026-08-24 16:16:43 +08:00
parent 2efce6de11
commit 05aad89706
54 changed files with 874 additions and 694 deletions
+19 -18
View File
@@ -7,26 +7,27 @@
@refresh="refresh"
>
<t-cell-group v-if="sortedRoles.length" theme="card">
<t-swipe-cell
v-for="item in sortedRoles"
:key="item.id"
class="item"
>
<t-cell
:title="item.name"
:note="item.code"
arrow
hover
@click="router.push(`/management/permissions/roles/${item.id}`)"
<t-swipe-cell
v-entrance-transition="index * 30"
v-for="(item, index) in sortedRoles"
:key="item.id"
class="item"
>
<template #title>
<div class="title" v-text="item.name" :style="{ paddingLeft: `${item.level * 1.25}rem` }" />
<t-cell
:title="item.name"
:note="item.code"
arrow
hover
@click="router.push(`/management/permissions/roles/${item.id}`)"
>
<template #title>
<div class="title" v-text="item.name" :style="{ paddingLeft: `${item.level * 1.25}rem` }" />
</template>
</t-cell>
<template #right>
<t-button v-if="canDeleteRole(item)" v-can="corePermissionCodes.role.delete" class="delete" theme="danger" @click="removeRole(item.id)">删除</t-button>
</template>
</t-cell>
<template #right>
<t-button v-if="canDeleteRole(item)" v-can="corePermissionCodes.role.delete" class="delete" theme="danger" @click="removeRole(item.id)">删除</t-button>
</template>
</t-swipe-cell>
</t-swipe-cell>
</t-cell-group>
<t-empty v-else-if="!permissionStore.loading" description="暂无角色" />
</t-pull-down-refresh>