mirror of
https://gitee.com/dapppp/ruoyi-plus-vben5.git
synced 2026-03-20 05:55:36 +08:00
refactor(icons): 迁移部分图标到 @ant-design/icons-vue 并移除未使用的离线图标
移除 @vben/icons 中的 UserOutlined、InBoxIcon、ExcelIcon 等图标,改用 @ant-design/icons-vue 提供的对应组件。 删除 packages/icons 中未使用的离线图标定义,包括 TaobaoIcon、AlipayIcon、GithubOAuthIcon 等。 在 apps/web-antd/src/views/_core/ 新增 oauth-common.tsx 文件,集中管理 OAuth 绑定相关逻辑与数据。
This commit is contained in:
@@ -10,7 +10,6 @@ import {
|
||||
CircleHelp,
|
||||
GiteeIcon,
|
||||
GitHubOutlined,
|
||||
UserOutlined,
|
||||
} from '@vben/icons';
|
||||
import {
|
||||
BasicLayout,
|
||||
@@ -22,6 +21,8 @@ import { preferences } from '@vben/preferences';
|
||||
import { useAccessStore, useUserStore } from '@vben/stores';
|
||||
import { openWindow } from '@vben/utils';
|
||||
|
||||
import { UserOutlined } from '@ant-design/icons-vue';
|
||||
|
||||
import { TenantToggle } from '#/components/tenant-toggle';
|
||||
import { $t } from '#/locales';
|
||||
import { resetRoutes } from '#/router';
|
||||
|
||||
@@ -1,15 +1,10 @@
|
||||
import type { Component, CSSProperties } from 'vue';
|
||||
|
||||
import { markRaw, ref } from 'vue';
|
||||
import { ref } from 'vue';
|
||||
|
||||
import { DEFAULT_TENANT_ID } from '@vben/constants';
|
||||
import {
|
||||
GiteeIcon,
|
||||
GithubOAuthIcon,
|
||||
SvgMaxKeyIcon,
|
||||
SvgTopiamIcon,
|
||||
SvgWechatIcon,
|
||||
} from '@vben/icons';
|
||||
import { VbenIcon } from '@vben/icons';
|
||||
import { cn } from '@vben/utils';
|
||||
|
||||
import { createGlobalState } from '@vueuse/core';
|
||||
|
||||
@@ -69,32 +64,38 @@ export async function handleAuthBinding(source: string) {
|
||||
*/
|
||||
export const accountBindList: BindItem[] = [
|
||||
{
|
||||
avatar: markRaw(GiteeIcon),
|
||||
avatar: (
|
||||
<span
|
||||
class={cn('icon-[simple-icons--gitee]', 'size-6')}
|
||||
style={{ color: '#c71d23' }}
|
||||
/>
|
||||
),
|
||||
description: '绑定Gitee账号',
|
||||
source: 'gitee',
|
||||
title: 'Gitee',
|
||||
style: { color: '#c71d23' },
|
||||
},
|
||||
{
|
||||
avatar: markRaw(GithubOAuthIcon),
|
||||
avatar: (
|
||||
<span class={cn('icon-[fa--github-alt]', 'text-[#333]', 'size-6')} />
|
||||
),
|
||||
description: '绑定Github账号',
|
||||
source: 'github',
|
||||
title: 'Github',
|
||||
},
|
||||
{
|
||||
avatar: markRaw(SvgMaxKeyIcon),
|
||||
avatar: <VbenIcon icon={'svg:max-key'} />,
|
||||
description: '绑定MaxKey账号',
|
||||
source: 'maxkey',
|
||||
title: 'MaxKey',
|
||||
},
|
||||
{
|
||||
avatar: markRaw(SvgTopiamIcon),
|
||||
avatar: <VbenIcon icon={'svg:topiam'} />,
|
||||
description: '绑定topiam账号',
|
||||
source: 'topiam',
|
||||
title: 'Topiam',
|
||||
},
|
||||
{
|
||||
avatar: markRaw(SvgWechatIcon),
|
||||
avatar: <VbenIcon icon={'svg:wechat'} />,
|
||||
description: '绑定wechat账号',
|
||||
source: 'wechat',
|
||||
title: 'Wechat',
|
||||
@@ -4,8 +4,8 @@ import type { UploadFile } from 'antdv-next';
|
||||
import { h, ref, unref } from 'vue';
|
||||
|
||||
import { useVbenModal } from '@vben/common-ui';
|
||||
import { ExcelIcon, InBoxIcon } from '@vben/icons';
|
||||
|
||||
import { InboxOutlined } from '@ant-design/icons-vue';
|
||||
import { Switch, Upload } from 'antdv-next';
|
||||
|
||||
import { downloadImportTemplate, userImportData } from '#/api/system/user';
|
||||
@@ -80,7 +80,7 @@ function handleCancel() {
|
||||
accept="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet, application/vnd.ms-excel"
|
||||
>
|
||||
<p class="ant-upload-drag-icon flex items-center justify-center">
|
||||
<InBoxIcon class="size-[48px] text-primary" />
|
||||
<InboxOutlined class="size-[48px] text-primary" />
|
||||
</p>
|
||||
<p class="ant-upload-text">点击或者拖拽到此处上传文件</p>
|
||||
</UploadDragger>
|
||||
@@ -92,7 +92,7 @@ function handleCancel() {
|
||||
@click="commonDownloadExcel(downloadImportTemplate, '用户导入模板')"
|
||||
>
|
||||
<div class="flex items-center gap-[4px]">
|
||||
<ExcelIcon />
|
||||
<span class="icon-[vscode-icons--file-type-excel]"></span>
|
||||
<span>下载模板</span>
|
||||
</div>
|
||||
</a-button>
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
<script setup lang="ts">
|
||||
import type { UploadFile } from 'antdv-next/es/upload/interface';
|
||||
import type { UploadFile } from 'antdv-next';
|
||||
|
||||
import { ref } from 'vue';
|
||||
|
||||
import { useVbenModal } from '@vben/common-ui';
|
||||
import { InBoxIcon } from '@vben/icons';
|
||||
|
||||
import { InboxOutlined } from '@ant-design/icons-vue';
|
||||
import { Upload } from 'antdv-next';
|
||||
|
||||
import { workflowDefinitionImport } from '#/api/workflow/definition';
|
||||
@@ -65,7 +65,7 @@ function handleCancel() {
|
||||
accept="application/json"
|
||||
>
|
||||
<p class="ant-upload-drag-icon flex items-center justify-center">
|
||||
<InBoxIcon class="text-primary size-[48px]" />
|
||||
<InboxOutlined class="size-[48px] text-primary" />
|
||||
</p>
|
||||
<p class="ant-upload-text">点击或者拖拽到此处上传[json]文件</p>
|
||||
</UploadDragger>
|
||||
|
||||
Reference in New Issue
Block a user