@bigbinary/neeto-molecules 1.0.37 → 1.0.39
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/NeetoWidget.cjs.js +14 -10
- package/dist/NeetoWidget.cjs.js.map +1 -1
- package/dist/NeetoWidget.js +14 -10
- package/dist/NeetoWidget.js.map +1 -1
- package/package.json +1 -1
- package/types/IntegrationCard.d.ts +43 -0
- package/types/NeetoWidget.d.ts +2 -0
- package/types/Integration.d.ts +0 -15
package/dist/NeetoWidget.cjs.js
CHANGED
|
@@ -2342,7 +2342,7 @@ var CodeBlock = function CodeBlock(_ref) {
|
|
|
2342
2342
|
return /*#__PURE__*/React__default["default"].createElement("div", {
|
|
2343
2343
|
className: classnames(["relative", className])
|
|
2344
2344
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
2345
|
-
className: "neeto-ui-bg-primary-100 flex w-full items-center justify-between gap-2 p-3"
|
|
2345
|
+
className: "neeto-ui-bg-primary-100 neeto-ui-rounded-lg flex w-full flex-wrap items-center justify-between gap-2 rounded-b-none p-3"
|
|
2346
2346
|
}, title && /*#__PURE__*/React__default["default"].createElement(neetoui.Typography, {
|
|
2347
2347
|
className: "m-0 flex-shrink-0",
|
|
2348
2348
|
"data-cy": "code-block-title-text",
|
|
@@ -2354,7 +2354,7 @@ var CodeBlock = function CodeBlock(_ref) {
|
|
|
2354
2354
|
value: selectedFramework,
|
|
2355
2355
|
onChange: setSelectedFramework
|
|
2356
2356
|
}), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
2357
|
-
className: "flex flex-shrink-0 items-center justify-end gap-2"
|
|
2357
|
+
className: "ml-auto flex flex-shrink-0 items-center justify-end gap-2"
|
|
2358
2358
|
}, sendViaEmail ? /*#__PURE__*/React__default["default"].createElement(neetoui.Button, {
|
|
2359
2359
|
style: "text",
|
|
2360
2360
|
label: t("neetoMolecules.widget.installation.snippet.sendViaEmail"),
|
|
@@ -2367,7 +2367,7 @@ var CodeBlock = function CodeBlock(_ref) {
|
|
|
2367
2367
|
return utils.copyToClipboard(codeString);
|
|
2368
2368
|
}
|
|
2369
2369
|
}))), /*#__PURE__*/React__default["default"].createElement(SyntaxHighlighter, {
|
|
2370
|
-
className: "neeto-ui-bg-gray-800 m-0",
|
|
2370
|
+
className: "neeto-ui-bg-gray-800 neeto-ui-rounded-lg m-0 rounded-t-none",
|
|
2371
2371
|
code: codeString,
|
|
2372
2372
|
language: "javascript"
|
|
2373
2373
|
}));
|
|
@@ -2907,7 +2907,7 @@ var CodeSnippet = function CodeSnippet(_ref) {
|
|
|
2907
2907
|
var props = {
|
|
2908
2908
|
codeString: codeToDisplay,
|
|
2909
2909
|
showCopyButton: false,
|
|
2910
|
-
className: "neeto-ui-bg-primary-100 neeto-ui-rounded-
|
|
2910
|
+
className: "neeto-ui-bg-primary-100 neeto-ui-rounded-lg"
|
|
2911
2911
|
};
|
|
2912
2912
|
if (emailType === EMAIL_TYPES.userIdentity) {
|
|
2913
2913
|
props = ramda.assoc("frameworkProps", {
|
|
@@ -3036,7 +3036,9 @@ var SelectionTabs = function SelectionTabs(_ref) {
|
|
|
3036
3036
|
};
|
|
3037
3037
|
|
|
3038
3038
|
var EmbedCode = function EmbedCode(_ref) {
|
|
3039
|
-
var
|
|
3039
|
+
var showSessionContext = _ref.showSessionContext,
|
|
3040
|
+
showUserIdentity = _ref.showUserIdentity,
|
|
3041
|
+
_ref$primaryApp = _ref.primaryApp,
|
|
3040
3042
|
primaryApp = _ref$primaryApp === void 0 ? "" : _ref$primaryApp,
|
|
3041
3043
|
_ref$maxWidth = _ref.maxWidth,
|
|
3042
3044
|
maxWidth = _ref$maxWidth === void 0 ? "max-w-3xl" : _ref$maxWidth;
|
|
@@ -3076,6 +3078,8 @@ var EmbedCode = function EmbedCode(_ref) {
|
|
|
3076
3078
|
var enabledWidgets = ramda.fromPairs(selectedWidgets.map(function (widget) {
|
|
3077
3079
|
return [widget, true];
|
|
3078
3080
|
}));
|
|
3081
|
+
var shouldShowUserIdentity = showUserIdentity !== null && showUserIdentity !== void 0 ? showUserIdentity : enabledWidgets.chat || enabledWidgets.replay;
|
|
3082
|
+
var shouldShowSessionContext = showSessionContext !== null && showSessionContext !== void 0 ? showSessionContext : enabledWidgets.replay;
|
|
3079
3083
|
var updateSelectedWidgets = function updateSelectedWidgets(widget) {
|
|
3080
3084
|
var widgetId = neetoWidgetTokens.find(function (item) {
|
|
3081
3085
|
return item.clientApplicationName.toLowerCase() === widget;
|
|
@@ -3222,7 +3226,7 @@ var EmbedCode = function EmbedCode(_ref) {
|
|
|
3222
3226
|
className: "mx-auto mb-2 w-full",
|
|
3223
3227
|
"data-testid": "embed-code-block"
|
|
3224
3228
|
}, /*#__PURE__*/React__default["default"].createElement(CodeBlock, {
|
|
3225
|
-
className: "neeto-ui-bg-primary-100 neeto-ui-rounded-
|
|
3229
|
+
className: "neeto-ui-bg-primary-100 neeto-ui-rounded-lg",
|
|
3226
3230
|
codeString: getEmbedCodeString(),
|
|
3227
3231
|
sendViaEmail: function sendViaEmail() {
|
|
3228
3232
|
return handleSendViaEmail(EMAIL_TYPES.embedCode);
|
|
@@ -3243,12 +3247,12 @@ var EmbedCode = function EmbedCode(_ref) {
|
|
|
3243
3247
|
})
|
|
3244
3248
|
},
|
|
3245
3249
|
i18nKey: pure.isNotEmpty(selectedWidgets) ? "neetoMolecules.widget.installation.instructions.placement.selectedWidgets" : "neetoMolecules.widget.installation.instructions.placement.noneOfThese"
|
|
3246
|
-
}))),
|
|
3250
|
+
}))), shouldShowUserIdentity ? /*#__PURE__*/React__default["default"].createElement("div", {
|
|
3247
3251
|
className: "mb-8 w-full flex-grow flex-col items-center justify-start"
|
|
3248
3252
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
3249
3253
|
className: "mx-auto mb-2 w-full"
|
|
3250
3254
|
}, /*#__PURE__*/React__default["default"].createElement(CodeBlock, {
|
|
3251
|
-
className: "neeto-ui-bg-primary-100 neeto-ui-rounded-
|
|
3255
|
+
className: "neeto-ui-bg-primary-100 neeto-ui-rounded-lg",
|
|
3252
3256
|
frameworkProps: {
|
|
3253
3257
|
selectedFramework: selectedFramework,
|
|
3254
3258
|
setSelectedFramework: setSelectedFramework
|
|
@@ -3269,12 +3273,12 @@ var EmbedCode = function EmbedCode(_ref) {
|
|
|
3269
3273
|
})))
|
|
3270
3274
|
})), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
3271
3275
|
className: "w-full"
|
|
3272
|
-
}, t("neetoMolecules.widget.installation.instructions.userIdentity"))) : null,
|
|
3276
|
+
}, t("neetoMolecules.widget.installation.instructions.userIdentity"))) : null, shouldShowSessionContext ? /*#__PURE__*/React__default["default"].createElement("div", {
|
|
3273
3277
|
className: "w-full flex-grow flex-col items-center justify-start"
|
|
3274
3278
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
3275
3279
|
className: "mx-auto mb-2 w-full"
|
|
3276
3280
|
}, /*#__PURE__*/React__default["default"].createElement(CodeBlock, {
|
|
3277
|
-
className: "neeto-ui-bg-primary-100 neeto-ui-rounded-
|
|
3281
|
+
className: "neeto-ui-bg-primary-100 neeto-ui-rounded-lg",
|
|
3278
3282
|
codeString: SAMPLE_CONTEXT_CODE_STRING,
|
|
3279
3283
|
sendViaEmail: function sendViaEmail() {
|
|
3280
3284
|
return handleSendViaEmail(EMAIL_TYPES.sessionContext);
|