vintasend-aws-s3-attachments 0.9.1 → 0.11.0
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.
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
1
|
+
import type { AttachmentFile, AttachmentFileRecord, FileAttachment, StorageIdentifiers } from 'vintasend';
|
|
2
|
+
import { BaseAttachmentManager } from 'vintasend';
|
|
3
3
|
export interface S3AttachmentManagerConfig {
|
|
4
4
|
/**
|
|
5
5
|
* S3 bucket name where attachments will be stored
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"aws-s3-attachment-manager.d.ts","sourceRoot":"","sources":["../src/aws-s3-attachment-manager.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"aws-s3-attachment-manager.d.ts","sourceRoot":"","sources":["../src/aws-s3-attachment-manager.ts"],"names":[],"mappings":"AASA,OAAO,KAAK,EACV,cAAc,EACd,oBAAoB,EACpB,cAAc,EACd,kBAAkB,EACnB,MAAM,WAAW,CAAC;AACnB,OAAO,EAAE,qBAAqB,EAAE,MAAM,WAAW,CAAC;AAGlD,MAAM,WAAW,yBAAyB;IACxC;;OAEG;IACH,MAAM,EAAE,MAAM,CAAC;IAEf;;OAEG;IACH,MAAM,EAAE,MAAM,CAAC;IAEf;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;;OAGG;IACH,WAAW,CAAC,EAAE;QACZ,WAAW,EAAE,MAAM,CAAC;QACpB,eAAe,EAAE,MAAM,CAAC;KACzB,CAAC;IAEF;;;OAGG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAElB;;OAEG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CAC1C;AAED;;;;;;;;;;;GAWG;AACH,qBAAa,mBAAoB,SAAQ,qBAAqB;IAC5D,OAAO,CAAC,QAAQ,CAAW;IAC3B,OAAO,CAAC,MAAM,CAAS;IACvB,OAAO,CAAC,SAAS,CAAS;gBAEd,MAAM,EAAE,yBAAyB;IAc7C;;;;;;;OAOG;IACG,UAAU,CACd,IAAI,EAAE,cAAc,EACpB,QAAQ,EAAE,MAAM,EAChB,WAAW,CAAC,EAAE,MAAM,GACnB,OAAO,CAAC,oBAAoB,CAAC;IAgDhC;;;;;;;;;;;OAWG;IACG,OAAO,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,oBAAoB,GAAG,IAAI,CAAC;IA0DnE;;;;;;;;OAQG;IACH,yBAAyB,CAAC,kBAAkB,EAAE,kBAAkB,GAAG,cAAc;IAUjF;;;;;;;OAOG;IACG,uBAAuB,CAAC,kBAAkB,EAAE,kBAAkB,GAAG,OAAO,CAAC,IAAI,CAAC;IAepF;;;;;;OAMG;IACH,OAAO,CAAC,UAAU;CAMnB"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { BaseAttachmentManager } from 'vintasend/dist/services/attachment-manager/base-attachment-manager';
|
|
2
|
-
import { S3Client, PutObjectCommand, GetObjectCommand, DeleteObjectCommand, } from '@aws-sdk/client-s3';
|
|
3
|
-
import { getSignedUrl } from '@aws-sdk/s3-request-presigner';
|
|
4
|
-
import { Readable } from 'node:stream';
|
|
5
1
|
import { randomUUID } from 'node:crypto';
|
|
2
|
+
import { Readable } from 'node:stream';
|
|
3
|
+
import { DeleteObjectCommand, GetObjectCommand, PutObjectCommand, S3Client, } from '@aws-sdk/client-s3';
|
|
4
|
+
import { getSignedUrl } from '@aws-sdk/s3-request-presigner';
|
|
5
|
+
import { BaseAttachmentManager } from 'vintasend';
|
|
6
6
|
/**
|
|
7
7
|
* AWS S3 AttachmentManager implementation for VintaSend.
|
|
8
8
|
*
|
|
@@ -132,7 +132,7 @@ export class S3AttachmentManager extends BaseAttachmentManager {
|
|
|
132
132
|
updatedAt: headResponse.LastModified || new Date(),
|
|
133
133
|
};
|
|
134
134
|
}
|
|
135
|
-
catch (
|
|
135
|
+
catch (_error) {
|
|
136
136
|
return null;
|
|
137
137
|
}
|
|
138
138
|
}
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,mBAAmB,EACnB,KAAK,yBAAyB,GAC/B,MAAM,6BAA6B,CAAC"}
|
package/dist/types.d.ts
CHANGED
package/dist/types.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,WAAW,CAAC;AAEpD;;;;;;;;GAQG;AACH,MAAM,WAAW,oBAAqB,SAAQ,kBAAkB;IAE9D,EAAE,EAAE,MAAM,CAAC;IAGX,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;IAGpB,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC;CACxB"}
|
package/package.json
CHANGED
|
@@ -1,11 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "vintasend-aws-s3-attachments",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.11.0",
|
|
4
4
|
"description": "Implementation of AWS S3 Attachments for VintaSend",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"scripts": {
|
|
7
7
|
"build": "tsc",
|
|
8
8
|
"prepublishOnly": "npm run build",
|
|
9
|
+
"prepare": "husky",
|
|
10
|
+
"lint": "biome check .",
|
|
11
|
+
"format": "biome check --write .",
|
|
9
12
|
"test": "vitest run",
|
|
10
13
|
"test:watch": "vitest",
|
|
11
14
|
"test:coverage": "vitest run --coverage"
|
|
@@ -18,10 +21,12 @@
|
|
|
18
21
|
"dependencies": {
|
|
19
22
|
"@aws-sdk/client-s3": "^3.1000.0",
|
|
20
23
|
"@aws-sdk/s3-request-presigner": "^3.1000.0",
|
|
21
|
-
"vintasend": "^0.
|
|
24
|
+
"vintasend": "^0.11.0"
|
|
22
25
|
},
|
|
23
26
|
"devDependencies": {
|
|
27
|
+
"@biomejs/biome": "^2.4.5",
|
|
24
28
|
"@vitest/coverage-v8": "^4.0.18",
|
|
29
|
+
"husky": "^9.1.7",
|
|
25
30
|
"typescript": "^5.9.3",
|
|
26
31
|
"vitest": "^4.0.18"
|
|
27
32
|
}
|