refactor(创建模板): 优化文件选择界面布局和交互
移除冗余的文件选择按钮,将文件路径选择整合到文本输入框中 调整容器间距和最大宽度限制 删除已显示在输入框中的选中路径展示区域
This commit is contained in:
1 parent
703b5a1040
commit
f2d88bb3d1
2 files changed
+15
-22
No files matched your search
@@ -229,6 +229,6 @@ Building creates different distribution formats based on the platform:
|
|||||||
|
|
||||||
Artifacts are named with the format `${productName} ${version}_${arch}.${ext}` and stored in the `release/${version}` directory.
|
Artifacts are named with the format `${productName} ${version}_${arch}.${ext}` and stored in the `release/${version}` directory.
|
||||||
|
|
||||||
run `pnpm typecheck` before finish the task if need,don't run `pnpm dev`.
|
run `pnpm typecheck` before finish the task if need,don't run `pnpm dev` or `pnpm build`.
|
||||||
|
|
||||||
Always respond in 中文
|
Always respond in 中文
|
||||||
@@ -1,7 +1,8 @@
|
|||||||
<template>
|
<template>
|
||||||
<v-container
|
<v-container
|
||||||
fluid
|
fluid
|
||||||
class="pa-0 fill-height"
|
class="pa-4 fill-height"
|
||||||
|
style="max-width: 1200px;"
|
||||||
>
|
>
|
||||||
<v-row class="fill-height">
|
<v-row class="fill-height">
|
||||||
<!-- Left Panel - Template Info -->
|
<!-- Left Panel - Template Info -->
|
||||||
@@ -207,20 +208,20 @@
|
|||||||
required
|
required
|
||||||
density="comfortable"
|
density="comfortable"
|
||||||
ref="fileInputRef"
|
ref="fileInputRef"
|
||||||
@keydown.enter="selectAndAddFile"
|
|
||||||
/>
|
/>
|
||||||
<v-file-input webkitdirectory directory label="选择文件或文件夹" density="comfortable"></v-file-input>
|
|
||||||
|
|
||||||
<div class="d-flex align-center my-4">
|
<!-- 文件路径选择输入框 -->
|
||||||
<v-btn
|
<v-text-field
|
||||||
@click="selectSourceFileOrFolder"
|
v-model="selectedSourcePath"
|
||||||
variant="outlined"
|
label="文件或文件夹"
|
||||||
class="mr-2"
|
placeholder="点击输入框选择文件或文件夹"
|
||||||
:disabled="!!currentEditingItem"
|
readonly
|
||||||
>
|
:rules="currentEditingItem ? [] : [requiredRule('文件或文件夹')]"
|
||||||
选择文件或文件夹
|
:append-inner-icon="isAutoFindMode ? 'mdi-folder' : 'mdi-file'"
|
||||||
</v-btn>
|
density="comfortable"
|
||||||
</div>
|
class="mt-4"
|
||||||
|
@click="selectSourceFileOrFolder()"
|
||||||
|
/>
|
||||||
|
|
||||||
<!-- 选择提示 -->
|
<!-- 选择提示 -->
|
||||||
<v-alert
|
<v-alert
|
||||||
@@ -233,14 +234,6 @@
|
|||||||
<span>选择文件夹则会自动匹配该文件夹下的文件进行复制并且重命名</span>
|
<span>选择文件夹则会自动匹配该文件夹下的文件进行复制并且重命名</span>
|
||||||
</div>
|
</div>
|
||||||
</v-alert>
|
</v-alert>
|
||||||
|
|
||||||
<!-- Display selected source -->
|
|
||||||
<div v-if="selectedSourcePath" class="d-flex align-center">
|
|
||||||
<v-icon :color="isAutoFindMode ? 'warning' : 'info'" class="mr-2">
|
|
||||||
{{ isAutoFindMode ? 'mdi-folder' : 'mdi-file' }}
|
|
||||||
</v-icon>
|
|
||||||
<span class="text-truncate">{{ selectedSourcePath }}</span>
|
|
||||||
</div>
|
|
||||||
</v-form>
|
</v-form>
|
||||||
</v-card-text>
|
</v-card-text>
|
||||||
<v-card-actions>
|
<v-card-actions>
|
||||||
|
|||||||
Reference in new issue
Block a user