mirror of
https://github.com/Kuingsmile/PicList.git
synced 2025-01-23 14:48:13 -05:00
✨ Feature: optimize title text jump action of upload page
This commit is contained in:
parent
079b0345ec
commit
dfb6f767d2
@ -53,7 +53,7 @@
|
|||||||
"cos-nodejs-sdk-v5": "^2.12.4",
|
"cos-nodejs-sdk-v5": "^2.12.4",
|
||||||
"dexie": "^3.2.4",
|
"dexie": "^3.2.4",
|
||||||
"electron-updater": "^6.1.4",
|
"electron-updater": "^6.1.4",
|
||||||
"element-plus": "^2.3.9",
|
"element-plus": "2.3.12",
|
||||||
"epipebomb": "^1.0.0",
|
"epipebomb": "^1.0.0",
|
||||||
"fast-xml-parser": "^4.2.7",
|
"fast-xml-parser": "^4.2.7",
|
||||||
"form-data": "^4.0.0",
|
"form-data": "^4.0.0",
|
||||||
|
@ -502,11 +502,8 @@ const isShowBatchRenameDialog = ref(false)
|
|||||||
const batchRenameMatch = ref('')
|
const batchRenameMatch = ref('')
|
||||||
const batchRenameReplace = ref('')
|
const batchRenameReplace = ref('')
|
||||||
const mathcedCount = computed(() => {
|
const mathcedCount = computed(() => {
|
||||||
const matchedFiles = [] as any[]
|
const matchedFiles = filterList.value.filter((item: any) => {
|
||||||
filterList.value.forEach((item: any) => {
|
return customStrMatch(item.imgUrl, batchRenameMatch.value)
|
||||||
if (customStrMatch(item.imgUrl, batchRenameMatch.value)) {
|
|
||||||
matchedFiles.push(item)
|
|
||||||
}
|
|
||||||
})
|
})
|
||||||
return matchedFiles.length
|
return matchedFiles.length
|
||||||
})
|
})
|
||||||
|
@ -1248,7 +1248,7 @@
|
|||||||
>
|
>
|
||||||
<el-radio-group v-model="waterMarkForm.watermarkType">
|
<el-radio-group v-model="waterMarkForm.watermarkType">
|
||||||
<el-radio label="text">
|
<el-radio label="text">
|
||||||
{{ $T('UPLOAD_PAGE_IMAGE_PROCESS_WMTYPE_TEXT') }}}
|
{{ $T('UPLOAD_PAGE_IMAGE_PROCESS_WMTYPE_TEXT') }}
|
||||||
</el-radio>
|
</el-radio>
|
||||||
<el-radio label="image">
|
<el-radio label="image">
|
||||||
{{ $T('UPLOAD_PAGE_IMAGE_PROCESS_WMTYPE_IMAGE') }}
|
{{ $T('UPLOAD_PAGE_IMAGE_PROCESS_WMTYPE_IMAGE') }}
|
||||||
|
@ -17,7 +17,7 @@
|
|||||||
id="upload-view-title"
|
id="upload-view-title"
|
||||||
@click="handlePicBedNameClick(picBedName, picBedConfigName)"
|
@click="handlePicBedNameClick(picBedName, picBedConfigName)"
|
||||||
>
|
>
|
||||||
{{ picBedName }} - {{ picBedConfigName }}
|
{{ picBedName }} - {{ picBedConfigName || 'Default' }}
|
||||||
</span>
|
</span>
|
||||||
</el-tooltip>
|
</el-tooltip>
|
||||||
<el-icon
|
<el-icon
|
||||||
@ -449,7 +449,7 @@ import {
|
|||||||
import { ElMessage as $message } from 'element-plus'
|
import { ElMessage as $message } from 'element-plus'
|
||||||
|
|
||||||
// 数据发送工具函数
|
// 数据发送工具函数
|
||||||
import { getConfig, saveConfig, sendToMain } from '@/utils/dataSender'
|
import { getConfig, saveConfig, sendToMain, triggerRPC } from '@/utils/dataSender'
|
||||||
|
|
||||||
// 类型声明
|
// 类型声明
|
||||||
import { IBuildInCompressOptions, IBuildInWaterMarkOptions } from 'piclist'
|
import { IBuildInCompressOptions, IBuildInWaterMarkOptions } from 'piclist'
|
||||||
@ -459,6 +459,7 @@ import { useRouter } from 'vue-router'
|
|||||||
|
|
||||||
// 路由配置常量
|
// 路由配置常量
|
||||||
import { PICBEDS_PAGE } from '@/router/config'
|
import { PICBEDS_PAGE } from '@/router/config'
|
||||||
|
import { IRPCActionType } from '~/universal/types/enum'
|
||||||
|
|
||||||
const $router = useRouter()
|
const $router = useRouter()
|
||||||
|
|
||||||
@ -602,16 +603,18 @@ function onProgressChange (val: number) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
async function handlePicBedNameClick (picBedName: string, picBedConfigName: string) {
|
async function handlePicBedNameClick (_picBedName: string, picBedConfigName: string | undefined) {
|
||||||
|
const formatedpicBedConfigName = picBedConfigName || 'Default'
|
||||||
const currentPicBed = await getConfig<string>('picBed.current')
|
const currentPicBed = await getConfig<string>('picBed.current')
|
||||||
const currentPicBedConfig = await getConfig<any[]>(`uploader.${currentPicBed}`) as any || {}
|
const currentPicBedConfig = await getConfig<any[]>(`uploader.${currentPicBed}`) as any || {}
|
||||||
const configList = currentPicBedConfig.configList || []
|
const configList = await triggerRPC<IUploaderConfigItem>(IRPCActionType.GET_PICBED_CONFIG_LIST, currentPicBed)
|
||||||
const config = configList.find((item: any) => item._configName === picBedConfigName)
|
const currentConfigList = configList?.configList ?? []
|
||||||
|
const config = currentConfigList.find((item: any) => item._configName === formatedpicBedConfigName)
|
||||||
$router.push({
|
$router.push({
|
||||||
name: PICBEDS_PAGE,
|
name: PICBEDS_PAGE,
|
||||||
params: {
|
params: {
|
||||||
type: currentPicBed,
|
type: currentPicBed,
|
||||||
configId: config._id
|
configId: config?._id || ''
|
||||||
},
|
},
|
||||||
query: {
|
query: {
|
||||||
defaultConfigId: currentPicBedConfig.defaultId || ''
|
defaultConfigId: currentPicBedConfig.defaultId || ''
|
||||||
|
@ -7440,10 +7440,10 @@ electron@^22.0.2:
|
|||||||
"@types/node" "^16.11.26"
|
"@types/node" "^16.11.26"
|
||||||
extract-zip "^2.0.1"
|
extract-zip "^2.0.1"
|
||||||
|
|
||||||
element-plus@^2.3.9:
|
element-plus@2.3.12:
|
||||||
version "2.3.9"
|
version "2.3.12"
|
||||||
resolved "https://registry.npmjs.org/element-plus/-/element-plus-2.3.9.tgz#4a3363c62e6cc9b0a2f40f4df5aaa7b6feb4e6e4"
|
resolved "https://registry.npmjs.org/element-plus/-/element-plus-2.3.12.tgz#d3c91d0c701b2b3e67d06a351cb0c42dcc46460e"
|
||||||
integrity sha512-TIOLnPl4cnoCPXqK3QYh+jpkthUBQnAM21O7o3Lhbse8v9pfrRXRTaBJtoEKnYNa8GZ4lZptUfH0PeZgDCNLUg==
|
integrity sha512-fAWpbKCyt+l1dsqSNPOs/F/dBN4Wp5CGAyxbiS5zqDwI4q3QPM+LxLU2h3GUHMIBtMGCvmsG98j5HPMkTKkvcA==
|
||||||
dependencies:
|
dependencies:
|
||||||
"@ctrl/tinycolor" "^3.4.1"
|
"@ctrl/tinycolor" "^3.4.1"
|
||||||
"@element-plus/icons-vue" "^2.0.6"
|
"@element-plus/icons-vue" "^2.0.6"
|
||||||
|
Loading…
Reference in New Issue
Block a user