@nocobase/plugin-file-manager 1.2.13-alpha → 1.3.0-alpha.20240710084543
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +2 -2
- package/dist/client/FileManagerProvider.d.ts +0 -10
- package/dist/client/FileSizeField.d.ts +0 -10
- package/dist/client/FileStorage.d.ts +0 -12
- package/dist/client/StorageOptions.d.ts +0 -10
- package/dist/client/hooks/index.d.ts +0 -10
- package/dist/client/hooks/useStorageRules.d.ts +0 -14
- package/dist/client/hooks/useUploadFiles.d.ts +0 -13
- package/dist/client/index.d.ts +0 -15
- package/dist/client/index.js +0 -10
- package/dist/client/initializers/UploadActionInitializer.d.ts +0 -10
- package/dist/client/initializers/index.d.ts +0 -9
- package/dist/client/interfaces/attachment.d.ts +0 -113
- package/dist/client/locale/index.d.ts +0 -10
- package/dist/client/schemas/storage.d.ts +0 -10
- package/dist/client/schemas/storageTypes/ali-oss.d.ts +0 -117
- package/dist/client/schemas/storageTypes/common.d.ts +0 -68
- package/dist/client/schemas/storageTypes/index.d.ts +0 -398
- package/dist/client/schemas/storageTypes/local.d.ts +0 -89
- package/dist/client/schemas/storageTypes/s3.d.ts +0 -112
- package/dist/client/schemas/storageTypes/tx-cos.d.ts +0 -106
- package/dist/client/templates/file.d.ts +0 -142
- package/dist/client/templates/index.d.ts +0 -9
- package/dist/constants.d.ts +0 -17
- package/dist/constants.js +0 -60
- package/dist/externalVersion.js +0 -27
- package/dist/index.d.ts +0 -10
- package/dist/index.js +0 -48
- package/dist/locale/en-US.json +0 -22
- package/dist/locale/fr-FR.json +0 -21
- package/dist/locale/ja-JP.json +0 -18
- package/dist/locale/ko_KR.json +0 -32
- package/dist/locale/ru-RU.json +0 -18
- package/dist/locale/tr-TR.json +0 -17
- package/dist/locale/zh-CN.json +0 -40
- package/dist/node_modules/@aws-sdk/client-s3/LICENSE +0 -201
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/S3.js +0 -201
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/S3Client.js +0 -53
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/AbortMultipartUploadCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/CompleteMultipartUploadCommand.js +0 -64
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/CopyObjectCommand.js +0 -63
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/CreateBucketCommand.js +0 -62
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/CreateMultipartUploadCommand.js +0 -62
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/CreateSessionCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/DeleteBucketAnalyticsConfigurationCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/DeleteBucketCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/DeleteBucketCorsCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/DeleteBucketEncryptionCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/DeleteBucketIntelligentTieringConfigurationCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/DeleteBucketInventoryConfigurationCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/DeleteBucketLifecycleCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/DeleteBucketMetricsConfigurationCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/DeleteBucketOwnershipControlsCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/DeleteBucketPolicyCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/DeleteBucketReplicationCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/DeleteBucketTaggingCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/DeleteBucketWebsiteCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/DeleteObjectCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/DeleteObjectTaggingCommand.js +0 -58
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/DeleteObjectsCommand.js +0 -64
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/DeletePublicAccessBlockCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetBucketAccelerateConfigurationCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetBucketAclCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetBucketAnalyticsConfigurationCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetBucketCorsCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetBucketEncryptionCommand.js +0 -60
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetBucketIntelligentTieringConfigurationCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetBucketInventoryConfigurationCommand.js +0 -60
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetBucketLifecycleConfigurationCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetBucketLocationCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetBucketLoggingCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetBucketMetricsConfigurationCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetBucketNotificationConfigurationCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetBucketOwnershipControlsCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetBucketPolicyCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetBucketPolicyStatusCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetBucketReplicationCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetBucketRequestPaymentCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetBucketTaggingCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetBucketVersioningCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetBucketWebsiteCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetObjectAclCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetObjectAttributesCommand.js +0 -61
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetObjectCommand.js +0 -69
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetObjectLegalHoldCommand.js +0 -58
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetObjectLockConfigurationCommand.js +0 -58
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetObjectRetentionCommand.js +0 -58
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetObjectTaggingCommand.js +0 -58
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetObjectTorrentCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/GetPublicAccessBlockCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/HeadBucketCommand.js +0 -58
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/HeadObjectCommand.js +0 -62
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/ListBucketAnalyticsConfigurationsCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/ListBucketIntelligentTieringConfigurationsCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/ListBucketInventoryConfigurationsCommand.js +0 -60
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/ListBucketMetricsConfigurationsCommand.js +0 -58
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/ListBucketsCommand.js +0 -57
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/ListDirectoryBucketsCommand.js +0 -58
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/ListMultipartUploadsCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/ListObjectVersionsCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/ListObjectsCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/ListObjectsV2Command.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/ListPartsCommand.js +0 -62
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/PutBucketAccelerateConfigurationCommand.js +0 -65
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/PutBucketAclCommand.js +0 -65
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/PutBucketAnalyticsConfigurationCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/PutBucketCorsCommand.js +0 -65
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/PutBucketEncryptionCommand.js +0 -66
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/PutBucketIntelligentTieringConfigurationCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/PutBucketInventoryConfigurationCommand.js +0 -60
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/PutBucketLifecycleConfigurationCommand.js +0 -65
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/PutBucketLoggingCommand.js +0 -65
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/PutBucketMetricsConfigurationCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/PutBucketNotificationConfigurationCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/PutBucketOwnershipControlsCommand.js +0 -61
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/PutBucketPolicyCommand.js +0 -65
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/PutBucketReplicationCommand.js +0 -65
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/PutBucketRequestPaymentCommand.js +0 -65
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/PutBucketTaggingCommand.js +0 -65
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/PutBucketVersioningCommand.js +0 -65
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/PutBucketWebsiteCommand.js +0 -65
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/PutObjectAclCommand.js +0 -65
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/PutObjectCommand.js +0 -70
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/PutObjectLegalHoldCommand.js +0 -64
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/PutObjectLockConfigurationCommand.js +0 -64
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/PutObjectRetentionCommand.js +0 -64
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/PutObjectTaggingCommand.js +0 -64
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/PutPublicAccessBlockCommand.js +0 -65
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/RestoreObjectCommand.js +0 -65
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/SelectObjectContentCommand.js +0 -64
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/UploadPartCommand.js +0 -68
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/UploadPartCopyCommand.js +0 -63
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/WriteGetObjectResponseCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/commands/index.js +0 -98
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/endpoint/EndpointParameters.js +0 -16
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/endpoint/endpointResolver.js +0 -12
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/endpoint/ruleset.js +0 -7
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/extensionConfiguration.js +0 -2
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/index.js +0 -31
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/models/S3ServiceException.js +0 -12
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/models/index.js +0 -5
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/models/models_0.js +0 -647
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/models/models_1.js +0 -156
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/pagination/Interfaces.js +0 -2
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/pagination/ListDirectoryBucketsPaginator.js +0 -29
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/pagination/ListObjectsV2Paginator.js +0 -29
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/pagination/ListPartsPaginator.js +0 -29
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/pagination/index.js +0 -7
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/protocols/Aws_restXml.js +0 -9820
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/runtimeConfig.browser.js +0 -47
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/runtimeConfig.js +0 -60
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/runtimeConfig.native.js +0 -15
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/runtimeConfig.shared.js +0 -31
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/runtimeExtensions.js +0 -22
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/waiters/index.js +0 -7
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/waiters/waitForBucketExists.js +0 -31
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/waiters/waitForBucketNotExists.js +0 -30
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/waiters/waitForObjectExists.js +0 -31
- package/dist/node_modules/@aws-sdk/client-s3/dist-cjs/waiters/waitForObjectNotExists.js +0 -30
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/S3.js +0 -197
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/S3Client.js +0 -49
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/AbortMultipartUploadCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/CompleteMultipartUploadCommand.js +0 -60
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/CopyObjectCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/CreateBucketCommand.js +0 -58
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/CreateMultipartUploadCommand.js +0 -58
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/CreateSessionCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/DeleteBucketAnalyticsConfigurationCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/DeleteBucketCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/DeleteBucketCorsCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/DeleteBucketEncryptionCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/DeleteBucketIntelligentTieringConfigurationCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/DeleteBucketInventoryConfigurationCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/DeleteBucketLifecycleCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/DeleteBucketMetricsConfigurationCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/DeleteBucketOwnershipControlsCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/DeleteBucketPolicyCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/DeleteBucketReplicationCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/DeleteBucketTaggingCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/DeleteBucketWebsiteCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/DeleteObjectCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/DeleteObjectTaggingCommand.js +0 -54
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/DeleteObjectsCommand.js +0 -60
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/DeletePublicAccessBlockCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetBucketAccelerateConfigurationCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetBucketAclCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetBucketAnalyticsConfigurationCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetBucketCorsCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetBucketEncryptionCommand.js +0 -56
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetBucketIntelligentTieringConfigurationCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetBucketInventoryConfigurationCommand.js +0 -56
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetBucketLifecycleConfigurationCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetBucketLocationCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetBucketLoggingCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetBucketMetricsConfigurationCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetBucketNotificationConfigurationCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetBucketOwnershipControlsCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetBucketPolicyCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetBucketPolicyStatusCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetBucketReplicationCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetBucketRequestPaymentCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetBucketTaggingCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetBucketVersioningCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetBucketWebsiteCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetObjectAclCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetObjectAttributesCommand.js +0 -57
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetObjectCommand.js +0 -65
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetObjectLegalHoldCommand.js +0 -54
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetObjectLockConfigurationCommand.js +0 -54
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetObjectRetentionCommand.js +0 -54
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetObjectTaggingCommand.js +0 -54
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetObjectTorrentCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/GetPublicAccessBlockCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/HeadBucketCommand.js +0 -54
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/HeadObjectCommand.js +0 -58
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/ListBucketAnalyticsConfigurationsCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/ListBucketIntelligentTieringConfigurationsCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/ListBucketInventoryConfigurationsCommand.js +0 -56
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/ListBucketMetricsConfigurationsCommand.js +0 -54
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/ListBucketsCommand.js +0 -53
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/ListDirectoryBucketsCommand.js +0 -54
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/ListMultipartUploadsCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/ListObjectVersionsCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/ListObjectsCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/ListObjectsV2Command.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/ListPartsCommand.js +0 -58
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/PutBucketAccelerateConfigurationCommand.js +0 -61
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/PutBucketAclCommand.js +0 -61
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/PutBucketAnalyticsConfigurationCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/PutBucketCorsCommand.js +0 -61
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/PutBucketEncryptionCommand.js +0 -62
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/PutBucketIntelligentTieringConfigurationCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/PutBucketInventoryConfigurationCommand.js +0 -56
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/PutBucketLifecycleConfigurationCommand.js +0 -61
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/PutBucketLoggingCommand.js +0 -61
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/PutBucketMetricsConfigurationCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/PutBucketNotificationConfigurationCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/PutBucketOwnershipControlsCommand.js +0 -57
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/PutBucketPolicyCommand.js +0 -61
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/PutBucketReplicationCommand.js +0 -61
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/PutBucketRequestPaymentCommand.js +0 -61
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/PutBucketTaggingCommand.js +0 -61
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/PutBucketVersioningCommand.js +0 -61
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/PutBucketWebsiteCommand.js +0 -61
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/PutObjectAclCommand.js +0 -61
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/PutObjectCommand.js +0 -66
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/PutObjectLegalHoldCommand.js +0 -60
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/PutObjectLockConfigurationCommand.js +0 -60
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/PutObjectRetentionCommand.js +0 -60
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/PutObjectTaggingCommand.js +0 -60
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/PutPublicAccessBlockCommand.js +0 -61
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/RestoreObjectCommand.js +0 -61
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/SelectObjectContentCommand.js +0 -60
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/UploadPartCommand.js +0 -64
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/UploadPartCopyCommand.js +0 -59
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/WriteGetObjectResponseCommand.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/commands/index.js +0 -95
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/endpoint/EndpointParameters.js +0 -12
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/endpoint/endpointResolver.js +0 -8
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/endpoint/ruleset.js +0 -4
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/extensionConfiguration.js +0 -1
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/index.js +0 -8
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/models/S3ServiceException.js +0 -8
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/models/index.js +0 -2
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/models/models_0.js +0 -607
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/models/models_1.js +0 -137
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/pagination/Interfaces.js +0 -1
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/pagination/ListDirectoryBucketsPaginator.js +0 -25
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/pagination/ListObjectsV2Paginator.js +0 -25
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/pagination/ListPartsPaginator.js +0 -25
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/pagination/index.js +0 -4
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/protocols/Aws_restXml.js +0 -9624
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/runtimeConfig.browser.js +0 -42
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/runtimeConfig.js +0 -55
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/runtimeConfig.native.js +0 -11
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/runtimeConfig.shared.js +0 -27
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/runtimeExtensions.js +0 -18
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/waiters/index.js +0 -4
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/waiters/waitForBucketExists.js +0 -26
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/waiters/waitForBucketNotExists.js +0 -25
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/waiters/waitForObjectExists.js +0 -26
- package/dist/node_modules/@aws-sdk/client-s3/dist-es/waiters/waitForObjectNotExists.js +0 -25
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/S3.d.ts +0 -675
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/S3Client.d.ts +0 -308
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/AbortMultipartUploadCommand.d.ts +0 -163
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/CompleteMultipartUploadCommand.d.ts +0 -296
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/CopyObjectCommand.d.ts +0 -314
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/CreateBucketCommand.d.ts +0 -260
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/CreateMultipartUploadCommand.d.ts +0 -351
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/CreateSessionCommand.d.ts +0 -145
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/DeleteBucketAnalyticsConfigurationCommand.d.ts +0 -103
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/DeleteBucketCommand.d.ts +0 -132
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/DeleteBucketCorsCommand.d.ts +0 -106
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/DeleteBucketEncryptionCommand.d.ts +0 -97
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/DeleteBucketIntelligentTieringConfigurationCommand.d.ts +0 -96
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/DeleteBucketInventoryConfigurationCommand.d.ts +0 -101
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/DeleteBucketLifecycleCommand.d.ts +0 -108
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/DeleteBucketMetricsConfigurationCommand.d.ts +0 -109
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/DeleteBucketOwnershipControlsCommand.d.ts +0 -93
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/DeleteBucketPolicyCommand.d.ts +0 -144
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/DeleteBucketReplicationCommand.d.ts +0 -110
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/DeleteBucketTaggingCommand.d.ts +0 -102
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/DeleteBucketWebsiteCommand.d.ts +0 -109
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/DeleteObjectCommand.d.ts +0 -202
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/DeleteObjectTaggingCommand.d.ts +0 -133
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/DeleteObjectsCommand.d.ts +0 -304
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/DeletePublicAccessBlockCommand.d.ts +0 -102
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetBucketAccelerateConfigurationCommand.d.ts +0 -104
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetBucketAclCommand.d.ts +0 -117
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetBucketAnalyticsConfigurationCommand.d.ts +0 -137
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetBucketCorsCommand.d.ts +0 -147
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetBucketEncryptionCommand.d.ts +0 -108
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetBucketIntelligentTieringConfigurationCommand.d.ts +0 -123
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetBucketInventoryConfigurationCommand.d.ts +0 -131
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetBucketLifecycleConfigurationCommand.d.ts +0 -210
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetBucketLocationCommand.d.ts +0 -118
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetBucketLoggingCommand.d.ts +0 -112
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetBucketMetricsConfigurationCommand.d.ts +0 -130
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetBucketNotificationConfigurationCommand.d.ts +0 -156
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetBucketOwnershipControlsCommand.d.ts +0 -101
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetBucketPolicyCommand.d.ts +0 -151
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetBucketPolicyStatusCommand.d.ts +0 -107
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetBucketReplicationCommand.d.ts +0 -197
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetBucketRequestPaymentCommand.d.ts +0 -103
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetBucketTaggingCommand.d.ts +0 -136
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetBucketVersioningCommand.d.ts +0 -117
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetBucketWebsiteCommand.d.ts +0 -141
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetObjectAclCommand.d.ts +0 -191
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetObjectAttributesCommand.d.ts +0 -303
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetObjectCommand.d.ts +0 -342
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetObjectLegalHoldCommand.d.ts +0 -92
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetObjectLockConfigurationCommand.d.ts +0 -96
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetObjectRetentionCommand.d.ts +0 -93
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetObjectTaggingCommand.d.ts +0 -165
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetObjectTorrentCommand.d.ts +0 -109
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/GetPublicAccessBlockCommand.d.ts +0 -118
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/HeadBucketCommand.d.ts +0 -140
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/HeadObjectCommand.d.ts +0 -282
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/ListBucketAnalyticsConfigurationsCommand.d.ts +0 -149
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/ListBucketIntelligentTieringConfigurationsCommand.d.ts +0 -128
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/ListBucketInventoryConfigurationsCommand.d.ts +0 -144
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/ListBucketMetricsConfigurationsCommand.d.ts +0 -138
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/ListBucketsCommand.d.ts +0 -117
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/ListDirectoryBucketsCommand.d.ts +0 -98
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/ListMultipartUploadsCommand.d.ts +0 -326
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/ListObjectVersionsCommand.d.ts +0 -215
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/ListObjectsCommand.d.ts +0 -198
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/ListObjectsV2Command.d.ts +0 -239
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/ListPartsCommand.d.ts +0 -234
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/PutBucketAccelerateConfigurationCommand.d.ts +0 -117
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/PutBucketAclCommand.d.ts +0 -311
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/PutBucketAnalyticsConfigurationCommand.d.ts +0 -210
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/PutBucketCorsCommand.d.ts +0 -195
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/PutBucketEncryptionCommand.d.ts +0 -118
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/PutBucketIntelligentTieringConfigurationCommand.d.ts +0 -155
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/PutBucketInventoryConfigurationCommand.d.ts +0 -187
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/PutBucketLifecycleConfigurationCommand.d.ts +0 -255
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/PutBucketLoggingCommand.d.ts +0 -211
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/PutBucketMetricsConfigurationCommand.d.ts +0 -143
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/PutBucketNotificationConfigurationCommand.d.ts +0 -208
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/PutBucketOwnershipControlsCommand.d.ts +0 -101
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/PutBucketPolicyCommand.d.ts +0 -154
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/PutBucketReplicationCommand.d.ts +0 -236
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/PutBucketRequestPaymentCommand.d.ts +0 -111
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/PutBucketTaggingCommand.d.ts +0 -165
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/PutBucketVersioningCommand.d.ts +0 -137
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/PutBucketWebsiteCommand.d.ts +0 -246
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/PutObjectAclCommand.d.ts +0 -309
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/PutObjectCommand.d.ts +0 -397
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/PutObjectLegalHoldCommand.d.ts +0 -88
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/PutObjectLockConfigurationCommand.d.ts +0 -111
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/PutObjectRetentionCommand.d.ts +0 -91
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/PutObjectTaggingCommand.d.ts +0 -171
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/PutPublicAccessBlockCommand.d.ts +0 -119
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/RestoreObjectCommand.d.ts +0 -444
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/SelectObjectContentCommand.d.ts +0 -256
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/UploadPartCommand.d.ts +0 -282
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/UploadPartCopyCommand.d.ts +0 -329
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/WriteGetObjectResponseCommand.d.ts +0 -149
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/commands/index.d.ts +0 -95
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/endpoint/EndpointParameters.d.ts +0 -40
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/endpoint/endpointResolver.d.ts +0 -5
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/endpoint/ruleset.d.ts +0 -2
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/extensionConfiguration.d.ts +0 -8
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/index.d.ts +0 -16
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/models/S3ServiceException.d.ts +0 -13
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/models/index.d.ts +0 -2
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/models/models_0.d.ts +0 -12676
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/models/models_1.d.ts +0 -3292
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/pagination/Interfaces.d.ts +0 -8
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/pagination/ListDirectoryBucketsPaginator.d.ts +0 -7
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/pagination/ListObjectsV2Paginator.d.ts +0 -7
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/pagination/ListPartsPaginator.d.ts +0 -7
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/pagination/index.d.ts +0 -4
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/protocols/Aws_restXml.d.ts +0 -857
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/runtimeConfig.browser.d.ts +0 -61
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/runtimeConfig.d.ts +0 -62
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/runtimeConfig.native.d.ts +0 -60
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/runtimeConfig.shared.d.ts +0 -26
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/runtimeExtensions.d.ts +0 -17
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/S3.d.ts +0 -1680
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/S3Client.d.ts +0 -709
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/AbortMultipartUploadCommand.d.ts +0 -42
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/CompleteMultipartUploadCommand.d.ts +0 -42
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/CopyObjectCommand.d.ts +0 -35
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/CreateBucketCommand.d.ts +0 -35
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/CreateMultipartUploadCommand.d.ts +0 -42
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/CreateSessionCommand.d.ts +0 -35
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/DeleteBucketAnalyticsConfigurationCommand.d.ts +0 -38
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/DeleteBucketCommand.d.ts +0 -33
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/DeleteBucketCorsCommand.d.ts +0 -33
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/DeleteBucketEncryptionCommand.d.ts +0 -37
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/DeleteBucketIntelligentTieringConfigurationCommand.d.ts +0 -38
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/DeleteBucketInventoryConfigurationCommand.d.ts +0 -38
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/DeleteBucketLifecycleCommand.d.ts +0 -37
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/DeleteBucketMetricsConfigurationCommand.d.ts +0 -38
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/DeleteBucketOwnershipControlsCommand.d.ts +0 -38
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/DeleteBucketPolicyCommand.d.ts +0 -34
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/DeleteBucketReplicationCommand.d.ts +0 -38
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/DeleteBucketTaggingCommand.d.ts +0 -34
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/DeleteBucketWebsiteCommand.d.ts +0 -34
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/DeleteObjectCommand.d.ts +0 -35
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/DeleteObjectTaggingCommand.d.ts +0 -39
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/DeleteObjectsCommand.d.ts +0 -35
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/DeletePublicAccessBlockCommand.d.ts +0 -38
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetBucketAccelerateConfigurationCommand.d.ts +0 -42
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetBucketAclCommand.d.ts +0 -35
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetBucketAnalyticsConfigurationCommand.d.ts +0 -42
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetBucketCorsCommand.d.ts +0 -35
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetBucketEncryptionCommand.d.ts +0 -39
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetBucketIntelligentTieringConfigurationCommand.d.ts +0 -42
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetBucketInventoryConfigurationCommand.d.ts +0 -42
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetBucketLifecycleConfigurationCommand.d.ts +0 -42
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetBucketLocationCommand.d.ts +0 -39
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetBucketLoggingCommand.d.ts +0 -38
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetBucketMetricsConfigurationCommand.d.ts +0 -42
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetBucketNotificationConfigurationCommand.d.ts +0 -42
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetBucketOwnershipControlsCommand.d.ts +0 -42
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetBucketPolicyCommand.d.ts +0 -38
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetBucketPolicyStatusCommand.d.ts +0 -42
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetBucketReplicationCommand.d.ts +0 -42
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetBucketRequestPaymentCommand.d.ts +0 -42
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetBucketTaggingCommand.d.ts +0 -38
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetBucketVersioningCommand.d.ts +0 -39
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetBucketWebsiteCommand.d.ts +0 -38
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetObjectAclCommand.d.ts +0 -35
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetObjectAttributesCommand.d.ts +0 -39
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetObjectCommand.d.ts +0 -38
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetObjectLegalHoldCommand.d.ts +0 -39
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetObjectLockConfigurationCommand.d.ts +0 -42
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetObjectRetentionCommand.d.ts +0 -39
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetObjectTaggingCommand.d.ts +0 -38
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetObjectTorrentCommand.d.ts +0 -44
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/GetPublicAccessBlockCommand.d.ts +0 -42
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/HeadBucketCommand.d.ts +0 -35
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/HeadObjectCommand.d.ts +0 -35
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/ListBucketAnalyticsConfigurationsCommand.d.ts +0 -42
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/ListBucketIntelligentTieringConfigurationsCommand.d.ts +0 -42
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/ListBucketInventoryConfigurationsCommand.d.ts +0 -42
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/ListBucketMetricsConfigurationsCommand.d.ts +0 -42
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/ListBucketsCommand.d.ts +0 -35
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/ListDirectoryBucketsCommand.d.ts +0 -42
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/ListMultipartUploadsCommand.d.ts +0 -42
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/ListObjectVersionsCommand.d.ts +0 -39
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/ListObjectsCommand.d.ts +0 -35
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/ListObjectsV2Command.d.ts +0 -35
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/ListPartsCommand.d.ts +0 -35
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutBucketAccelerateConfigurationCommand.d.ts +0 -38
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutBucketAclCommand.d.ts +0 -33
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutBucketAnalyticsConfigurationCommand.d.ts +0 -38
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutBucketCorsCommand.d.ts +0 -33
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutBucketEncryptionCommand.d.ts +0 -34
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutBucketIntelligentTieringConfigurationCommand.d.ts +0 -38
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutBucketInventoryConfigurationCommand.d.ts +0 -38
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutBucketLifecycleConfigurationCommand.d.ts +0 -38
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutBucketLoggingCommand.d.ts +0 -33
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutBucketMetricsConfigurationCommand.d.ts +0 -38
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutBucketNotificationConfigurationCommand.d.ts +0 -38
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutBucketOwnershipControlsCommand.d.ts +0 -38
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutBucketPolicyCommand.d.ts +0 -33
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutBucketReplicationCommand.d.ts +0 -37
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutBucketRequestPaymentCommand.d.ts +0 -38
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutBucketTaggingCommand.d.ts +0 -33
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutBucketVersioningCommand.d.ts +0 -34
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutBucketWebsiteCommand.d.ts +0 -33
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutObjectAclCommand.d.ts +0 -35
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutObjectCommand.d.ts +0 -39
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutObjectLegalHoldCommand.d.ts +0 -39
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutObjectLockConfigurationCommand.d.ts +0 -42
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutObjectRetentionCommand.d.ts +0 -39
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutObjectTaggingCommand.d.ts +0 -38
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutPublicAccessBlockCommand.d.ts +0 -37
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/RestoreObjectCommand.d.ts +0 -35
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/SelectObjectContentCommand.d.ts +0 -39
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/UploadPartCommand.d.ts +0 -39
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/UploadPartCopyCommand.d.ts +0 -38
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/WriteGetObjectResponseCommand.d.ts +0 -43
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/index.d.ts +0 -95
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/endpoint/EndpointParameters.d.ts +0 -51
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/endpoint/endpointResolver.d.ts +0 -8
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/endpoint/ruleset.d.ts +0 -2
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/extensionConfiguration.d.ts +0 -7
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/index.d.ts +0 -11
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/models/S3ServiceException.d.ts +0 -8
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/models/index.d.ts +0 -2
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/models/models_0.d.ts +0 -2143
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/models/models_1.d.ts +0 -620
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/pagination/Interfaces.d.ts +0 -5
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/pagination/ListDirectoryBucketsPaginator.d.ts +0 -11
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/pagination/ListObjectsV2Paginator.d.ts +0 -11
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/pagination/ListPartsPaginator.d.ts +0 -11
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/pagination/index.d.ts +0 -4
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/protocols/Aws_restXml.d.ts +0 -1149
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/runtimeConfig.browser.d.ts +0 -131
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/runtimeConfig.d.ts +0 -133
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/runtimeConfig.native.d.ts +0 -116
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/runtimeConfig.shared.d.ts +0 -34
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/runtimeExtensions.d.ts +0 -11
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/waiters/index.d.ts +0 -4
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/waiters/waitForBucketExists.d.ts +0 -11
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/waiters/waitForBucketNotExists.d.ts +0 -11
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/waiters/waitForObjectExists.d.ts +0 -11
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/waiters/waitForObjectNotExists.d.ts +0 -11
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/waiters/index.d.ts +0 -4
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/waiters/waitForBucketExists.d.ts +0 -14
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/waiters/waitForBucketNotExists.d.ts +0 -14
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/waiters/waitForObjectExists.d.ts +0 -14
- package/dist/node_modules/@aws-sdk/client-s3/dist-types/waiters/waitForObjectNotExists.d.ts +0 -14
- package/dist/node_modules/@aws-sdk/client-s3/package.json +0 -1
- package/dist/node_modules/mime-match/.travis.yml +0 -11
- package/dist/node_modules/mime-match/example.js +0 -17
- package/dist/node_modules/mime-match/index.js +0 -1
- package/dist/node_modules/mime-match/package.json +0 -1
- package/dist/node_modules/mime-match/test.js +0 -45
- package/dist/node_modules/mkdirp/LICENSE +0 -21
- package/dist/node_modules/mkdirp/bin/cmd.js +0 -33
- package/dist/node_modules/mkdirp/bin/usage.txt +0 -12
- package/dist/node_modules/mkdirp/index.js +0 -1
- package/dist/node_modules/mkdirp/package.json +0 -1
- package/dist/node_modules/mkdirp/readme.markdown +0 -100
- package/dist/node_modules/multer-aliyun-oss/index.js +0 -74
- package/dist/node_modules/multer-aliyun-oss/package.json +0 -1
- package/dist/node_modules/multer-cos/LICENSE +0 -24
- package/dist/node_modules/multer-cos/demo/index.js +0 -39
- package/dist/node_modules/multer-cos/demo/myMulter.js +0 -88
- package/dist/node_modules/multer-cos/index.js +0 -220
- package/dist/node_modules/multer-cos/package.json +0 -1
- package/dist/node_modules/multer-s3/.gitattributes +0 -1
- package/dist/node_modules/multer-s3/.travis.yml +0 -6
- package/dist/node_modules/multer-s3/LICENSE +0 -22
- package/dist/node_modules/multer-s3/index.js +0 -35
- package/dist/node_modules/multer-s3/package.json +0 -1
- package/dist/node_modules/multer-s3/test/basic.js +0 -293
- package/dist/node_modules/multer-s3/test/files/a.txt +0 -1
- package/dist/node_modules/multer-s3/test/files/test.svg +0 -3
- package/dist/node_modules/multer-s3/test/files/test2.svg +0 -9
- package/dist/node_modules/multer-s3/test/util/mock-s3.js +0 -17
- package/dist/server/FileModel.d.ts +0 -12
- package/dist/server/FileModel.js +0 -53
- package/dist/server/actions/attachments.d.ts +0 -11
- package/dist/server/actions/attachments.js +0 -197
- package/dist/server/actions/index.d.ts +0 -11
- package/dist/server/actions/index.js +0 -53
- package/dist/server/actions/storages.d.ts +0 -1
- package/dist/server/actions/storages.js +0 -62
- package/dist/server/collections/attachments.d.ts +0 -10
- package/dist/server/collections/attachments.js +0 -97
- package/dist/server/collections/storages.d.ts +0 -10
- package/dist/server/collections/storages.js +0 -94
- package/dist/server/index.d.ts +0 -10
- package/dist/server/index.js +0 -48
- package/dist/server/interfaces/attachment-interface.d.ts +0 -18
- package/dist/server/interfaces/attachment-interface.js +0 -63
- package/dist/server/migrations/20230831160742-fix-attachment-field.d.ts +0 -13
- package/dist/server/migrations/20230831160742-fix-attachment-field.js +0 -71
- package/dist/server/migrations/20231120142523-fix-storage.d.ts +0 -13
- package/dist/server/migrations/20231120142523-fix-storage.js +0 -72
- package/dist/server/migrations/20240306223006-update-target.d.ts +0 -14
- package/dist/server/migrations/20240306223006-update-target.js +0 -54
- package/dist/server/migrations/20240523152854-change-attachment-field-props.d.ts +0 -14
- package/dist/server/migrations/20240523152854-change-attachment-field-props.js +0 -65
- package/dist/server/migrations/20240613110121-fix-schema-in-field.d.ts +0 -13
- package/dist/server/migrations/20240613110121-fix-schema-in-field.js +0 -93
- package/dist/server/rules/index.d.ts +0 -9
- package/dist/server/rules/index.js +0 -46
- package/dist/server/rules/mimetype.d.ts +0 -9
- package/dist/server/rules/mimetype.js +0 -49
- package/dist/server/server.d.ts +0 -22
- package/dist/server/server.js +0 -147
- package/dist/server/storages/ali-oss.d.ts +0 -25
- package/dist/server/storages/ali-oss.js +0 -62
- package/dist/server/storages/index.d.ts +0 -44
- package/dist/server/storages/index.js +0 -37
- package/dist/server/storages/local.d.ts +0 -26
- package/dist/server/storages/local.js +0 -100
- package/dist/server/storages/s3.d.ts +0 -26
- package/dist/server/storages/s3.js +0 -89
- package/dist/server/storages/tx-cos.d.ts +0 -26
- package/dist/server/storages/tx-cos.js +0 -71
- package/dist/server/utils.d.ts +0 -11
- package/dist/server/utils.js +0 -67
- package/dist/swagger/index.json +0 -81
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"name":"multer-s3","version":"3.0.1","description":"Streaming multer storage engine for AWS S3","main":"index.js","scripts":{"test":"standard && mocha test/basic.js"},"engines":{"node":">= 12.0.0"},"repository":{"type":"git","url":"git+https://github.com/badunk/multer-s3.git"},"keywords":["multer","s3","amazon","aws"],"author":"badunk","license":"MIT","bugs":{"url":"https://github.com/badunk/multer-s3/issues"},"homepage":"https://github.com/badunk/multer-s3#readme","dependencies":{"@aws-sdk/lib-storage":"^3.46.0","file-type":"^3.3.0","html-comment-regex":"^1.1.2","run-parallel":"^1.1.6"},"peerDependencies":{"@aws-sdk/client-s3":"^3.0.0"},"devDependencies":{"express":"^4.13.1","form-data":"^1.0.0-rc3","mocha":"^2.2.5","multer":"^1.1.0","on-finished":"^2.3.0","standard":"^5.4.1","xtend":"^4.0.1"},"_lastModified":"2024-07-10T04:54:31.474Z"}
|
|
@@ -1,293 +0,0 @@
|
|
|
1
|
-
/* eslint-env mocha */
|
|
2
|
-
|
|
3
|
-
var multerS3 = require('../')
|
|
4
|
-
|
|
5
|
-
var fs = require('fs')
|
|
6
|
-
var path = require('path')
|
|
7
|
-
var extend = require('xtend')
|
|
8
|
-
var assert = require('assert')
|
|
9
|
-
var multer = require('multer')
|
|
10
|
-
var stream = require('stream')
|
|
11
|
-
var FormData = require('form-data')
|
|
12
|
-
var onFinished = require('on-finished')
|
|
13
|
-
var mockS3 = require('./util/mock-s3')
|
|
14
|
-
|
|
15
|
-
var VALID_OPTIONS = {
|
|
16
|
-
bucket: 'string'
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
var INVALID_OPTIONS = [
|
|
20
|
-
['numeric key', { key: 1337 }],
|
|
21
|
-
['string key', { key: 'string' }],
|
|
22
|
-
['numeric bucket', { bucket: 1337 }],
|
|
23
|
-
['numeric contentType', { contentType: 1337 }]
|
|
24
|
-
]
|
|
25
|
-
|
|
26
|
-
function submitForm (multer, form, cb) {
|
|
27
|
-
form.getLength(function (err, length) {
|
|
28
|
-
if (err) return cb(err)
|
|
29
|
-
|
|
30
|
-
var req = new stream.PassThrough()
|
|
31
|
-
|
|
32
|
-
req.complete = false
|
|
33
|
-
form.once('end', function () {
|
|
34
|
-
req.complete = true
|
|
35
|
-
})
|
|
36
|
-
|
|
37
|
-
form.pipe(req)
|
|
38
|
-
req.headers = {
|
|
39
|
-
'content-type': 'multipart/form-data; boundary=' + form.getBoundary(),
|
|
40
|
-
'content-length': length
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
multer(req, null, function (err) {
|
|
44
|
-
onFinished(req, function () { cb(err, req) })
|
|
45
|
-
})
|
|
46
|
-
})
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
describe('Multer S3', function () {
|
|
50
|
-
it('is exposed as a function', function () {
|
|
51
|
-
assert.equal(typeof multerS3, 'function')
|
|
52
|
-
})
|
|
53
|
-
|
|
54
|
-
INVALID_OPTIONS.forEach(function (testCase) {
|
|
55
|
-
it('throws when given ' + testCase[0], function () {
|
|
56
|
-
function testBody () {
|
|
57
|
-
multerS3(extend(VALID_OPTIONS, testCase[1]))
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
assert.throws(testBody, TypeError)
|
|
61
|
-
})
|
|
62
|
-
})
|
|
63
|
-
|
|
64
|
-
it('upload files', function (done) {
|
|
65
|
-
var s3 = mockS3()
|
|
66
|
-
var form = new FormData()
|
|
67
|
-
var storage = multerS3({ s3: s3, bucket: 'test' })
|
|
68
|
-
var upload = multer({ storage: storage })
|
|
69
|
-
var parser = upload.single('image')
|
|
70
|
-
var image = fs.createReadStream(path.join(__dirname, 'files', 'ffffff.png'))
|
|
71
|
-
|
|
72
|
-
form.append('name', 'Multer')
|
|
73
|
-
form.append('image', image)
|
|
74
|
-
|
|
75
|
-
submitForm(parser, form, function (err, req) {
|
|
76
|
-
assert.ifError(err)
|
|
77
|
-
|
|
78
|
-
assert.equal(req.body.name, 'Multer')
|
|
79
|
-
|
|
80
|
-
assert.equal(req.file.fieldname, 'image')
|
|
81
|
-
assert.equal(req.file.originalname, 'ffffff.png')
|
|
82
|
-
assert.equal(req.file.size, 68)
|
|
83
|
-
assert.equal(req.file.bucket, 'test')
|
|
84
|
-
assert.equal(req.file.etag, 'mock-etag')
|
|
85
|
-
assert.equal(req.file.location, 'mock-location')
|
|
86
|
-
|
|
87
|
-
done()
|
|
88
|
-
})
|
|
89
|
-
})
|
|
90
|
-
|
|
91
|
-
it('uploads file with AES256 server-side encryption', function (done) {
|
|
92
|
-
var s3 = mockS3()
|
|
93
|
-
var form = new FormData()
|
|
94
|
-
var storage = multerS3({ s3: s3, bucket: 'test', serverSideEncryption: 'AES256' })
|
|
95
|
-
var upload = multer({ storage: storage })
|
|
96
|
-
var parser = upload.single('image')
|
|
97
|
-
var image = fs.createReadStream(path.join(__dirname, 'files', 'ffffff.png'))
|
|
98
|
-
|
|
99
|
-
form.append('name', 'Multer')
|
|
100
|
-
form.append('image', image)
|
|
101
|
-
|
|
102
|
-
submitForm(parser, form, function (err, req) {
|
|
103
|
-
assert.ifError(err)
|
|
104
|
-
|
|
105
|
-
assert.equal(req.body.name, 'Multer')
|
|
106
|
-
|
|
107
|
-
assert.equal(req.file.fieldname, 'image')
|
|
108
|
-
assert.equal(req.file.originalname, 'ffffff.png')
|
|
109
|
-
assert.equal(req.file.size, 68)
|
|
110
|
-
assert.equal(req.file.bucket, 'test')
|
|
111
|
-
assert.equal(req.file.etag, 'mock-etag')
|
|
112
|
-
assert.equal(req.file.location, 'mock-location')
|
|
113
|
-
assert.equal(req.file.serverSideEncryption, 'AES256')
|
|
114
|
-
|
|
115
|
-
done()
|
|
116
|
-
})
|
|
117
|
-
})
|
|
118
|
-
|
|
119
|
-
it('uploads file with AWS KMS-managed server-side encryption', function (done) {
|
|
120
|
-
var s3 = mockS3()
|
|
121
|
-
var form = new FormData()
|
|
122
|
-
var storage = multerS3({ s3: s3, bucket: 'test', serverSideEncryption: 'aws:kms' })
|
|
123
|
-
var upload = multer({ storage: storage })
|
|
124
|
-
var parser = upload.single('image')
|
|
125
|
-
var image = fs.createReadStream(path.join(__dirname, 'files', 'ffffff.png'))
|
|
126
|
-
|
|
127
|
-
form.append('name', 'Multer')
|
|
128
|
-
form.append('image', image)
|
|
129
|
-
|
|
130
|
-
submitForm(parser, form, function (err, req) {
|
|
131
|
-
assert.ifError(err)
|
|
132
|
-
|
|
133
|
-
assert.equal(req.body.name, 'Multer')
|
|
134
|
-
|
|
135
|
-
assert.equal(req.file.fieldname, 'image')
|
|
136
|
-
assert.equal(req.file.originalname, 'ffffff.png')
|
|
137
|
-
assert.equal(req.file.size, 68)
|
|
138
|
-
assert.equal(req.file.bucket, 'test')
|
|
139
|
-
assert.equal(req.file.etag, 'mock-etag')
|
|
140
|
-
assert.equal(req.file.location, 'mock-location')
|
|
141
|
-
assert.equal(req.file.serverSideEncryption, 'aws:kms')
|
|
142
|
-
|
|
143
|
-
done()
|
|
144
|
-
})
|
|
145
|
-
})
|
|
146
|
-
|
|
147
|
-
it('uploads PNG file with correct content-type', function (done) {
|
|
148
|
-
var s3 = mockS3()
|
|
149
|
-
var form = new FormData()
|
|
150
|
-
var storage = multerS3({ s3: s3, bucket: 'test', serverSideEncryption: 'aws:kms', contentType: multerS3.AUTO_CONTENT_TYPE })
|
|
151
|
-
var upload = multer({ storage: storage })
|
|
152
|
-
var parser = upload.single('image')
|
|
153
|
-
var image = fs.createReadStream(path.join(__dirname, 'files', 'ffffff.png'))
|
|
154
|
-
|
|
155
|
-
form.append('name', 'Multer')
|
|
156
|
-
form.append('image', image)
|
|
157
|
-
|
|
158
|
-
submitForm(parser, form, function (err, req) {
|
|
159
|
-
assert.ifError(err)
|
|
160
|
-
|
|
161
|
-
assert.equal(req.body.name, 'Multer')
|
|
162
|
-
|
|
163
|
-
assert.equal(req.file.fieldname, 'image')
|
|
164
|
-
assert.equal(req.file.contentType, 'image/png')
|
|
165
|
-
assert.equal(req.file.originalname, 'ffffff.png')
|
|
166
|
-
assert.equal(req.file.size, 68)
|
|
167
|
-
assert.equal(req.file.bucket, 'test')
|
|
168
|
-
assert.equal(req.file.etag, 'mock-etag')
|
|
169
|
-
assert.equal(req.file.location, 'mock-location')
|
|
170
|
-
assert.equal(req.file.serverSideEncryption, 'aws:kms')
|
|
171
|
-
|
|
172
|
-
done()
|
|
173
|
-
})
|
|
174
|
-
})
|
|
175
|
-
|
|
176
|
-
it('uploads pure SVG file with correct content-type', function (done) {
|
|
177
|
-
var s3 = mockS3()
|
|
178
|
-
var form = new FormData()
|
|
179
|
-
var storage = multerS3({ s3: s3, bucket: 'test', serverSideEncryption: 'aws:kms', contentType: multerS3.AUTO_CONTENT_TYPE })
|
|
180
|
-
var upload = multer({ storage: storage })
|
|
181
|
-
var parser = upload.single('image')
|
|
182
|
-
var image = fs.createReadStream(path.join(__dirname, 'files', 'test.svg'))
|
|
183
|
-
|
|
184
|
-
form.append('name', 'Multer')
|
|
185
|
-
form.append('image', image)
|
|
186
|
-
|
|
187
|
-
submitForm(parser, form, function (err, req) {
|
|
188
|
-
assert.ifError(err)
|
|
189
|
-
|
|
190
|
-
assert.equal(req.body.name, 'Multer')
|
|
191
|
-
|
|
192
|
-
assert.equal(req.file.fieldname, 'image')
|
|
193
|
-
assert.equal(req.file.contentType, 'image/svg+xml')
|
|
194
|
-
assert.equal(req.file.originalname, 'test.svg')
|
|
195
|
-
assert.equal(req.file.size, 100)
|
|
196
|
-
assert.equal(req.file.bucket, 'test')
|
|
197
|
-
assert.equal(req.file.etag, 'mock-etag')
|
|
198
|
-
assert.equal(req.file.location, 'mock-location')
|
|
199
|
-
assert.equal(req.file.serverSideEncryption, 'aws:kms')
|
|
200
|
-
|
|
201
|
-
done()
|
|
202
|
-
})
|
|
203
|
-
})
|
|
204
|
-
|
|
205
|
-
it('uploads common SVG file with correct content-type', function (done) {
|
|
206
|
-
var s3 = mockS3()
|
|
207
|
-
var form = new FormData()
|
|
208
|
-
var storage = multerS3({ s3: s3, bucket: 'test', serverSideEncryption: 'aws:kms', contentType: multerS3.AUTO_CONTENT_TYPE })
|
|
209
|
-
var upload = multer({ storage: storage })
|
|
210
|
-
var parser = upload.single('image')
|
|
211
|
-
var image = fs.createReadStream(path.join(__dirname, 'files', 'test2.svg'))
|
|
212
|
-
|
|
213
|
-
form.append('name', 'Multer')
|
|
214
|
-
form.append('image', image)
|
|
215
|
-
|
|
216
|
-
submitForm(parser, form, function (err, req) {
|
|
217
|
-
assert.ifError(err)
|
|
218
|
-
|
|
219
|
-
assert.equal(req.body.name, 'Multer')
|
|
220
|
-
|
|
221
|
-
assert.equal(req.file.fieldname, 'image')
|
|
222
|
-
assert.equal(req.file.contentType, 'image/svg+xml')
|
|
223
|
-
assert.equal(req.file.originalname, 'test2.svg')
|
|
224
|
-
assert.equal(req.file.size, 285)
|
|
225
|
-
assert.equal(req.file.bucket, 'test')
|
|
226
|
-
assert.equal(req.file.etag, 'mock-etag')
|
|
227
|
-
assert.equal(req.file.location, 'mock-location')
|
|
228
|
-
assert.equal(req.file.serverSideEncryption, 'aws:kms')
|
|
229
|
-
|
|
230
|
-
done()
|
|
231
|
-
})
|
|
232
|
-
})
|
|
233
|
-
|
|
234
|
-
it('uploads SVG file without quadratic regex', function (done) {
|
|
235
|
-
this.timeout('10s')
|
|
236
|
-
|
|
237
|
-
var s3 = mockS3()
|
|
238
|
-
var form = new FormData()
|
|
239
|
-
var storage = multerS3({ s3: s3, bucket: 'test', serverSideEncryption: 'aws:kms', contentType: multerS3.AUTO_CONTENT_TYPE })
|
|
240
|
-
var upload = multer({ storage: storage })
|
|
241
|
-
var parser = upload.single('image')
|
|
242
|
-
fs.writeFileSync(path.join(__dirname, 'files', 'test_generated.svg'), '<!doctype svg ' + ' '.repeat(34560))
|
|
243
|
-
var image = fs.createReadStream(path.join(__dirname, 'files', 'test_generated.svg'))
|
|
244
|
-
|
|
245
|
-
form.append('name', 'Multer')
|
|
246
|
-
form.append('image', image)
|
|
247
|
-
|
|
248
|
-
submitForm(parser, form, function (err, req) {
|
|
249
|
-
assert.ifError(err)
|
|
250
|
-
|
|
251
|
-
assert.equal(req.body.name, 'Multer')
|
|
252
|
-
|
|
253
|
-
assert.equal(req.file.fieldname, 'image')
|
|
254
|
-
assert.equal(req.file.contentType, 'application/octet-stream')
|
|
255
|
-
assert.equal(req.file.originalname, 'test_generated.svg')
|
|
256
|
-
assert.equal(req.file.size, 34574)
|
|
257
|
-
assert.equal(req.file.bucket, 'test')
|
|
258
|
-
assert.equal(req.file.etag, 'mock-etag')
|
|
259
|
-
assert.equal(req.file.location, 'mock-location')
|
|
260
|
-
assert.equal(req.file.serverSideEncryption, 'aws:kms')
|
|
261
|
-
|
|
262
|
-
done()
|
|
263
|
-
})
|
|
264
|
-
})
|
|
265
|
-
|
|
266
|
-
it('uploads common file as gzip content encoded', function (done) {
|
|
267
|
-
var s3 = mockS3()
|
|
268
|
-
var form = new FormData()
|
|
269
|
-
var storage = multerS3({ s3: s3, bucket: 'test', serverSideEncryption: 'aws:kms', contentType: multerS3.AUTO_CONTENT_TYPE, contentEncoding: 'gzip' })
|
|
270
|
-
var upload = multer({ storage: storage })
|
|
271
|
-
var parser = upload.single('file')
|
|
272
|
-
var image = fs.createReadStream(path.join(__dirname, 'files', 'a.txt'))
|
|
273
|
-
|
|
274
|
-
form.append('name', 'Multer')
|
|
275
|
-
form.append('file', image)
|
|
276
|
-
|
|
277
|
-
submitForm(parser, form, function (err, req) {
|
|
278
|
-
assert.ifError(err)
|
|
279
|
-
|
|
280
|
-
assert.equal(req.body.name, 'Multer')
|
|
281
|
-
assert.equal(req.file.fieldname, 'file')
|
|
282
|
-
assert.equal(req.file.contentType, 'application/octet-stream')
|
|
283
|
-
assert.equal(req.file.originalname, 'a.txt')
|
|
284
|
-
assert.equal(req.file.size, 7)
|
|
285
|
-
assert.equal(req.file.bucket, 'test')
|
|
286
|
-
assert.equal(req.file.etag, 'mock-etag')
|
|
287
|
-
assert.equal(req.file.location, 'mock-location')
|
|
288
|
-
assert.equal(req.file.serverSideEncryption, 'aws:kms')
|
|
289
|
-
assert.equal(req.file.contentEncoding, 'gzip')
|
|
290
|
-
done()
|
|
291
|
-
})
|
|
292
|
-
})
|
|
293
|
-
})
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
content
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0"?>
|
|
2
|
-
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
|
|
3
|
-
"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
|
|
4
|
-
|
|
5
|
-
<svg xmlns="http://www.w3.org/2000/svg"
|
|
6
|
-
width="226" height="226">
|
|
7
|
-
<circle cx="110" cy="107" r="80" stroke="black"
|
|
8
|
-
stroke-width="5" fill="red" />
|
|
9
|
-
</svg>
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
var events = require('events')
|
|
2
|
-
|
|
3
|
-
function createMockS3 () {
|
|
4
|
-
function send (opts, cb) {
|
|
5
|
-
var ee = new events.EventEmitter()
|
|
6
|
-
var buffer = opts['input']['Body']
|
|
7
|
-
ee.emit('httpUploadProgress', { total: buffer.length })
|
|
8
|
-
return Promise.resolve({
|
|
9
|
-
Location: 'mock-location',
|
|
10
|
-
ETag: 'mock-etag'
|
|
11
|
-
})
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
return { send: send }
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
module.exports = createMockS3
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file is part of the NocoBase (R) project.
|
|
3
|
-
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
-
* Authors: NocoBase Team.
|
|
5
|
-
*
|
|
6
|
-
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
-
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
-
*/
|
|
9
|
-
import { Model } from '@nocobase/database';
|
|
10
|
-
export declare class FileModel extends Model {
|
|
11
|
-
toJSON(): any;
|
|
12
|
-
}
|
package/dist/server/FileModel.js
DELETED
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file is part of the NocoBase (R) project.
|
|
3
|
-
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
-
* Authors: NocoBase Team.
|
|
5
|
-
*
|
|
6
|
-
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
-
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
-
*/
|
|
9
|
-
|
|
10
|
-
var __defProp = Object.defineProperty;
|
|
11
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
12
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
13
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
14
|
-
var __export = (target, all) => {
|
|
15
|
-
for (var name in all)
|
|
16
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
17
|
-
};
|
|
18
|
-
var __copyProps = (to, from, except, desc) => {
|
|
19
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
20
|
-
for (let key of __getOwnPropNames(from))
|
|
21
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
22
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
23
|
-
}
|
|
24
|
-
return to;
|
|
25
|
-
};
|
|
26
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
27
|
-
var FileModel_exports = {};
|
|
28
|
-
__export(FileModel_exports, {
|
|
29
|
-
FileModel: () => FileModel
|
|
30
|
-
});
|
|
31
|
-
module.exports = __toCommonJS(FileModel_exports);
|
|
32
|
-
var import_database = require("@nocobase/database");
|
|
33
|
-
class FileModel extends import_database.Model {
|
|
34
|
-
toJSON() {
|
|
35
|
-
var _a, _b, _c;
|
|
36
|
-
const json = super.toJSON();
|
|
37
|
-
const fileStorages = (_a = this.constructor["database"]) == null ? void 0 : _a["_fileStorages"];
|
|
38
|
-
if (json.storageId && fileStorages && fileStorages.has(json.storageId)) {
|
|
39
|
-
const storage = fileStorages.get(json.storageId);
|
|
40
|
-
if ((_b = storage == null ? void 0 : storage.options) == null ? void 0 : _b.thumbnailRule) {
|
|
41
|
-
json["thumbnailRule"] = (_c = storage == null ? void 0 : storage.options) == null ? void 0 : _c.thumbnailRule;
|
|
42
|
-
}
|
|
43
|
-
if ((storage == null ? void 0 : storage.type) === "local" && process.env.APP_PUBLIC_PATH) {
|
|
44
|
-
json["url"] = process.env.APP_PUBLIC_PATH.replace(/\/$/g, "") + json.url;
|
|
45
|
-
}
|
|
46
|
-
}
|
|
47
|
-
return json;
|
|
48
|
-
}
|
|
49
|
-
}
|
|
50
|
-
// Annotate the CommonJS export names for ESM import in node:
|
|
51
|
-
0 && (module.exports = {
|
|
52
|
-
FileModel
|
|
53
|
-
});
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file is part of the NocoBase (R) project.
|
|
3
|
-
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
-
* Authors: NocoBase Team.
|
|
5
|
-
*
|
|
6
|
-
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
-
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
-
*/
|
|
9
|
-
import { Context, Next } from '@nocobase/actions';
|
|
10
|
-
export declare function createMiddleware(ctx: Context, next: Next): Promise<any>;
|
|
11
|
-
export declare function destroyMiddleware(ctx: Context, next: Next): Promise<any>;
|
|
@@ -1,197 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file is part of the NocoBase (R) project.
|
|
3
|
-
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
-
* Authors: NocoBase Team.
|
|
5
|
-
*
|
|
6
|
-
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
-
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
-
*/
|
|
9
|
-
|
|
10
|
-
var __create = Object.create;
|
|
11
|
-
var __defProp = Object.defineProperty;
|
|
12
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
13
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
14
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
15
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
16
|
-
var __export = (target, all) => {
|
|
17
|
-
for (var name in all)
|
|
18
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
19
|
-
};
|
|
20
|
-
var __copyProps = (to, from, except, desc) => {
|
|
21
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
22
|
-
for (let key of __getOwnPropNames(from))
|
|
23
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
24
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
25
|
-
}
|
|
26
|
-
return to;
|
|
27
|
-
};
|
|
28
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
29
|
-
// If the importer is in node compatibility mode or this is not an ESM
|
|
30
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
31
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
32
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
33
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
34
|
-
mod
|
|
35
|
-
));
|
|
36
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
37
|
-
var attachments_exports = {};
|
|
38
|
-
__export(attachments_exports, {
|
|
39
|
-
createMiddleware: () => createMiddleware,
|
|
40
|
-
destroyMiddleware: () => destroyMiddleware
|
|
41
|
-
});
|
|
42
|
-
module.exports = __toCommonJS(attachments_exports);
|
|
43
|
-
var import_utils = require("@nocobase/utils");
|
|
44
|
-
var import_path = __toESM(require("path"));
|
|
45
|
-
var import_constants = require("../../constants");
|
|
46
|
-
var Rules = __toESM(require("../rules"));
|
|
47
|
-
var import__ = __toESM(require(".."));
|
|
48
|
-
function getFileFilter(storage) {
|
|
49
|
-
return (req, file, cb) => {
|
|
50
|
-
const { size, ...rules } = storage.rules;
|
|
51
|
-
const ruleKeys = Object.keys(rules);
|
|
52
|
-
const result = !ruleKeys.length || !ruleKeys.some((key) => typeof Rules[key] !== "function" || !Rules[key](file, rules[key]));
|
|
53
|
-
cb(null, result);
|
|
54
|
-
};
|
|
55
|
-
}
|
|
56
|
-
function getFileData(ctx) {
|
|
57
|
-
const { [import_constants.FILE_FIELD_NAME]: file, storage } = ctx;
|
|
58
|
-
if (!file) {
|
|
59
|
-
return ctx.throw(400, "file validation failed");
|
|
60
|
-
}
|
|
61
|
-
const storageConfig = ctx.app.pm.get(import__.default).storageTypes.get(storage.type);
|
|
62
|
-
const { [storageConfig.filenameKey || "filename"]: name } = file;
|
|
63
|
-
const filename = import_path.default.basename(name);
|
|
64
|
-
const extname = import_path.default.extname(filename);
|
|
65
|
-
const path = (storage.path || "").replace(/^\/|\/$/g, "");
|
|
66
|
-
const baseUrl = storage.baseUrl.replace(/\/+$/, "");
|
|
67
|
-
const pathname = [path, filename].filter(Boolean).join("/");
|
|
68
|
-
return {
|
|
69
|
-
title: Buffer.from(file.originalname, "latin1").toString("utf8").replace(extname, ""),
|
|
70
|
-
filename,
|
|
71
|
-
extname,
|
|
72
|
-
// TODO(feature): 暂时两者相同,后面 storage.path 模版化以后,这里只是 file 实际的 path
|
|
73
|
-
path,
|
|
74
|
-
size: file.size,
|
|
75
|
-
// 直接缓存起来
|
|
76
|
-
url: `${baseUrl}/${pathname}`,
|
|
77
|
-
mimetype: file.mimetype,
|
|
78
|
-
// @ts-ignore
|
|
79
|
-
meta: ctx.request.body,
|
|
80
|
-
storageId: storage.id,
|
|
81
|
-
...storageConfig.getFileData ? storageConfig.getFileData(file) : {}
|
|
82
|
-
};
|
|
83
|
-
}
|
|
84
|
-
async function multipart(ctx, next) {
|
|
85
|
-
const { storage } = ctx;
|
|
86
|
-
if (!storage) {
|
|
87
|
-
ctx.logger.error("[file-manager] no linked or default storage provided");
|
|
88
|
-
return ctx.throw(500);
|
|
89
|
-
}
|
|
90
|
-
const storageConfig = ctx.app.pm.get(import__.default).storageTypes.get(storage.type);
|
|
91
|
-
if (!storageConfig) {
|
|
92
|
-
ctx.logger.error(`[file-manager] storage type "${storage.type}" is not defined`);
|
|
93
|
-
return ctx.throw(500);
|
|
94
|
-
}
|
|
95
|
-
const multerOptions = {
|
|
96
|
-
fileFilter: getFileFilter(storage),
|
|
97
|
-
limits: {
|
|
98
|
-
// 每次只允许提交一个文件
|
|
99
|
-
files: import_constants.LIMIT_FILES
|
|
100
|
-
},
|
|
101
|
-
storage: storageConfig.make(storage)
|
|
102
|
-
};
|
|
103
|
-
multerOptions.limits["fileSize"] = Math.min(
|
|
104
|
-
Math.max(import_constants.FILE_SIZE_LIMIT_MIN, storage.rules.size ?? import_constants.FILE_SIZE_LIMIT_DEFAULT),
|
|
105
|
-
import_constants.FILE_SIZE_LIMIT_MAX
|
|
106
|
-
);
|
|
107
|
-
const upload = (0, import_utils.koaMulter)(multerOptions).single(import_constants.FILE_FIELD_NAME);
|
|
108
|
-
try {
|
|
109
|
-
await upload(ctx, () => {
|
|
110
|
-
});
|
|
111
|
-
} catch (err) {
|
|
112
|
-
if (err.name === "MulterError") {
|
|
113
|
-
return ctx.throw(400, err);
|
|
114
|
-
}
|
|
115
|
-
ctx.logger.error(err);
|
|
116
|
-
return ctx.throw(500);
|
|
117
|
-
}
|
|
118
|
-
const values = getFileData(ctx);
|
|
119
|
-
ctx.action.mergeParams({
|
|
120
|
-
values
|
|
121
|
-
});
|
|
122
|
-
await next();
|
|
123
|
-
}
|
|
124
|
-
async function createMiddleware(ctx, next) {
|
|
125
|
-
var _a, _b, _c;
|
|
126
|
-
const { resourceName, actionName } = ctx.action;
|
|
127
|
-
const { attachmentField } = ctx.action.params;
|
|
128
|
-
const collection = ctx.db.getCollection(resourceName);
|
|
129
|
-
if (((_a = collection == null ? void 0 : collection.options) == null ? void 0 : _a.template) !== "file" || !["upload", "create"].includes(actionName)) {
|
|
130
|
-
return next();
|
|
131
|
-
}
|
|
132
|
-
const storageName = ((_c = (_b = ctx.db.getFieldByPath(attachmentField)) == null ? void 0 : _b.options) == null ? void 0 : _c.storage) || collection.options.storage;
|
|
133
|
-
const StorageRepo = ctx.db.getRepository("storages");
|
|
134
|
-
const storage = await StorageRepo.findOne({ filter: storageName ? { name: storageName } : { default: true } });
|
|
135
|
-
ctx.storage = storage;
|
|
136
|
-
await multipart(ctx, next);
|
|
137
|
-
}
|
|
138
|
-
async function destroyMiddleware(ctx, next) {
|
|
139
|
-
var _a;
|
|
140
|
-
const { resourceName, actionName } = ctx.action;
|
|
141
|
-
const collection = ctx.db.getCollection(resourceName);
|
|
142
|
-
if (((_a = collection == null ? void 0 : collection.options) == null ? void 0 : _a.template) !== "file" || actionName !== "destroy") {
|
|
143
|
-
return next();
|
|
144
|
-
}
|
|
145
|
-
const repository = ctx.db.getRepository(resourceName);
|
|
146
|
-
const { filterByTk, filter } = ctx.action.params;
|
|
147
|
-
const records = await repository.find({
|
|
148
|
-
filterByTk,
|
|
149
|
-
filter,
|
|
150
|
-
context: ctx
|
|
151
|
-
});
|
|
152
|
-
const storageIds = new Set(records.map((record) => record.storageId));
|
|
153
|
-
const storageGroupedRecords = records.reduce((result, record) => {
|
|
154
|
-
const storageId = record.storageId;
|
|
155
|
-
if (!result[storageId]) {
|
|
156
|
-
result[storageId] = [];
|
|
157
|
-
}
|
|
158
|
-
result[storageId].push(record);
|
|
159
|
-
return result;
|
|
160
|
-
}, {});
|
|
161
|
-
const storages = await ctx.db.getRepository("storages").find({
|
|
162
|
-
filter: {
|
|
163
|
-
id: [...storageIds],
|
|
164
|
-
paranoid: {
|
|
165
|
-
$ne: true
|
|
166
|
-
}
|
|
167
|
-
}
|
|
168
|
-
});
|
|
169
|
-
let count = 0;
|
|
170
|
-
const undeleted = [];
|
|
171
|
-
await storages.reduce(
|
|
172
|
-
(promise, storage) => promise.then(async () => {
|
|
173
|
-
const storageConfig = ctx.app.pm.get(import__.default).storageTypes.get(storage.type);
|
|
174
|
-
const result = await storageConfig.delete(storage, storageGroupedRecords[storage.id]);
|
|
175
|
-
count += result[0];
|
|
176
|
-
undeleted.push(...result[1]);
|
|
177
|
-
}),
|
|
178
|
-
Promise.resolve()
|
|
179
|
-
);
|
|
180
|
-
if (undeleted.length) {
|
|
181
|
-
const ids = undeleted.map((record) => record.id);
|
|
182
|
-
ctx.action.mergeParams({
|
|
183
|
-
filter: {
|
|
184
|
-
id: {
|
|
185
|
-
$notIn: ids
|
|
186
|
-
}
|
|
187
|
-
}
|
|
188
|
-
});
|
|
189
|
-
ctx.logger.error("[file-manager] some of attachment files are not successfully deleted: ", { ids });
|
|
190
|
-
}
|
|
191
|
-
await next();
|
|
192
|
-
}
|
|
193
|
-
// Annotate the CommonJS export names for ESM import in node:
|
|
194
|
-
0 && (module.exports = {
|
|
195
|
-
createMiddleware,
|
|
196
|
-
destroyMiddleware
|
|
197
|
-
});
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file is part of the NocoBase (R) project.
|
|
3
|
-
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
-
* Authors: NocoBase Team.
|
|
5
|
-
*
|
|
6
|
-
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
-
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
-
*/
|
|
9
|
-
export default function ({ app }: {
|
|
10
|
-
app: any;
|
|
11
|
-
}): void;
|
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file is part of the NocoBase (R) project.
|
|
3
|
-
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
-
* Authors: NocoBase Team.
|
|
5
|
-
*
|
|
6
|
-
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
-
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
-
*/
|
|
9
|
-
|
|
10
|
-
var __create = Object.create;
|
|
11
|
-
var __defProp = Object.defineProperty;
|
|
12
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
13
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
14
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
15
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
16
|
-
var __export = (target, all) => {
|
|
17
|
-
for (var name in all)
|
|
18
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
19
|
-
};
|
|
20
|
-
var __copyProps = (to, from, except, desc) => {
|
|
21
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
22
|
-
for (let key of __getOwnPropNames(from))
|
|
23
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
24
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
25
|
-
}
|
|
26
|
-
return to;
|
|
27
|
-
};
|
|
28
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
29
|
-
// If the importer is in node compatibility mode or this is not an ESM
|
|
30
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
31
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
32
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
33
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
34
|
-
mod
|
|
35
|
-
));
|
|
36
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
37
|
-
var actions_exports = {};
|
|
38
|
-
__export(actions_exports, {
|
|
39
|
-
default: () => actions_default
|
|
40
|
-
});
|
|
41
|
-
module.exports = __toCommonJS(actions_exports);
|
|
42
|
-
var import_actions = __toESM(require("@nocobase/actions"));
|
|
43
|
-
var import_attachments = require("./attachments");
|
|
44
|
-
var storageActions = __toESM(require("./storages"));
|
|
45
|
-
function actions_default({ app }) {
|
|
46
|
-
app.resourcer.define({
|
|
47
|
-
name: "storages",
|
|
48
|
-
actions: storageActions
|
|
49
|
-
});
|
|
50
|
-
app.resourcer.use(import_attachments.createMiddleware, { tag: "createMiddleware", after: "auth" });
|
|
51
|
-
app.resourcer.registerActionHandler("upload", import_actions.default.create);
|
|
52
|
-
app.resourcer.use(import_attachments.destroyMiddleware);
|
|
53
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function getRules(context: any, next: any): Promise<any>;
|