@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.js
CHANGED
|
@@ -2316,7 +2316,7 @@ var CodeBlock = function CodeBlock(_ref) {
|
|
|
2316
2316
|
return /*#__PURE__*/React.createElement("div", {
|
|
2317
2317
|
className: classnames(["relative", className])
|
|
2318
2318
|
}, /*#__PURE__*/React.createElement("div", {
|
|
2319
|
-
className: "neeto-ui-bg-primary-100 flex w-full items-center justify-between gap-2 p-3"
|
|
2319
|
+
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"
|
|
2320
2320
|
}, title && /*#__PURE__*/React.createElement(Typography, {
|
|
2321
2321
|
className: "m-0 flex-shrink-0",
|
|
2322
2322
|
"data-cy": "code-block-title-text",
|
|
@@ -2328,7 +2328,7 @@ var CodeBlock = function CodeBlock(_ref) {
|
|
|
2328
2328
|
value: selectedFramework,
|
|
2329
2329
|
onChange: setSelectedFramework
|
|
2330
2330
|
}), /*#__PURE__*/React.createElement("div", {
|
|
2331
|
-
className: "flex flex-shrink-0 items-center justify-end gap-2"
|
|
2331
|
+
className: "ml-auto flex flex-shrink-0 items-center justify-end gap-2"
|
|
2332
2332
|
}, sendViaEmail ? /*#__PURE__*/React.createElement(Button, {
|
|
2333
2333
|
style: "text",
|
|
2334
2334
|
label: t("neetoMolecules.widget.installation.snippet.sendViaEmail"),
|
|
@@ -2341,7 +2341,7 @@ var CodeBlock = function CodeBlock(_ref) {
|
|
|
2341
2341
|
return copyToClipboard(codeString);
|
|
2342
2342
|
}
|
|
2343
2343
|
}))), /*#__PURE__*/React.createElement(SyntaxHighlighter, {
|
|
2344
|
-
className: "neeto-ui-bg-gray-800 m-0",
|
|
2344
|
+
className: "neeto-ui-bg-gray-800 neeto-ui-rounded-lg m-0 rounded-t-none",
|
|
2345
2345
|
code: codeString,
|
|
2346
2346
|
language: "javascript"
|
|
2347
2347
|
}));
|
|
@@ -2881,7 +2881,7 @@ var CodeSnippet = function CodeSnippet(_ref) {
|
|
|
2881
2881
|
var props = {
|
|
2882
2882
|
codeString: codeToDisplay,
|
|
2883
2883
|
showCopyButton: false,
|
|
2884
|
-
className: "neeto-ui-bg-primary-100 neeto-ui-rounded-
|
|
2884
|
+
className: "neeto-ui-bg-primary-100 neeto-ui-rounded-lg"
|
|
2885
2885
|
};
|
|
2886
2886
|
if (emailType === EMAIL_TYPES.userIdentity) {
|
|
2887
2887
|
props = assoc("frameworkProps", {
|
|
@@ -3010,7 +3010,9 @@ var SelectionTabs = function SelectionTabs(_ref) {
|
|
|
3010
3010
|
};
|
|
3011
3011
|
|
|
3012
3012
|
var EmbedCode = function EmbedCode(_ref) {
|
|
3013
|
-
var
|
|
3013
|
+
var showSessionContext = _ref.showSessionContext,
|
|
3014
|
+
showUserIdentity = _ref.showUserIdentity,
|
|
3015
|
+
_ref$primaryApp = _ref.primaryApp,
|
|
3014
3016
|
primaryApp = _ref$primaryApp === void 0 ? "" : _ref$primaryApp,
|
|
3015
3017
|
_ref$maxWidth = _ref.maxWidth,
|
|
3016
3018
|
maxWidth = _ref$maxWidth === void 0 ? "max-w-3xl" : _ref$maxWidth;
|
|
@@ -3050,6 +3052,8 @@ var EmbedCode = function EmbedCode(_ref) {
|
|
|
3050
3052
|
var enabledWidgets = fromPairs(selectedWidgets.map(function (widget) {
|
|
3051
3053
|
return [widget, true];
|
|
3052
3054
|
}));
|
|
3055
|
+
var shouldShowUserIdentity = showUserIdentity !== null && showUserIdentity !== void 0 ? showUserIdentity : enabledWidgets.chat || enabledWidgets.replay;
|
|
3056
|
+
var shouldShowSessionContext = showSessionContext !== null && showSessionContext !== void 0 ? showSessionContext : enabledWidgets.replay;
|
|
3053
3057
|
var updateSelectedWidgets = function updateSelectedWidgets(widget) {
|
|
3054
3058
|
var widgetId = neetoWidgetTokens.find(function (item) {
|
|
3055
3059
|
return item.clientApplicationName.toLowerCase() === widget;
|
|
@@ -3196,7 +3200,7 @@ var EmbedCode = function EmbedCode(_ref) {
|
|
|
3196
3200
|
className: "mx-auto mb-2 w-full",
|
|
3197
3201
|
"data-testid": "embed-code-block"
|
|
3198
3202
|
}, /*#__PURE__*/React.createElement(CodeBlock, {
|
|
3199
|
-
className: "neeto-ui-bg-primary-100 neeto-ui-rounded-
|
|
3203
|
+
className: "neeto-ui-bg-primary-100 neeto-ui-rounded-lg",
|
|
3200
3204
|
codeString: getEmbedCodeString(),
|
|
3201
3205
|
sendViaEmail: function sendViaEmail() {
|
|
3202
3206
|
return handleSendViaEmail(EMAIL_TYPES.embedCode);
|
|
@@ -3217,12 +3221,12 @@ var EmbedCode = function EmbedCode(_ref) {
|
|
|
3217
3221
|
})
|
|
3218
3222
|
},
|
|
3219
3223
|
i18nKey: isNotEmpty(selectedWidgets) ? "neetoMolecules.widget.installation.instructions.placement.selectedWidgets" : "neetoMolecules.widget.installation.instructions.placement.noneOfThese"
|
|
3220
|
-
}))),
|
|
3224
|
+
}))), shouldShowUserIdentity ? /*#__PURE__*/React.createElement("div", {
|
|
3221
3225
|
className: "mb-8 w-full flex-grow flex-col items-center justify-start"
|
|
3222
3226
|
}, /*#__PURE__*/React.createElement("div", {
|
|
3223
3227
|
className: "mx-auto mb-2 w-full"
|
|
3224
3228
|
}, /*#__PURE__*/React.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
|
frameworkProps: {
|
|
3227
3231
|
selectedFramework: selectedFramework,
|
|
3228
3232
|
setSelectedFramework: setSelectedFramework
|
|
@@ -3243,12 +3247,12 @@ var EmbedCode = function EmbedCode(_ref) {
|
|
|
3243
3247
|
})))
|
|
3244
3248
|
})), /*#__PURE__*/React.createElement("div", {
|
|
3245
3249
|
className: "w-full"
|
|
3246
|
-
}, t("neetoMolecules.widget.installation.instructions.userIdentity"))) : null,
|
|
3250
|
+
}, t("neetoMolecules.widget.installation.instructions.userIdentity"))) : null, shouldShowSessionContext ? /*#__PURE__*/React.createElement("div", {
|
|
3247
3251
|
className: "w-full flex-grow flex-col items-center justify-start"
|
|
3248
3252
|
}, /*#__PURE__*/React.createElement("div", {
|
|
3249
3253
|
className: "mx-auto mb-2 w-full"
|
|
3250
3254
|
}, /*#__PURE__*/React.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
|
codeString: SAMPLE_CONTEXT_CODE_STRING,
|
|
3253
3257
|
sendViaEmail: function sendViaEmail() {
|
|
3254
3258
|
return handleSendViaEmail(EMAIL_TYPES.sessionContext);
|