@bindu-dashing/dam-solution-v2 5.8.150 → 5.8.151

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.
@@ -8,7 +8,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
8
8
  });
9
9
  };
10
10
  import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
11
- import { Button, Drawer, Form, Input, Select, Typography } from "antd";
11
+ import { Button, Checkbox, Drawer, Form, Input, Select, Typography } from "antd";
12
12
  import { useEffect, useMemo, useState } from "react";
13
13
  import { ACCESS_TYPES, DAM_LOCATION_TYPES } from "../hocs/appConstants";
14
14
  import { useDamConfig } from "../hocs/DamConfigContext";
@@ -41,9 +41,9 @@ const CreateClientForm = ({ teamsApi, username, password, toggleShow, onSuccess,
41
41
  }
42
42
  }, [existingClientData]);
43
43
  const onFinish = (data) => __awaiter(void 0, void 0, void 0, function* () {
44
- var _a, _b, _c, _d, _e, _f, _g;
44
+ var _a, _b, _c, _d, _e, _f, _g, _h;
45
45
  try {
46
- const values = Object.assign(Object.assign({}, data), { accessKey: appType == "reactJs"
46
+ const values = Object.assign(Object.assign({}, data), { showFilePreview: (_a = data.showFilePreview) !== null && _a !== void 0 ? _a : false, accessKey: appType == "reactJs"
47
47
  ? process.env.REACT_APP_MIXDRIVE_CLIENT_PARENT_ACCESS_KEY
48
48
  : process.env.NEXT_PUBLIC_MIXDRIVE_CLIENT_PARENT_ACCESS_KEY, secretKey: appType == "reactJs"
49
49
  ? process.env.REACT_APP_MIXDRIVE_CLIENT_PARENT_SECRET_KEY
@@ -55,13 +55,13 @@ const CreateClientForm = ({ teamsApi, username, password, toggleShow, onSuccess,
55
55
  password: password,
56
56
  }, damLocationDetails: damLocationType === "external"
57
57
  ? {
58
- bucket: (_a = data === null || data === void 0 ? void 0 : data.damLocationDetails) === null || _a === void 0 ? void 0 : _a.bucket,
58
+ bucket: (_b = data === null || data === void 0 ? void 0 : data.damLocationDetails) === null || _b === void 0 ? void 0 : _b.bucket,
59
59
  locationType: damLocationType === "external" ? "EXTERNAL" : "INTERNAL",
60
- rootPath: (_b = data === null || data === void 0 ? void 0 : data.damLocationDetails) === null || _b === void 0 ? void 0 : _b.rootPath,
61
- accessKeyId: (_c = data === null || data === void 0 ? void 0 : data.damLocationDetails) === null || _c === void 0 ? void 0 : _c.accessKeyId,
62
- secretAccessKey: (_d = data === null || data === void 0 ? void 0 : data.damLocationDetails) === null || _d === void 0 ? void 0 : _d.secretAccessKey,
63
- url: (_e = data === null || data === void 0 ? void 0 : data.damLocationDetails) === null || _e === void 0 ? void 0 : _e.url,
64
- region: (_f = data === null || data === void 0 ? void 0 : data.damLocationDetails) === null || _f === void 0 ? void 0 : _f.region,
60
+ rootPath: (_c = data === null || data === void 0 ? void 0 : data.damLocationDetails) === null || _c === void 0 ? void 0 : _c.rootPath,
61
+ accessKeyId: (_d = data === null || data === void 0 ? void 0 : data.damLocationDetails) === null || _d === void 0 ? void 0 : _d.accessKeyId,
62
+ secretAccessKey: (_e = data === null || data === void 0 ? void 0 : data.damLocationDetails) === null || _e === void 0 ? void 0 : _e.secretAccessKey,
63
+ url: (_f = data === null || data === void 0 ? void 0 : data.damLocationDetails) === null || _f === void 0 ? void 0 : _f.url,
64
+ region: (_g = data === null || data === void 0 ? void 0 : data.damLocationDetails) === null || _g === void 0 ? void 0 : _g.region,
65
65
  }
66
66
  : {
67
67
  locationType: damLocationType === "external" ? "EXTERNAL" : "INTERNAL",
@@ -69,7 +69,7 @@ const CreateClientForm = ({ teamsApi, username, password, toggleShow, onSuccess,
69
69
  setLoading(true);
70
70
  const response = yield api.post(CREATE_SUB_BRAND, values);
71
71
  setLoading(false);
72
- showNotification((_g = response === null || response === void 0 ? void 0 : response.message) !== null && _g !== void 0 ? _g : (get(response, "message") || CREATE_SUCCESS), NotificationStatus.SUCCESS);
72
+ showNotification((_h = response === null || response === void 0 ? void 0 : response.message) !== null && _h !== void 0 ? _h : (get(response, "message") || CREATE_SUCCESS), NotificationStatus.SUCCESS);
73
73
  toggleShow();
74
74
  if (onSuccess) {
75
75
  onSuccess(response === null || response === void 0 ? void 0 : response.data);
@@ -164,6 +164,6 @@ const CreateClientForm = ({ teamsApi, username, password, toggleShow, onSuccess,
164
164
  required: true,
165
165
  message: "Subdomain is required",
166
166
  },
167
- ], children: _jsx(Input, { placeholder: "Subdomain" }) }), _jsx(Form.Item, { children: _jsx(Button, { htmlType: "submit", type: "primary", block: true, loading: loading, children: "Submit" }) })] }) }));
167
+ ], children: _jsx(Input, { placeholder: "Subdomain" }) }), _jsx(Form.Item, { name: "showFilePreview", valuePropName: "checked", initialValue: false, children: _jsx(Checkbox, { children: "Show File Preview" }) }), _jsx(Form.Item, { children: _jsx(Button, { htmlType: "submit", type: "primary", block: true, loading: loading, children: "Submit" }) })] }) }));
168
168
  };
169
169
  export default CreateClientForm;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bindu-dashing/dam-solution-v2",
3
- "version": "5.8.150",
3
+ "version": "5.8.151",
4
4
  "dependencies": {
5
5
  "@ant-design/icons": "^5.0.1",
6
6
  "@emoji-mart/data": "^1.2.1",