diff --git a/client/index.js b/client/index.js index 0706e23..4eb1422 100644 --- a/client/index.js +++ b/client/index.js @@ -3,8 +3,8 @@ * Imports * ============================================================================== */ -import imageInputFileToBase64 from "./media/imageInputFileToBase64"; -import imageInputToBase64 from "./media/imageInputToBase64"; +const imageInputFileToBase64 = require("./media/imageInputFileToBase64"); +const imageInputToBase64 = require("./media/imageInputToBase64"); /** ****************************************************************************** */ /** ****************************************************************************** */ diff --git a/client/media/client.js b/client/media/client.js new file mode 100644 index 0000000..671d450 --- /dev/null +++ b/client/media/client.js @@ -0,0 +1,39 @@ +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +import imageInputFileToBase64 from "./imageInputFileToBase64"; +import imageInputToBase64 from "./imageInputToBase64"; + +/** ****************************************************************************** */ +/** ****************************************************************************** */ +/** ****************************************************************************** */ +/** ****************************************************************************** */ +/** ****************************************************************************** */ +/** ****************************************************************************** */ + +/** + * ============================================================================== + * Media Functions Object + * ============================================================================== + */ +const media = { + imageInputToBase64: imageInputToBase64, + imageInputFileToBase64: imageInputFileToBase64, +}; + +/** + * ============================================================================== + * Main Export + * ============================================================================== + */ +const datasquirelClient = { + media: media, +}; + +export default datasquirelClient; + +/** ********************************************** */ +/** ********************************************** */ +/** ********************************************** */ diff --git a/client/media/imageInputFileToBase64.js b/client/media/imageInputFileToBase64.js index 9ecf137..9eb2125 100644 --- a/client/media/imageInputFileToBase64.js +++ b/client/media/imageInputFileToBase64.js @@ -21,7 +21,7 @@ * * @returns { Promise } - Return Object */ -export default async function imageInputFileToBase64({ imageInputFile, maxWidth, imagePreviewNode }) { +module.exports = async function imageInputFileToBase64({ imageInputFile, maxWidth, imagePreviewNode }) { /** * Make https request * @@ -108,7 +108,7 @@ export default async function imageInputFileToBase64({ imageInputFile, maxWidth, imageSize: null, }; } -} +}; /** ********************************************** */ /** ********************************************** */ diff --git a/client/media/imageInputToBase64.js b/client/media/imageInputToBase64.js index 9e616e9..23bd2bf 100644 --- a/client/media/imageInputToBase64.js +++ b/client/media/imageInputToBase64.js @@ -20,7 +20,7 @@ * * @returns { Promise } - Return Object */ -export default async function imageInputToBase64({ imageInput, maxWidth, mimeType }) { +module.exports = async function imageInputToBase64({ imageInput, maxWidth, mimeType }) { /** * Make https request * @@ -94,7 +94,7 @@ export default async function imageInputToBase64({ imageInput, maxWidth, mimeTyp imageName: null, }; } -} +}; /** ********************************************** */ /** ********************************************** */ diff --git a/package.json b/package.json index 989f6c5..7de45a6 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "datasquirel", - "version": "1.1.32", + "version": "1.1.33", "description": "Cloud-based SQL data management tool", "main": "index.js", "scripts": {