@bigbinary/neeto-integrations-frontend 2.12.7 → 2.12.8
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/app/javascript/src/translations/en.json +1 -1
- package/dist/Daily.cjs.js +276 -204
- package/dist/Daily.cjs.js.map +1 -1
- package/dist/Daily.js +270 -204
- package/dist/Daily.js.map +1 -1
- package/dist/GoogleCalender.cjs.js +372 -282
- package/dist/GoogleCalender.cjs.js.map +1 -1
- package/dist/GoogleCalender.js +364 -282
- package/dist/GoogleCalender.js.map +1 -1
- package/dist/Twilio.cjs.js +73 -59
- package/dist/Twilio.cjs.js.map +1 -1
- package/dist/Twilio.js +66 -55
- package/dist/Twilio.js.map +1 -1
- package/dist/ZapierForm.cjs.js +138 -105
- package/dist/ZapierForm.cjs.js.map +1 -1
- package/dist/ZapierForm.js +126 -100
- package/dist/ZapierForm.js.map +1 -1
- package/dist/Zoom.cjs.js +280 -208
- package/dist/Zoom.cjs.js.map +1 -1
- package/dist/Zoom.js +275 -209
- package/dist/Zoom.js.map +1 -1
- package/dist/index.cjs.js +514 -410
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.js +505 -410
- package/dist/index.js.map +1 -1
- package/package.json +14 -13
- package/types.d.ts +3 -0
|
@@ -4,7 +4,9 @@ var React = require('react');
|
|
|
4
4
|
var neetoCist = require('@bigbinary/neeto-cist');
|
|
5
5
|
var utils = require('@bigbinary/neeto-commons-frontend/utils');
|
|
6
6
|
var misc = require('@bigbinary/neeto-icons/misc');
|
|
7
|
-
var
|
|
7
|
+
var Typography = require('@bigbinary/neetoui/Typography');
|
|
8
|
+
var Callout = require('@bigbinary/neetoui/Callout');
|
|
9
|
+
var Button = require('@bigbinary/neetoui/Button');
|
|
8
10
|
var reactI18next = require('react-i18next');
|
|
9
11
|
require('@bigbinary/neeto-molecules/IntegrationCard');
|
|
10
12
|
var DisconnectAlert = require('@bigbinary/neeto-molecules/IntegrationDisconnectAlert');
|
|
@@ -12,6 +14,7 @@ var WalkthroughModal = require('@bigbinary/neeto-molecules/IntegrationWalkthroug
|
|
|
12
14
|
var classnames = require('classnames');
|
|
13
15
|
var reactUtils = require('@bigbinary/neeto-commons-frontend/react-utils');
|
|
14
16
|
var neetoIcons = require('@bigbinary/neeto-icons');
|
|
17
|
+
var Tooltip = require('@bigbinary/neetoui/Tooltip');
|
|
15
18
|
var i18next = require('i18next');
|
|
16
19
|
var constants = require('@bigbinary/neeto-commons-frontend/constants');
|
|
17
20
|
var reactQuery = require('react-query');
|
|
@@ -20,9 +23,15 @@ var Container = require('@bigbinary/neeto-molecules/Container');
|
|
|
20
23
|
var Header = require('@bigbinary/neeto-molecules/Header');
|
|
21
24
|
var HelpPopover = require('@bigbinary/neeto-molecules/HelpPopover');
|
|
22
25
|
var PageLoader = require('@bigbinary/neeto-molecules/PageLoader');
|
|
23
|
-
var
|
|
26
|
+
var Input = require('@bigbinary/neetoui/formik/Input');
|
|
27
|
+
var FormikForm = require('@bigbinary/neetoui/formik/Form');
|
|
28
|
+
var ActionBlock = require('@bigbinary/neetoui/formik/ActionBlock');
|
|
29
|
+
var reactRouterDom = require('react-router-dom');
|
|
30
|
+
var jsxRuntime = require('react/jsx-runtime');
|
|
24
31
|
require('ramda');
|
|
32
|
+
require('@bigbinary/neetoui/formik/Select');
|
|
25
33
|
var yup = require('yup');
|
|
34
|
+
var NeetoUIModal = require('@bigbinary/neetoui/Modal');
|
|
26
35
|
var CopyToClipboardButton = require('@bigbinary/neeto-molecules/CopyToClipboardButton');
|
|
27
36
|
|
|
28
37
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
@@ -47,16 +56,24 @@ function _interopNamespace(e) {
|
|
|
47
56
|
|
|
48
57
|
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
49
58
|
var React__namespace = /*#__PURE__*/_interopNamespace(React);
|
|
59
|
+
var Typography__default = /*#__PURE__*/_interopDefaultLegacy(Typography);
|
|
60
|
+
var Callout__default = /*#__PURE__*/_interopDefaultLegacy(Callout);
|
|
61
|
+
var Button__default = /*#__PURE__*/_interopDefaultLegacy(Button);
|
|
50
62
|
var DisconnectAlert__default = /*#__PURE__*/_interopDefaultLegacy(DisconnectAlert);
|
|
51
63
|
var WalkthroughModal__default = /*#__PURE__*/_interopDefaultLegacy(WalkthroughModal);
|
|
52
64
|
var classnames__default = /*#__PURE__*/_interopDefaultLegacy(classnames);
|
|
65
|
+
var Tooltip__default = /*#__PURE__*/_interopDefaultLegacy(Tooltip);
|
|
53
66
|
var i18next__default = /*#__PURE__*/_interopDefaultLegacy(i18next);
|
|
54
67
|
var axios__default = /*#__PURE__*/_interopDefaultLegacy(axios);
|
|
55
68
|
var Container__default = /*#__PURE__*/_interopDefaultLegacy(Container);
|
|
56
69
|
var Header__default = /*#__PURE__*/_interopDefaultLegacy(Header);
|
|
57
70
|
var HelpPopover__default = /*#__PURE__*/_interopDefaultLegacy(HelpPopover);
|
|
58
71
|
var PageLoader__default = /*#__PURE__*/_interopDefaultLegacy(PageLoader);
|
|
72
|
+
var Input__default = /*#__PURE__*/_interopDefaultLegacy(Input);
|
|
73
|
+
var FormikForm__default = /*#__PURE__*/_interopDefaultLegacy(FormikForm);
|
|
74
|
+
var ActionBlock__default = /*#__PURE__*/_interopDefaultLegacy(ActionBlock);
|
|
59
75
|
var yup__namespace = /*#__PURE__*/_interopNamespace(yup);
|
|
76
|
+
var NeetoUIModal__default = /*#__PURE__*/_interopDefaultLegacy(NeetoUIModal);
|
|
60
77
|
var CopyToClipboardButton__default = /*#__PURE__*/_interopDefaultLegacy(CopyToClipboardButton);
|
|
61
78
|
|
|
62
79
|
function _typeof(o) {
|
|
@@ -171,21 +188,8 @@ function _slicedToArray(arr, i) {
|
|
|
171
188
|
return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest();
|
|
172
189
|
}
|
|
173
190
|
|
|
174
|
-
function
|
|
175
|
-
|
|
176
|
-
for (var i = 1; i < arguments.length; i++) {
|
|
177
|
-
var source = arguments[i];
|
|
178
|
-
for (var key in source) {
|
|
179
|
-
if (Object.prototype.hasOwnProperty.call(source, key)) {
|
|
180
|
-
target[key] = source[key];
|
|
181
|
-
}
|
|
182
|
-
}
|
|
183
|
-
}
|
|
184
|
-
return target;
|
|
185
|
-
};
|
|
186
|
-
return _extends$1.apply(this, arguments);
|
|
187
|
-
}
|
|
188
|
-
|
|
191
|
+
function ownKeys$5(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
192
|
+
function _objectSpread$5(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$5(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$5(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
189
193
|
var Manage$1 = reactUtils.withT(function (_ref) {
|
|
190
194
|
var t = _ref.t,
|
|
191
195
|
_ref$title = _ref.title,
|
|
@@ -229,86 +233,107 @@ var Manage$1 = reactUtils.withT(function (_ref) {
|
|
|
229
233
|
_ref$isConnectDisable = _ref.isConnectDisabled,
|
|
230
234
|
isConnectDisabled = _ref$isConnectDisable === void 0 ? false : _ref$isConnectDisable,
|
|
231
235
|
_ref$connectTooltipPr = _ref.connectTooltipProps,
|
|
232
|
-
connectTooltipProps = _ref$connectTooltipPr === void 0 ? null : _ref$connectTooltipPr
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
236
|
+
connectTooltipProps = _ref$connectTooltipPr === void 0 ? null : _ref$connectTooltipPr,
|
|
237
|
+
_ref$buttonProps = _ref.buttonProps,
|
|
238
|
+
buttonProps = _ref$buttonProps === void 0 ? {} : _ref$buttonProps,
|
|
239
|
+
_ref$secondaryButtonP = _ref.secondaryButtonProps,
|
|
240
|
+
secondaryButtonProps = _ref$secondaryButtonP === void 0 ? {} : _ref$secondaryButtonP;
|
|
241
|
+
return /*#__PURE__*/jsxRuntime.jsxs(jsxRuntime.Fragment, {
|
|
242
|
+
children: [/*#__PURE__*/jsxRuntime.jsx("div", {
|
|
243
|
+
className: "mx-auto w-full max-w-3xl",
|
|
244
|
+
children: /*#__PURE__*/jsxRuntime.jsxs("div", {
|
|
245
|
+
className: "neeto-ui-border-gray-300 neeto-ui-rounded-xl mt-10 w-full space-y-4 border p-6",
|
|
246
|
+
children: [Icon && /*#__PURE__*/jsxRuntime.jsx(Icon, {
|
|
247
|
+
className: "neeto-ui-text-gray-600",
|
|
248
|
+
size: 48
|
|
249
|
+
}), /*#__PURE__*/jsxRuntime.jsxs("div", {
|
|
250
|
+
className: "space-y-2",
|
|
251
|
+
children: [/*#__PURE__*/jsxRuntime.jsxs("div", {
|
|
252
|
+
className: "flex items-center space-x-4",
|
|
253
|
+
children: [/*#__PURE__*/jsxRuntime.jsx(Typography__default["default"], {
|
|
254
|
+
className: "neeto-ui-text-gray-800 mb-0.5",
|
|
255
|
+
style: "h2",
|
|
256
|
+
weight: "semibold",
|
|
257
|
+
children: title
|
|
258
|
+
}), isConnected && /*#__PURE__*/jsxRuntime.jsx("div", {
|
|
259
|
+
className: "neeto-ui-bg-success-500 neeto-ui-text-white neeto-ui-rounded-full flex items-center justify-center p-1",
|
|
260
|
+
children: /*#__PURE__*/jsxRuntime.jsx(neetoIcons.Check, {
|
|
261
|
+
size: 24
|
|
262
|
+
})
|
|
263
|
+
})]
|
|
264
|
+
}), /*#__PURE__*/jsxRuntime.jsx(Typography__default["default"], {
|
|
265
|
+
style: "body1",
|
|
266
|
+
weight: "normal",
|
|
267
|
+
className: classnames__default["default"]("neeto-ui-text-gray-800", {
|
|
268
|
+
"break-all": isConnected
|
|
269
|
+
}),
|
|
270
|
+
children: description
|
|
271
|
+
}), helpDocUrl && /*#__PURE__*/jsxRuntime.jsx(Typography__default["default"], {
|
|
272
|
+
className: "neeto-ui-text-gray-800",
|
|
273
|
+
style: "body2",
|
|
274
|
+
weight: "normal",
|
|
275
|
+
children: /*#__PURE__*/jsxRuntime.jsx(reactI18next.Trans, {
|
|
276
|
+
i18nKey: "neetoIntegrations.common.helpDocUrl",
|
|
277
|
+
components: {
|
|
278
|
+
helpLink: /*#__PURE__*/jsxRuntime.jsx(Button__default["default"], {
|
|
279
|
+
href: helpDocUrl,
|
|
280
|
+
style: "link",
|
|
281
|
+
target: "_blank"
|
|
282
|
+
})
|
|
283
|
+
},
|
|
284
|
+
values: {
|
|
285
|
+
integration: integrationName || neetoCist.humanize(integration)
|
|
286
|
+
}
|
|
287
|
+
})
|
|
288
|
+
})]
|
|
289
|
+
}), isConnected ? /*#__PURE__*/jsxRuntime.jsxs("div", {
|
|
290
|
+
className: "space-x-2",
|
|
291
|
+
children: [(managePath || manageUrl) && /*#__PURE__*/jsxRuntime.jsx(Button__default["default"], _objectSpread$5({
|
|
292
|
+
"data-cy": "manage-button",
|
|
293
|
+
href: manageUrl,
|
|
294
|
+
target: manageUrl ? "_blank" : "_self",
|
|
295
|
+
to: managePath,
|
|
296
|
+
label: t("neetoIntegrations.common.manageIntegration", {
|
|
297
|
+
integration: integrationName || neetoCist.humanize(integration)
|
|
298
|
+
})
|
|
299
|
+
}, buttonProps)), onDisconnect && /*#__PURE__*/jsxRuntime.jsx(Button__default["default"], _objectSpread$5({
|
|
300
|
+
"data-cy": "disconnect-button",
|
|
301
|
+
style: "secondary",
|
|
302
|
+
label: t("neetoIntegrations.common.disconnectIntegration", {
|
|
303
|
+
integration: integrationName || neetoCist.humanize(integration)
|
|
304
|
+
}),
|
|
305
|
+
onClick: function onClick() {
|
|
306
|
+
return setIsDisconnectAlertOpen(true);
|
|
307
|
+
}
|
|
308
|
+
}, secondaryButtonProps))]
|
|
309
|
+
}) : /*#__PURE__*/jsxRuntime.jsx("div", {
|
|
310
|
+
children: /*#__PURE__*/jsxRuntime.jsx(Tooltip__default["default"], _objectSpread$5(_objectSpread$5({
|
|
311
|
+
disabled: !isConnectDisabled
|
|
312
|
+
}, connectTooltipProps), {}, {
|
|
313
|
+
children: /*#__PURE__*/jsxRuntime.jsx("span", {
|
|
314
|
+
children: (connectPath || connectUrl || onConnect) && /*#__PURE__*/jsxRuntime.jsx(Button__default["default"], _objectSpread$5({
|
|
315
|
+
"data-cy": "connect-button",
|
|
316
|
+
disabled: isConnectDisabled,
|
|
317
|
+
href: connectUrl,
|
|
318
|
+
to: connectPath,
|
|
319
|
+
label: t("neetoIntegrations.common.connectIntegration", {
|
|
320
|
+
integration: integrationName || neetoCist.humanize(integration)
|
|
321
|
+
}),
|
|
322
|
+
onClick: onConnect
|
|
323
|
+
}, buttonProps))
|
|
324
|
+
})
|
|
325
|
+
}))
|
|
326
|
+
})]
|
|
269
327
|
})
|
|
270
|
-
},
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
target: manageUrl ? "_blank" : "_self",
|
|
280
|
-
to: managePath,
|
|
281
|
-
label: t("neetoIntegrations.common.manageIntegration", {
|
|
282
|
-
integration: integrationName || neetoCist.humanize(integration)
|
|
283
|
-
})
|
|
284
|
-
}), onDisconnect && /*#__PURE__*/React__default["default"].createElement(neetoui.Button, {
|
|
285
|
-
"data-cy": "disconnect-button",
|
|
286
|
-
style: "secondary",
|
|
287
|
-
label: t("neetoIntegrations.common.disconnectIntegration", {
|
|
288
|
-
integration: integrationName || neetoCist.humanize(integration)
|
|
289
|
-
}),
|
|
290
|
-
onClick: function onClick() {
|
|
291
|
-
return setIsDisconnectAlertOpen(true);
|
|
292
|
-
}
|
|
293
|
-
})) : /*#__PURE__*/React__default["default"].createElement("div", null, /*#__PURE__*/React__default["default"].createElement(neetoui.Tooltip, _extends$1({
|
|
294
|
-
disabled: !isConnectDisabled
|
|
295
|
-
}, connectTooltipProps), /*#__PURE__*/React__default["default"].createElement("span", null, (connectPath || connectUrl || onConnect) && /*#__PURE__*/React__default["default"].createElement(neetoui.Button, {
|
|
296
|
-
"data-cy": "connect-button",
|
|
297
|
-
disabled: isConnectDisabled,
|
|
298
|
-
href: connectUrl,
|
|
299
|
-
to: connectPath,
|
|
300
|
-
label: t("neetoIntegrations.common.connectIntegration", {
|
|
301
|
-
integration: integrationName || neetoCist.humanize(integration)
|
|
302
|
-
}),
|
|
303
|
-
onClick: onConnect
|
|
304
|
-
})))))), /*#__PURE__*/React__default["default"].createElement(DisconnectAlert__default["default"], {
|
|
305
|
-
isDisconnecting: isDisconnecting,
|
|
306
|
-
onClose: onClose,
|
|
307
|
-
onDisconnect: onDisconnect,
|
|
308
|
-
isOpen: isDisconnectAlertOpen,
|
|
309
|
-
message: disconnectMessage || t("settings.integrations.".concat(integration, ".disconnect.message")),
|
|
310
|
-
title: disconnectTitle || t("settings.integrations.".concat(integration, ".disconnect.title"))
|
|
311
|
-
}));
|
|
328
|
+
}), /*#__PURE__*/jsxRuntime.jsx(DisconnectAlert__default["default"], {
|
|
329
|
+
isDisconnecting: isDisconnecting,
|
|
330
|
+
onClose: onClose,
|
|
331
|
+
onDisconnect: onDisconnect,
|
|
332
|
+
isOpen: isDisconnectAlertOpen,
|
|
333
|
+
message: disconnectMessage || t("settings.integrations.".concat(integration, ".disconnect.message")),
|
|
334
|
+
title: disconnectTitle || t("settings.integrations.".concat(integration, ".disconnect.title"))
|
|
335
|
+
})]
|
|
336
|
+
});
|
|
312
337
|
});
|
|
313
338
|
|
|
314
339
|
var INTEGRATIONS_ENGINE_BASE_URL = "/neeto_integrations";
|
|
@@ -338,11 +363,11 @@ var QUERY_KEYS = {
|
|
|
338
363
|
ZOOM_DETAILS: "zoom-details"
|
|
339
364
|
};
|
|
340
365
|
|
|
341
|
-
function ownKeys$
|
|
342
|
-
function _objectSpread$
|
|
366
|
+
function ownKeys$4(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
367
|
+
function _objectSpread$4(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$4(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$4(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
343
368
|
var useCreateDaily = function useCreateDaily() {
|
|
344
369
|
var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
345
|
-
return reactUtils.useMutationWithInvalidation(dailiesApi.create, _objectSpread$
|
|
370
|
+
return reactUtils.useMutationWithInvalidation(dailiesApi.create, _objectSpread$4({
|
|
346
371
|
keysToInvalidate: [QUERY_KEYS.DAILY_CO_DETAILS]
|
|
347
372
|
}, options));
|
|
348
373
|
};
|
|
@@ -389,15 +414,19 @@ function _objectWithoutProperties(source, excluded) {
|
|
|
389
414
|
}
|
|
390
415
|
|
|
391
416
|
var _excluded = ["className", "children"];
|
|
417
|
+
function ownKeys$3(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
418
|
+
function _objectSpread$3(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$3(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$3(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
392
419
|
var ExternalLink = function ExternalLink(_ref) {
|
|
393
420
|
var _ref$className = _ref.className,
|
|
394
421
|
className = _ref$className === void 0 ? "" : _ref$className,
|
|
395
422
|
_ref$children = _ref.children,
|
|
396
423
|
children = _ref$children === void 0 ? null : _ref$children,
|
|
397
424
|
props = _objectWithoutProperties(_ref, _excluded);
|
|
398
|
-
return /*#__PURE__*/
|
|
425
|
+
return /*#__PURE__*/jsxRuntime.jsx("a", _objectSpread$3(_objectSpread$3({
|
|
399
426
|
className: classnames__default["default"](["neeto-ui-text-primary-800 hover:neeto-ui-text-primary-800 visited:neeto-ui-text-primary-600 font-medium", className])
|
|
400
|
-
}, props),
|
|
427
|
+
}, props), {}, {
|
|
428
|
+
children: children
|
|
429
|
+
}));
|
|
401
430
|
};
|
|
402
431
|
var ExternalLink$1 = /*#__PURE__*/React__default["default"].memo(ExternalLink);
|
|
403
432
|
|
|
@@ -417,6 +446,7 @@ var Form = function Form(_ref) {
|
|
|
417
446
|
breadcrumbs = _ref.breadcrumbs;
|
|
418
447
|
var _useTranslation = reactI18next.useTranslation(),
|
|
419
448
|
t = _useTranslation.t;
|
|
449
|
+
var history = reactRouterDom.useHistory();
|
|
420
450
|
var _useState = React.useState(false),
|
|
421
451
|
_useState2 = _slicedToArray(_useState, 2),
|
|
422
452
|
isDemoModalOpen = _useState2[0],
|
|
@@ -432,70 +462,78 @@ var Form = function Form(_ref) {
|
|
|
432
462
|
return createDaily(payload);
|
|
433
463
|
};
|
|
434
464
|
if (isConnecting) {
|
|
435
|
-
return /*#__PURE__*/
|
|
465
|
+
return /*#__PURE__*/jsxRuntime.jsx(PageLoader__default["default"], {});
|
|
436
466
|
}
|
|
437
|
-
return /*#__PURE__*/
|
|
438
|
-
isHeaderFixed: true
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
467
|
+
return /*#__PURE__*/jsxRuntime.jsxs(Container__default["default"], {
|
|
468
|
+
isHeaderFixed: true,
|
|
469
|
+
children: [/*#__PURE__*/jsxRuntime.jsx(Header__default["default"], {
|
|
470
|
+
breadcrumbs: breadcrumbs,
|
|
471
|
+
title: /*#__PURE__*/jsxRuntime.jsxs("span", {
|
|
472
|
+
className: "flex items-center gap-2",
|
|
473
|
+
children: [t("neetoIntegrations.daily.connect.title"), /*#__PURE__*/jsxRuntime.jsx(HelpPopover__default["default"], {
|
|
474
|
+
title: t("neetoIntegrations.daily.connect.title"),
|
|
475
|
+
description: /*#__PURE__*/jsxRuntime.jsx(reactI18next.Trans, {
|
|
476
|
+
i18nKey: "neetoIntegrations.daily.helpDoc",
|
|
477
|
+
components: {
|
|
478
|
+
externalLink: /*#__PURE__*/jsxRuntime.jsx(ExternalLink$1, {
|
|
479
|
+
"data-cy": "api-key-help-doc-link",
|
|
480
|
+
href: helpDocUrl,
|
|
481
|
+
rel: "noreferrer",
|
|
482
|
+
target: "_blank"
|
|
483
|
+
})
|
|
484
|
+
}
|
|
485
|
+
}),
|
|
486
|
+
helpLinkProps: {
|
|
487
|
+
label: /*#__PURE__*/jsxRuntime.jsx(Button__default["default"], {
|
|
488
|
+
className: "mt-8",
|
|
489
|
+
label: t("neetoIntegrations.daily.walkthroughText"),
|
|
490
|
+
style: "link",
|
|
491
|
+
onClick: function onClick() {
|
|
492
|
+
return setIsDemoModalOpen(true);
|
|
493
|
+
}
|
|
494
|
+
})
|
|
463
495
|
}
|
|
496
|
+
})]
|
|
497
|
+
})
|
|
498
|
+
}), /*#__PURE__*/jsxRuntime.jsxs("div", {
|
|
499
|
+
className: "mx-auto w-full max-w-md",
|
|
500
|
+
children: [/*#__PURE__*/jsxRuntime.jsx(FormikForm__default["default"], {
|
|
501
|
+
formikProps: {
|
|
502
|
+
initialValues: MANAGE_DAILY_CO_FORM_INITIAL_VALUES,
|
|
503
|
+
validationSchema: DAILY_CO_VALIDATION_SCHEMA,
|
|
504
|
+
onSubmit: handleSubmit
|
|
505
|
+
},
|
|
506
|
+
children: /*#__PURE__*/jsxRuntime.jsxs("div", {
|
|
507
|
+
className: "mt-14 w-full space-y-2",
|
|
508
|
+
children: [/*#__PURE__*/jsxRuntime.jsx("div", {
|
|
509
|
+
className: "block min-h-20",
|
|
510
|
+
children: /*#__PURE__*/jsxRuntime.jsx(Input__default["default"], {
|
|
511
|
+
autoFocus: true,
|
|
512
|
+
required: true,
|
|
513
|
+
label: t("neetoIntegrations.daily.apiKey"),
|
|
514
|
+
name: "apiKey"
|
|
515
|
+
})
|
|
516
|
+
}), /*#__PURE__*/jsxRuntime.jsx(ActionBlock__default["default"], {
|
|
517
|
+
cancelButtonProps: {
|
|
518
|
+
onClick: function onClick() {
|
|
519
|
+
return history.goBack();
|
|
520
|
+
}
|
|
521
|
+
},
|
|
522
|
+
isSubmitting: isConnecting,
|
|
523
|
+
submitButtonProps: {
|
|
524
|
+
label: t("neetoIntegrations.common.connect")
|
|
525
|
+
}
|
|
526
|
+
})]
|
|
464
527
|
})
|
|
465
|
-
}
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
}
|
|
475
|
-
}, function (_ref2) {
|
|
476
|
-
var dirty = _ref2.dirty;
|
|
477
|
-
return /*#__PURE__*/React__default["default"].createElement("div", {
|
|
478
|
-
className: "mt-14 w-full space-y-5"
|
|
479
|
-
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
480
|
-
className: "block min-h-20"
|
|
481
|
-
}, /*#__PURE__*/React__default["default"].createElement(formik.Input, {
|
|
482
|
-
autoFocus: true,
|
|
483
|
-
required: true,
|
|
484
|
-
label: t("neetoIntegrations.daily.apiKey"),
|
|
485
|
-
name: "apiKey"
|
|
486
|
-
})), /*#__PURE__*/React__default["default"].createElement("div", null, /*#__PURE__*/React__default["default"].createElement(neetoui.Button, {
|
|
487
|
-
disabled: isConnecting || !dirty,
|
|
488
|
-
label: t("neetoIntegrations.common.connect"),
|
|
489
|
-
loading: isConnecting,
|
|
490
|
-
type: "submit"
|
|
491
|
-
})));
|
|
492
|
-
}), /*#__PURE__*/React__default["default"].createElement(WalkthroughModal__default["default"], {
|
|
493
|
-
videoUrl: videoUrl,
|
|
494
|
-
isOpen: isDemoModalOpen,
|
|
495
|
-
onClose: function onClose() {
|
|
496
|
-
return setIsDemoModalOpen(false);
|
|
497
|
-
}
|
|
498
|
-
})));
|
|
528
|
+
}), /*#__PURE__*/jsxRuntime.jsx(WalkthroughModal__default["default"], {
|
|
529
|
+
videoUrl: videoUrl,
|
|
530
|
+
isOpen: isDemoModalOpen,
|
|
531
|
+
onClose: function onClose() {
|
|
532
|
+
return setIsDemoModalOpen(false);
|
|
533
|
+
}
|
|
534
|
+
})]
|
|
535
|
+
})]
|
|
536
|
+
});
|
|
499
537
|
};
|
|
500
538
|
var Form$1 = reactUtils.withTitle(Form, i18next__default["default"].t("neetoIntegrations.browserTitles.integrations.dailyco"));
|
|
501
539
|
|
|
@@ -529,8 +567,8 @@ var Manage = function Manage(_ref) {
|
|
|
529
567
|
var handleDisconnect = function handleDisconnect() {
|
|
530
568
|
return destroyIntegration("daily");
|
|
531
569
|
};
|
|
532
|
-
if (isFetching || isDisconnecting) return /*#__PURE__*/
|
|
533
|
-
return /*#__PURE__*/
|
|
570
|
+
if (isFetching || isDisconnecting) return /*#__PURE__*/jsxRuntime.jsx(PageLoader__default["default"], {});
|
|
571
|
+
return /*#__PURE__*/jsxRuntime.jsx(Manage$1, {
|
|
534
572
|
isConnected: isConnected,
|
|
535
573
|
isDisconnectAlertOpen: isDisconnectAlertOpen,
|
|
536
574
|
isDisconnecting: isDisconnecting,
|
|
@@ -540,19 +578,19 @@ var Manage = function Manage(_ref) {
|
|
|
540
578
|
connect: true
|
|
541
579
|
}),
|
|
542
580
|
integration: "daily",
|
|
543
|
-
description: isConnected ? /*#__PURE__*/
|
|
581
|
+
description: isConnected ? /*#__PURE__*/jsxRuntime.jsx(reactI18next.Trans, {
|
|
544
582
|
i18nKey: "neetoIntegrations.daily.yourApiKey",
|
|
545
583
|
values: {
|
|
546
584
|
apiKey: apiKey
|
|
547
585
|
},
|
|
548
586
|
components: {
|
|
549
|
-
wrapper: /*#__PURE__*/
|
|
587
|
+
wrapper: /*#__PURE__*/jsxRuntime.jsx("div", {
|
|
550
588
|
className: "neeto-ui-rounded-md mt-2 flex items-center justify-between gap-x-3 border px-3 py-2"
|
|
551
589
|
}),
|
|
552
|
-
span: /*#__PURE__*/
|
|
590
|
+
span: /*#__PURE__*/jsxRuntime.jsx("span", {
|
|
553
591
|
className: "break-all text-sm"
|
|
554
592
|
}),
|
|
555
|
-
copy: /*#__PURE__*/
|
|
593
|
+
copy: /*#__PURE__*/jsxRuntime.jsx(CopyToClipboardButton__default["default"], {
|
|
556
594
|
className: "flex-shrink-0 self-start",
|
|
557
595
|
style: "text",
|
|
558
596
|
value: apiKey
|
|
@@ -591,12 +629,12 @@ var Daily = function Daily(_ref) {
|
|
|
591
629
|
_ref2$apiKey = _ref2.apiKey,
|
|
592
630
|
apiKey = _ref2$apiKey === void 0 ? null : _ref2$apiKey;
|
|
593
631
|
if (neetoCist.isPresent(apiKey) && !isOnboarding || !connect) {
|
|
594
|
-
return /*#__PURE__*/
|
|
632
|
+
return /*#__PURE__*/jsxRuntime.jsx(Manage, {
|
|
595
633
|
description: description,
|
|
596
634
|
onDisconnect: onDisconnect
|
|
597
635
|
});
|
|
598
636
|
}
|
|
599
|
-
return /*#__PURE__*/
|
|
637
|
+
return /*#__PURE__*/jsxRuntime.jsx(Form$1, {
|
|
600
638
|
helpDocUrl: helpDocUrl,
|
|
601
639
|
onConnect: onConnect,
|
|
602
640
|
videoUrl: videoUrl
|
|
@@ -610,42 +648,47 @@ var Stepper = function Stepper(_ref) {
|
|
|
610
648
|
var isActiveOrCompleted = function isActiveOrCompleted(activeStatus, completedStatus) {
|
|
611
649
|
return activeStatus || completedStatus;
|
|
612
650
|
};
|
|
613
|
-
return /*#__PURE__*/
|
|
614
|
-
className: "flex gap-4"
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
651
|
+
return /*#__PURE__*/jsxRuntime.jsx("ul", {
|
|
652
|
+
className: "flex gap-4",
|
|
653
|
+
children: steps === null || steps === void 0 ? void 0 : steps.map(function (_ref2) {
|
|
654
|
+
var step = _ref2.step,
|
|
655
|
+
label = _ref2.label,
|
|
656
|
+
isActive = _ref2.isActive,
|
|
657
|
+
isCompleted = _ref2.isCompleted;
|
|
658
|
+
return /*#__PURE__*/jsxRuntime.jsxs("li", {
|
|
659
|
+
className: "flex items-center gap-4",
|
|
660
|
+
children: [step !== "1" && /*#__PURE__*/jsxRuntime.jsx("div", {
|
|
661
|
+
className: classnames__default["default"]("w-10 border-b", {
|
|
662
|
+
"neeto-ui-border-gray-800": isActiveOrCompleted(isActive, isCompleted),
|
|
663
|
+
"neeto-ui-border-gray-400": !isActiveOrCompleted(isActive, isCompleted)
|
|
664
|
+
})
|
|
665
|
+
}), /*#__PURE__*/jsxRuntime.jsxs("div", {
|
|
666
|
+
className: "flex items-center gap-2",
|
|
667
|
+
children: [/*#__PURE__*/jsxRuntime.jsx("div", {
|
|
668
|
+
className: classnames__default["default"]("neeto-ui-rounded-full neeto-ui-gray-600 flex h-6 w-6 items-center justify-center border", {
|
|
669
|
+
"neeto-ui-bg-success-600 neeto-ui-border-success-600 neeto-ui-text-white": isActive,
|
|
670
|
+
"neeto-ui-bg-primary-600 neeto-ui-border-primary-600 neeto-ui-text-white": isCompleted,
|
|
671
|
+
"neeto-ui-border-gray-400": !isActiveOrCompleted(isActive, isCompleted)
|
|
672
|
+
}),
|
|
673
|
+
children: /*#__PURE__*/jsxRuntime.jsx(Typography__default["default"], {
|
|
674
|
+
component: "span",
|
|
675
|
+
style: "body2",
|
|
676
|
+
weight: "normal",
|
|
677
|
+
children: step
|
|
678
|
+
})
|
|
679
|
+
}), /*#__PURE__*/jsxRuntime.jsx(Typography__default["default"], {
|
|
680
|
+
style: "body2",
|
|
681
|
+
weight: "normal",
|
|
682
|
+
className: classnames__default["default"]({
|
|
683
|
+
"neeto-ui-text-gray-800": isActiveOrCompleted(isActive, isCompleted),
|
|
684
|
+
"neeto-ui-text-gray-600": !isActiveOrCompleted(isActive, isCompleted)
|
|
685
|
+
}),
|
|
686
|
+
children: label
|
|
687
|
+
})]
|
|
688
|
+
})]
|
|
689
|
+
}, step);
|
|
690
|
+
})
|
|
691
|
+
});
|
|
649
692
|
};
|
|
650
693
|
|
|
651
694
|
var Modal = function Modal(_ref) {
|
|
@@ -656,18 +699,23 @@ var Modal = function Modal(_ref) {
|
|
|
656
699
|
_ref$steps = _ref.steps,
|
|
657
700
|
steps = _ref$steps === void 0 ? {} : _ref$steps,
|
|
658
701
|
children = _ref.children;
|
|
659
|
-
return /*#__PURE__*/
|
|
702
|
+
return /*#__PURE__*/jsxRuntime.jsxs(NeetoUIModal__default["default"], {
|
|
660
703
|
isOpen: isOpen,
|
|
661
704
|
onClose: onClose,
|
|
662
705
|
className: "neeto-ui-flex neeto-ui-flex-col neeto-ui-transform-none w-screen overflow-y-auto",
|
|
663
|
-
size: "fullScreen"
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
706
|
+
size: "fullScreen",
|
|
707
|
+
children: [/*#__PURE__*/jsxRuntime.jsx(NeetoUIModal__default["default"].Header, {
|
|
708
|
+
children: /*#__PURE__*/jsxRuntime.jsx(Stepper, {
|
|
709
|
+
steps: steps
|
|
710
|
+
})
|
|
711
|
+
}), /*#__PURE__*/jsxRuntime.jsx(NeetoUIModal__default["default"].Body, {
|
|
712
|
+
className: "neeto-ui-flex neeto-ui-justify-center neeto-ui-flex-grow",
|
|
713
|
+
children: /*#__PURE__*/jsxRuntime.jsx("div", {
|
|
714
|
+
className: "neeto-ui-w-full py-10",
|
|
715
|
+
children: children
|
|
716
|
+
})
|
|
717
|
+
})]
|
|
718
|
+
});
|
|
671
719
|
};
|
|
672
720
|
|
|
673
721
|
function getDefaultExportFromCjs (x) {
|
|
@@ -752,6 +800,8 @@ var factoryWithThrowingShims = function factoryWithThrowingShims() {
|
|
|
752
800
|
var propTypesExports = propTypes.exports;
|
|
753
801
|
var PropTypes = /*@__PURE__*/getDefaultExportFromCjs(propTypesExports);
|
|
754
802
|
|
|
803
|
+
function ownKeys$2(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
804
|
+
function _objectSpread$2(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$2(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$2(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
755
805
|
var Connect = reactUtils.withT(function (_ref) {
|
|
756
806
|
var t = _ref.t,
|
|
757
807
|
Icon = _ref.Icon,
|
|
@@ -759,32 +809,61 @@ var Connect = reactUtils.withT(function (_ref) {
|
|
|
759
809
|
title = _ref$title === void 0 ? "" : _ref$title,
|
|
760
810
|
_ref$description = _ref.description,
|
|
761
811
|
description = _ref$description === void 0 ? "" : _ref$description,
|
|
812
|
+
_ref$integration = _ref.integration,
|
|
813
|
+
integration = _ref$integration === void 0 ? "" : _ref$integration,
|
|
814
|
+
_ref$integrationName = _ref.integrationName,
|
|
815
|
+
integrationName = _ref$integrationName === void 0 ? "" : _ref$integrationName,
|
|
816
|
+
_ref$helpDocUrl = _ref.helpDocUrl,
|
|
817
|
+
helpDocUrl = _ref$helpDocUrl === void 0 ? "" : _ref$helpDocUrl,
|
|
762
818
|
_ref$buttonProps = _ref.buttonProps,
|
|
763
819
|
buttonProps = _ref$buttonProps === void 0 ? {} : _ref$buttonProps,
|
|
764
820
|
_ref$onConnect = _ref.onConnect,
|
|
765
821
|
onConnect = _ref$onConnect === void 0 ? neetoCist.noop : _ref$onConnect,
|
|
766
822
|
children = _ref.children,
|
|
767
823
|
secondaryButtonProps = _ref.secondaryButtonProps;
|
|
768
|
-
return /*#__PURE__*/
|
|
769
|
-
className: "mx-auto w-full max-w-3xl"
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
|
|
824
|
+
return /*#__PURE__*/jsxRuntime.jsxs("div", {
|
|
825
|
+
className: "mx-auto w-full max-w-3xl",
|
|
826
|
+
children: [/*#__PURE__*/jsxRuntime.jsxs("div", {
|
|
827
|
+
className: "mb-6 flex flex-col gap-y-2",
|
|
828
|
+
children: [/*#__PURE__*/jsxRuntime.jsx(Icon, {
|
|
829
|
+
size: 48
|
|
830
|
+
}), /*#__PURE__*/jsxRuntime.jsxs("div", {
|
|
831
|
+
className: "flex flex-col gap-y-1",
|
|
832
|
+
children: [/*#__PURE__*/jsxRuntime.jsx(Typography__default["default"], {
|
|
833
|
+
style: "h2",
|
|
834
|
+
children: title
|
|
835
|
+
}), /*#__PURE__*/jsxRuntime.jsx(Typography__default["default"], {
|
|
836
|
+
style: "body2",
|
|
837
|
+
children: description
|
|
838
|
+
})]
|
|
839
|
+
})]
|
|
840
|
+
}), helpDocUrl && /*#__PURE__*/jsxRuntime.jsx("div", {
|
|
841
|
+
className: "mb-4",
|
|
842
|
+
children: /*#__PURE__*/jsxRuntime.jsx(reactI18next.Trans, {
|
|
843
|
+
i18nKey: "neetoIntegrations.common.helpDocUrl",
|
|
844
|
+
components: {
|
|
845
|
+
helpLink: /*#__PURE__*/jsxRuntime.jsx(Button__default["default"], {
|
|
846
|
+
className: "text-xs",
|
|
847
|
+
href: helpDocUrl,
|
|
848
|
+
size: "small",
|
|
849
|
+
style: "link",
|
|
850
|
+
target: "_blank"
|
|
851
|
+
})
|
|
852
|
+
},
|
|
853
|
+
values: {
|
|
854
|
+
integration: integrationName || neetoCist.humanize(integration)
|
|
855
|
+
}
|
|
856
|
+
})
|
|
857
|
+
}), children, /*#__PURE__*/jsxRuntime.jsxs("div", {
|
|
858
|
+
className: "flex w-full items-center gap-x-3",
|
|
859
|
+
children: [/*#__PURE__*/jsxRuntime.jsx(Button__default["default"], _objectSpread$2({
|
|
860
|
+
label: t("neetoIntegrations.common.connect"),
|
|
861
|
+
onClick: onConnect
|
|
862
|
+
}, buttonProps)), secondaryButtonProps && /*#__PURE__*/jsxRuntime.jsx(Button__default["default"], _objectSpread$2({
|
|
863
|
+
style: "secondary"
|
|
864
|
+
}, secondaryButtonProps))]
|
|
865
|
+
})]
|
|
866
|
+
});
|
|
788
867
|
});
|
|
789
868
|
Connect.prototypes = {
|
|
790
869
|
/**
|
|
@@ -858,6 +937,8 @@ const SvgSuccess = props => /*#__PURE__*/React__namespace.createElement("svg", _
|
|
|
858
937
|
height: 344
|
|
859
938
|
}))));
|
|
860
939
|
|
|
940
|
+
function ownKeys$1(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
941
|
+
function _objectSpread$1(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$1(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$1(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
861
942
|
var Finish = reactUtils.withT(function (_ref) {
|
|
862
943
|
var t = _ref.t,
|
|
863
944
|
_ref$onClick = _ref.onClick,
|
|
@@ -869,20 +950,23 @@ var Finish = reactUtils.withT(function (_ref) {
|
|
|
869
950
|
_ref$secondaryButtonP = _ref.secondaryButtonProps,
|
|
870
951
|
secondaryButtonProps = _ref$secondaryButtonP === void 0 ? {} : _ref$secondaryButtonP,
|
|
871
952
|
children = _ref.children;
|
|
872
|
-
return /*#__PURE__*/
|
|
873
|
-
className: "mx-auto w-full max-w-3xl"
|
|
874
|
-
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
|
|
883
|
-
|
|
884
|
-
|
|
885
|
-
|
|
953
|
+
return /*#__PURE__*/jsxRuntime.jsxs("div", {
|
|
954
|
+
className: "mx-auto w-full max-w-3xl",
|
|
955
|
+
children: [/*#__PURE__*/jsxRuntime.jsx(SvgSuccess, {}), /*#__PURE__*/jsxRuntime.jsx(Typography__default["default"], {
|
|
956
|
+
className: "mb-6 mt-4",
|
|
957
|
+
style: "h2",
|
|
958
|
+
weight: "semibold",
|
|
959
|
+
children: title
|
|
960
|
+
}), children, /*#__PURE__*/jsxRuntime.jsxs("div", {
|
|
961
|
+
className: "flex w-full items-center gap-x-2",
|
|
962
|
+
children: [/*#__PURE__*/jsxRuntime.jsx(Button__default["default"], _objectSpread$1({
|
|
963
|
+
onClick: onClick,
|
|
964
|
+
label: t("neetoIntegrations.common.continue")
|
|
965
|
+
}, buttonProps)), neetoCist.isNotEmpty(secondaryButtonProps) && /*#__PURE__*/jsxRuntime.jsx(Button__default["default"], _objectSpread$1({
|
|
966
|
+
style: "secondary"
|
|
967
|
+
}, secondaryButtonProps))]
|
|
968
|
+
})]
|
|
969
|
+
});
|
|
886
970
|
});
|
|
887
971
|
Finish.prototypes = {
|
|
888
972
|
/**
|
|
@@ -974,41 +1058,47 @@ var GoogleCalendar = function GoogleCalendar(_ref) {
|
|
|
974
1058
|
return stepsClone;
|
|
975
1059
|
});
|
|
976
1060
|
}, [activeTab]);
|
|
977
|
-
return /*#__PURE__*/
|
|
1061
|
+
return /*#__PURE__*/jsxRuntime.jsxs(Modal, {
|
|
978
1062
|
steps: steps,
|
|
979
1063
|
isOpen: true,
|
|
980
|
-
onClose: handleClose
|
|
981
|
-
|
|
982
|
-
|
|
983
|
-
|
|
984
|
-
|
|
985
|
-
|
|
986
|
-
|
|
987
|
-
|
|
988
|
-
|
|
989
|
-
|
|
990
|
-
|
|
991
|
-
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
|
|
1002
|
-
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
|
|
1006
|
-
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
|
|
1064
|
+
onClose: handleClose,
|
|
1065
|
+
children: [activeTab === STEPS.connect && /*#__PURE__*/jsxRuntime.jsxs("div", {
|
|
1066
|
+
className: "mx-auto w-full max-w-3xl",
|
|
1067
|
+
children: [/*#__PURE__*/jsxRuntime.jsx(misc.GoogleCalendar, {
|
|
1068
|
+
size: 48
|
|
1069
|
+
}), /*#__PURE__*/jsxRuntime.jsx(Typography__default["default"], {
|
|
1070
|
+
className: "mb-4 mt-2",
|
|
1071
|
+
style: "h2",
|
|
1072
|
+
children: t("neetoIntegrations.google.connect.title")
|
|
1073
|
+
}), /*#__PURE__*/jsxRuntime.jsxs("div", {
|
|
1074
|
+
className: "flex w-full flex-col items-start",
|
|
1075
|
+
children: [/*#__PURE__*/jsxRuntime.jsx(Callout__default["default"], {
|
|
1076
|
+
className: "block leading-5",
|
|
1077
|
+
children: /*#__PURE__*/jsxRuntime.jsx(reactI18next.Trans, {
|
|
1078
|
+
components: {
|
|
1079
|
+
bold: /*#__PURE__*/jsxRuntime.jsx("strong", {})
|
|
1080
|
+
},
|
|
1081
|
+
i18nKey: "neetoIntegrations.google.connect.reminderToAcceptPermissions",
|
|
1082
|
+
values: {
|
|
1083
|
+
selectCheckbox: t("neetoIntegrations.google.connect.selectCheckbox")
|
|
1084
|
+
}
|
|
1085
|
+
})
|
|
1086
|
+
}), permissionImage && /*#__PURE__*/jsxRuntime.jsx("div", {
|
|
1087
|
+
className: "neeto-ui-border-gray-300 neeto-ui-rounded-md my-4 overflow-hidden border",
|
|
1088
|
+
children: /*#__PURE__*/jsxRuntime.jsx("img", {
|
|
1089
|
+
src: permissionImage
|
|
1090
|
+
})
|
|
1091
|
+
})]
|
|
1092
|
+
}), /*#__PURE__*/jsxRuntime.jsx(Button__default["default"], {
|
|
1093
|
+
icon: misc.Google,
|
|
1094
|
+
label: t("neetoIntegrations.google.connect.signIn"),
|
|
1095
|
+
onClick: fetchAuthorizationUrl
|
|
1096
|
+
})]
|
|
1097
|
+
}), activeTab === STEPS.finish && /*#__PURE__*/jsxRuntime.jsx(Finish, {
|
|
1098
|
+
title: t("neetoIntegrations.google.finish.title"),
|
|
1099
|
+
onClick: handleRedirect
|
|
1100
|
+
})]
|
|
1101
|
+
});
|
|
1012
1102
|
};
|
|
1013
1103
|
|
|
1014
1104
|
module.exports = GoogleCalendar;
|