@liujitcn/kratos-admin-core 0.0.29 → 0.0.32

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (147) hide show
  1. package/README.md +15 -8
  2. package/build/auto-imports.json +73 -0
  3. package/build/plugins.ts +2 -58
  4. package/dist/package/declarations/src/api/base/{config.d.ts → v1/config.d.ts} +1 -1
  5. package/dist/package/declarations/src/api/base/{file.d.ts → v1/file.d.ts} +3 -1
  6. package/dist/package/declarations/src/api/base/{language.d.ts → v1/language.d.ts} +1 -1
  7. package/dist/package/declarations/src/api/base/{login.d.ts → v1/login.d.ts} +2 -2
  8. package/dist/package/declarations/src/api/base/v1/mfa.d.ts +26 -0
  9. package/dist/package/declarations/src/api/base/{oauth.d.ts → v1/oauth.d.ts} +1 -1
  10. package/dist/package/declarations/src/api/system/{auth.d.ts → admin/v1/auth.d.ts} +2 -2
  11. package/dist/package/declarations/src/api/system/{base_dict.d.ts → admin/v1/base_dict.d.ts} +1 -1
  12. package/dist/package/declarations/src/api/system/{base_tenant.d.ts → admin/v1/base_tenant.d.ts} +2 -2
  13. package/dist/package/declarations/src/components/Dialog/FormDialog.vue.d.ts +3 -3
  14. package/dist/package/declarations/src/components/Dialog/PasswordVerifyDialog.vue.d.ts +65 -0
  15. package/dist/package/declarations/src/components/Dialog/ProDialog.vue.d.ts +1 -1
  16. package/dist/package/declarations/src/components/Grid/components/GridItem.vue.d.ts +1 -1
  17. package/dist/package/declarations/src/components/Mfa/MfaRecoveryCodesDialog.vue.d.ts +19 -0
  18. package/dist/package/declarations/src/components/Mfa/MfaSetupPanel.vue.d.ts +8 -0
  19. package/dist/package/declarations/src/components/ProForm/components/ProFormItem.vue.d.ts +4 -4
  20. package/dist/package/declarations/src/components/ProForm/index.vue.d.ts +1 -1
  21. package/dist/package/declarations/src/components/ProForm/interface/index.d.ts +4 -1
  22. package/dist/package/declarations/src/components/ProTable/index.vue.d.ts +114 -0
  23. package/dist/package/declarations/src/components/RichTextPreview/index.vue.d.ts +8 -0
  24. package/dist/package/declarations/src/components/TreeFilter/index.vue.d.ts +84 -76
  25. package/dist/package/declarations/src/components/Upload/File.vue.d.ts +1 -1
  26. package/dist/package/declarations/src/components/Upload/Files.vue.d.ts +1 -1
  27. package/dist/package/declarations/src/components/Upload/Img.vue.d.ts +2 -2
  28. package/dist/package/declarations/src/components/Upload/Imgs.vue.d.ts +2 -2
  29. package/dist/package/declarations/src/components/WangEditor/index.vue.d.ts +2 -0
  30. package/dist/package/declarations/src/documentTitle.d.ts +2 -0
  31. package/dist/package/declarations/src/format.d.ts +1 -1
  32. package/dist/package/declarations/src/index.d.ts +2 -1
  33. package/dist/package/declarations/src/layouts/components/LockScreen.vue.d.ts +3 -0
  34. package/dist/package/declarations/src/locales/generated.d.ts +208 -0
  35. package/dist/package/declarations/src/locales/index.d.ts +2 -0
  36. package/dist/package/declarations/src/modules/index.d.ts +1 -3
  37. package/dist/package/declarations/src/request.d.ts +1 -1
  38. package/dist/package/declarations/src/routers/index.d.ts +1 -1
  39. package/dist/package/declarations/src/rpc/base/v1/login.d.ts +37 -5
  40. package/dist/package/declarations/src/rpc/base/v1/mfa.d.ts +152 -0
  41. package/dist/package/declarations/src/rpc/base/v1/oauth.d.ts +25 -0
  42. package/dist/package/declarations/src/rpc/base/v1/oauth_client.d.ts +23 -0
  43. package/dist/package/declarations/src/rpc/system/admin/v1/auth.d.ts +13 -0
  44. package/dist/package/declarations/src/rpc/system/admin/v1/base_dict.d.ts +0 -101
  45. package/dist/package/declarations/src/rpc/system/admin/v1/base_i18n.d.ts +10 -6
  46. package/dist/package/declarations/src/rpc/system/common/v1/common.d.ts +26 -0
  47. package/dist/package/declarations/src/security.d.ts +2 -0
  48. package/dist/package/declarations/src/stores/interface/index.d.ts +19 -1
  49. package/dist/package/declarations/src/stores/modules/lockScreen.d.ts +20 -0
  50. package/dist/package/declarations/src/stores/modules/user.d.ts +7 -6
  51. package/dist/package/declarations/src/stores/runtime.d.ts +1 -0
  52. package/dist/package/declarations/src/utils/clipboard.d.ts +2 -0
  53. package/dist/package/declarations/src/utils/passwordStrength.d.ts +1 -12
  54. package/dist/package/declarations/src/utils/request.d.ts +13 -2
  55. package/dist/package/declarations/src/utils/utils.d.ts +4 -0
  56. package/dist/package/declarations/src/utils/webauthn.d.ts +4 -0
  57. package/dist/package/declarations/vite.config.d.ts +2 -0
  58. package/dist/package/src/api/base/{config.ts → v1/config.ts} +2 -2
  59. package/dist/package/src/api/base/{file.ts → v1/file.ts} +20 -24
  60. package/dist/package/src/api/base/{language.ts → v1/language.ts} +2 -2
  61. package/dist/package/src/api/base/{login.ts → v1/login.ts} +3 -3
  62. package/dist/package/src/api/base/v1/mfa.ts +114 -0
  63. package/dist/package/src/api/base/{oauth.ts → v1/oauth.ts} +2 -2
  64. package/dist/package/src/api/system/{auth.ts → admin/v1/auth.ts} +3 -3
  65. package/dist/package/src/api/system/{base_dict.ts → admin/v1/base_dict.ts} +2 -2
  66. package/dist/package/src/api/system/{base_tenant.ts → admin/v1/base_tenant.ts} +3 -3
  67. package/dist/package/src/bootstrap.ts +6 -5
  68. package/dist/package/src/components/CronExpression/index.vue +4 -3
  69. package/dist/package/src/components/Dialog/PasswordVerifyDialog.vue +176 -0
  70. package/dist/package/src/components/Dialog/ProDialog.vue +1 -0
  71. package/dist/package/src/components/ImportExcel/index.vue +4 -2
  72. package/dist/package/src/components/Loading/fullScreen.ts +2 -1
  73. package/dist/package/src/components/MarkdownPreview/index.vue +22 -2
  74. package/dist/package/src/components/Mfa/MfaRecoveryCodesDialog.vue +91 -0
  75. package/dist/package/src/components/Mfa/MfaSetupPanel.vue +81 -0
  76. package/dist/package/src/components/PasswordStrength/index.vue +1 -1
  77. package/dist/package/src/components/ProForm/components/ProFormItem.vue +16 -1
  78. package/dist/package/src/components/ProForm/interface/index.ts +4 -0
  79. package/dist/package/src/components/ProTable/components/ColSetting.vue +1 -1
  80. package/dist/package/src/components/ProTable/components/TableColumn.vue +14 -6
  81. package/dist/package/src/components/ProTable/index.vue +9 -5
  82. package/dist/package/src/components/RichTextPreview/index.vue +56 -0
  83. package/dist/package/src/components/SelectIcon/index.vue +3 -2
  84. package/dist/package/src/components/Upload/File.vue +2 -2
  85. package/dist/package/src/components/Upload/Files.vue +2 -2
  86. package/dist/package/src/components/Upload/Img.vue +7 -5
  87. package/dist/package/src/components/Upload/Imgs.vue +6 -5
  88. package/dist/package/src/components/WangEditor/index.vue +10 -7
  89. package/dist/package/src/config/index.ts +1 -1
  90. package/dist/package/src/documentTitle.ts +8 -0
  91. package/dist/package/src/format.ts +1 -1
  92. package/dist/package/src/index.ts +2 -1
  93. package/dist/package/src/layouts/LayoutClassic/index.vue +3 -1
  94. package/dist/package/src/layouts/LayoutColumns/index.vue +3 -1
  95. package/dist/package/src/layouts/LayoutTransverse/index.vue +3 -1
  96. package/dist/package/src/layouts/LayoutVertical/index.vue +9 -1
  97. package/dist/package/src/layouts/components/Header/components/Avatar.vue +26 -6
  98. package/dist/package/src/layouts/components/Header/components/InfoDialog.vue +4 -3
  99. package/dist/package/src/layouts/components/Header/components/PasswordDialog.vue +4 -3
  100. package/dist/package/src/layouts/components/Header/components/SearchMenu.vue +16 -8
  101. package/dist/package/src/layouts/components/LockScreen.vue +573 -0
  102. package/dist/package/src/layouts/components/Tabs/index.vue +12 -3
  103. package/dist/package/src/layouts/components/ThemeDrawer/index.scss +4 -4
  104. package/dist/package/src/layouts/index.vue +2 -0
  105. package/dist/package/src/layouts/indexAsync.vue +2 -0
  106. package/dist/package/src/locales/README.md +2 -1
  107. package/dist/package/src/locales/en-US.json +51 -3
  108. package/dist/package/src/locales/index.ts +16 -12
  109. package/dist/package/src/locales/ja-JP.json +51 -3
  110. package/dist/package/src/locales/zh-CN.json +51 -3
  111. package/dist/package/src/locales/zh-TW.json +51 -3
  112. package/dist/package/src/modules/index.ts +2 -4
  113. package/dist/package/src/request.ts +3 -0
  114. package/dist/package/src/routers/index.ts +15 -14
  115. package/dist/package/src/rpc/base/v1/login.ts +37 -4
  116. package/dist/package/src/rpc/base/v1/mfa.ts +180 -0
  117. package/dist/package/src/rpc/base/v1/oauth.ts +25 -0
  118. package/dist/package/src/rpc/base/v1/oauth_client.ts +33 -0
  119. package/dist/package/src/rpc/system/admin/v1/auth.ts +13 -0
  120. package/dist/package/src/rpc/system/admin/v1/base_dict.ts +0 -112
  121. package/dist/package/src/rpc/system/admin/v1/base_i18n.ts +10 -6
  122. package/dist/package/src/rpc/system/common/v1/common.ts +35 -0
  123. package/dist/package/src/security.ts +2 -0
  124. package/dist/package/src/stores/interface/index.ts +20 -1
  125. package/dist/package/src/stores/modules/auth.ts +1 -1
  126. package/dist/package/src/stores/modules/config.ts +2 -2
  127. package/dist/package/src/stores/modules/dict.ts +1 -1
  128. package/dist/package/src/stores/modules/lockScreen.ts +78 -0
  129. package/dist/package/src/stores/modules/user.ts +34 -22
  130. package/dist/package/src/stores/runtime.ts +1 -0
  131. package/dist/package/src/styles/element.scss +35 -4
  132. package/dist/package/src/utils/clipboard.ts +22 -0
  133. package/dist/package/src/utils/passwordCrypto.ts +1 -1
  134. package/dist/package/src/utils/passwordStrength.ts +7 -24
  135. package/dist/package/src/utils/request.ts +175 -40
  136. package/dist/package/src/utils/tenant.ts +1 -1
  137. package/dist/package/src/utils/utils.ts +25 -6
  138. package/dist/package/src/utils/webauthn.ts +90 -0
  139. package/dist/package/src/views/login/components/LoginForm.vue +257 -24
  140. package/dist/package/src/views/login/index.scss +2 -2
  141. package/dist/package/src/views/login/index.vue +3 -1
  142. package/dist/package/types/generated/auto-imports.d.ts +132 -129
  143. package/dist/package/types/generated/components.d.ts +4 -72
  144. package/package.json +22 -1
  145. package/types/generated/auto-imports.d.ts +132 -129
  146. package/types/generated/components.d.ts +4 -72
  147. package/vite.config.ts +4 -1
@@ -6,6 +6,7 @@
6
6
 
7
7
  export * from "./modules";
8
8
  export * from "./locales";
9
- export { defLanguageService } from "./api/base/language";
9
+ export { defLanguageService } from "./api/base/v1/language";
10
+ export { setAdminDocumentTitle } from "./documentTitle";
10
11
  export { kratosAdminModule } from "./modules/kratosAdmin";
11
12
  export { bootstrapAdminApp } from "./bootstrap";
@@ -4,7 +4,7 @@
4
4
  <el-header>
5
5
  <div class="header-lf mask-image">
6
6
  <div class="logo flx-center">
7
- <img class="logo-img" :src="logoUrl" alt="logo" />
7
+ <img class="logo-img" :src="logoUrl" :alt="t('core.layout.logo_alt')" />
8
8
  <span class="logo-text">{{ title }}</span>
9
9
  </div>
10
10
  <ToolBarLeft />
@@ -46,11 +46,13 @@ import Main from "../../layouts/components/Main/index.vue";
46
46
  import SubMenu from "../../layouts/components/Menu/SubMenu.vue";
47
47
  import ToolBarLeft from "../../layouts/components/Header/ToolBarLeft.vue";
48
48
  import ToolBarRight from "../../layouts/components/Header/ToolBarRight.vue";
49
+ import { useLocaleStore } from "../../locales";
49
50
 
50
51
  const route = useRoute();
51
52
  const authStore = useAuthStore();
52
53
  const configStore = useConfigStore();
53
54
  const globalStore = useGlobalStore();
55
+ const { t } = useLocaleStore();
54
56
  const accordion = computed(() => globalStore.accordion);
55
57
  const isCollapse = computed(() => globalStore.isCollapse);
56
58
  const menuList = computed(() => authStore.showMenuListGet);
@@ -3,7 +3,7 @@
3
3
  <el-container class="layout">
4
4
  <div class="aside-split">
5
5
  <div class="logo flx-center">
6
- <img class="logo-img" :src="logoUrl" alt="logo" />
6
+ <img class="logo-img" :src="logoUrl" :alt="t('core.layout.logo_alt')" />
7
7
  </div>
8
8
  <el-scrollbar>
9
9
  <div class="split-list">
@@ -60,12 +60,14 @@ import Main from "../../layouts/components/Main/index.vue";
60
60
  import ToolBarLeft from "../../layouts/components/Header/ToolBarLeft.vue";
61
61
  import ToolBarRight from "../../layouts/components/Header/ToolBarRight.vue";
62
62
  import SubMenu from "../../layouts/components/Menu/SubMenu.vue";
63
+ import { useLocaleStore } from "../../locales";
63
64
 
64
65
  const route = useRoute();
65
66
  const router = useRouter();
66
67
  const authStore = useAuthStore();
67
68
  const configStore = useConfigStore();
68
69
  const globalStore = useGlobalStore();
70
+ const { t } = useLocaleStore();
69
71
  const accordion = computed(() => globalStore.accordion);
70
72
  const isCollapse = computed(() => globalStore.isCollapse);
71
73
  const menuList = computed(() => authStore.showMenuListGet.filter(item => Boolean(item.path) || Boolean(item.children?.length)));
@@ -3,7 +3,7 @@
3
3
  <el-container class="layout">
4
4
  <el-header>
5
5
  <div class="logo flx-center">
6
- <img class="logo-img" :src="logoUrl" alt="logo" />
6
+ <img class="logo-img" :src="logoUrl" :alt="t('core.layout.logo_alt')" />
7
7
  <span class="logo-text">{{ title }}</span>
8
8
  </div>
9
9
  <el-menu mode="horizontal" :router="false" :default-active="activeMenu">
@@ -44,11 +44,13 @@ import { getRouteMenuKey, getRouteMetaIcon, getRouteMetaTitle, getRouteTarget, i
44
44
  import Main from "../../layouts/components/Main/index.vue";
45
45
  import ToolBarRight from "../../layouts/components/Header/ToolBarRight.vue";
46
46
  import SubMenu from "../../layouts/components/Menu/SubMenu.vue";
47
+ import { useLocaleStore } from "../../locales";
47
48
 
48
49
  const route = useRoute();
49
50
  const router = useRouter();
50
51
  const authStore = useAuthStore();
51
52
  const configStore = useConfigStore();
53
+ const { t } = useLocaleStore();
52
54
  const menuList = computed(() => authStore.showMenuListGet);
53
55
  const activeMenu = computed(() => route.path as string);
54
56
  const title = computed(() => configStore.display.sysName || import.meta.env.VITE_GLOB_APP_TITLE);
@@ -4,7 +4,13 @@
4
4
  <el-aside>
5
5
  <div class="aside-box" :style="{ width: isCollapse ? '65px' : '240px' }">
6
6
  <div ref="logoWrapperRef" :class="['logo', { 'logo--text-only': !showLogoIcon && !isCollapse }]">
7
- <img v-show="isCollapse || showLogoIcon" ref="logoIconRef" class="logo-img" :src="logoUrl" alt="logo" />
7
+ <img
8
+ v-show="isCollapse || showLogoIcon"
9
+ ref="logoIconRef"
10
+ class="logo-img"
11
+ :src="logoUrl"
12
+ :alt="t('core.layout.logo_alt')"
13
+ />
8
14
  <span
9
15
  v-show="!isCollapse"
10
16
  ref="logoTextRef"
@@ -46,11 +52,13 @@ import Main from "../../layouts/components/Main/index.vue";
46
52
  import ToolBarLeft from "../../layouts/components/Header/ToolBarLeft.vue";
47
53
  import ToolBarRight from "../../layouts/components/Header/ToolBarRight.vue";
48
54
  import SubMenu from "../../layouts/components/Menu/SubMenu.vue";
55
+ import { useLocaleStore } from "../../locales";
49
56
 
50
57
  const route = useRoute();
51
58
  const authStore = useAuthStore();
52
59
  const configStore = useConfigStore();
53
60
  const globalStore = useGlobalStore();
61
+ const { t } = useLocaleStore();
54
62
  const accordion = computed(() => globalStore.accordion);
55
63
  const isCollapse = computed(() => globalStore.isCollapse);
56
64
  const menuList = computed(() => authStore.showMenuListGet);
@@ -1,13 +1,13 @@
1
1
  <template>
2
2
  <el-dropdown ref="dropdownRef" trigger="click" placement="bottom-end" popper-class="header-avatar-dropdown">
3
3
  <div class="avatar">
4
- <img :src="avatarSrc" alt="avatar" @error="handleAvatarError" />
4
+ <img :src="avatarSrc" :alt="t('core.layout.avatar')" @error="handleAvatarError" />
5
5
  </div>
6
6
  <template #dropdown>
7
7
  <div class="user-panel">
8
8
  <div class="user-panel__summary">
9
9
  <div class="user-panel__avatar">
10
- <img :src="avatarSrc" alt="avatar" @error="handleAvatarError" />
10
+ <img :src="avatarSrc" :alt="t('core.layout.avatar')" @error="handleAvatarError" />
11
11
  </div>
12
12
  <div class="user-panel__identity">
13
13
  <div class="user-panel__name">{{ displayName }}</div>
@@ -23,7 +23,11 @@
23
23
  @click.stop="handleUserMenuAction(action.path)"
24
24
  >
25
25
  <el-icon v-if="action.icon"><component :is="action.icon" /></el-icon>
26
- <span>{{ action.labelKey ? t(action.labelKey) : action.label }}</span>
26
+ <span>{{ t(action.labelKey) }}</span>
27
+ </button>
28
+ <button class="action-btn action-btn--lock" type="button" @click.stop="lockScreen">
29
+ <el-icon><Lock /></el-icon>
30
+ <span>{{ t("core.layout.lock_screen") }}</span>
27
31
  </button>
28
32
  <button class="action-btn action-btn--danger" type="button" @click="logout">
29
33
  <el-icon><SwitchButton /></el-icon>
@@ -41,16 +45,17 @@ import { LOGIN_URL } from "../../../../config";
41
45
  import { useRouter } from "vue-router";
42
46
  import { useUserStore } from "../../../../stores/modules/user";
43
47
  import { useAuthStore } from "../../../../stores/modules/auth";
44
- import { ElMessageBox, ElMessage } from "element-plus";
45
48
  import type { DropdownInstance } from "element-plus";
46
49
  import defaultAvatar from "../../../../assets/images/avatar.png";
47
50
  import { navigateTo } from "../../../../utils/router";
48
51
  import { getAdminUserMenuActions } from "../../../../modules";
49
52
  import { useLocaleStore } from "../../../../locales";
53
+ import { useLockScreenStore } from "../../../../stores/modules/lockScreen";
50
54
 
51
55
  const router = useRouter();
52
56
  const userStore = useUserStore();
53
57
  const authStore = useAuthStore();
58
+ const lockScreenStore = useLockScreenStore();
54
59
  const userMenuActions = getAdminUserMenuActions();
55
60
  const dropdownRef = ref<DropdownInstance>();
56
61
  const { t } = useLocaleStore();
@@ -112,6 +117,12 @@ const handleUserMenuAction = async (path: string) => {
112
117
  dropdownRef.value?.handleClose();
113
118
  await navigateTo(router, path);
114
119
  };
120
+
121
+ /** 打开锁屏密码设置界面并关闭头像菜单。 */
122
+ const lockScreen = () => {
123
+ dropdownRef.value?.handleClose();
124
+ lockScreenStore.openSetup();
125
+ };
115
126
  </script>
116
127
 
117
128
  <style scoped lang="scss">
@@ -135,7 +146,7 @@ const handleUserMenuAction = async (path: string) => {
135
146
  padding: 16px;
136
147
  background: linear-gradient(180deg, #ffffff 0%, #f7f9fc 100%);
137
148
  border: 1px solid rgb(15 23 42 / 8%);
138
- border-radius: 12px;
149
+ border-radius: var(--admin-page-radius);
139
150
  box-shadow: 0 16px 40px rgb(15 23 42 / 14%);
140
151
  &__summary {
141
152
  display: flex;
@@ -192,7 +203,7 @@ const handleUserMenuAction = async (path: string) => {
192
203
  height: 38px;
193
204
  cursor: pointer;
194
205
  border: none;
195
- border-radius: 10px;
206
+ border-radius: var(--admin-page-radius);
196
207
  transition:
197
208
  transform 0.2s ease,
198
209
  box-shadow 0.2s ease,
@@ -218,6 +229,15 @@ const handleUserMenuAction = async (path: string) => {
218
229
  box-shadow: 0 8px 18px rgb(220 38 38 / 14%);
219
230
  }
220
231
  }
232
+ &--lock {
233
+ color: var(--el-color-warning-dark-2);
234
+ background: var(--el-color-warning-light-9);
235
+ &:hover {
236
+ color: var(--el-color-warning-dark-2);
237
+ background: var(--el-color-warning-light-8);
238
+ box-shadow: 0 8px 18px rgb(230 162 60 / 14%);
239
+ }
240
+ }
221
241
  }
222
242
  :deep(.header-avatar-dropdown) {
223
243
  padding: 0;
@@ -1,17 +1,18 @@
1
1
  <template>
2
- <el-dialog v-model="dialogVisible" :title="t('core.layout.info')" width="500px" draggable>
3
- <span>This is userInfo</span>
2
+ <ProDialog v-model="dialogVisible" :title="t('core.layout.info')" width="500px" draggable>
3
+ <span>{{ t("core.layout.info_content") }}</span>
4
4
  <template #footer>
5
5
  <span class="dialog-footer">
6
6
  <el-button @click="dialogVisible = false">{{ t("common.action.cancel") }}</el-button>
7
7
  <el-button type="primary" @click="dialogVisible = false">{{ t("common.action.confirm") }}</el-button>
8
8
  </span>
9
9
  </template>
10
- </el-dialog>
10
+ </ProDialog>
11
11
  </template>
12
12
 
13
13
  <script setup lang="ts">
14
14
  import { useLocaleStore } from "../../../../locales";
15
+ import ProDialog from "../../../../components/Dialog/ProDialog.vue";
15
16
 
16
17
  const { t } = useLocaleStore();
17
18
  import { ref } from "vue";
@@ -1,17 +1,18 @@
1
1
  <template>
2
- <el-dialog v-model="dialogVisible" :title="t('core.layout.password_change')" width="500px" draggable>
3
- <span>This is Password</span>
2
+ <ProDialog v-model="dialogVisible" :title="t('core.layout.password_change')" width="500px" draggable>
3
+ <span>{{ t("core.layout.password_content") }}</span>
4
4
  <template #footer>
5
5
  <span class="dialog-footer">
6
6
  <el-button @click="dialogVisible = false">{{ t("common.action.cancel") }}</el-button>
7
7
  <el-button type="primary" @click="dialogVisible = false">{{ t("common.action.confirm") }}</el-button>
8
8
  </span>
9
9
  </template>
10
- </el-dialog>
10
+ </ProDialog>
11
11
  </template>
12
12
 
13
13
  <script setup lang="ts">
14
14
  import { useLocaleStore } from "../../../../locales";
15
+ import ProDialog from "../../../../components/Dialog/ProDialog.vue";
15
16
 
16
17
  const { t } = useLocaleStore();
17
18
  import { ref } from "vue";
@@ -3,7 +3,14 @@
3
3
  <el-tooltip effect="dark" :content="t('core.header.menu_search')" placement="bottom" :show-after="200">
4
4
  <i :class="'iconfont icon-sousuo'" class="toolBar-icon" @click="handleOpen"></i>
5
5
  </el-tooltip>
6
- <el-dialog class="search-dialog" v-model="isShowSearch" :width="600" :show-close="false" top="10vh">
6
+ <ProDialog
7
+ class="search-dialog"
8
+ v-model="isShowSearch"
9
+ :width="600"
10
+ :show-close="false"
11
+ :show-footer="false"
12
+ top="10vh"
13
+ >
7
14
  <el-input
8
15
  v-model="searchMenu"
9
16
  ref="menuInputRef"
@@ -30,7 +37,7 @@
30
37
  </div>
31
38
  </div>
32
39
  <el-empty v-else class="mt20 mb20" :image-size="100" :description="t('core.header.menu_search_empty')" />
33
- </el-dialog>
40
+ </ProDialog>
34
41
  </div>
35
42
  </template>
36
43
 
@@ -44,6 +51,7 @@ import { useDebounceFn } from "@vueuse/core";
44
51
  import type { RouteItem } from "../../../../rpc/system/admin/v1/auth";
45
52
  import { getRouteMetaHidden, getRouteMetaIcon, getRouteMetaTitle, getRouteTarget, isExternalPath } from "../../../../utils";
46
53
  import { useLocaleStore } from "../../../../locales";
54
+ import ProDialog from "../../../../components/Dialog/ProDialog.vue";
47
55
 
48
56
  /** 可被菜单搜索展示的路由项。 */
49
57
  interface SearchRouteItem extends RouteItem {
@@ -152,11 +160,11 @@ const handleClickMenu = () => {
152
160
 
153
161
  <style scoped lang="scss">
154
162
  .search-menu {
155
- :deep(.el-dialog) {
156
- border-radius: 4px;
157
- .el-dialog__header {
158
- display: none;
159
- }
163
+ :global(.search-dialog) {
164
+ border-radius: var(--admin-page-radius);
165
+ }
166
+ :global(.search-dialog .el-dialog__header) {
167
+ display: none;
160
168
  }
161
169
  .menu-list {
162
170
  max-height: 515px;
@@ -174,7 +182,7 @@ const handleClickMenu = () => {
174
182
  cursor: pointer;
175
183
  background-color: transparent;
176
184
  border: 1px solid var(--el-border-color);
177
- border-radius: 6px;
185
+ border-radius: var(--admin-page-radius);
178
186
  transition: all 0.2s ease;
179
187
  .menu-lf {
180
188
  display: flex;