@awell-health/awell-extensions 1.0.112 → 1.0.114
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/dist/extensions/cloudinary/actions/index.d.ts +1 -0
- package/dist/extensions/cloudinary/actions/index.js +3 -1
- package/dist/extensions/cloudinary/actions/index.js.map +1 -1
- package/dist/extensions/cloudinary/actions/uploadFiles/uploadFiles.test.js +1 -1
- package/dist/extensions/cloudinary/actions/uploadFiles/uploadFiles.test.js.map +1 -1
- package/dist/extensions/cloudinary/actions/uploadSingleFile/config/dataPoints.d.ts +6 -0
- package/dist/extensions/cloudinary/actions/uploadSingleFile/config/dataPoints.js +10 -0
- package/dist/extensions/cloudinary/actions/uploadSingleFile/config/dataPoints.js.map +1 -0
- package/dist/extensions/cloudinary/actions/uploadSingleFile/config/fields.d.ts +38 -0
- package/dist/extensions/cloudinary/actions/uploadSingleFile/config/fields.js +45 -0
- package/dist/extensions/cloudinary/actions/uploadSingleFile/config/fields.js.map +1 -0
- package/dist/extensions/cloudinary/actions/uploadSingleFile/config/index.d.ts +2 -0
- package/dist/extensions/cloudinary/actions/uploadSingleFile/config/index.js +9 -0
- package/dist/extensions/cloudinary/actions/uploadSingleFile/config/index.js.map +1 -0
- package/dist/extensions/cloudinary/actions/uploadSingleFile/index.d.ts +1 -0
- package/dist/extensions/cloudinary/actions/uploadSingleFile/index.js +6 -0
- package/dist/extensions/cloudinary/actions/uploadSingleFile/index.js.map +1 -0
- package/dist/extensions/cloudinary/actions/uploadSingleFile/uploadSingleFile.d.ts +4 -0
- package/dist/extensions/cloudinary/actions/uploadSingleFile/uploadSingleFile.js +69 -0
- package/dist/extensions/cloudinary/actions/uploadSingleFile/uploadSingleFile.js.map +1 -0
- package/dist/extensions/cloudinary/actions/uploadSingleFile/uploadSingleFile.test.d.ts +1 -0
- package/dist/extensions/cloudinary/actions/uploadSingleFile/uploadSingleFile.test.js +32 -0
- package/dist/extensions/cloudinary/actions/uploadSingleFile/uploadSingleFile.test.js.map +1 -0
- package/dist/extensions/cloudinary/index.js +1 -0
- package/dist/extensions/cloudinary/index.js.map +1 -1
- package/dist/extensions/markdown.json +2 -2
- package/package.json +1 -1
@@ -1,6 +1,8 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.uploadFiles = void 0;
|
3
|
+
exports.uploadSingleFile = exports.uploadFiles = void 0;
|
4
4
|
var uploadFiles_1 = require("./uploadFiles");
|
5
5
|
Object.defineProperty(exports, "uploadFiles", { enumerable: true, get: function () { return uploadFiles_1.uploadFiles; } });
|
6
|
+
var uploadSingleFile_1 = require("./uploadSingleFile");
|
7
|
+
Object.defineProperty(exports, "uploadSingleFile", { enumerable: true, get: function () { return uploadSingleFile_1.uploadSingleFile; } });
|
6
8
|
//# sourceMappingURL=index.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../extensions/cloudinary/actions/index.ts"],"names":[],"mappings":";;;AAAA,6CAA2C;AAAlC,0GAAA,WAAW,OAAA"}
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../extensions/cloudinary/actions/index.ts"],"names":[],"mappings":";;;AAAA,6CAA2C;AAAlC,0GAAA,WAAW,OAAA;AACpB,uDAAqD;AAA5C,oHAAA,gBAAgB,OAAA"}
|
@@ -2,7 +2,7 @@
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
3
|
const tests_1 = require("../../../../src/tests");
|
4
4
|
const uploadFiles_1 = require("./uploadFiles");
|
5
|
-
describe('Upload files
|
5
|
+
describe('Cloudinary - Upload files', () => {
|
6
6
|
const onComplete = jest.fn();
|
7
7
|
const onError = jest.fn();
|
8
8
|
beforeEach(() => {
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"uploadFiles.test.js","sourceRoot":"","sources":["../../../../../extensions/cloudinary/actions/uploadFiles/uploadFiles.test.ts"],"names":[],"mappings":";;AAAA,iDAA2D;AAC3D,+CAA2C;AAE3C,QAAQ,CAAC,
|
1
|
+
{"version":3,"file":"uploadFiles.test.js","sourceRoot":"","sources":["../../../../../extensions/cloudinary/actions/uploadFiles/uploadFiles.test.ts"],"names":[],"mappings":";;AAAA,iDAA2D;AAC3D,+CAA2C;AAE3C,QAAQ,CAAC,2BAA2B,EAAE,GAAG,EAAE;IACzC,MAAM,UAAU,GAAG,IAAI,CAAC,EAAE,EAAE,CAAA;IAC5B,MAAM,OAAO,GAAG,IAAI,CAAC,EAAE,EAAE,CAAA;IAEzB,UAAU,CAAC,GAAG,EAAE;QACd,UAAU,CAAC,SAAS,EAAE,CAAA;QACtB,OAAO,CAAC,SAAS,EAAE,CAAA;IACrB,CAAC,CAAC,CAAA;IAEF,IAAI,CAAC,yCAAyC,EAAE,KAAK,IAAI,EAAE;QACzD,MAAM,yBAAW,CAAC,iBAAiB,CACjC,IAAA,2BAAmB,EAAC;YAClB,MAAM,EAAE;gBACN,YAAY,EAAE,SAAS;gBACvB,MAAM,EAAE,SAAS;gBACjB,IAAI,EAAE,qBAAqB;aAC5B;YACD,QAAQ,EAAE;gBACR,SAAS,EAAE,YAAY;gBACvB,YAAY,EAAE,eAAe;gBAC7B,MAAM,EAAE,eAAe;aACxB;SACF,CAAC,EACF,UAAU,EACV,IAAI,CAAC,EAAE,EAAE,CACV,CAAA;QAED;;WAEG;QACH,MAAM,CAAC,UAAU,CAAC,CAAC,GAAG,CAAC,gBAAgB,EAAE,CAAA;QACzC,MAAM,CAAC,OAAO,CAAC,CAAC,GAAG,CAAC,gBAAgB,EAAE,CAAA;IACxC,CAAC,CAAC,CAAA;AACJ,CAAC,CAAC,CAAA"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"dataPoints.js","sourceRoot":"","sources":["../../../../../../extensions/cloudinary/actions/uploadSingleFile/config/dataPoints.ts"],"names":[],"mappings":";;;AAEa,QAAA,UAAU,GAAG;IACxB,OAAO,EAAE;QACP,GAAG,EAAE,SAAS;QACd,SAAS,EAAE,QAAQ;KACpB;CAC4C,CAAA"}
|
@@ -0,0 +1,38 @@
|
|
1
|
+
import { z } from 'zod';
|
2
|
+
import { FieldType } from '@awell-health/extensions-core';
|
3
|
+
export declare const fields: {
|
4
|
+
uploadPreset: {
|
5
|
+
id: string;
|
6
|
+
label: string;
|
7
|
+
description: string;
|
8
|
+
type: FieldType.STRING;
|
9
|
+
required: false;
|
10
|
+
};
|
11
|
+
folder: {
|
12
|
+
id: string;
|
13
|
+
label: string;
|
14
|
+
description: string;
|
15
|
+
type: FieldType.STRING;
|
16
|
+
required: false;
|
17
|
+
};
|
18
|
+
tags: {
|
19
|
+
id: string;
|
20
|
+
label: string;
|
21
|
+
description: string;
|
22
|
+
type: FieldType.STRING;
|
23
|
+
required: false;
|
24
|
+
};
|
25
|
+
};
|
26
|
+
export declare const FieldsValidationSchema: z.ZodObject<{
|
27
|
+
uploadPreset: z.ZodOptional<z.ZodString>;
|
28
|
+
folder: z.ZodOptional<z.ZodString>;
|
29
|
+
tags: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string[], string>, string[], string>>;
|
30
|
+
}, "strip", z.ZodTypeAny, {
|
31
|
+
uploadPreset?: string | undefined;
|
32
|
+
folder?: string | undefined;
|
33
|
+
tags?: string[] | undefined;
|
34
|
+
}, {
|
35
|
+
uploadPreset?: string | undefined;
|
36
|
+
folder?: string | undefined;
|
37
|
+
tags?: string | undefined;
|
38
|
+
}>;
|
@@ -0,0 +1,45 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.FieldsValidationSchema = exports.fields = void 0;
|
4
|
+
const lodash_1 = require("lodash");
|
5
|
+
const zod_1 = require("zod");
|
6
|
+
const extensions_core_1 = require("@awell-health/extensions-core");
|
7
|
+
exports.fields = {
|
8
|
+
uploadPreset: {
|
9
|
+
id: 'uploadPreset',
|
10
|
+
label: 'Upload preset',
|
11
|
+
description: 'The name of an upload preset defined for your product environment. If left empty, the preset defined in the extension settings will be used.',
|
12
|
+
type: extensions_core_1.FieldType.STRING,
|
13
|
+
required: false,
|
14
|
+
},
|
15
|
+
folder: {
|
16
|
+
id: 'folder',
|
17
|
+
label: 'Folder',
|
18
|
+
description: 'Upload the file to the specified folder. If left empty, the folder defined in the extension settings will be used.',
|
19
|
+
type: extensions_core_1.FieldType.STRING,
|
20
|
+
required: false,
|
21
|
+
},
|
22
|
+
tags: {
|
23
|
+
id: 'tags',
|
24
|
+
label: 'Tags',
|
25
|
+
description: 'A comma-separated string of tags to assign to the uploaded asset',
|
26
|
+
type: extensions_core_1.FieldType.STRING,
|
27
|
+
required: false,
|
28
|
+
},
|
29
|
+
};
|
30
|
+
exports.FieldsValidationSchema = zod_1.z.object({
|
31
|
+
uploadPreset: zod_1.z.optional(zod_1.z.string()),
|
32
|
+
folder: zod_1.z.optional(zod_1.z.string()),
|
33
|
+
tags: zod_1.z.optional(zod_1.z
|
34
|
+
.string()
|
35
|
+
// Make sure all white spaces are stripped
|
36
|
+
.transform((chars) => chars.replace(/\s/g, ''))
|
37
|
+
.transform((chars) => chars.split(','))
|
38
|
+
// Make sure there are no undefined or empty characteristics
|
39
|
+
.transform((charsArray) => charsArray.filter((chars) => {
|
40
|
+
if ((0, lodash_1.isNil)(chars) || (0, lodash_1.isEmpty)(chars))
|
41
|
+
return false;
|
42
|
+
return true;
|
43
|
+
}))),
|
44
|
+
});
|
45
|
+
//# sourceMappingURL=fields.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"fields.js","sourceRoot":"","sources":["../../../../../../extensions/cloudinary/actions/uploadSingleFile/config/fields.ts"],"names":[],"mappings":";;;AAAA,mCAAuC;AACvC,6BAAwC;AACxC,mEAAqE;AAExD,QAAA,MAAM,GAAG;IACpB,YAAY,EAAE;QACZ,EAAE,EAAE,cAAc;QAClB,KAAK,EAAE,eAAe;QACtB,WAAW,EACT,8IAA8I;QAChJ,IAAI,EAAE,2BAAS,CAAC,MAAM;QACtB,QAAQ,EAAE,KAAK;KAChB;IACD,MAAM,EAAE;QACN,EAAE,EAAE,QAAQ;QACZ,KAAK,EAAE,QAAQ;QACf,WAAW,EACT,oHAAoH;QACtH,IAAI,EAAE,2BAAS,CAAC,MAAM;QACtB,QAAQ,EAAE,KAAK;KAChB;IACD,IAAI,EAAE;QACJ,EAAE,EAAE,MAAM;QACV,KAAK,EAAE,MAAM;QACb,WAAW,EACT,kEAAkE;QACpE,IAAI,EAAE,2BAAS,CAAC,MAAM;QACtB,QAAQ,EAAE,KAAK;KAChB;CAC8B,CAAA;AAEpB,QAAA,sBAAsB,GAAG,OAAC,CAAC,MAAM,CAAC;IAC7C,YAAY,EAAE,OAAC,CAAC,QAAQ,CAAC,OAAC,CAAC,MAAM,EAAE,CAAC;IACpC,MAAM,EAAE,OAAC,CAAC,QAAQ,CAAC,OAAC,CAAC,MAAM,EAAE,CAAC;IAC9B,IAAI,EAAE,OAAC,CAAC,QAAQ,CACd,OAAC;SACE,MAAM,EAAE;QACT,0CAA0C;SACzC,SAAS,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC;SAC9C,SAAS,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;QACvC,4DAA4D;SAC3D,SAAS,CAAC,CAAC,UAAU,EAAE,EAAE,CACxB,UAAU,CAAC,MAAM,CAAC,CAAC,KAAK,EAAE,EAAE;QAC1B,IAAI,IAAA,cAAK,EAAC,KAAK,CAAC,IAAI,IAAA,gBAAO,EAAC,KAAK,CAAC;YAAE,OAAO,KAAK,CAAA;QAEhD,OAAO,IAAI,CAAA;IACb,CAAC,CAAC,CACH,CACJ;CACgD,CAAC,CAAA"}
|
@@ -0,0 +1,9 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.dataPoints = exports.FieldsValidationSchema = exports.fields = void 0;
|
4
|
+
var fields_1 = require("./fields");
|
5
|
+
Object.defineProperty(exports, "fields", { enumerable: true, get: function () { return fields_1.fields; } });
|
6
|
+
Object.defineProperty(exports, "FieldsValidationSchema", { enumerable: true, get: function () { return fields_1.FieldsValidationSchema; } });
|
7
|
+
var dataPoints_1 = require("./dataPoints");
|
8
|
+
Object.defineProperty(exports, "dataPoints", { enumerable: true, get: function () { return dataPoints_1.dataPoints; } });
|
9
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../extensions/cloudinary/actions/uploadSingleFile/config/index.ts"],"names":[],"mappings":";;;AAAA,mCAAyD;AAAhD,gGAAA,MAAM,OAAA;AAAE,gHAAA,sBAAsB,OAAA;AACvC,2CAAyC;AAAhC,wGAAA,UAAU,OAAA"}
|
@@ -0,0 +1 @@
|
|
1
|
+
export { uploadSingleFile } from './uploadSingleFile';
|
@@ -0,0 +1,6 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.uploadSingleFile = void 0;
|
4
|
+
var uploadSingleFile_1 = require("./uploadSingleFile");
|
5
|
+
Object.defineProperty(exports, "uploadSingleFile", { enumerable: true, get: function () { return uploadSingleFile_1.uploadSingleFile; } });
|
6
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../extensions/cloudinary/actions/uploadSingleFile/index.ts"],"names":[],"mappings":";;;AAAA,uDAAqD;AAA5C,oHAAA,gBAAgB,OAAA"}
|
@@ -0,0 +1,69 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.uploadSingleFile = void 0;
|
4
|
+
const extensions_core_1 = require("@awell-health/extensions-core");
|
5
|
+
const settings_1 = require("../../settings");
|
6
|
+
const config_1 = require("./config");
|
7
|
+
const zod_validation_error_1 = require("zod-validation-error");
|
8
|
+
const zod_1 = require("zod");
|
9
|
+
exports.uploadSingleFile = {
|
10
|
+
key: 'uploadSingleFile',
|
11
|
+
title: 'Upload single file',
|
12
|
+
description: 'Allow a stakeholder to upload one file',
|
13
|
+
category: extensions_core_1.Category.CONTENT_AND_FILES,
|
14
|
+
fields: config_1.fields,
|
15
|
+
options: {
|
16
|
+
stakeholders: {
|
17
|
+
label: 'Stakeholder',
|
18
|
+
mode: 'single',
|
19
|
+
},
|
20
|
+
},
|
21
|
+
dataPoints: config_1.dataPoints,
|
22
|
+
previewable: false,
|
23
|
+
onActivityCreated: async (payload, onComplete, onError) => {
|
24
|
+
try {
|
25
|
+
(0, extensions_core_1.validate)({
|
26
|
+
schema: zod_1.z.object({
|
27
|
+
settings: settings_1.SettingsValidationSchema,
|
28
|
+
fields: config_1.FieldsValidationSchema,
|
29
|
+
}),
|
30
|
+
payload,
|
31
|
+
});
|
32
|
+
/**
|
33
|
+
* Completion happens in Awell Hosted Pages
|
34
|
+
*/
|
35
|
+
}
|
36
|
+
catch (err) {
|
37
|
+
if (err instanceof zod_1.ZodError) {
|
38
|
+
const error = (0, zod_validation_error_1.fromZodError)(err);
|
39
|
+
await onError({
|
40
|
+
events: [
|
41
|
+
{
|
42
|
+
date: new Date().toISOString(),
|
43
|
+
text: { en: error.name },
|
44
|
+
error: {
|
45
|
+
category: 'WRONG_INPUT',
|
46
|
+
message: `${error.message}`,
|
47
|
+
},
|
48
|
+
},
|
49
|
+
],
|
50
|
+
});
|
51
|
+
return;
|
52
|
+
}
|
53
|
+
const error = err;
|
54
|
+
await onError({
|
55
|
+
events: [
|
56
|
+
{
|
57
|
+
date: new Date().toISOString(),
|
58
|
+
text: { en: 'Something went wrong while orchestration the action' },
|
59
|
+
error: {
|
60
|
+
category: 'SERVER_ERROR',
|
61
|
+
message: error.message,
|
62
|
+
},
|
63
|
+
},
|
64
|
+
],
|
65
|
+
});
|
66
|
+
}
|
67
|
+
},
|
68
|
+
};
|
69
|
+
//# sourceMappingURL=uploadSingleFile.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"uploadSingleFile.js","sourceRoot":"","sources":["../../../../../extensions/cloudinary/actions/uploadSingleFile/uploadSingleFile.ts"],"names":[],"mappings":";;;AACA,mEAAkE;AAClE,6CAAwE;AACxE,qCAAqE;AACrE,+DAAmD;AACnD,6BAAiC;AAEpB,QAAA,gBAAgB,GAA2C;IACtE,GAAG,EAAE,kBAAkB;IACvB,KAAK,EAAE,oBAAoB;IAC3B,WAAW,EAAE,wCAAwC;IACrD,QAAQ,EAAE,0BAAQ,CAAC,iBAAiB;IACpC,MAAM,EAAN,eAAM;IACN,OAAO,EAAE;QACP,YAAY,EAAE;YACZ,KAAK,EAAE,aAAa;YACpB,IAAI,EAAE,QAAQ;SACf;KACF;IACD,UAAU,EAAV,mBAAU;IACV,WAAW,EAAE,KAAK;IAClB,iBAAiB,EAAE,KAAK,EAAE,OAAO,EAAE,UAAU,EAAE,OAAO,EAAE,EAAE;QACxD,IAAI;YACF,IAAA,0BAAQ,EAAC;gBACP,MAAM,EAAE,OAAC,CAAC,MAAM,CAAC;oBACf,QAAQ,EAAE,mCAAwB;oBAClC,MAAM,EAAE,+BAAsB;iBAC/B,CAAC;gBACF,OAAO;aACR,CAAC,CAAA;YAEF;;eAEG;SACJ;QAAC,OAAO,GAAG,EAAE;YACZ,IAAI,GAAG,YAAY,cAAQ,EAAE;gBAC3B,MAAM,KAAK,GAAG,IAAA,mCAAY,EAAC,GAAG,CAAC,CAAA;gBAC/B,MAAM,OAAO,CAAC;oBACZ,MAAM,EAAE;wBACN;4BACE,IAAI,EAAE,IAAI,IAAI,EAAE,CAAC,WAAW,EAAE;4BAC9B,IAAI,EAAE,EAAE,EAAE,EAAE,KAAK,CAAC,IAAI,EAAE;4BACxB,KAAK,EAAE;gCACL,QAAQ,EAAE,aAAa;gCACvB,OAAO,EAAE,GAAG,KAAK,CAAC,OAAO,EAAE;6BAC5B;yBACF;qBACF;iBACF,CAAC,CAAA;gBACF,OAAM;aACP;YAED,MAAM,KAAK,GAAG,GAAY,CAAA;YAC1B,MAAM,OAAO,CAAC;gBACZ,MAAM,EAAE;oBACN;wBACE,IAAI,EAAE,IAAI,IAAI,EAAE,CAAC,WAAW,EAAE;wBAC9B,IAAI,EAAE,EAAE,EAAE,EAAE,qDAAqD,EAAE;wBACnE,KAAK,EAAE;4BACL,QAAQ,EAAE,cAAc;4BACxB,OAAO,EAAE,KAAK,CAAC,OAAO;yBACvB;qBACF;iBACF;aACF,CAAC,CAAA;SACH;IACH,CAAC;CACF,CAAA"}
|
@@ -0,0 +1 @@
|
|
1
|
+
export {};
|
@@ -0,0 +1,32 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
const tests_1 = require("../../../../src/tests");
|
4
|
+
const uploadSingleFile_1 = require("./uploadSingleFile");
|
5
|
+
describe('Cloudinary - Upload single file', () => {
|
6
|
+
const onComplete = jest.fn();
|
7
|
+
const onError = jest.fn();
|
8
|
+
beforeEach(() => {
|
9
|
+
onComplete.mockClear();
|
10
|
+
onError.mockClear();
|
11
|
+
});
|
12
|
+
test('Should not call the onComplete callback', async () => {
|
13
|
+
await uploadSingleFile_1.uploadSingleFile.onActivityCreated((0, tests_1.generateTestPayload)({
|
14
|
+
fields: {
|
15
|
+
uploadPreset: undefined,
|
16
|
+
folder: undefined,
|
17
|
+
tags: 'tag-1, tag-2, tag-3',
|
18
|
+
},
|
19
|
+
settings: {
|
20
|
+
cloudName: 'cloud-name',
|
21
|
+
uploadPreset: 'upload-preset',
|
22
|
+
folder: 'variant-label',
|
23
|
+
},
|
24
|
+
}), onComplete, jest.fn());
|
25
|
+
/**
|
26
|
+
* Because completion is done in Awell Hosted Pages
|
27
|
+
*/
|
28
|
+
expect(onComplete).not.toHaveBeenCalled();
|
29
|
+
expect(onError).not.toHaveBeenCalled();
|
30
|
+
});
|
31
|
+
});
|
32
|
+
//# sourceMappingURL=uploadSingleFile.test.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"uploadSingleFile.test.js","sourceRoot":"","sources":["../../../../../extensions/cloudinary/actions/uploadSingleFile/uploadSingleFile.test.ts"],"names":[],"mappings":";;AAAA,iDAA2D;AAC3D,yDAAqD;AAErD,QAAQ,CAAC,iCAAiC,EAAE,GAAG,EAAE;IAC/C,MAAM,UAAU,GAAG,IAAI,CAAC,EAAE,EAAE,CAAA;IAC5B,MAAM,OAAO,GAAG,IAAI,CAAC,EAAE,EAAE,CAAA;IAEzB,UAAU,CAAC,GAAG,EAAE;QACd,UAAU,CAAC,SAAS,EAAE,CAAA;QACtB,OAAO,CAAC,SAAS,EAAE,CAAA;IACrB,CAAC,CAAC,CAAA;IAEF,IAAI,CAAC,yCAAyC,EAAE,KAAK,IAAI,EAAE;QACzD,MAAM,mCAAgB,CAAC,iBAAiB,CACtC,IAAA,2BAAmB,EAAC;YAClB,MAAM,EAAE;gBACN,YAAY,EAAE,SAAS;gBACvB,MAAM,EAAE,SAAS;gBACjB,IAAI,EAAE,qBAAqB;aAC5B;YACD,QAAQ,EAAE;gBACR,SAAS,EAAE,YAAY;gBACvB,YAAY,EAAE,eAAe;gBAC7B,MAAM,EAAE,eAAe;aACxB;SACF,CAAC,EACF,UAAU,EACV,IAAI,CAAC,EAAE,EAAE,CACV,CAAA;QAED;;WAEG;QACH,MAAM,CAAC,UAAU,CAAC,CAAC,GAAG,CAAC,gBAAgB,EAAE,CAAA;QACzC,MAAM,CAAC,OAAO,CAAC,CAAC,GAAG,CAAC,gBAAgB,EAAE,CAAA;IACxC,CAAC,CAAC,CAAA;AACJ,CAAC,CAAC,CAAA"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../extensions/cloudinary/index.ts"],"names":[],"mappings":";;;AACA,mEAAoE;AACpE,
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../extensions/cloudinary/index.ts"],"names":[],"mappings":";;;AACA,mEAAoE;AACpE,uCAAyD;AACzD,yCAAqC;AAExB,QAAA,UAAU,GAAc;IACnC,GAAG,EAAE,YAAY;IACjB,KAAK,EAAE,YAAY;IACnB,QAAQ,EACN,6GAA6G;IAC/G,WAAW,EACT,6HAA6H;IAC/H,QAAQ,EAAE,0BAAQ,CAAC,iBAAiB;IACpC,MAAM,EAAE;QACN,UAAU,EAAE,4BAAU,CAAC,KAAK;KAC7B;IACD,OAAO,EAAE;QACP,WAAW,EAAX,qBAAW;QACX,gBAAgB,EAAhB,0BAAgB;KACjB;IACD,QAAQ,EAAR,mBAAQ;CACT,CAAA"}
|
@@ -16,8 +16,8 @@
|
|
16
16
|
"changelog": "# Canvas Medical changelog\n\n## 2023-09-01\n\n- Add new actions: `createAppointment`, `createPatient`, `createQuestionnaireResponses`, `createTask`, `updateAppointment`, `updatePatient`, and `updateTask` for enhanced functionality.\n"
|
17
17
|
},
|
18
18
|
"cloudinary": {
|
19
|
-
"readme": "---\ntitle: Cloudinary\ndescription: Cloudinary is a cloud-based image and video management platform that provides a comprehensive set of tools for storing, managing, and delivering digital media assets. \n---\n# Cloudinary\n\nCloudinary is a cloud-based image and video management platform that provides a comprehensive set of tools for storing, managing, and delivering digital media assets. It enables users to upload, manipulate, optimize, and deliver media files to any device or website quickly and easily.\n\nThe platform offers features such as image and video transformation, automatic image optimization, and responsive image delivery. Cloudinary also provides tools for organizing media assets, including tags, folders, and metadata.\n\n##
|
20
|
-
"changelog": "# Cloudinary changelog"
|
19
|
+
"readme": "---\ntitle: Cloudinary\ndescription: Cloudinary is a cloud-based image and video management platform that provides a comprehensive set of tools for storing, managing, and delivering digital media assets. \n---\n# Cloudinary\n\nCloudinary is a cloud-based image and video management platform that provides a comprehensive set of tools for storing, managing, and delivering digital media assets. It enables users to upload, manipulate, optimize, and deliver media files to any device or website quickly and easily.\n\nThe platform offers features such as image and video transformation, automatic image optimization, and responsive image delivery. Cloudinary also provides tools for organizing media assets, including tags, folders, and metadata.\n\n## Set up\n\nTo set up this extension and allow image upload you will need to:\n\n1. Have a Cloudinary account and know your cloud name\n2. Created an upload preset that allows for **unsigned uploads**\n\n## Custom Actions\n\n### Upload single file\n\nAllows a user to upload a single file using Awell Hosted Pages (all file types allowed). The URL of the uploaded file is returned as a data point.\n### Upload files\n\nThis action allows a given stakeholder to upload one or many files using Awell Hosted Pages (all file types allowed). This action currently doesn't return the URLs of the uploaded files. If you need this functionality, please use the \"Upload single file\" action for now.\n",
|
20
|
+
"changelog": "# Cloudinary changelog\n\n## October 2023\n\n- Action added: Upload a single file"
|
21
21
|
},
|
22
22
|
"cmDotCom": {
|
23
23
|
"readme": "---\ntitle: cm.com\ndescription: CM.com is a global communication and digital services provider based in the Netherlands.\n---\n# CM.com\n\nCM.com is a global communication and digital services provider based in the Netherlands. It offers a wide range of services and solutions in the areas of messaging, payments, voice, and customer experience.\n\nCM.com enables businesses to communicate with their customers through various channels such as SMS, email, push notifications, social media messaging, and more.\n\n## Extension settings\n\nIn order to set up this extension, you will need:\n\n1. A **Product Token** - visit https://gateway.cmtelecom.com/ to retrieve your product token.\n2. A **From/sender name** - the maximum length is 11 alphanumerical characters or 16 digit\n\n## Custom Actions\n\n### Send SMS\n\nSend an SMS with CM.com to a recipient of your liking.\n",
|