Feature: add support for dogeCloud manage

ISSUES CLOSED: #73
This commit is contained in:
萌萌哒赫萝
2023-08-21 08:53:01 -07:00
parent 10da6a92d1
commit 3040f4bfbb
8 changed files with 87 additions and 17 deletions

View File

@@ -790,6 +790,7 @@ async function transUpToManage (config: IUploaderConfigListItem, picBedName: str
sslEnabled: config.endpoint ? config.endpoint.startsWith('https') : false,
aclForUpload: 'public-read',
s3ForcePathStyle: config.pathStyleAccess,
dogeCloudSupport: false,
transformedConfig: JSON.stringify(
config.urlPrefix
? {

View File

@@ -642,6 +642,13 @@ export const supportedPicBedList: IStringKeyMap = {
default: '/',
tooltip: baseDirTooltip
},
dogeCloudSupport: {
required: false,
description: $T('MANAGE_CONSTANT_S3_DOGE_CLOUD_SUPPORT_DESC'),
default: false,
type: 'boolean',
tooltip: $T('MANAGE_CONSTANT_S3_DOGE_CLOUD_SUPPORT_TOOLTIP')
},
paging: {
required: true,
description: $T('MANAGE_CONSTANT_S3_PAGING_DESC'),
@@ -659,7 +666,7 @@ export const supportedPicBedList: IStringKeyMap = {
}
},
explain: $T('MANAGE_CONSTANT_S3_EXPLAIN'),
options: ['alias', 'accessKeyId', 'secretAccessKey', 'endpoint', 'sslEnabled', 's3ForcePathStyle', 'proxy', 'aclForUpload', 'bucketName', 'baseDir', 'paging', 'itemsPerPage'],
options: ['alias', 'accessKeyId', 'secretAccessKey', 'endpoint', 'sslEnabled', 's3ForcePathStyle', 'proxy', 'aclForUpload', 'bucketName', 'baseDir', 'dogeCloudSupport', 'paging', 'itemsPerPage'],
refLink: 'https://github.com/wayjam/picgo-plugin-s3',
referenceText: $T('MANAGE_CONSTANT_S3_REFER_TEXT')
},