From 01e95e029f58a11160bd9a51659eae5d2657f262 Mon Sep 17 00:00:00 2001 From: vince Date: Thu, 18 Jul 2024 21:31:34 +0800 Subject: [PATCH] feat: add v-access directive --- apps/web-antd/src/layouts/basic.vue | 1 + .../src/router/routes/modules/demos.ts | 2 +- .../src/views/demos/access/button-control.vue | 26 ++++++------- .../@core/forward/preferences/src/config.ts | 3 +- .../@core/forward/preferences/src/types.ts | 2 + packages/@core/locales/src/langs/zh-CN.json | 2 +- .../ui-kit/layout-ui/src/vben-layout.vue | 2 +- .../shadcn-ui/src/components/ui/card/Card.vue | 2 +- .../effects/access/src/access-control.vue | 24 ++++++------ packages/effects/access/src/directive.ts | 38 +++++++++++++++++++ packages/effects/access/src/index.ts | 1 + packages/effects/access/src/use-access.ts | 8 ++-- .../authentication/login-expired-modal.vue | 13 +++++-- packages/effects/layouts/src/basic/layout.vue | 1 + 14 files changed, 89 insertions(+), 36 deletions(-) create mode 100644 packages/effects/access/src/directive.ts diff --git a/apps/web-antd/src/layouts/basic.vue b/apps/web-antd/src/layouts/basic.vue index 2a574b3f..fcd2c57f 100644 --- a/apps/web-antd/src/layouts/basic.vue +++ b/apps/web-antd/src/layouts/basic.vue @@ -144,6 +144,7 @@ function handleLockScreen(password: string) {