feat(ui): 简化文件上传按钮,移除下拉菜单,直接调用上传功能
This commit is contained in:
parent
d7b6b6ca64
commit
42aa4f4771
@ -2,38 +2,15 @@
|
|||||||
<div class="file-table-container">
|
<div class="file-table-container">
|
||||||
<div class="panel-header">
|
<div class="panel-header">
|
||||||
<div class="upload-btn-group">
|
<div class="upload-btn-group">
|
||||||
<a-dropdown trigger="click">
|
<a-button
|
||||||
<a-button type="primary" size="small" class="upload-btn">
|
type="primary"
|
||||||
<FileUp size="14" style="margin-left: 4px" />
|
size="small"
|
||||||
上传
|
class="upload-btn"
|
||||||
<ChevronDown size="14" style="margin-left: 4px" />
|
@click="showAddFilesModal()"
|
||||||
</a-button>
|
>
|
||||||
<template #overlay>
|
<FileUp size="14" />
|
||||||
<a-menu>
|
上传
|
||||||
<a-menu-item
|
</a-button>
|
||||||
key="upload-file"
|
|
||||||
@click="showAddFilesModal({ isFolder: false })"
|
|
||||||
:icon="h(FileUp, { size: 16 })"
|
|
||||||
>
|
|
||||||
上传文件
|
|
||||||
</a-menu-item>
|
|
||||||
<a-menu-item
|
|
||||||
key="upload-folder"
|
|
||||||
@click="showAddFilesModal({ isFolder: true })"
|
|
||||||
:icon="h(FolderUp, { size: 16 })"
|
|
||||||
>
|
|
||||||
上传文件夹
|
|
||||||
</a-menu-item>
|
|
||||||
<a-menu-item
|
|
||||||
key="upload-url"
|
|
||||||
@click="showAddFilesModal({ mode: 'url' })"
|
|
||||||
:icon="h(Link, { size: 16 })"
|
|
||||||
>
|
|
||||||
解析 URL
|
|
||||||
</a-menu-item>
|
|
||||||
</a-menu>
|
|
||||||
</template>
|
|
||||||
</a-dropdown>
|
|
||||||
|
|
||||||
<a-button
|
<a-button
|
||||||
class="panel-action-btn"
|
class="panel-action-btn"
|
||||||
@ -452,12 +429,9 @@ import {
|
|||||||
Plus,
|
Plus,
|
||||||
Database,
|
Database,
|
||||||
FileUp,
|
FileUp,
|
||||||
FolderUp,
|
|
||||||
Search,
|
Search,
|
||||||
Filter,
|
Filter,
|
||||||
ArrowUpDown,
|
ArrowUpDown
|
||||||
ChevronDown,
|
|
||||||
Link
|
|
||||||
} from 'lucide-vue-next'
|
} from 'lucide-vue-next'
|
||||||
|
|
||||||
const store = useDatabaseStore()
|
const store = useDatabaseStore()
|
||||||
@ -1544,6 +1518,7 @@ import ChunkParamsConfig from '@/components/ChunkParamsConfig.vue'
|
|||||||
height: 28px;
|
height: 28px;
|
||||||
font-size: 13px;
|
font-size: 13px;
|
||||||
display: flex;
|
display: flex;
|
||||||
|
padding: 0 12px;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
gap: 4px;
|
gap: 4px;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user