From 4fe1a52d23da322eb2f7298941586825407f2529 Mon Sep 17 00:00:00 2001
From: hooray <304327508@qq.com>
Date: Mon, 26 Sep 2022 00:05:06 +0800
Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=BC=94=E7=A4=BA=E9=85=8D?=
=?UTF-8?q?=E7=BD=AE?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/auto-imports.d.ts | 1 +
src/layouts/components/BuyIt/index.vue | 10 ++++++
src/router/modules/component.basic.example.ts | 10 +++++-
src/store/modules/user.ts | 2 +-
src/views/component_basic_example/button.vue | 32 +++++++++----------
src/views/component_basic_example/icon.vue | 20 +++---------
6 files changed, 41 insertions(+), 34 deletions(-)
diff --git a/src/auto-imports.d.ts b/src/auto-imports.d.ts
index 5e30355b..d0edda1b 100644
--- a/src/auto-imports.d.ts
+++ b/src/auto-imports.d.ts
@@ -2,6 +2,7 @@
export {}
declare global {
const EffectScope: typeof import('vue')['EffectScope']
+ const ElLoading: typeof import('element-plus/es')['ElLoading']
const ElMessage: typeof import('element-plus/es')['ElMessage']
const ElNotification: typeof import('element-plus/es')['ElNotification']
const acceptHMRUpdate: typeof import('pinia')['acceptHMRUpdate']
diff --git a/src/layouts/components/BuyIt/index.vue b/src/layouts/components/BuyIt/index.vue
index 5e757e3a..6ea23b99 100644
--- a/src/layouts/components/BuyIt/index.vue
+++ b/src/layouts/components/BuyIt/index.vue
@@ -16,6 +16,16 @@ onMounted(() => {
position: 'bottom-right',
duration: 5000,
})
+
+ setTimeout(() => {
+ ElNotification({
+ type: 'info',
+ title: 'TypeScript 支持',
+ message: 'Fantastic-admin 现已支持 TypeScript',
+ position: 'bottom-right',
+ duration: 3000,
+ })
+ }, 0)
})
function open(url: string) {
diff --git a/src/router/modules/component.basic.example.ts b/src/router/modules/component.basic.example.ts
index d854cf11..ccaf17b4 100644
--- a/src/router/modules/component.basic.example.ts
+++ b/src/router/modules/component.basic.example.ts
@@ -12,6 +12,14 @@ const routes: Route.recordRaw = {
icon: 'ep:element-plus',
},
children: [
+ {
+ path: 'icon',
+ name: 'componentBasicExampleIcon',
+ component: () => import('@/views/component_basic_example/icon.vue'),
+ meta: {
+ title: '图标',
+ },
+ },
{
path: 'button',
name: 'componentBasicExampleButton',
@@ -57,7 +65,7 @@ const routes: Route.recordRaw = {
name: 'componentBasicExampleInputnumber',
component: () => import('@/views/component_basic_example/inputnumber.vue'),
meta: {
- title: '计数器',
+ title: '数字输入框',
},
},
{
diff --git a/src/store/modules/user.ts b/src/store/modules/user.ts
index 1fdd5ec5..abeba47c 100644
--- a/src/store/modules/user.ts
+++ b/src/store/modules/user.ts
@@ -10,7 +10,7 @@ const useUserStore = defineStore(
account: localStorage.account || '',
token: localStorage.token || '',
failure_time: localStorage.failure_time || '',
- permissions: [],
+ permissions: [] as string[],
}),
getters: {
isLogin: (state) => {
diff --git a/src/views/component_basic_example/button.vue b/src/views/component_basic_example/button.vue
index d1f41211..434ade7a 100644
--- a/src/views/component_basic_example/button.vue
+++ b/src/views/component_basic_example/button.vue
@@ -74,42 +74,42 @@ import Alert from './components/alert.vue'
-
+
-
+
-
+
-
+
-
+
-
+
@@ -181,28 +181,28 @@ import Alert from './components/alert.vue'
-
+
-
+
-
+
-
+
搜索
@@ -210,7 +210,7 @@ import Alert from './components/alert.vue'
上传
-
+
@@ -218,14 +218,14 @@ import Alert from './components/alert.vue'
-
+
上一页
下一页
-
+
@@ -233,21 +233,21 @@ import Alert from './components/alert.vue'
-
+
-
+
-
+
diff --git a/src/views/component_basic_example/icon.vue b/src/views/component_basic_example/icon.vue
index f68468dc..7262674a 100644
--- a/src/views/component_basic_example/icon.vue
+++ b/src/views/component_basic_example/icon.vue
@@ -5,9 +5,6 @@ meta:
@@ -15,27 +12,18 @@ const icon = icons.filter(item => item.prefix === 'ep')[0]
-
-
-
+
+
+
-
+
搜索
-
-
-
-
-
-
-
-
-