@livechat/platform-workflows 0.0.6 → 0.0.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/dist/index.js +3253 -3697
- package/dist/index.mjs +621 -330
- package/package.json +8 -9
package/dist/index.mjs
CHANGED
|
@@ -1533,7 +1533,7 @@ var useUserContext = () => {
|
|
|
1533
1533
|
import { Route as Route6, Routes as Routes6 } from "react-router-dom";
|
|
1534
1534
|
|
|
1535
1535
|
// src/views/Flows/Definitions/index.tsx
|
|
1536
|
-
import { useContext as useContext30, useEffect as
|
|
1536
|
+
import { useContext as useContext30, useEffect as useEffect22 } from "react";
|
|
1537
1537
|
import { Navigate as Navigate2, Route as Route5, Routes as Routes5, useNavigate as useNavigate20 } from "react-router-dom";
|
|
1538
1538
|
|
|
1539
1539
|
// src/views/Flows/Definitions/Edit/index.tsx
|
|
@@ -9043,7 +9043,7 @@ var workflowBuilderUtils = {
|
|
|
9043
9043
|
return JSON.stringify(json, null, space);
|
|
9044
9044
|
},
|
|
9045
9045
|
escapeTag(value) {
|
|
9046
|
-
const valueWithoutQuotes = value.replaceAll('"', "");
|
|
9046
|
+
const valueWithoutQuotes = (value != null ? value : "").replaceAll('"', "");
|
|
9047
9047
|
return valueWithoutQuotes.substring(2, valueWithoutQuotes.length - 1);
|
|
9048
9048
|
},
|
|
9049
9049
|
getRegex(prefix2 = "$") {
|
|
@@ -13211,7 +13211,7 @@ import SchemaForm from "@rjsf/core";
|
|
|
13211
13211
|
import validator from "@rjsf/validator-ajv8";
|
|
13212
13212
|
|
|
13213
13213
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Forms/Schema/overrides/Fields/CustomString/Field.tsx
|
|
13214
|
-
import { useEffect as
|
|
13214
|
+
import { useEffect as useEffect7, useState as useState12 } from "react";
|
|
13215
13215
|
import { getDefaultRegistry } from "@rjsf/core";
|
|
13216
13216
|
import { MoreHoriz } from "@livechat/design-system-icons";
|
|
13217
13217
|
import {
|
|
@@ -13225,7 +13225,7 @@ import {
|
|
|
13225
13225
|
import { Intro, Row as Row7 } from "@livechat/developer-studio-ui-react";
|
|
13226
13226
|
|
|
13227
13227
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Forms/Schema/overrides/Fields/CustomTags/Field.tsx
|
|
13228
|
-
import { useRef as
|
|
13228
|
+
import { useRef as useRef6, useState as useState11 } from "react";
|
|
13229
13229
|
import { useOnClickOutside } from "@livechat/developer-studio-ui-react";
|
|
13230
13230
|
|
|
13231
13231
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Forms/Schema/overrides/Fields/CustomTags/TagsPicker/Picker.tsx
|
|
@@ -13668,8 +13668,7 @@ function CustomTagsPicker({
|
|
|
13668
13668
|
}
|
|
13669
13669
|
|
|
13670
13670
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Forms/Schema/overrides/Fields/CustomTags/TagsInput/Input.tsx
|
|
13671
|
-
import { useCallback as
|
|
13672
|
-
import Tags from "@yaireo/tagify/dist/react.tagify";
|
|
13671
|
+
import { useCallback as useCallback7, useEffect as useEffect6, useRef as useRef5 } from "react";
|
|
13673
13672
|
import { Tooltip as Tooltip3 } from "@livechat/design-system-react-components";
|
|
13674
13673
|
|
|
13675
13674
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Forms/Schema/overrides/Fields/CustomTags/TagsInput/Tag/Icon.tsx
|
|
@@ -13822,6 +13821,298 @@ function CustomTagsInputTagTooltip({
|
|
|
13822
13821
|
);
|
|
13823
13822
|
}
|
|
13824
13823
|
|
|
13824
|
+
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Forms/Schema/overrides/Fields/CustomTags/TagsInput/Tags.tsx
|
|
13825
|
+
import {
|
|
13826
|
+
memo,
|
|
13827
|
+
useCallback as useCallback6,
|
|
13828
|
+
useEffect as useEffect5,
|
|
13829
|
+
useMemo as useMemo2,
|
|
13830
|
+
useRef as useRef4
|
|
13831
|
+
} from "react";
|
|
13832
|
+
import Tagify from "@yaireo/tagify";
|
|
13833
|
+
import { jsx as jsx8 } from "react/jsx-runtime";
|
|
13834
|
+
var noop = (_) => _;
|
|
13835
|
+
var isSameDeep = (a, b) => {
|
|
13836
|
+
const trans = (x) => typeof x === "string" ? x : JSON.stringify(x);
|
|
13837
|
+
return trans(a) === trans(b);
|
|
13838
|
+
};
|
|
13839
|
+
function renderToStaticMarkup(element) {
|
|
13840
|
+
if (typeof element === "string") {
|
|
13841
|
+
return element;
|
|
13842
|
+
}
|
|
13843
|
+
if (Array.isArray(element)) {
|
|
13844
|
+
return element.map(renderToStaticMarkup).join("");
|
|
13845
|
+
}
|
|
13846
|
+
if (typeof element === "object" && element !== null) {
|
|
13847
|
+
if (typeof element.type === "function") {
|
|
13848
|
+
return renderToStaticMarkup(element.type(element.props));
|
|
13849
|
+
}
|
|
13850
|
+
if (typeof element.type === "string") {
|
|
13851
|
+
const attrs = Object.entries(element.props || {}).filter(([key]) => key !== "children").map(([key, value]) => `${key}="${value}"`).join(" ");
|
|
13852
|
+
const children = element.props.children ? renderToStaticMarkup(element.props.children) : "";
|
|
13853
|
+
return `<${element.type} ${attrs}>${children}</${element.type}>`;
|
|
13854
|
+
}
|
|
13855
|
+
}
|
|
13856
|
+
return "";
|
|
13857
|
+
}
|
|
13858
|
+
function templatesToString(templates) {
|
|
13859
|
+
if (templates) {
|
|
13860
|
+
for (const templateName in templates) {
|
|
13861
|
+
const Template = templates[templateName];
|
|
13862
|
+
const isReactComp = String(Template).includes("jsxRuntime");
|
|
13863
|
+
if (isReactComp)
|
|
13864
|
+
templates[templateName] = (...props) => renderToStaticMarkup(/* @__PURE__ */ jsx8(Template, { props }));
|
|
13865
|
+
}
|
|
13866
|
+
}
|
|
13867
|
+
}
|
|
13868
|
+
function compareStrings(str1, str2) {
|
|
13869
|
+
if (typeof str1 !== typeof str2)
|
|
13870
|
+
return;
|
|
13871
|
+
const words1 = str1.split(" ");
|
|
13872
|
+
const words2 = str2.split(" ");
|
|
13873
|
+
const added = words2.filter((word) => !words1.includes(word));
|
|
13874
|
+
const removed = words1.filter((word) => !words2.includes(word));
|
|
13875
|
+
return { added, removed };
|
|
13876
|
+
}
|
|
13877
|
+
var TagifyWrapper = ({
|
|
13878
|
+
name,
|
|
13879
|
+
value,
|
|
13880
|
+
loading = false,
|
|
13881
|
+
onInput = noop,
|
|
13882
|
+
onAdd = noop,
|
|
13883
|
+
onRemove = noop,
|
|
13884
|
+
onEditInput = noop,
|
|
13885
|
+
onEditBeforeUpdate = noop,
|
|
13886
|
+
onEditUpdated = noop,
|
|
13887
|
+
onEditStart = noop,
|
|
13888
|
+
onEditKeydown = noop,
|
|
13889
|
+
onInvalid = noop,
|
|
13890
|
+
onClick = noop,
|
|
13891
|
+
onKeydown = noop,
|
|
13892
|
+
onFocus = noop,
|
|
13893
|
+
onBlur = noop,
|
|
13894
|
+
onChange = noop,
|
|
13895
|
+
onDropdownShow = noop,
|
|
13896
|
+
onDropdownHide = noop,
|
|
13897
|
+
onDropdownSelect = noop,
|
|
13898
|
+
onDropdownScroll = noop,
|
|
13899
|
+
onDropdownNoMatch = noop,
|
|
13900
|
+
onDropdownUpdated = noop,
|
|
13901
|
+
readOnly,
|
|
13902
|
+
disabled,
|
|
13903
|
+
userInput = true,
|
|
13904
|
+
children,
|
|
13905
|
+
settings: settings2 = {},
|
|
13906
|
+
InputMode = "input",
|
|
13907
|
+
autoFocus,
|
|
13908
|
+
className,
|
|
13909
|
+
whitelist,
|
|
13910
|
+
tagifyRef,
|
|
13911
|
+
placeholder: placeholder2 = "",
|
|
13912
|
+
defaultValue,
|
|
13913
|
+
showDropdown
|
|
13914
|
+
}) => {
|
|
13915
|
+
const mountedRef = useRef4();
|
|
13916
|
+
const inputElmRef = useRef4(null);
|
|
13917
|
+
const tagify = useRef4();
|
|
13918
|
+
const lastClassNameRef = useRef4();
|
|
13919
|
+
const _value = defaultValue || value;
|
|
13920
|
+
const inputAttrs = useMemo2(
|
|
13921
|
+
() => ({
|
|
13922
|
+
ref: inputElmRef,
|
|
13923
|
+
name,
|
|
13924
|
+
defaultValue: children || typeof _value === "string" ? _value : JSON.stringify(_value),
|
|
13925
|
+
className,
|
|
13926
|
+
readOnly,
|
|
13927
|
+
disabled,
|
|
13928
|
+
autoFocus,
|
|
13929
|
+
placeholder: placeholder2
|
|
13930
|
+
}),
|
|
13931
|
+
[]
|
|
13932
|
+
);
|
|
13933
|
+
const setFocus = useCallback6(() => {
|
|
13934
|
+
var _a;
|
|
13935
|
+
autoFocus && ((_a = tagify.current) == null ? void 0 : _a.DOM.input.focus());
|
|
13936
|
+
}, [tagify]);
|
|
13937
|
+
useEffect5(() => {
|
|
13938
|
+
templatesToString(settings2.templates);
|
|
13939
|
+
settings2.userInput = userInput;
|
|
13940
|
+
if (InputMode === "textarea")
|
|
13941
|
+
settings2.mode = "mix";
|
|
13942
|
+
if (whitelist == null ? void 0 : whitelist.length)
|
|
13943
|
+
settings2.whitelist = whitelist;
|
|
13944
|
+
const t = new Tagify(inputElmRef.current, settings2);
|
|
13945
|
+
if (tagifyRef) {
|
|
13946
|
+
tagifyRef.current = t;
|
|
13947
|
+
}
|
|
13948
|
+
tagify.current = t;
|
|
13949
|
+
setFocus();
|
|
13950
|
+
return () => {
|
|
13951
|
+
t.destroy();
|
|
13952
|
+
};
|
|
13953
|
+
}, []);
|
|
13954
|
+
useEffect5(() => {
|
|
13955
|
+
var _a;
|
|
13956
|
+
(_a = tagify.current) == null ? void 0 : _a.off("change", onChange).on("change", onChange);
|
|
13957
|
+
}, [onChange]);
|
|
13958
|
+
useEffect5(() => {
|
|
13959
|
+
var _a;
|
|
13960
|
+
(_a = tagify.current) == null ? void 0 : _a.off("input", onInput).on("input", onInput);
|
|
13961
|
+
}, [onInput]);
|
|
13962
|
+
useEffect5(() => {
|
|
13963
|
+
var _a;
|
|
13964
|
+
(_a = tagify.current) == null ? void 0 : _a.off("add", onAdd).on("add", onAdd);
|
|
13965
|
+
}, [onAdd]);
|
|
13966
|
+
useEffect5(() => {
|
|
13967
|
+
var _a;
|
|
13968
|
+
(_a = tagify.current) == null ? void 0 : _a.off("remove", onRemove).on("remove", onRemove);
|
|
13969
|
+
}, [onRemove]);
|
|
13970
|
+
useEffect5(() => {
|
|
13971
|
+
var _a;
|
|
13972
|
+
(_a = tagify.current) == null ? void 0 : _a.off("invalid", onInvalid).on("invalid", onInvalid);
|
|
13973
|
+
}, [onInvalid]);
|
|
13974
|
+
useEffect5(() => {
|
|
13975
|
+
var _a;
|
|
13976
|
+
(_a = tagify.current) == null ? void 0 : _a.off("keydown", onKeydown).on("keydown", onKeydown);
|
|
13977
|
+
}, [onKeydown]);
|
|
13978
|
+
useEffect5(() => {
|
|
13979
|
+
var _a;
|
|
13980
|
+
(_a = tagify.current) == null ? void 0 : _a.off("focus", onFocus).on("focus", onFocus);
|
|
13981
|
+
}, [onFocus]);
|
|
13982
|
+
useEffect5(() => {
|
|
13983
|
+
var _a;
|
|
13984
|
+
(_a = tagify.current) == null ? void 0 : _a.off("blur", onBlur).on("blur", onBlur);
|
|
13985
|
+
}, [onBlur]);
|
|
13986
|
+
useEffect5(() => {
|
|
13987
|
+
var _a;
|
|
13988
|
+
(_a = tagify.current) == null ? void 0 : _a.off("click", onClick).on("click", onClick);
|
|
13989
|
+
}, [onClick]);
|
|
13990
|
+
useEffect5(() => {
|
|
13991
|
+
var _a;
|
|
13992
|
+
(_a = tagify.current) == null ? void 0 : _a.off("edit:input", onEditInput).on("edit:input", onEditInput);
|
|
13993
|
+
}, [onEditInput]);
|
|
13994
|
+
useEffect5(() => {
|
|
13995
|
+
var _a;
|
|
13996
|
+
(_a = tagify.current) == null ? void 0 : _a.off("edit:beforeUpdate", onEditBeforeUpdate).on("edit:beforeUpdate", onEditBeforeUpdate);
|
|
13997
|
+
}, [onEditBeforeUpdate]);
|
|
13998
|
+
useEffect5(() => {
|
|
13999
|
+
var _a;
|
|
14000
|
+
(_a = tagify.current) == null ? void 0 : _a.off("edit:updated", onEditUpdated).on("edit:updated", onEditUpdated);
|
|
14001
|
+
}, [onEditUpdated]);
|
|
14002
|
+
useEffect5(() => {
|
|
14003
|
+
var _a;
|
|
14004
|
+
(_a = tagify.current) == null ? void 0 : _a.off("edit:start", onEditStart).on("edit:start", onEditStart);
|
|
14005
|
+
}, [onEditStart]);
|
|
14006
|
+
useEffect5(() => {
|
|
14007
|
+
var _a;
|
|
14008
|
+
(_a = tagify.current) == null ? void 0 : _a.off("edit:keydown", onEditKeydown).on("edit:keydown", onEditKeydown);
|
|
14009
|
+
}, [onEditKeydown]);
|
|
14010
|
+
useEffect5(() => {
|
|
14011
|
+
var _a;
|
|
14012
|
+
(_a = tagify.current) == null ? void 0 : _a.off("dropdown:show", onDropdownShow).on("dropdown:show", onDropdownShow);
|
|
14013
|
+
}, [onDropdownShow]);
|
|
14014
|
+
useEffect5(() => {
|
|
14015
|
+
var _a;
|
|
14016
|
+
(_a = tagify.current) == null ? void 0 : _a.off("dropdown:hide", onDropdownHide).on("dropdown:hide", onDropdownHide);
|
|
14017
|
+
}, [onDropdownHide]);
|
|
14018
|
+
useEffect5(() => {
|
|
14019
|
+
var _a;
|
|
14020
|
+
(_a = tagify.current) == null ? void 0 : _a.off("dropdown:select", onDropdownSelect).on("dropdown:select", onDropdownSelect);
|
|
14021
|
+
}, [onDropdownSelect]);
|
|
14022
|
+
useEffect5(() => {
|
|
14023
|
+
var _a;
|
|
14024
|
+
(_a = tagify.current) == null ? void 0 : _a.off("dropdown:scroll", onDropdownScroll).on("dropdown:scroll", onDropdownScroll);
|
|
14025
|
+
}, [onDropdownScroll]);
|
|
14026
|
+
useEffect5(() => {
|
|
14027
|
+
var _a;
|
|
14028
|
+
(_a = tagify.current) == null ? void 0 : _a.off("dropdown:noMatch", onDropdownNoMatch).on("dropdown:noMatch", onDropdownNoMatch);
|
|
14029
|
+
}, [onDropdownNoMatch]);
|
|
14030
|
+
useEffect5(() => {
|
|
14031
|
+
var _a;
|
|
14032
|
+
(_a = tagify.current) == null ? void 0 : _a.off("dropdown:updated", onDropdownUpdated).on("dropdown:updated", onDropdownUpdated);
|
|
14033
|
+
}, [onDropdownUpdated]);
|
|
14034
|
+
useEffect5(() => {
|
|
14035
|
+
setFocus();
|
|
14036
|
+
}, [autoFocus]);
|
|
14037
|
+
useEffect5(() => {
|
|
14038
|
+
var _a;
|
|
14039
|
+
if (mountedRef.current) {
|
|
14040
|
+
tagify.current.settings.whitelist.length = 0;
|
|
14041
|
+
(whitelist == null ? void 0 : whitelist.length) && ((_a = tagify.current) == null ? void 0 : _a.settings.whitelist.push(...whitelist));
|
|
14042
|
+
}
|
|
14043
|
+
}, [whitelist]);
|
|
14044
|
+
useEffect5(() => {
|
|
14045
|
+
const currentValue = tagify.current.getInputValue();
|
|
14046
|
+
if (mountedRef.current && !isSameDeep(value, currentValue)) {
|
|
14047
|
+
tagify.current.loadOriginalValues(value);
|
|
14048
|
+
}
|
|
14049
|
+
}, [value]);
|
|
14050
|
+
useEffect5(() => {
|
|
14051
|
+
if (mountedRef.current) {
|
|
14052
|
+
const { added, removed } = compareStrings(
|
|
14053
|
+
lastClassNameRef.current,
|
|
14054
|
+
className
|
|
14055
|
+
);
|
|
14056
|
+
added.filter(String).forEach((cls) => {
|
|
14057
|
+
tagify.current.toggleClass(cls, true);
|
|
14058
|
+
});
|
|
14059
|
+
removed.filter(String).forEach((cls) => {
|
|
14060
|
+
tagify.current.toggleClass(cls, false);
|
|
14061
|
+
});
|
|
14062
|
+
}
|
|
14063
|
+
lastClassNameRef.current = className;
|
|
14064
|
+
}, [className]);
|
|
14065
|
+
useEffect5(() => {
|
|
14066
|
+
var _a;
|
|
14067
|
+
if (mountedRef.current) {
|
|
14068
|
+
(_a = tagify.current) == null ? void 0 : _a.loading(loading);
|
|
14069
|
+
}
|
|
14070
|
+
}, [loading]);
|
|
14071
|
+
useEffect5(() => {
|
|
14072
|
+
var _a;
|
|
14073
|
+
if (mountedRef.current) {
|
|
14074
|
+
(_a = tagify.current) == null ? void 0 : _a.setReadonly(readOnly);
|
|
14075
|
+
}
|
|
14076
|
+
}, [readOnly]);
|
|
14077
|
+
useEffect5(() => {
|
|
14078
|
+
var _a;
|
|
14079
|
+
if (mountedRef.current) {
|
|
14080
|
+
(_a = tagify.current) == null ? void 0 : _a.setDisabled(disabled);
|
|
14081
|
+
}
|
|
14082
|
+
}, [disabled]);
|
|
14083
|
+
useEffect5(() => {
|
|
14084
|
+
if (mountedRef.current) {
|
|
14085
|
+
tagify.current.userInput = userInput;
|
|
14086
|
+
}
|
|
14087
|
+
}, [userInput]);
|
|
14088
|
+
useEffect5(() => {
|
|
14089
|
+
if (mountedRef.current) {
|
|
14090
|
+
tagify.current.setPlaceholder(placeholder2);
|
|
14091
|
+
}
|
|
14092
|
+
}, [placeholder2]);
|
|
14093
|
+
useEffect5(() => {
|
|
14094
|
+
const t = tagify.current;
|
|
14095
|
+
if (mountedRef.current) {
|
|
14096
|
+
if (showDropdown) {
|
|
14097
|
+
t.dropdown.show.call(t, showDropdown);
|
|
14098
|
+
t.toggleFocusClass(true);
|
|
14099
|
+
} else {
|
|
14100
|
+
t.dropdown.hide.call(t);
|
|
14101
|
+
}
|
|
14102
|
+
}
|
|
14103
|
+
}, [showDropdown]);
|
|
14104
|
+
useEffect5(() => {
|
|
14105
|
+
mountedRef.current = true;
|
|
14106
|
+
}, []);
|
|
14107
|
+
return (
|
|
14108
|
+
// a wrapper must be used because Tagify will appened inside it it's component,
|
|
14109
|
+
// keeping the virtual-DOM out of the way
|
|
14110
|
+
/* @__PURE__ */ jsx8("div", { className: "tags-input", children: /* @__PURE__ */ jsx8(InputMode, __spreadValues({}, inputAttrs)) })
|
|
14111
|
+
);
|
|
14112
|
+
};
|
|
14113
|
+
var Tags = memo(TagifyWrapper);
|
|
14114
|
+
var Tags_default = Tags;
|
|
14115
|
+
|
|
13825
14116
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Forms/Schema/overrides/Fields/CustomTags/TagsInput/utils.ts
|
|
13826
14117
|
var createTagFromPath = (path, frame) => {
|
|
13827
14118
|
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l;
|
|
@@ -13920,23 +14211,23 @@ function CustomTagsInput({
|
|
|
13920
14211
|
renderPicker,
|
|
13921
14212
|
renderPickerTrigger
|
|
13922
14213
|
}) {
|
|
13923
|
-
const tagifyRef =
|
|
14214
|
+
const tagifyRef = useRef5();
|
|
13924
14215
|
const [tooltipData, { showTagTooltip, hideTagTooltip }] = useCustomTagsInputTagTooltipData();
|
|
13925
|
-
const updateAllIcons =
|
|
14216
|
+
const updateAllIcons = useCallback7(() => {
|
|
13926
14217
|
const tagify = tagifyRef.current;
|
|
13927
14218
|
if (!tagify) {
|
|
13928
14219
|
return;
|
|
13929
14220
|
}
|
|
13930
14221
|
tagify.value.forEach(updateCustomTagsInputTagIcon);
|
|
13931
14222
|
}, []);
|
|
13932
|
-
const getCurrentValue =
|
|
14223
|
+
const getCurrentValue = useCallback7(() => {
|
|
13933
14224
|
const tagify = tagifyRef.current;
|
|
13934
14225
|
if (!tagify) {
|
|
13935
14226
|
return "";
|
|
13936
14227
|
}
|
|
13937
14228
|
return tagify.getMixedTagsAsString().replace(trim2 ? /\s+/g : /\r\n$/, "").replaceAll("[[", "${").replaceAll("]]", "}").replaceAll("\u200B", "");
|
|
13938
14229
|
}, [trim2]);
|
|
13939
|
-
const setCurrentValue =
|
|
14230
|
+
const setCurrentValue = useCallback7(
|
|
13940
14231
|
(value2, frame) => {
|
|
13941
14232
|
const tagify = tagifyRef.current;
|
|
13942
14233
|
if (!tagify) {
|
|
@@ -13947,11 +14238,11 @@ function CustomTagsInput({
|
|
|
13947
14238
|
},
|
|
13948
14239
|
[updateAllIcons]
|
|
13949
14240
|
);
|
|
13950
|
-
const handleChange =
|
|
14241
|
+
const handleChange = useCallback7(() => {
|
|
13951
14242
|
onChange(getCurrentValue());
|
|
13952
14243
|
updateAllIcons();
|
|
13953
14244
|
}, [onChange, getCurrentValue, updateAllIcons]);
|
|
13954
|
-
const handleKeyDown =
|
|
14245
|
+
const handleKeyDown = useCallback7(
|
|
13955
14246
|
(e) => {
|
|
13956
14247
|
if (e.detail.event.key !== "Backspace") {
|
|
13957
14248
|
return;
|
|
@@ -13962,7 +14253,7 @@ function CustomTagsInput({
|
|
|
13962
14253
|
},
|
|
13963
14254
|
[handleChange]
|
|
13964
14255
|
);
|
|
13965
|
-
const addTag =
|
|
14256
|
+
const addTag = useCallback7(
|
|
13966
14257
|
(tag) => {
|
|
13967
14258
|
const tagify = tagifyRef.current;
|
|
13968
14259
|
if (!tagify) {
|
|
@@ -13978,7 +14269,7 @@ function CustomTagsInput({
|
|
|
13978
14269
|
},
|
|
13979
14270
|
[trim2, onPickerToggle]
|
|
13980
14271
|
);
|
|
13981
|
-
|
|
14272
|
+
useEffect6(() => {
|
|
13982
14273
|
const tagify = tagifyRef.current;
|
|
13983
14274
|
if (!tagify) {
|
|
13984
14275
|
return;
|
|
@@ -14004,7 +14295,7 @@ function CustomTagsInput({
|
|
|
14004
14295
|
showTagTooltip,
|
|
14005
14296
|
hideTagTooltip
|
|
14006
14297
|
]);
|
|
14007
|
-
|
|
14298
|
+
useEffect6(() => {
|
|
14008
14299
|
const tagify = tagifyRef.current;
|
|
14009
14300
|
if (!tagify || !value) {
|
|
14010
14301
|
return;
|
|
@@ -14029,7 +14320,7 @@ function CustomTagsInput({
|
|
|
14029
14320
|
triggerOnHover: false,
|
|
14030
14321
|
triggerRenderer: /* @__PURE__ */ jsxs2(Fragment3, { children: [
|
|
14031
14322
|
/* @__PURE__ */ jsx7(
|
|
14032
|
-
|
|
14323
|
+
Tags_default,
|
|
14033
14324
|
{
|
|
14034
14325
|
className: ["customLook", error ? "tagify--error" : void 0].filter(Boolean).join(" "),
|
|
14035
14326
|
disabled,
|
|
@@ -14090,7 +14381,7 @@ function CustomTagsField({
|
|
|
14090
14381
|
wrapperCss,
|
|
14091
14382
|
onChange
|
|
14092
14383
|
}) {
|
|
14093
|
-
const wrapperRef =
|
|
14384
|
+
const wrapperRef = useRef6(null);
|
|
14094
14385
|
const [isPickerVisible, setIsPickerVisible] = useState11(false);
|
|
14095
14386
|
useOnClickOutside(wrapperRef, () => {
|
|
14096
14387
|
setIsPickerVisible(false);
|
|
@@ -14177,7 +14468,7 @@ function CustomStringField(props) {
|
|
|
14177
14468
|
const [isPredefined, setIsPredefined] = useState12(
|
|
14178
14469
|
() => pickerOptions.some((option) => option.key === props.formData) || !props.formData && pickerOptions.length > 0 || void 0
|
|
14179
14470
|
);
|
|
14180
|
-
|
|
14471
|
+
useEffect7(() => {
|
|
14181
14472
|
const externalEntityReference = props.schema["x-ref"];
|
|
14182
14473
|
const fetchData = () => {
|
|
14183
14474
|
const json = [
|
|
@@ -14200,7 +14491,7 @@ function CustomStringField(props) {
|
|
|
14200
14491
|
fetchData();
|
|
14201
14492
|
}
|
|
14202
14493
|
}, [props.formData, props.schema]);
|
|
14203
|
-
|
|
14494
|
+
useEffect7(() => {
|
|
14204
14495
|
setIsPredefined(
|
|
14205
14496
|
pickerOptions.some((option) => option.key === props.formData) || !props.formData && pickerOptions.length > 0
|
|
14206
14497
|
);
|
|
@@ -14886,7 +15177,7 @@ function ForkJoinNodeForm({
|
|
|
14886
15177
|
var Form_default2 = ForkJoinNodeForm;
|
|
14887
15178
|
|
|
14888
15179
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Diagram/Nodes/CustomNodes/ForkJoinNode/Node.tsx
|
|
14889
|
-
import { memo as
|
|
15180
|
+
import { memo as memo3, useState as useState14 } from "react";
|
|
14890
15181
|
import { Position as Position4 } from "reactflow";
|
|
14891
15182
|
|
|
14892
15183
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Diagram/Handles/CustomAdd/Handle.tsx
|
|
@@ -14973,13 +15264,13 @@ var Toolbar_default = CustomToolbar;
|
|
|
14973
15264
|
var CustomToolbar_default = Toolbar_default;
|
|
14974
15265
|
|
|
14975
15266
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Diagram/Nodes/CustomNodes/Custom.tsx
|
|
14976
|
-
import { memo } from "react";
|
|
15267
|
+
import { memo as memo2 } from "react";
|
|
14977
15268
|
import { Handle as Handle2, Position as Position3, useReactFlow as useReactFlow2, useStoreApi } from "reactflow";
|
|
14978
15269
|
import {
|
|
14979
15270
|
DesignToken as DesignToken11,
|
|
14980
15271
|
RadiusToken as RadiusToken3
|
|
14981
15272
|
} from "@livechat/design-system-react-components";
|
|
14982
|
-
import { Fragment as Fragment9, jsx as
|
|
15273
|
+
import { Fragment as Fragment9, jsx as jsx9, jsxs as jsxs3 } from "react/jsx-runtime";
|
|
14983
15274
|
var Wrapper2 = newStyled.div`
|
|
14984
15275
|
&:hover {
|
|
14985
15276
|
cursor: pointer;
|
|
@@ -15003,7 +15294,7 @@ function CustomNodeWrapper({
|
|
|
15003
15294
|
onMouseEnter,
|
|
15004
15295
|
onMouseLeave
|
|
15005
15296
|
}) {
|
|
15006
|
-
return /* @__PURE__ */
|
|
15297
|
+
return /* @__PURE__ */ jsx9(Wrapper2, { onMouseEnter, onMouseLeave, children });
|
|
15007
15298
|
}
|
|
15008
15299
|
var options = [
|
|
15009
15300
|
{
|
|
@@ -15046,9 +15337,9 @@ function Select({
|
|
|
15046
15337
|
);
|
|
15047
15338
|
};
|
|
15048
15339
|
return /* @__PURE__ */ jsxs3("div", { className: "custom-node__select", children: [
|
|
15049
|
-
/* @__PURE__ */
|
|
15050
|
-
/* @__PURE__ */
|
|
15051
|
-
/* @__PURE__ */
|
|
15340
|
+
/* @__PURE__ */ jsx9("div", { children: "Edge Type" }),
|
|
15341
|
+
/* @__PURE__ */ jsx9("select", { className: "nodrag", onChange, value, children: options.map((option) => /* @__PURE__ */ jsx9("option", { value: option.value, children: option.label }, option.value)) }),
|
|
15342
|
+
/* @__PURE__ */ jsx9(Handle2, { id: handleId, position: Position3.Right, type: "source" })
|
|
15052
15343
|
] });
|
|
15053
15344
|
}
|
|
15054
15345
|
function CustomNode({
|
|
@@ -15058,9 +15349,9 @@ function CustomNode({
|
|
|
15058
15349
|
return /* @__PURE__ */ jsxs3(Fragment9, { children: [
|
|
15059
15350
|
/* @__PURE__ */ jsxs3("div", { className: "custom-node__header", children: [
|
|
15060
15351
|
"This is a ",
|
|
15061
|
-
/* @__PURE__ */
|
|
15352
|
+
/* @__PURE__ */ jsx9("strong", { children: "custom node" })
|
|
15062
15353
|
] }),
|
|
15063
|
-
/* @__PURE__ */
|
|
15354
|
+
/* @__PURE__ */ jsx9("div", { className: "custom-node__body", children: Object.keys(data.selects).map((handleId) => /* @__PURE__ */ jsx9(
|
|
15064
15355
|
Select,
|
|
15065
15356
|
{
|
|
15066
15357
|
handleId,
|
|
@@ -15071,7 +15362,7 @@ function CustomNode({
|
|
|
15071
15362
|
)) })
|
|
15072
15363
|
] });
|
|
15073
15364
|
}
|
|
15074
|
-
var Custom_default =
|
|
15365
|
+
var Custom_default = memo2(CustomNode);
|
|
15075
15366
|
|
|
15076
15367
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Diagram/Nodes/CustomNodes/ForkJoinNode/Node.tsx
|
|
15077
15368
|
function ForkJoinNode({
|
|
@@ -15135,7 +15426,7 @@ function ForkJoinNode({
|
|
|
15135
15426
|
}
|
|
15136
15427
|
);
|
|
15137
15428
|
}
|
|
15138
|
-
var Node_default =
|
|
15429
|
+
var Node_default = memo3(ForkJoinNode);
|
|
15139
15430
|
|
|
15140
15431
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Diagram/Nodes/CustomNodes/HttpNode/Base.tsx
|
|
15141
15432
|
import { Automation } from "@livechat/design-system-icons";
|
|
@@ -15275,7 +15566,7 @@ import {
|
|
|
15275
15566
|
} from "@livechat/developer-studio-api";
|
|
15276
15567
|
|
|
15277
15568
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Forms/Schema/Wrapper.tsx
|
|
15278
|
-
import { useMemo as
|
|
15569
|
+
import { useMemo as useMemo3, useState as useState19 } from "react";
|
|
15279
15570
|
import { Error as Error2 } from "@livechat/design-system-icons";
|
|
15280
15571
|
import {
|
|
15281
15572
|
Icon as Icon18,
|
|
@@ -15288,7 +15579,7 @@ import {
|
|
|
15288
15579
|
} from "@livechat/developer-studio-api";
|
|
15289
15580
|
|
|
15290
15581
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Forms/Schema/integrations/BigCommerce/index.tsx
|
|
15291
|
-
import { useCallback as
|
|
15582
|
+
import { useCallback as useCallback10, useContext as useContext15, useState as useState16 } from "react";
|
|
15292
15583
|
import { Link, useLocation } from "react-router-dom";
|
|
15293
15584
|
import { useQueryClient as useQueryClient5 } from "@tanstack/react-query";
|
|
15294
15585
|
import { notificationConnect } from "@livechat/design-system";
|
|
@@ -15341,9 +15632,9 @@ import { useMatch } from "@livechat/developer-studio-ui-react";
|
|
|
15341
15632
|
|
|
15342
15633
|
// src/views/Settings/Integrations/Common/IntegrationAction.tsx
|
|
15343
15634
|
import {
|
|
15344
|
-
useCallback as
|
|
15635
|
+
useCallback as useCallback9,
|
|
15345
15636
|
useContext as useContext13,
|
|
15346
|
-
useEffect as
|
|
15637
|
+
useEffect as useEffect9,
|
|
15347
15638
|
useState as useState15
|
|
15348
15639
|
} from "react";
|
|
15349
15640
|
import { useNavigate as useNavigate4 } from "react-router-dom";
|
|
@@ -15360,7 +15651,7 @@ import {
|
|
|
15360
15651
|
} from "@livechat/developer-studio-ui-react";
|
|
15361
15652
|
|
|
15362
15653
|
// src/views/Settings/Integrations/Common/IntegrationCallback.tsx
|
|
15363
|
-
import { useCallback as
|
|
15654
|
+
import { useCallback as useCallback8, useEffect as useEffect8 } from "react";
|
|
15364
15655
|
import { useNavigate as useNavigate3 } from "react-router-dom";
|
|
15365
15656
|
import {
|
|
15366
15657
|
decodeQueryString as decodeQueryString3,
|
|
@@ -15377,7 +15668,7 @@ function IntegrationLoading() {
|
|
|
15377
15668
|
var IntegrationLoading_default = IntegrationLoading;
|
|
15378
15669
|
|
|
15379
15670
|
// src/views/Settings/Integrations/Common/IntegrationCallback.tsx
|
|
15380
|
-
import { jsx as
|
|
15671
|
+
import { jsx as jsx10 } from "react/jsx-runtime";
|
|
15381
15672
|
function integrationHandlerWrapper(output, handler, notifications, provider) {
|
|
15382
15673
|
var _a, _b;
|
|
15383
15674
|
const response = handler(output);
|
|
@@ -15405,7 +15696,7 @@ function integrationHandlerWrapper(output, handler, notifications, provider) {
|
|
|
15405
15696
|
}
|
|
15406
15697
|
function useIntegrationCallback() {
|
|
15407
15698
|
const history = useNavigate3();
|
|
15408
|
-
return
|
|
15699
|
+
return useCallback8(
|
|
15409
15700
|
(response, data) => {
|
|
15410
15701
|
if (!data.redirectTo) {
|
|
15411
15702
|
window.close();
|
|
@@ -15437,7 +15728,7 @@ function IntegrationCallback({
|
|
|
15437
15728
|
}) {
|
|
15438
15729
|
const callback = useIntegrationCallback();
|
|
15439
15730
|
const notifications = useNotifications6();
|
|
15440
|
-
|
|
15731
|
+
useEffect8(() => {
|
|
15441
15732
|
const params = new URL(window.location.toString()).searchParams;
|
|
15442
15733
|
const _a = Object.fromEntries(params), {
|
|
15443
15734
|
state: stateFromParams,
|
|
@@ -15473,12 +15764,12 @@ function IntegrationCallback({
|
|
|
15473
15764
|
);
|
|
15474
15765
|
callback(response, data);
|
|
15475
15766
|
}, [callback, handler, notifications]);
|
|
15476
|
-
return /* @__PURE__ */
|
|
15767
|
+
return /* @__PURE__ */ jsx10(IntegrationLoading_default, {});
|
|
15477
15768
|
}
|
|
15478
15769
|
var IntegrationCallback_default = IntegrationCallback;
|
|
15479
15770
|
|
|
15480
15771
|
// src/views/Settings/Integrations/Common/IntegrationAction.tsx
|
|
15481
|
-
import { Fragment as Fragment11, jsx as
|
|
15772
|
+
import { Fragment as Fragment11, jsx as jsx11, jsxs as jsxs4 } from "react/jsx-runtime";
|
|
15482
15773
|
var deserializeIntegrationActionData = (state) => serializerBase64.deserialize(state);
|
|
15483
15774
|
var serializeIntegrationActionData = (data) => serializerBase64.serialize(data);
|
|
15484
15775
|
var serializeContextState = (data) => {
|
|
@@ -15507,7 +15798,7 @@ function IntegrationAction(props) {
|
|
|
15507
15798
|
props.serializedData
|
|
15508
15799
|
);
|
|
15509
15800
|
const context = (_b = props.context) != null ? _b : serializerBase64.deserialize(props.serializedContext);
|
|
15510
|
-
const execute =
|
|
15801
|
+
const execute = useCallback9(() => __async(this, null, function* () {
|
|
15511
15802
|
if (!data) {
|
|
15512
15803
|
history(`/settings/integrations/${props.name}/status`);
|
|
15513
15804
|
return;
|
|
@@ -15528,7 +15819,7 @@ function IntegrationAction(props) {
|
|
|
15528
15819
|
}));
|
|
15529
15820
|
}
|
|
15530
15821
|
}), [props, data, context, user, notifications, history]);
|
|
15531
|
-
|
|
15822
|
+
useEffect9(() => {
|
|
15532
15823
|
var _a2;
|
|
15533
15824
|
if (((_a2 = props.executor) == null ? void 0 : _a2.type) === "manual") {
|
|
15534
15825
|
return;
|
|
@@ -15542,7 +15833,7 @@ function IntegrationAction(props) {
|
|
|
15542
15833
|
((_d = props.executor) == null ? void 0 : _d.type) === "manual" ? props.executor.render(() => {
|
|
15543
15834
|
execute();
|
|
15544
15835
|
}) : null,
|
|
15545
|
-
state.isTriggered ? /* @__PURE__ */
|
|
15836
|
+
state.isTriggered ? /* @__PURE__ */ jsx11(IntegrationLoading_default, {}) : null
|
|
15546
15837
|
] });
|
|
15547
15838
|
}
|
|
15548
15839
|
function executeIntegrationAction(props, meta) {
|
|
@@ -15601,7 +15892,7 @@ function executeIntegrationAction(props, meta) {
|
|
|
15601
15892
|
var IntegrationAction_default = IntegrationAction;
|
|
15602
15893
|
|
|
15603
15894
|
// src/views/Settings/Integrations/BigCommerce/Action.tsx
|
|
15604
|
-
import { jsx as
|
|
15895
|
+
import { jsx as jsx12 } from "react/jsx-runtime";
|
|
15605
15896
|
function BigCommerceAction(props) {
|
|
15606
15897
|
var _a;
|
|
15607
15898
|
const { login } = useContext14(AuthContext);
|
|
@@ -15610,7 +15901,7 @@ function BigCommerceAction(props) {
|
|
|
15610
15901
|
if (!action) {
|
|
15611
15902
|
throw new Error("Invalid action");
|
|
15612
15903
|
}
|
|
15613
|
-
return /* @__PURE__ */
|
|
15904
|
+
return /* @__PURE__ */ jsx12(
|
|
15614
15905
|
IntegrationAction_default,
|
|
15615
15906
|
{
|
|
15616
15907
|
action,
|
|
@@ -15725,14 +16016,14 @@ function BigCommerce() {
|
|
|
15725
16016
|
const { context: notifications } = useNotifications8();
|
|
15726
16017
|
const connected = (_a = credentialsQuery.data.internal) == null ? void 0 : _a.data.connected;
|
|
15727
16018
|
const [state, setState] = useState16();
|
|
15728
|
-
const refetch =
|
|
16019
|
+
const refetch = useCallback10(() => {
|
|
15729
16020
|
credentialsQuery.refetch();
|
|
15730
16021
|
queryClient.invalidateQueries(
|
|
15731
16022
|
integrationCredentialsQueryKeys.getCredentials()
|
|
15732
16023
|
);
|
|
15733
16024
|
}, [credentialsQuery, queryClient]);
|
|
15734
16025
|
const oauthCredential = credentialsQuery.data.internal;
|
|
15735
|
-
const triggerConnect =
|
|
16026
|
+
const triggerConnect = useCallback10(
|
|
15736
16027
|
(shop) => {
|
|
15737
16028
|
triggerBigCommerceAction(
|
|
15738
16029
|
{
|
|
@@ -15757,14 +16048,14 @@ function BigCommerce() {
|
|
|
15757
16048
|
},
|
|
15758
16049
|
[login, refetch, notifications, user, pathname]
|
|
15759
16050
|
);
|
|
15760
|
-
const toggleModal =
|
|
16051
|
+
const toggleModal = useCallback10((isVisible) => {
|
|
15761
16052
|
setState((prevState) => __spreadProps(__spreadValues({}, prevState), {
|
|
15762
16053
|
modal: {
|
|
15763
16054
|
isVisible
|
|
15764
16055
|
}
|
|
15765
16056
|
}));
|
|
15766
16057
|
}, []);
|
|
15767
|
-
const updateShop =
|
|
16058
|
+
const updateShop = useCallback10((shop) => {
|
|
15768
16059
|
setState(
|
|
15769
16060
|
(prevState) => {
|
|
15770
16061
|
var _a2;
|
|
@@ -15776,7 +16067,7 @@ function BigCommerce() {
|
|
|
15776
16067
|
}
|
|
15777
16068
|
);
|
|
15778
16069
|
}, []);
|
|
15779
|
-
const submit =
|
|
16070
|
+
const submit = useCallback10(() => {
|
|
15780
16071
|
var _a2;
|
|
15781
16072
|
setState(
|
|
15782
16073
|
(prevState) => {
|
|
@@ -15793,7 +16084,7 @@ function BigCommerce() {
|
|
|
15793
16084
|
triggerConnect(state.modal.shop);
|
|
15794
16085
|
}
|
|
15795
16086
|
}, [state == null ? void 0 : state.modal, toggleModal, triggerConnect]);
|
|
15796
|
-
const Connect =
|
|
16087
|
+
const Connect = useCallback10(
|
|
15797
16088
|
({ credential }) => {
|
|
15798
16089
|
if (!credential) {
|
|
15799
16090
|
return /* @__PURE__ */ jsx7(
|
|
@@ -15937,7 +16228,7 @@ function BigCommerce() {
|
|
|
15937
16228
|
var BigCommerce_default = notificationConnect(BigCommerce);
|
|
15938
16229
|
|
|
15939
16230
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Forms/Schema/integrations/HubSpot/index.tsx
|
|
15940
|
-
import { useCallback as
|
|
16231
|
+
import { useCallback as useCallback11 } from "react";
|
|
15941
16232
|
import { Link as Link2, useLocation as useLocation2 } from "react-router-dom";
|
|
15942
16233
|
import { useQueryClient as useQueryClient6 } from "@tanstack/react-query";
|
|
15943
16234
|
import {
|
|
@@ -15985,7 +16276,7 @@ import {
|
|
|
15985
16276
|
IntegrationNames as IntegrationNames16
|
|
15986
16277
|
} from "@livechat/developer-studio-api";
|
|
15987
16278
|
import { useMatch as useMatch2 } from "@livechat/developer-studio-ui-react";
|
|
15988
|
-
import { jsx as
|
|
16279
|
+
import { jsx as jsx13 } from "react/jsx-runtime";
|
|
15989
16280
|
function HubSpotAction(props) {
|
|
15990
16281
|
var _a;
|
|
15991
16282
|
const { login } = useContext16(AuthContext);
|
|
@@ -15994,7 +16285,7 @@ function HubSpotAction(props) {
|
|
|
15994
16285
|
if (!action) {
|
|
15995
16286
|
throw new Error("Invalid action");
|
|
15996
16287
|
}
|
|
15997
|
-
return /* @__PURE__ */
|
|
16288
|
+
return /* @__PURE__ */ jsx13(
|
|
15998
16289
|
IntegrationAction_default,
|
|
15999
16290
|
{
|
|
16000
16291
|
action,
|
|
@@ -16074,13 +16365,13 @@ function HubSpot() {
|
|
|
16074
16365
|
const credentialsQuery = useFetchHubspotCredentials();
|
|
16075
16366
|
const oauthCredential = credentialsQuery.data.internal;
|
|
16076
16367
|
const connected = (_a = credentialsQuery.data.internal) == null ? void 0 : _a.data.connected;
|
|
16077
|
-
const refetch =
|
|
16368
|
+
const refetch = useCallback11(() => {
|
|
16078
16369
|
credentialsQuery.refetch();
|
|
16079
16370
|
queryClient.invalidateQueries(
|
|
16080
16371
|
integrationCredentialsQueryKeys.getCredentials()
|
|
16081
16372
|
);
|
|
16082
16373
|
}, [credentialsQuery, queryClient]);
|
|
16083
|
-
const AuthorizeTrigger =
|
|
16374
|
+
const AuthorizeTrigger = useCallback11(
|
|
16084
16375
|
({ credential }) => /* @__PURE__ */ jsx7(
|
|
16085
16376
|
Action_default2,
|
|
16086
16377
|
{
|
|
@@ -16138,7 +16429,7 @@ function HubSpot() {
|
|
|
16138
16429
|
var HubSpot_default = HubSpot;
|
|
16139
16430
|
|
|
16140
16431
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Forms/Schema/integrations/Mailchimp/index.tsx
|
|
16141
|
-
import { useCallback as
|
|
16432
|
+
import { useCallback as useCallback12 } from "react";
|
|
16142
16433
|
import { Link as Link3, useLocation as useLocation3 } from "react-router-dom";
|
|
16143
16434
|
import { useQueryClient as useQueryClient7 } from "@tanstack/react-query";
|
|
16144
16435
|
import {
|
|
@@ -16186,7 +16477,7 @@ import {
|
|
|
16186
16477
|
IntegrationNames as IntegrationNames18
|
|
16187
16478
|
} from "@livechat/developer-studio-api";
|
|
16188
16479
|
import { useMatch as useMatch3 } from "@livechat/developer-studio-ui-react";
|
|
16189
|
-
import { jsx as
|
|
16480
|
+
import { jsx as jsx14 } from "react/jsx-runtime";
|
|
16190
16481
|
function MailchimpAction(props) {
|
|
16191
16482
|
var _a;
|
|
16192
16483
|
const { login } = useContext17(AuthContext);
|
|
@@ -16195,7 +16486,7 @@ function MailchimpAction(props) {
|
|
|
16195
16486
|
if (!action) {
|
|
16196
16487
|
throw new Error("Invalid action");
|
|
16197
16488
|
}
|
|
16198
|
-
return /* @__PURE__ */
|
|
16489
|
+
return /* @__PURE__ */ jsx14(
|
|
16199
16490
|
IntegrationAction_default,
|
|
16200
16491
|
{
|
|
16201
16492
|
action,
|
|
@@ -16275,13 +16566,13 @@ function Mailchimp() {
|
|
|
16275
16566
|
const credentialsQuery = useFetchMailchimpCredentials();
|
|
16276
16567
|
const oauthCredential = credentialsQuery.data.internal;
|
|
16277
16568
|
const connected = (_a = credentialsQuery.data.internal) == null ? void 0 : _a.data.connected;
|
|
16278
|
-
const refetch =
|
|
16569
|
+
const refetch = useCallback12(() => {
|
|
16279
16570
|
credentialsQuery.refetch();
|
|
16280
16571
|
queryClient.invalidateQueries(
|
|
16281
16572
|
integrationCredentialsQueryKeys.getCredentials()
|
|
16282
16573
|
);
|
|
16283
16574
|
}, [credentialsQuery, queryClient]);
|
|
16284
|
-
const AuthorizeTrigger =
|
|
16575
|
+
const AuthorizeTrigger = useCallback12(
|
|
16285
16576
|
({ credential }) => /* @__PURE__ */ jsx7(
|
|
16286
16577
|
Action_default3,
|
|
16287
16578
|
{
|
|
@@ -16541,7 +16832,7 @@ function OpenAI() {
|
|
|
16541
16832
|
var OpenAI_default = OpenAI;
|
|
16542
16833
|
|
|
16543
16834
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Forms/Schema/integrations/Shopify/index.tsx
|
|
16544
|
-
import { useCallback as
|
|
16835
|
+
import { useCallback as useCallback13, useContext as useContext19, useState as useState18 } from "react";
|
|
16545
16836
|
import { Link as Link4, useLocation as useLocation4 } from "react-router-dom";
|
|
16546
16837
|
import { useQueryClient as useQueryClient8 } from "@tanstack/react-query";
|
|
16547
16838
|
import { notificationConnect as notificationConnect2 } from "@livechat/design-system";
|
|
@@ -16591,7 +16882,7 @@ import {
|
|
|
16591
16882
|
IntegrationNames as IntegrationNames20
|
|
16592
16883
|
} from "@livechat/developer-studio-api";
|
|
16593
16884
|
import { useMatch as useMatch4 } from "@livechat/developer-studio-ui-react";
|
|
16594
|
-
import { jsx as
|
|
16885
|
+
import { jsx as jsx15 } from "react/jsx-runtime";
|
|
16595
16886
|
function ShopifyAction(props) {
|
|
16596
16887
|
var _a;
|
|
16597
16888
|
const { login } = useContext18(AuthContext);
|
|
@@ -16600,7 +16891,7 @@ function ShopifyAction(props) {
|
|
|
16600
16891
|
if (!action) {
|
|
16601
16892
|
throw new Error("Invalid action");
|
|
16602
16893
|
}
|
|
16603
|
-
return /* @__PURE__ */
|
|
16894
|
+
return /* @__PURE__ */ jsx15(
|
|
16604
16895
|
IntegrationAction_default,
|
|
16605
16896
|
{
|
|
16606
16897
|
action,
|
|
@@ -16710,7 +17001,7 @@ function Shopify() {
|
|
|
16710
17001
|
const { user } = useContext19(UserContext);
|
|
16711
17002
|
const { context: notifications } = useNotifications9();
|
|
16712
17003
|
const [state, setState] = useState18();
|
|
16713
|
-
const refetch =
|
|
17004
|
+
const refetch = useCallback13(() => {
|
|
16714
17005
|
credentialsQuery.refetch();
|
|
16715
17006
|
queryClient.invalidateQueries(
|
|
16716
17007
|
integrationCredentialsQueryKeys.getCredentials()
|
|
@@ -16718,7 +17009,7 @@ function Shopify() {
|
|
|
16718
17009
|
}, [credentialsQuery, queryClient]);
|
|
16719
17010
|
const oauthCredential = credentialsQuery.data.internal;
|
|
16720
17011
|
const connected = (_a = credentialsQuery.data.internal) == null ? void 0 : _a.data.connected;
|
|
16721
|
-
const triggerConnect =
|
|
17012
|
+
const triggerConnect = useCallback13(
|
|
16722
17013
|
(shop) => {
|
|
16723
17014
|
triggerShopifyAction(
|
|
16724
17015
|
{
|
|
@@ -16743,14 +17034,14 @@ function Shopify() {
|
|
|
16743
17034
|
},
|
|
16744
17035
|
[login, refetch, notifications, user, pathname]
|
|
16745
17036
|
);
|
|
16746
|
-
const toggleModal =
|
|
17037
|
+
const toggleModal = useCallback13((isVisible) => {
|
|
16747
17038
|
setState((prevState) => __spreadProps(__spreadValues({}, prevState), {
|
|
16748
17039
|
modal: {
|
|
16749
17040
|
isVisible
|
|
16750
17041
|
}
|
|
16751
17042
|
}));
|
|
16752
17043
|
}, []);
|
|
16753
|
-
const updateShop =
|
|
17044
|
+
const updateShop = useCallback13((shop) => {
|
|
16754
17045
|
setState(
|
|
16755
17046
|
(prevState) => {
|
|
16756
17047
|
var _a2;
|
|
@@ -16762,7 +17053,7 @@ function Shopify() {
|
|
|
16762
17053
|
}
|
|
16763
17054
|
);
|
|
16764
17055
|
}, []);
|
|
16765
|
-
const submit =
|
|
17056
|
+
const submit = useCallback13(() => {
|
|
16766
17057
|
var _a2;
|
|
16767
17058
|
setState(
|
|
16768
17059
|
(prevState) => {
|
|
@@ -16779,7 +17070,7 @@ function Shopify() {
|
|
|
16779
17070
|
triggerConnect(state.modal.shop);
|
|
16780
17071
|
}
|
|
16781
17072
|
}, [state == null ? void 0 : state.modal, toggleModal, triggerConnect]);
|
|
16782
|
-
const Connect =
|
|
17073
|
+
const Connect = useCallback13(
|
|
16783
17074
|
({ credential }) => {
|
|
16784
17075
|
if (!credential) {
|
|
16785
17076
|
return /* @__PURE__ */ jsx7(
|
|
@@ -17062,7 +17353,7 @@ function CustomSchemaFormWrapper({
|
|
|
17062
17353
|
const [selectedTab, setSelectedTab] = useState19(
|
|
17063
17354
|
preselectedTab != null ? preselectedTab : !spec || spec.specification.input ? "parameters" : spec && spec.customization.provider !== OTHER_TYPES.SYSTEM ? "connection" : void 0
|
|
17064
17355
|
);
|
|
17065
|
-
const tabItems =
|
|
17356
|
+
const tabItems = useMemo3(
|
|
17066
17357
|
() => [
|
|
17067
17358
|
!spec || spec.specification.input ? { id: "parameters", title: "Parameters" } : void 0,
|
|
17068
17359
|
spec && spec.customization.provider !== OTHER_TYPES.SYSTEM ? {
|
|
@@ -17223,7 +17514,7 @@ function HttpNodeForm({
|
|
|
17223
17514
|
var Form_default3 = HttpNodeForm;
|
|
17224
17515
|
|
|
17225
17516
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Diagram/Nodes/CustomNodes/HttpNode/Node.tsx
|
|
17226
|
-
import { memo as
|
|
17517
|
+
import { memo as memo4, useState as useState20 } from "react";
|
|
17227
17518
|
import { Position as Position5 } from "reactflow";
|
|
17228
17519
|
function HttpNode({
|
|
17229
17520
|
id,
|
|
@@ -17296,7 +17587,7 @@ function HttpNode({
|
|
|
17296
17587
|
}
|
|
17297
17588
|
);
|
|
17298
17589
|
}
|
|
17299
|
-
var Node_default2 =
|
|
17590
|
+
var Node_default2 = memo4(HttpNode);
|
|
17300
17591
|
|
|
17301
17592
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Diagram/Nodes/CustomNodes/SwitchNode/Base.tsx
|
|
17302
17593
|
import { Channels } from "@livechat/design-system-icons";
|
|
@@ -17408,7 +17699,7 @@ function SwitchNodeForm({
|
|
|
17408
17699
|
var Form_default4 = SwitchNodeForm;
|
|
17409
17700
|
|
|
17410
17701
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Diagram/Nodes/CustomNodes/SwitchNode/Node.tsx
|
|
17411
|
-
import { memo as
|
|
17702
|
+
import { memo as memo5, useEffect as useEffect10, useState as useState21 } from "react";
|
|
17412
17703
|
import { Handle as Handle3, Position as Position6 } from "reactflow";
|
|
17413
17704
|
import {
|
|
17414
17705
|
DesignToken as DesignToken20,
|
|
@@ -17437,7 +17728,7 @@ function SwitchNode({
|
|
|
17437
17728
|
const [isHovered, setIsHovered] = useState21(false);
|
|
17438
17729
|
const { nodes, updateTask, removeTask, goToAddTask } = useWorkflowContext();
|
|
17439
17730
|
const node2 = nodes.find((node3) => node3.id === id);
|
|
17440
|
-
|
|
17731
|
+
useEffect10(() => {
|
|
17441
17732
|
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
17442
17733
|
const sourceNode = nodes.find((node1) => node1.id === (node2 == null ? void 0 : node2.source));
|
|
17443
17734
|
if (sourceNode) {
|
|
@@ -17545,7 +17836,7 @@ function SwitchNode({
|
|
|
17545
17836
|
}
|
|
17546
17837
|
);
|
|
17547
17838
|
}
|
|
17548
|
-
var Node_default3 =
|
|
17839
|
+
var Node_default3 = memo5(SwitchNode);
|
|
17549
17840
|
|
|
17550
17841
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Diagram/Nodes/CustomNodes/TerminateNode/Base.tsx
|
|
17551
17842
|
import { ArrowBarToRight } from "@livechat/design-system-icons";
|
|
@@ -17556,7 +17847,7 @@ import {
|
|
|
17556
17847
|
SpacingToken as SpacingToken21
|
|
17557
17848
|
} from "@livechat/design-system-react-components";
|
|
17558
17849
|
import { Column as Column6 } from "@livechat/developer-studio-ui-react";
|
|
17559
|
-
import { jsx as
|
|
17850
|
+
import { jsx as jsx16, jsxs as jsxs5 } from "react/jsx-runtime";
|
|
17560
17851
|
var Node4 = newStyled.div`
|
|
17561
17852
|
background-color: ${({ editing }) => editing ? `var(${DesignToken21.SurfacePrimaryActive})` : `var(${DesignToken21.SurfacePrimaryDefault})`};
|
|
17562
17853
|
color: var(${DesignToken21.ContentBasicPrimary});
|
|
@@ -17607,9 +17898,9 @@ function TerminateNodeBase({
|
|
|
17607
17898
|
children: [
|
|
17608
17899
|
top,
|
|
17609
17900
|
toolbar,
|
|
17610
|
-
/* @__PURE__ */
|
|
17611
|
-
/* @__PURE__ */
|
|
17612
|
-
/* @__PURE__ */
|
|
17901
|
+
/* @__PURE__ */ jsx16(Header5, { children: /* @__PURE__ */ jsxs5(Title4, { children: [
|
|
17902
|
+
/* @__PURE__ */ jsx16(Icon20, { size: "large", source: ArrowBarToRight }),
|
|
17903
|
+
/* @__PURE__ */ jsx16(Column6, { notPadded: true, children: "END" })
|
|
17613
17904
|
] }) })
|
|
17614
17905
|
]
|
|
17615
17906
|
}
|
|
@@ -17642,7 +17933,7 @@ function TerminateNodeForm({
|
|
|
17642
17933
|
var Form_default5 = TerminateNodeForm;
|
|
17643
17934
|
|
|
17644
17935
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Diagram/Nodes/CustomNodes/TerminateNode/Node.tsx
|
|
17645
|
-
import { memo as
|
|
17936
|
+
import { memo as memo6, useState as useState22 } from "react";
|
|
17646
17937
|
import { Position as Position7 } from "reactflow";
|
|
17647
17938
|
function TerminateNode({
|
|
17648
17939
|
id,
|
|
@@ -17691,7 +17982,7 @@ function TerminateNode({
|
|
|
17691
17982
|
}
|
|
17692
17983
|
);
|
|
17693
17984
|
}
|
|
17694
|
-
var Node_default4 =
|
|
17985
|
+
var Node_default4 = memo6(TerminateNode);
|
|
17695
17986
|
|
|
17696
17987
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Diagram/Nodes/CustomNodes/TriggerNode/Base.tsx
|
|
17697
17988
|
import {
|
|
@@ -17928,7 +18219,7 @@ function TriggerNodeForm({
|
|
|
17928
18219
|
var Form_default6 = TriggerNodeForm;
|
|
17929
18220
|
|
|
17930
18221
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Diagram/Nodes/CustomNodes/TriggerNode/Node.tsx
|
|
17931
|
-
import { memo as
|
|
18222
|
+
import { memo as memo7, useState as useState24 } from "react";
|
|
17932
18223
|
import { Position as Position8 } from "reactflow";
|
|
17933
18224
|
function TriggerNode({
|
|
17934
18225
|
id,
|
|
@@ -17989,7 +18280,7 @@ function TriggerNode({
|
|
|
17989
18280
|
}
|
|
17990
18281
|
);
|
|
17991
18282
|
}
|
|
17992
|
-
var Node_default5 =
|
|
18283
|
+
var Node_default5 = memo7(TriggerNode);
|
|
17993
18284
|
|
|
17994
18285
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Diagram/Panels/Edit/Wrapper.tsx
|
|
17995
18286
|
import "react-js-cron/dist/styles.css";
|
|
@@ -18188,7 +18479,7 @@ var Wrapper_default2 = EditNodeWrapper;
|
|
|
18188
18479
|
var Edit_default = Wrapper_default2;
|
|
18189
18480
|
|
|
18190
18481
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Diagram/Diagram.tsx
|
|
18191
|
-
import { useCallback as
|
|
18482
|
+
import { useCallback as useCallback19, useEffect as useEffect18 } from "react";
|
|
18192
18483
|
import ReactFlow, {
|
|
18193
18484
|
addEdge,
|
|
18194
18485
|
Background as Background2,
|
|
@@ -18207,7 +18498,7 @@ import {
|
|
|
18207
18498
|
} from "@livechat/developer-studio-api";
|
|
18208
18499
|
|
|
18209
18500
|
// src/views/Flows/Definitions/Common/Modals/Preview.tsx
|
|
18210
|
-
import { useCallback as
|
|
18501
|
+
import { useCallback as useCallback14 } from "react";
|
|
18211
18502
|
import { useNavigate as useNavigate5 } from "react-router-dom";
|
|
18212
18503
|
import {
|
|
18213
18504
|
Button as Button14,
|
|
@@ -18266,7 +18557,7 @@ function WorkflowPreviewModal({
|
|
|
18266
18557
|
onClose
|
|
18267
18558
|
}) {
|
|
18268
18559
|
const navigate = useNavigate5();
|
|
18269
|
-
const handleClose =
|
|
18560
|
+
const handleClose = useCallback14(
|
|
18270
18561
|
(target) => {
|
|
18271
18562
|
if (onClose) {
|
|
18272
18563
|
onClose();
|
|
@@ -18280,7 +18571,7 @@ function WorkflowPreviewModal({
|
|
|
18280
18571
|
},
|
|
18281
18572
|
[onClose, navigate]
|
|
18282
18573
|
);
|
|
18283
|
-
const handleApply =
|
|
18574
|
+
const handleApply = useCallback14(() => {
|
|
18284
18575
|
if (onApply) {
|
|
18285
18576
|
onApply();
|
|
18286
18577
|
}
|
|
@@ -18337,7 +18628,7 @@ function WorkflowPreviewModalWrapper({
|
|
|
18337
18628
|
var Preview_default = WorkflowPreviewModalWrapper;
|
|
18338
18629
|
|
|
18339
18630
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Diagram/Nodes/CustomNodes/Add/Node/Node.tsx
|
|
18340
|
-
import { memo as
|
|
18631
|
+
import { memo as memo8 } from "react";
|
|
18341
18632
|
import { Handle as Handle4, Position as Position9 } from "reactflow";
|
|
18342
18633
|
import { Add as Add5 } from "@livechat/design-system-icons";
|
|
18343
18634
|
import { Button as Button15, Icon as Icon22 } from "@livechat/design-system-react-components";
|
|
@@ -18370,10 +18661,10 @@ function AddNode({ id }) {
|
|
|
18370
18661
|
/* @__PURE__ */ jsx7(Handle4, { isConnectable: false, position: Position9.Bottom, type: "source" })
|
|
18371
18662
|
] });
|
|
18372
18663
|
}
|
|
18373
|
-
var Node_default6 =
|
|
18664
|
+
var Node_default6 = memo8(AddNode);
|
|
18374
18665
|
|
|
18375
18666
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Diagram/Nodes/CustomNodes/Add/Trigger/Trigger.tsx
|
|
18376
|
-
import { memo as
|
|
18667
|
+
import { memo as memo9 } from "react";
|
|
18377
18668
|
import { Handle as Handle5, Position as Position10 } from "reactflow";
|
|
18378
18669
|
import { Add as Add6 } from "@livechat/design-system-icons";
|
|
18379
18670
|
import { Button as Button16, Icon as Icon23 } from "@livechat/design-system-react-components";
|
|
@@ -18396,7 +18687,7 @@ function AddTrigger({ id }) {
|
|
|
18396
18687
|
/* @__PURE__ */ jsx7(Handle5, { isConnectable: false, position: Position10.Bottom, type: "source" })
|
|
18397
18688
|
] });
|
|
18398
18689
|
}
|
|
18399
|
-
var Trigger_default =
|
|
18690
|
+
var Trigger_default = memo9(AddTrigger);
|
|
18400
18691
|
|
|
18401
18692
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Diagram/Nodes/CustomNodes/JoinNode/Base.tsx
|
|
18402
18693
|
import { DirectionsSignOff } from "@livechat/design-system-icons";
|
|
@@ -18461,7 +18752,7 @@ function JoinNodeBase({
|
|
|
18461
18752
|
var Base_default6 = JoinNodeBase;
|
|
18462
18753
|
|
|
18463
18754
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Diagram/Nodes/CustomNodes/JoinNode/Node.tsx
|
|
18464
|
-
import { memo as
|
|
18755
|
+
import { memo as memo10 } from "react";
|
|
18465
18756
|
import { Handle as Handle6, Position as Position11 } from "reactflow";
|
|
18466
18757
|
function JoinNode({
|
|
18467
18758
|
id,
|
|
@@ -18498,10 +18789,10 @@ function JoinNode({
|
|
|
18498
18789
|
}
|
|
18499
18790
|
) });
|
|
18500
18791
|
}
|
|
18501
|
-
var Node_default7 =
|
|
18792
|
+
var Node_default7 = memo10(JoinNode);
|
|
18502
18793
|
|
|
18503
18794
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Diagram/Controls/CustomControls.tsx
|
|
18504
|
-
import { useEffect as
|
|
18795
|
+
import { useEffect as useEffect17 } from "react";
|
|
18505
18796
|
import { useLocation as useLocation5 } from "react-router-dom";
|
|
18506
18797
|
import { ControlButton, Controls, useReactFlow as useReactFlow3 } from "reactflow";
|
|
18507
18798
|
import {
|
|
@@ -18649,7 +18940,7 @@ var StopGenerateButton = () => {
|
|
|
18649
18940
|
};
|
|
18650
18941
|
|
|
18651
18942
|
// src/views/Flows/Definitions/Common/One/widget/message-box/AskButton.tsx
|
|
18652
|
-
import { useEffect as
|
|
18943
|
+
import { useEffect as useEffect12, useState as useState27 } from "react";
|
|
18653
18944
|
import { useLexicalComposerContext as useLexicalComposerContext3 } from "@lexical/react/LexicalComposerContext";
|
|
18654
18945
|
import {
|
|
18655
18946
|
Button as Button18,
|
|
@@ -18658,7 +18949,7 @@ import {
|
|
|
18658
18949
|
} from "@livechat/design-system-react-components";
|
|
18659
18950
|
|
|
18660
18951
|
// src/views/Flows/Definitions/Common/One/hooks/use-above-character-limit.ts
|
|
18661
|
-
import { useEffect as
|
|
18952
|
+
import { useEffect as useEffect11, useState as useState25 } from "react";
|
|
18662
18953
|
import { useLexicalComposerContext } from "@lexical/react/LexicalComposerContext";
|
|
18663
18954
|
|
|
18664
18955
|
// src/views/Flows/Definitions/Common/One/widget/message-box/constants.ts
|
|
@@ -18668,7 +18959,7 @@ var ONE_CHARACTER_LIMIT = 1e4;
|
|
|
18668
18959
|
var useAboveCharacterLimit = () => {
|
|
18669
18960
|
const [editor] = useLexicalComposerContext();
|
|
18670
18961
|
const [aboveLimit, setAboveLimit] = useState25(0);
|
|
18671
|
-
|
|
18962
|
+
useEffect11(() => {
|
|
18672
18963
|
const registerTextContentListener = editor.registerTextContentListener(
|
|
18673
18964
|
(textContent) => {
|
|
18674
18965
|
setAboveLimit(textContent.length - ONE_CHARACTER_LIMIT);
|
|
@@ -18685,7 +18976,7 @@ var useAboveCharacterLimit = () => {
|
|
|
18685
18976
|
};
|
|
18686
18977
|
|
|
18687
18978
|
// src/views/Flows/Definitions/Common/One/hooks/use-send-one-message.ts
|
|
18688
|
-
import { useCallback as
|
|
18979
|
+
import { useCallback as useCallback15, useContext as useContext21 } from "react";
|
|
18689
18980
|
import { useLexicalComposerContext as useLexicalComposerContext2 } from "@lexical/react/LexicalComposerContext";
|
|
18690
18981
|
import { CLEAR_EDITOR_COMMAND } from "lexical";
|
|
18691
18982
|
|
|
@@ -18693,7 +18984,7 @@ import { CLEAR_EDITOR_COMMAND } from "lexical";
|
|
|
18693
18984
|
import {
|
|
18694
18985
|
createContext as createContext8,
|
|
18695
18986
|
useContext as useContext20,
|
|
18696
|
-
useMemo as
|
|
18987
|
+
useMemo as useMemo4,
|
|
18697
18988
|
useState as useState26
|
|
18698
18989
|
} from "react";
|
|
18699
18990
|
import { v4 as uuid } from "uuid";
|
|
@@ -18769,7 +19060,7 @@ var getSources = (sources) => {
|
|
|
18769
19060
|
};
|
|
18770
19061
|
|
|
18771
19062
|
// src/views/Flows/Definitions/Common/One/contexts/OneMessagesContext.tsx
|
|
18772
|
-
import { jsx as
|
|
19063
|
+
import { jsx as jsx17 } from "react/jsx-runtime";
|
|
18773
19064
|
var getInitialMessage = () => [
|
|
18774
19065
|
{
|
|
18775
19066
|
authorId: "live-assistant",
|
|
@@ -18847,7 +19138,7 @@ var OneMessagesProvider = ({
|
|
|
18847
19138
|
console.error(error);
|
|
18848
19139
|
}
|
|
18849
19140
|
});
|
|
18850
|
-
const eventsGroup =
|
|
19141
|
+
const eventsGroup = useMemo4(
|
|
18851
19142
|
() => createGroupedEvents({
|
|
18852
19143
|
events,
|
|
18853
19144
|
isLoading,
|
|
@@ -18856,7 +19147,7 @@ var OneMessagesProvider = ({
|
|
|
18856
19147
|
[events, isLoading, isError]
|
|
18857
19148
|
);
|
|
18858
19149
|
const hasAdditionalEvents = events.length !== eventsGroup.length;
|
|
18859
|
-
return /* @__PURE__ */
|
|
19150
|
+
return /* @__PURE__ */ jsx17(
|
|
18860
19151
|
OneMessagesContext.Provider,
|
|
18861
19152
|
{
|
|
18862
19153
|
value: {
|
|
@@ -18881,7 +19172,7 @@ var useOneMessagesContext = () => {
|
|
|
18881
19172
|
var useSendOneMessage = () => {
|
|
18882
19173
|
const [editor] = useLexicalComposerContext2();
|
|
18883
19174
|
const { sendMessage } = useContext21(OneMessagesContext);
|
|
18884
|
-
const onSend =
|
|
19175
|
+
const onSend = useCallback15(() => {
|
|
18885
19176
|
var _a;
|
|
18886
19177
|
const messageToSend = (_a = editor.getRootElement()) == null ? void 0 : _a.innerText.trim();
|
|
18887
19178
|
if (!messageToSend) {
|
|
@@ -18900,7 +19191,7 @@ var AskButton = () => {
|
|
|
18900
19191
|
const isLoading = false;
|
|
18901
19192
|
const { isAboveLimit } = useAboveCharacterLimit();
|
|
18902
19193
|
const handleSend = useSendOneMessage();
|
|
18903
|
-
|
|
19194
|
+
useEffect12(() => {
|
|
18904
19195
|
const registerTextContentListener = editor.registerTextContentListener(
|
|
18905
19196
|
(textContent) => {
|
|
18906
19197
|
setDisabled(!textContent);
|
|
@@ -18974,34 +19265,34 @@ import { HistoryPlugin } from "@lexical/react/LexicalHistoryPlugin";
|
|
|
18974
19265
|
import { PlainTextPlugin } from "@lexical/react/LexicalPlainTextPlugin";
|
|
18975
19266
|
|
|
18976
19267
|
// src/views/Flows/Definitions/Common/One/widget/message-box/custom-plugins/AutoFocusPlugin.tsx
|
|
18977
|
-
import { useCallback as
|
|
19268
|
+
import { useCallback as useCallback16, useEffect as useEffect13 } from "react";
|
|
18978
19269
|
import { useLexicalComposerContext as useLexicalComposerContext4 } from "@lexical/react/LexicalComposerContext";
|
|
18979
19270
|
var AutoFocusPlugin = () => {
|
|
18980
19271
|
const [editor] = useLexicalComposerContext4();
|
|
18981
|
-
const handleFocus =
|
|
19272
|
+
const handleFocus = useCallback16(() => {
|
|
18982
19273
|
editor.focus();
|
|
18983
19274
|
}, [editor]);
|
|
18984
|
-
|
|
19275
|
+
useEffect13(() => {
|
|
18985
19276
|
handleFocus();
|
|
18986
19277
|
}, []);
|
|
18987
19278
|
return null;
|
|
18988
19279
|
};
|
|
18989
19280
|
|
|
18990
19281
|
// src/views/Flows/Definitions/Common/One/widget/message-box/custom-plugins/EnterDownPlugin.tsx
|
|
18991
|
-
import { useCallback as
|
|
19282
|
+
import { useCallback as useCallback17, useEffect as useEffect14 } from "react";
|
|
18992
19283
|
import { useLexicalComposerContext as useLexicalComposerContext5 } from "@lexical/react/LexicalComposerContext";
|
|
18993
19284
|
import { COMMAND_PRIORITY_LOW, KEY_ENTER_COMMAND } from "lexical";
|
|
18994
19285
|
var EnterDownPlugin = ({ isCommandMenuVisibleRef }) => {
|
|
18995
19286
|
const [editor] = useLexicalComposerContext5();
|
|
18996
19287
|
const isLoading = false;
|
|
18997
19288
|
const handleSendMessage = useSendOneMessage();
|
|
18998
|
-
const onEnterDown =
|
|
19289
|
+
const onEnterDown = useCallback17(() => {
|
|
18999
19290
|
if (isLoading || (isCommandMenuVisibleRef == null ? void 0 : isCommandMenuVisibleRef.current)) {
|
|
19000
19291
|
return;
|
|
19001
19292
|
}
|
|
19002
19293
|
handleSendMessage({ enter: true, messageBox: true });
|
|
19003
19294
|
}, [handleSendMessage, isLoading, isCommandMenuVisibleRef]);
|
|
19004
|
-
|
|
19295
|
+
useEffect14(
|
|
19005
19296
|
() => editor.registerCommand(
|
|
19006
19297
|
KEY_ENTER_COMMAND,
|
|
19007
19298
|
(event) => {
|
|
@@ -19059,10 +19350,10 @@ var OneMessageBox = () => /* @__PURE__ */ jsx7("div", { css: popoverMessageBox,
|
|
|
19059
19350
|
] }) }) });
|
|
19060
19351
|
|
|
19061
19352
|
// src/views/Flows/Definitions/Common/One/widget/OneChatFeedContent.tsx
|
|
19062
|
-
import { useRef as
|
|
19353
|
+
import { useRef as useRef8 } from "react";
|
|
19063
19354
|
|
|
19064
19355
|
// src/views/Flows/Definitions/Common/One/hooks/use-scroll.ts
|
|
19065
|
-
import { useCallback as
|
|
19356
|
+
import { useCallback as useCallback18, useEffect as useEffect15, useRef as useRef7 } from "react";
|
|
19066
19357
|
import { debounce as debounce3 } from "lodash";
|
|
19067
19358
|
var useScroll = ({
|
|
19068
19359
|
oneChatFeedRef,
|
|
@@ -19070,10 +19361,10 @@ var useScroll = ({
|
|
|
19070
19361
|
additionalEvents
|
|
19071
19362
|
}) => {
|
|
19072
19363
|
const oneScrollPosition = 0;
|
|
19073
|
-
const currentScrollPosition =
|
|
19074
|
-
const isScrolledToBottom =
|
|
19075
|
-
const timeoutRef =
|
|
19076
|
-
const scrollToBottom =
|
|
19364
|
+
const currentScrollPosition = useRef7(null);
|
|
19365
|
+
const isScrolledToBottom = useRef7(true);
|
|
19366
|
+
const timeoutRef = useRef7(null);
|
|
19367
|
+
const scrollToBottom = useCallback18(() => {
|
|
19077
19368
|
if (timeoutRef.current) {
|
|
19078
19369
|
clearTimeout(timeoutRef.current);
|
|
19079
19370
|
}
|
|
@@ -19089,7 +19380,7 @@ var useScroll = ({
|
|
|
19089
19380
|
}
|
|
19090
19381
|
};
|
|
19091
19382
|
}, []);
|
|
19092
|
-
|
|
19383
|
+
useEffect15(() => {
|
|
19093
19384
|
var _a;
|
|
19094
19385
|
if (!oneScrollPosition) {
|
|
19095
19386
|
scrollToBottom();
|
|
@@ -19098,12 +19389,12 @@ var useScroll = ({
|
|
|
19098
19389
|
(_a = oneChatFeedRef.current) == null ? void 0 : _a.scrollTo({ top: oneScrollPosition });
|
|
19099
19390
|
currentScrollPosition.current = oneScrollPosition;
|
|
19100
19391
|
}, []);
|
|
19101
|
-
|
|
19392
|
+
useEffect15(() => {
|
|
19102
19393
|
if (additionalEvents && isScrolledToBottom.current) {
|
|
19103
19394
|
scrollToBottom();
|
|
19104
19395
|
}
|
|
19105
19396
|
}, [scrollToBottom, additionalEvents]);
|
|
19106
|
-
|
|
19397
|
+
useEffect15(() => {
|
|
19107
19398
|
const [lastGroupEvent] = groupedEvents.slice(-1)[0];
|
|
19108
19399
|
const isLastMessageFromAgent = lastGroupEvent.authorType === "agent" /* Agent */;
|
|
19109
19400
|
if (isLastMessageFromAgent || isScrolledToBottom.current) {
|
|
@@ -19672,7 +19963,7 @@ var OneErrorEvent = ({ eventId }) => {
|
|
|
19672
19963
|
};
|
|
19673
19964
|
|
|
19674
19965
|
// src/views/Flows/Definitions/Common/One/widget/events/OneImageEvent.tsx
|
|
19675
|
-
import { useEffect as
|
|
19966
|
+
import { useEffect as useEffect16, useState as useState28 } from "react";
|
|
19676
19967
|
|
|
19677
19968
|
// src/views/Flows/Definitions/Common/One/components/SkeletonLine.tsx
|
|
19678
19969
|
import { DesignToken as DesignToken30 } from "@livechat/design-system-react-components";
|
|
@@ -19734,7 +20025,7 @@ var SkeletonLine = ({
|
|
|
19734
20025
|
// src/views/Flows/Definitions/Common/One/widget/events/OneImageEvent.tsx
|
|
19735
20026
|
var OneImageEvent = ({ imageUrl }) => {
|
|
19736
20027
|
const [isLoaded, setIsLoaded] = useState28(false);
|
|
19737
|
-
|
|
20028
|
+
useEffect16(() => {
|
|
19738
20029
|
const image = new Image();
|
|
19739
20030
|
image.src = imageUrl;
|
|
19740
20031
|
image.onload = () => {
|
|
@@ -19759,7 +20050,7 @@ var OneImageEvent = ({ imageUrl }) => {
|
|
|
19759
20050
|
};
|
|
19760
20051
|
|
|
19761
20052
|
// src/views/Flows/Definitions/Common/One/components/TypingIndicator.tsx
|
|
19762
|
-
import { memo as
|
|
20053
|
+
import { memo as memo11 } from "react";
|
|
19763
20054
|
import { DesignToken as DesignToken31 } from "@livechat/design-system-react-components";
|
|
19764
20055
|
var typingAnimation = keyframes`
|
|
19765
20056
|
0% {
|
|
@@ -19800,7 +20091,7 @@ var typingIndicator2 = css`
|
|
|
19800
20091
|
}
|
|
19801
20092
|
}
|
|
19802
20093
|
`;
|
|
19803
|
-
var TypingIndicator =
|
|
20094
|
+
var TypingIndicator = memo11(() => /* @__PURE__ */ jsxs2("div", { css: typingIndicator2, "data-test": "typing-indicator", children: [
|
|
19804
20095
|
/* @__PURE__ */ jsx7("span", {}),
|
|
19805
20096
|
/* @__PURE__ */ jsx7("span", {}),
|
|
19806
20097
|
/* @__PURE__ */ jsx7("span", {})
|
|
@@ -20342,7 +20633,7 @@ function OneChatFeedContent({
|
|
|
20342
20633
|
updateWorkflow,
|
|
20343
20634
|
previewWorkflow
|
|
20344
20635
|
}) {
|
|
20345
|
-
const oneChatFeedRef =
|
|
20636
|
+
const oneChatFeedRef = useRef8(null);
|
|
20346
20637
|
const { groupedEvents, hasAdditionalEvents } = useOneMessagesContext();
|
|
20347
20638
|
const { handleScroll } = useScroll({
|
|
20348
20639
|
oneChatFeedRef,
|
|
@@ -20448,7 +20739,7 @@ function CustomControls({
|
|
|
20448
20739
|
state: { visibility }
|
|
20449
20740
|
} = useWorkflowContext();
|
|
20450
20741
|
const location = useLocation5();
|
|
20451
|
-
|
|
20742
|
+
useEffect17(() => {
|
|
20452
20743
|
var _a2;
|
|
20453
20744
|
if ((_a2 = location.state) == null ? void 0 : _a2.openOne) {
|
|
20454
20745
|
if (!isOpen) {
|
|
@@ -20567,7 +20858,7 @@ import { useState as useState31 } from "react";
|
|
|
20567
20858
|
import { useLocation as useLocation6, useNavigate as useNavigate7 } from "react-router-dom";
|
|
20568
20859
|
import { Controls as Controls2 } from "reactflow";
|
|
20569
20860
|
import { SegmentedControl } from "@livechat/design-system-react-components";
|
|
20570
|
-
import { Fragment as Fragment18, jsx as
|
|
20861
|
+
import { Fragment as Fragment18, jsx as jsx20 } from "react/jsx-runtime";
|
|
20571
20862
|
function SwitcherControls({
|
|
20572
20863
|
isDraft,
|
|
20573
20864
|
hasRelatedWorkflow,
|
|
@@ -20610,7 +20901,7 @@ function SwitcherControls({
|
|
|
20610
20901
|
}
|
|
20611
20902
|
};
|
|
20612
20903
|
if (!visibility.switcher || !isDraft && !hasRelatedWorkflow) {
|
|
20613
|
-
return /* @__PURE__ */
|
|
20904
|
+
return /* @__PURE__ */ jsx20(Fragment18, {});
|
|
20614
20905
|
}
|
|
20615
20906
|
const handleVersionClick = (id) => {
|
|
20616
20907
|
if (id === "draft" && isDraft) {
|
|
@@ -20625,14 +20916,14 @@ function SwitcherControls({
|
|
|
20625
20916
|
});
|
|
20626
20917
|
focus();
|
|
20627
20918
|
};
|
|
20628
|
-
return /* @__PURE__ */
|
|
20919
|
+
return /* @__PURE__ */ jsx20(
|
|
20629
20920
|
Controls2,
|
|
20630
20921
|
{
|
|
20631
20922
|
position: "top-center",
|
|
20632
20923
|
showFitView: false,
|
|
20633
20924
|
showInteractive: false,
|
|
20634
20925
|
showZoom: false,
|
|
20635
|
-
children: /* @__PURE__ */
|
|
20926
|
+
children: /* @__PURE__ */ jsx20(
|
|
20636
20927
|
SegmentedControl,
|
|
20637
20928
|
{
|
|
20638
20929
|
buttons: renderControlOptions(),
|
|
@@ -20709,7 +21000,7 @@ var Edges_default = CustomEdge_default;
|
|
|
20709
21000
|
|
|
20710
21001
|
// src/views/Flows/Definitions/Common/Builder/Editors/Visual/Diagram/Diagram.tsx
|
|
20711
21002
|
import "reactflow/dist/style.css";
|
|
20712
|
-
import { Fragment as Fragment20, jsx as
|
|
21003
|
+
import { Fragment as Fragment20, jsx as jsx21, jsxs as jsxs6 } from "react/jsx-runtime";
|
|
20713
21004
|
var nodeConfig = {
|
|
20714
21005
|
[WorkflowDefinitionTaskType14.http]: Node_default2,
|
|
20715
21006
|
[WorkflowDefinitionTaskType14.forkJoin]: Node_default,
|
|
@@ -20743,7 +21034,7 @@ function Diagram({
|
|
|
20743
21034
|
} = useWorkflowContext();
|
|
20744
21035
|
const [nodes, setNodes, onNodesChange] = useNodesState([]);
|
|
20745
21036
|
const [edges, setEdges, onEdgesChange] = useEdgesState([]);
|
|
20746
|
-
const onConnect =
|
|
21037
|
+
const onConnect = useCallback19(
|
|
20747
21038
|
(params) => {
|
|
20748
21039
|
setEdges((eds) => addEdge(params, eds));
|
|
20749
21040
|
},
|
|
@@ -20751,10 +21042,10 @@ function Diagram({
|
|
|
20751
21042
|
);
|
|
20752
21043
|
const onInit = (instance) => {
|
|
20753
21044
|
};
|
|
20754
|
-
|
|
21045
|
+
useEffect18(() => {
|
|
20755
21046
|
handleSetNodes(nodes);
|
|
20756
21047
|
}, [handleSetNodes, nodes]);
|
|
20757
|
-
|
|
21048
|
+
useEffect18(() => {
|
|
20758
21049
|
convertWorkflowDefinitionToReactflow(workflow).then(({ nodes: nodes2, edges: edges2 }) => {
|
|
20759
21050
|
const updatedNodes = nodes2.map((node2) => __spreadProps(__spreadValues({}, node2), {
|
|
20760
21051
|
position: __spreadProps(__spreadValues({}, node2.position), {
|
|
@@ -20767,10 +21058,10 @@ function Diagram({
|
|
|
20767
21058
|
if (forkNode.data.forkTasks.length > 2) {
|
|
20768
21059
|
const indexHelper = edge.id.split("-");
|
|
20769
21060
|
const pathIndex = indexHelper[indexHelper.length - 1];
|
|
20770
|
-
edge.data.label = /* @__PURE__ */
|
|
21061
|
+
edge.data.label = /* @__PURE__ */ jsx21(
|
|
20771
21062
|
Button24,
|
|
20772
21063
|
{
|
|
20773
|
-
icon: /* @__PURE__ */
|
|
21064
|
+
icon: /* @__PURE__ */ jsx21(Icon32, { source: Delete3 }),
|
|
20774
21065
|
kind: "plain",
|
|
20775
21066
|
onClick: () => {
|
|
20776
21067
|
forkNode.data.forkTasks.splice(pathIndex, 1);
|
|
@@ -20833,7 +21124,7 @@ function Diagram({
|
|
|
20833
21124
|
onNodesChange,
|
|
20834
21125
|
proOptions: { hideAttribution: true },
|
|
20835
21126
|
children: [
|
|
20836
|
-
/* @__PURE__ */
|
|
21127
|
+
/* @__PURE__ */ jsx21(
|
|
20837
21128
|
SwitcherControls,
|
|
20838
21129
|
{
|
|
20839
21130
|
hasRelatedWorkflow: Boolean(workflow.related_workflow_id),
|
|
@@ -20841,7 +21132,7 @@ function Diagram({
|
|
|
20841
21132
|
relatedWorkflowId: workflow.related_workflow_id
|
|
20842
21133
|
}
|
|
20843
21134
|
),
|
|
20844
|
-
/* @__PURE__ */
|
|
21135
|
+
/* @__PURE__ */ jsx21(
|
|
20845
21136
|
CustomControls_default,
|
|
20846
21137
|
{
|
|
20847
21138
|
isRawEditorVisible,
|
|
@@ -20857,7 +21148,7 @@ function Diagram({
|
|
|
20857
21148
|
}
|
|
20858
21149
|
}
|
|
20859
21150
|
),
|
|
20860
|
-
/* @__PURE__ */
|
|
21151
|
+
/* @__PURE__ */ jsx21(
|
|
20861
21152
|
Background2,
|
|
20862
21153
|
{
|
|
20863
21154
|
color: `var(${DesignToken34.SurfaceSecondaryActive})`,
|
|
@@ -20868,7 +21159,7 @@ function Diagram({
|
|
|
20868
21159
|
]
|
|
20869
21160
|
}
|
|
20870
21161
|
),
|
|
20871
|
-
previewModalVisible.isVisible ? /* @__PURE__ */
|
|
21162
|
+
previewModalVisible.isVisible ? /* @__PURE__ */ jsx21(
|
|
20872
21163
|
Preview_default,
|
|
20873
21164
|
{
|
|
20874
21165
|
onApply: () => {
|
|
@@ -20950,7 +21241,7 @@ function WorkflowBuilder() {
|
|
|
20950
21241
|
var Builder_default = WorkflowBuilder;
|
|
20951
21242
|
|
|
20952
21243
|
// src/views/Flows/Definitions/Common/Modals/Delete.tsx
|
|
20953
|
-
import { jsx as
|
|
21244
|
+
import { jsx as jsx22, jsxs as jsxs7 } from "react/jsx-runtime";
|
|
20954
21245
|
var ModalContent2 = newStyled.div`
|
|
20955
21246
|
display: grid;
|
|
20956
21247
|
align-items: center;
|
|
@@ -20989,8 +21280,8 @@ function WorkflowDeleteModal({
|
|
|
20989
21280
|
const amplitudeWorkflowsJourney = workflowsBlockAmplitudeJourneyFactory(
|
|
20990
21281
|
user.meta.email
|
|
20991
21282
|
);
|
|
20992
|
-
return /* @__PURE__ */
|
|
20993
|
-
/* @__PURE__ */
|
|
21283
|
+
return /* @__PURE__ */ jsx22(Modal4, { heading: true, onClose, children: /* @__PURE__ */ jsxs7(ModalContent2, { children: [
|
|
21284
|
+
/* @__PURE__ */ jsx22(
|
|
20994
21285
|
Icon33,
|
|
20995
21286
|
{
|
|
20996
21287
|
customColor: `var(${DesignToken36.ContentBasicDisabled})`,
|
|
@@ -21010,8 +21301,8 @@ function WorkflowDeleteModal({
|
|
|
21010
21301
|
". Are you sure you want to continue?"
|
|
21011
21302
|
] }),
|
|
21012
21303
|
/* @__PURE__ */ jsxs7(ModalFooter, { children: [
|
|
21013
|
-
/* @__PURE__ */
|
|
21014
|
-
/* @__PURE__ */
|
|
21304
|
+
/* @__PURE__ */ jsx22(Button25, { kind: "secondary", onClick: onClose, children: "Cancel" }),
|
|
21305
|
+
/* @__PURE__ */ jsx22(
|
|
21015
21306
|
Button25,
|
|
21016
21307
|
{
|
|
21017
21308
|
kind: "destructive",
|
|
@@ -21049,7 +21340,7 @@ import {
|
|
|
21049
21340
|
SpacingToken as SpacingToken33,
|
|
21050
21341
|
Text as Text19
|
|
21051
21342
|
} from "@livechat/design-system-react-components";
|
|
21052
|
-
import { jsx as
|
|
21343
|
+
import { jsx as jsx23, jsxs as jsxs8 } from "react/jsx-runtime";
|
|
21053
21344
|
var ModalContent3 = newStyled.div`
|
|
21054
21345
|
display: grid;
|
|
21055
21346
|
align-items: center;
|
|
@@ -21085,8 +21376,8 @@ function WorkflowEditModal({ onClose }) {
|
|
|
21085
21376
|
const amplitudeWorkflowsJourney = workflowsBlockAmplitudeJourneyFactory(
|
|
21086
21377
|
user.meta.email
|
|
21087
21378
|
);
|
|
21088
|
-
return /* @__PURE__ */
|
|
21089
|
-
/* @__PURE__ */
|
|
21379
|
+
return /* @__PURE__ */ jsx23(Modal5, { heading: true, onClose, children: /* @__PURE__ */ jsxs8(ModalContent3, { children: [
|
|
21380
|
+
/* @__PURE__ */ jsx23(
|
|
21090
21381
|
Icon34,
|
|
21091
21382
|
{
|
|
21092
21383
|
customColor: `var(${DesignToken37.ContentBasicDisabled})`,
|
|
@@ -21094,10 +21385,10 @@ function WorkflowEditModal({ onClose }) {
|
|
|
21094
21385
|
source: Error4
|
|
21095
21386
|
}
|
|
21096
21387
|
),
|
|
21097
|
-
/* @__PURE__ */
|
|
21098
|
-
/* @__PURE__ */
|
|
21388
|
+
/* @__PURE__ */ jsx23(Heading5, { as: "h2", size: "md", children: "You have an existing draft" }),
|
|
21389
|
+
/* @__PURE__ */ jsx23(Text19, { size: "md", children: "You already have an existing draft, by editing the published version you can overwrite the current draft for this workflow. Do you want to continue?" }),
|
|
21099
21390
|
/* @__PURE__ */ jsxs8(ModalFooter2, { children: [
|
|
21100
|
-
/* @__PURE__ */
|
|
21391
|
+
/* @__PURE__ */ jsx23(
|
|
21101
21392
|
Button26,
|
|
21102
21393
|
{
|
|
21103
21394
|
kind: "secondary",
|
|
@@ -21110,7 +21401,7 @@ function WorkflowEditModal({ onClose }) {
|
|
|
21110
21401
|
children: "Edit existing draft"
|
|
21111
21402
|
}
|
|
21112
21403
|
),
|
|
21113
|
-
/* @__PURE__ */
|
|
21404
|
+
/* @__PURE__ */ jsx23(
|
|
21114
21405
|
Button26,
|
|
21115
21406
|
{
|
|
21116
21407
|
kind: "destructive",
|
|
@@ -21138,7 +21429,7 @@ import {
|
|
|
21138
21429
|
SpacingToken as SpacingToken34,
|
|
21139
21430
|
Text as Text20
|
|
21140
21431
|
} from "@livechat/design-system-react-components";
|
|
21141
|
-
import { jsx as
|
|
21432
|
+
import { jsx as jsx24, jsxs as jsxs9 } from "react/jsx-runtime";
|
|
21142
21433
|
var ModalContent4 = newStyled.div`
|
|
21143
21434
|
display: grid;
|
|
21144
21435
|
align-items: center;
|
|
@@ -21170,8 +21461,8 @@ function WorkflowPublishModal({
|
|
|
21170
21461
|
},
|
|
21171
21462
|
publishDraft
|
|
21172
21463
|
} = useWorkflowContext();
|
|
21173
|
-
return /* @__PURE__ */
|
|
21174
|
-
/* @__PURE__ */
|
|
21464
|
+
return /* @__PURE__ */ jsx24(Modal6, { heading: true, onClose, children: /* @__PURE__ */ jsxs9(ModalContent4, { children: [
|
|
21465
|
+
/* @__PURE__ */ jsx24(
|
|
21175
21466
|
Icon35,
|
|
21176
21467
|
{
|
|
21177
21468
|
customColor: `var(${DesignToken38.ContentBasicDisabled})`,
|
|
@@ -21179,11 +21470,11 @@ function WorkflowPublishModal({
|
|
|
21179
21470
|
source: Error5
|
|
21180
21471
|
}
|
|
21181
21472
|
),
|
|
21182
|
-
/* @__PURE__ */
|
|
21183
|
-
/* @__PURE__ */
|
|
21473
|
+
/* @__PURE__ */ jsx24(Heading6, { as: "h2", size: "md", children: "You are publishing a workflow" }),
|
|
21474
|
+
/* @__PURE__ */ jsx24(Text20, { size: "md", children: "Once published, this will be the working version of your workflow and will\xA0be\xA0automatically set to active." }),
|
|
21184
21475
|
/* @__PURE__ */ jsxs9(ModalFooter3, { children: [
|
|
21185
|
-
/* @__PURE__ */
|
|
21186
|
-
/* @__PURE__ */
|
|
21476
|
+
/* @__PURE__ */ jsx24(Button27, { kind: "secondary", onClick: onClose, children: "Cancel" }),
|
|
21477
|
+
/* @__PURE__ */ jsx24(
|
|
21187
21478
|
Button27,
|
|
21188
21479
|
{
|
|
21189
21480
|
kind: "primary",
|
|
@@ -21199,7 +21490,7 @@ function WorkflowPublishModal({
|
|
|
21199
21490
|
}
|
|
21200
21491
|
|
|
21201
21492
|
// src/views/Flows/Definitions/Edit/Modals/Execute.tsx
|
|
21202
|
-
import { useCallback as
|
|
21493
|
+
import { useCallback as useCallback20 } from "react";
|
|
21203
21494
|
import { Field, Form } from "react-final-form";
|
|
21204
21495
|
import validator2 from "validator";
|
|
21205
21496
|
import {
|
|
@@ -21214,7 +21505,7 @@ import {
|
|
|
21214
21505
|
} from "@livechat/design-system-react-components";
|
|
21215
21506
|
function ExecuteWorkflow({ workflow, onClose }) {
|
|
21216
21507
|
const executeMutation = useExecuteWorkflow();
|
|
21217
|
-
const onSubmit =
|
|
21508
|
+
const onSubmit = useCallback20(
|
|
21218
21509
|
(data) => __async(this, null, function* () {
|
|
21219
21510
|
yield executeMutation.mutateAsync({
|
|
21220
21511
|
workflow,
|
|
@@ -21295,7 +21586,7 @@ function ExecuteWorkflow({ workflow, onClose }) {
|
|
|
21295
21586
|
var Execute_default = ExecuteWorkflow;
|
|
21296
21587
|
|
|
21297
21588
|
// src/views/Flows/Definitions/Edit/Tasks/Add.tsx
|
|
21298
|
-
import { useContext as useContext24, useEffect as
|
|
21589
|
+
import { useContext as useContext24, useEffect as useEffect19, useState as useState33 } from "react";
|
|
21299
21590
|
import {
|
|
21300
21591
|
NavLink,
|
|
21301
21592
|
useLocation as useLocation8,
|
|
@@ -21526,7 +21817,7 @@ function AddWorkflowTask({ basePath, onClose }) {
|
|
|
21526
21817
|
const amplitudeWorkflowsJourney = workflowsBlockAmplitudeJourneyFactory(
|
|
21527
21818
|
user.meta.email
|
|
21528
21819
|
);
|
|
21529
|
-
|
|
21820
|
+
useEffect19(() => {
|
|
21530
21821
|
var _a, _b, _c, _d, _e, _f;
|
|
21531
21822
|
if (!params.task) {
|
|
21532
21823
|
const firstTask = (_c = (_b = (_a = config10.find((el) => el.name === params.service)) == null ? void 0 : _a.values.sort((a, b) => a.name.localeCompare(b.name))) == null ? void 0 : _b[0]) == null ? void 0 : _c.key;
|
|
@@ -21748,7 +22039,7 @@ function AddWorkflowTask({ basePath, onClose }) {
|
|
|
21748
22039
|
var Add_default = AddWorkflowTask;
|
|
21749
22040
|
|
|
21750
22041
|
// src/views/Flows/Definitions/Edit/Triggers/Add.tsx
|
|
21751
|
-
import { useContext as useContext25, useEffect as
|
|
22042
|
+
import { useContext as useContext25, useEffect as useEffect20, useState as useState34 } from "react";
|
|
21752
22043
|
import { NavLink as NavLink2, useLocation as useLocation9, useNavigate as useNavigate11, useParams as useParams3 } from "react-router-dom";
|
|
21753
22044
|
import {
|
|
21754
22045
|
Button as Button30,
|
|
@@ -21944,7 +22235,7 @@ function AddWorkflowTrigger({ basePath, onClose }) {
|
|
|
21944
22235
|
const amplitudeWorkflowsJourney = workflowsBlockAmplitudeJourneyFactory(
|
|
21945
22236
|
user.meta.email
|
|
21946
22237
|
);
|
|
21947
|
-
|
|
22238
|
+
useEffect20(() => {
|
|
21948
22239
|
var _a, _b, _c;
|
|
21949
22240
|
if (!params.trigger) {
|
|
21950
22241
|
const firstTrigger = (_c = (_b = (_a = config11.find((el) => el.name === params.service)) == null ? void 0 : _a.values.sort((a, b) => a.name.localeCompare(b.name))) == null ? void 0 : _b[0]) == null ? void 0 : _c.key;
|
|
@@ -22130,7 +22421,7 @@ function AddWorkflowTrigger({ basePath, onClose }) {
|
|
|
22130
22421
|
var Add_default2 = AddWorkflowTrigger;
|
|
22131
22422
|
|
|
22132
22423
|
// src/views/Flows/Definitions/Common/Navbar/Navbar.tsx
|
|
22133
|
-
import { useContext as useContext26, useEffect as
|
|
22424
|
+
import { useContext as useContext26, useEffect as useEffect21, useRef as useRef9, useState as useState35 } from "react";
|
|
22134
22425
|
import { useNavigate as useNavigate12 } from "react-router-dom";
|
|
22135
22426
|
import { ArrowBarLeft, ChevronDown as ChevronDown3 } from "@livechat/design-system-icons";
|
|
22136
22427
|
import {
|
|
@@ -22164,7 +22455,7 @@ function WorkflowBuilderNavbar() {
|
|
|
22164
22455
|
publishDraft,
|
|
22165
22456
|
toggle
|
|
22166
22457
|
} = useWorkflowContext();
|
|
22167
|
-
const inputRef =
|
|
22458
|
+
const inputRef = useRef9(null);
|
|
22168
22459
|
const [isNameChanging, setIsNameChanging] = useState35(false);
|
|
22169
22460
|
const [workflowName, setWorkflowName] = useState35(workflow.name);
|
|
22170
22461
|
const { isMarketplaceFullscreenApp } = useMode();
|
|
@@ -22172,7 +22463,7 @@ function WorkflowBuilderNavbar() {
|
|
|
22172
22463
|
const amplitudeWorkflowsJourney = workflowsBlockAmplitudeJourneyFactory(
|
|
22173
22464
|
user.meta.email
|
|
22174
22465
|
);
|
|
22175
|
-
|
|
22466
|
+
useEffect21(() => {
|
|
22176
22467
|
setWorkflowName(workflow.name);
|
|
22177
22468
|
}, [workflow.name]);
|
|
22178
22469
|
useOnClickOutside2(inputRef, () => {
|
|
@@ -24122,7 +24413,7 @@ var flowTemplates = [
|
|
|
24122
24413
|
];
|
|
24123
24414
|
|
|
24124
24415
|
// src/views/Flows/Templates/Common/Modals/Preview/Modal.tsx
|
|
24125
|
-
import { useCallback as
|
|
24416
|
+
import { useCallback as useCallback21, useContext as useContext27 } from "react";
|
|
24126
24417
|
import { useNavigate as useNavigate14 } from "react-router-dom";
|
|
24127
24418
|
import { ArrowBackFilled } from "@livechat/design-system-icons";
|
|
24128
24419
|
import {
|
|
@@ -24247,7 +24538,7 @@ function WorkflowTemplatePreviewModal({
|
|
|
24247
24538
|
const amplitudeWorkflowsJourney = workflowsBlockAmplitudeJourneyFactory(
|
|
24248
24539
|
user.meta.email
|
|
24249
24540
|
);
|
|
24250
|
-
const handleClose =
|
|
24541
|
+
const handleClose = useCallback21(
|
|
24251
24542
|
(target) => {
|
|
24252
24543
|
if (onClose) {
|
|
24253
24544
|
onClose();
|
|
@@ -24427,7 +24718,7 @@ var Preview_default2 = WorkflowTemplatePreview;
|
|
|
24427
24718
|
import { Route as Route3, Routes as Routes3 } from "react-router-dom";
|
|
24428
24719
|
|
|
24429
24720
|
// src/views/Flows/Definitions/List/Modals/Create/Modal.tsx
|
|
24430
|
-
import { useCallback as
|
|
24721
|
+
import { useCallback as useCallback24 } from "react";
|
|
24431
24722
|
import { useNavigate as useNavigate17 } from "react-router-dom";
|
|
24432
24723
|
import { Modal as Modal11, ModalHeader as ModalHeader6 } from "@livechat/design-system-react-components";
|
|
24433
24724
|
|
|
@@ -24442,7 +24733,7 @@ import {
|
|
|
24442
24733
|
import { Column as Column16, Intro as Intro3, Row as Row21 } from "@livechat/developer-studio-ui-react";
|
|
24443
24734
|
|
|
24444
24735
|
// src/views/Flows/Templates/Common/Modals/List/Filters/Category.tsx
|
|
24445
|
-
import { useCallback as
|
|
24736
|
+
import { useCallback as useCallback22, useState as useState36 } from "react";
|
|
24446
24737
|
import {
|
|
24447
24738
|
ChatDots as ChatDots2,
|
|
24448
24739
|
CurrencyDollar as CurrencyDollar2,
|
|
@@ -24463,7 +24754,7 @@ function WorkflowTemplatesCategoryFilter({
|
|
|
24463
24754
|
status
|
|
24464
24755
|
}) {
|
|
24465
24756
|
const [isVisible, setIsVisible] = useState36(false);
|
|
24466
|
-
const getItem =
|
|
24757
|
+
const getItem = useCallback22(
|
|
24467
24758
|
(key, category, icon2) => ({
|
|
24468
24759
|
key,
|
|
24469
24760
|
element: /* @__PURE__ */ jsxs2(Row17, { gap: `var(${SpacingToken43.Spacing1});`, notPadded: true, children: [
|
|
@@ -24517,7 +24808,7 @@ function WorkflowTemplatesCategoryFilter({
|
|
|
24517
24808
|
var Category_default = WorkflowTemplatesCategoryFilter;
|
|
24518
24809
|
|
|
24519
24810
|
// src/views/Flows/Templates/Common/Modals/List/Filters/Product.tsx
|
|
24520
|
-
import { useCallback as
|
|
24811
|
+
import { useCallback as useCallback23, useState as useState37 } from "react";
|
|
24521
24812
|
import {
|
|
24522
24813
|
Chatgpt as Chatgpt2,
|
|
24523
24814
|
HelpDeskColored,
|
|
@@ -24538,7 +24829,7 @@ function WorkflowTemplatesProductFilter({
|
|
|
24538
24829
|
status
|
|
24539
24830
|
}) {
|
|
24540
24831
|
const [isVisible, setIsVisible] = useState37(false);
|
|
24541
|
-
const getItem =
|
|
24832
|
+
const getItem = useCallback23(
|
|
24542
24833
|
(key, product, icon2) => ({
|
|
24543
24834
|
key,
|
|
24544
24835
|
element: /* @__PURE__ */ jsxs2(Row18, { gap: `var(${SpacingToken44.Spacing1});`, notPadded: true, children: [
|
|
@@ -24807,7 +25098,7 @@ var Home_default = WorkflowsHome;
|
|
|
24807
25098
|
// src/views/Flows/Definitions/List/Modals/Create/Modal.tsx
|
|
24808
25099
|
function WorkflowCreateModal({ onClose }) {
|
|
24809
25100
|
const navigate = useNavigate17();
|
|
24810
|
-
const handleClose =
|
|
25101
|
+
const handleClose = useCallback24(() => {
|
|
24811
25102
|
if (onClose) {
|
|
24812
25103
|
onClose();
|
|
24813
25104
|
return;
|
|
@@ -24868,7 +25159,7 @@ import {
|
|
|
24868
25159
|
Button as Button35,
|
|
24869
25160
|
Icon as Icon43
|
|
24870
25161
|
} from "@livechat/design-system-react-components";
|
|
24871
|
-
import { jsx as
|
|
25162
|
+
import { jsx as jsx25, jsxs as jsxs10 } from "react/jsx-runtime";
|
|
24872
25163
|
function WorkflowStatusFilter({
|
|
24873
25164
|
handleStatus,
|
|
24874
25165
|
status
|
|
@@ -24900,7 +25191,7 @@ function WorkflowStatusFilter({
|
|
|
24900
25191
|
}
|
|
24901
25192
|
}
|
|
24902
25193
|
];
|
|
24903
|
-
return /* @__PURE__ */
|
|
25194
|
+
return /* @__PURE__ */ jsx25(
|
|
24904
25195
|
ActionMenu5,
|
|
24905
25196
|
{
|
|
24906
25197
|
onClose: () => {
|
|
@@ -24911,7 +25202,7 @@ function WorkflowStatusFilter({
|
|
|
24911
25202
|
triggerRenderer: /* @__PURE__ */ jsxs10(
|
|
24912
25203
|
Button35,
|
|
24913
25204
|
{
|
|
24914
|
-
icon: /* @__PURE__ */
|
|
25205
|
+
icon: /* @__PURE__ */ jsx25(Icon43, { source: ToggleLeft }),
|
|
24915
25206
|
kind: "secondary",
|
|
24916
25207
|
onClick: () => {
|
|
24917
25208
|
setIsVisible(!isVisible);
|
|
@@ -25323,11 +25614,11 @@ function WorkflowList() {
|
|
|
25323
25614
|
var List_default2 = WorkflowList;
|
|
25324
25615
|
|
|
25325
25616
|
// src/views/Flows/Definitions/index.tsx
|
|
25326
|
-
import { jsx as
|
|
25617
|
+
import { jsx as jsx26, jsxs as jsxs11 } from "react/jsx-runtime";
|
|
25327
25618
|
function Workflows() {
|
|
25328
25619
|
const navigate = useNavigate20();
|
|
25329
25620
|
const { isUserFetching, userHasAccessToWorkflows } = useContext30(UserContext);
|
|
25330
|
-
|
|
25621
|
+
useEffect22(() => {
|
|
25331
25622
|
if (isUserFetching) {
|
|
25332
25623
|
return;
|
|
25333
25624
|
}
|
|
@@ -25336,15 +25627,15 @@ function Workflows() {
|
|
|
25336
25627
|
}
|
|
25337
25628
|
}, [navigate, isUserFetching, userHasAccessToWorkflows]);
|
|
25338
25629
|
return /* @__PURE__ */ jsxs11(Routes5, { children: [
|
|
25339
|
-
/* @__PURE__ */
|
|
25340
|
-
/* @__PURE__ */
|
|
25341
|
-
/* @__PURE__ */
|
|
25630
|
+
/* @__PURE__ */ jsx26(Route5, { element: /* @__PURE__ */ jsx26(Navigate2, { replace: true, to: "list" }), path: "" }),
|
|
25631
|
+
/* @__PURE__ */ jsx26(Route5, { element: /* @__PURE__ */ jsx26(List_default2, {}), path: "list/*" }),
|
|
25632
|
+
/* @__PURE__ */ jsx26(Route5, { element: /* @__PURE__ */ jsx26(Edit_default2, {}), path: ":id/*" })
|
|
25342
25633
|
] });
|
|
25343
25634
|
}
|
|
25344
25635
|
var Definitions_default = Workflows;
|
|
25345
25636
|
|
|
25346
25637
|
// src/views/Flows/Waitlist/index.tsx
|
|
25347
|
-
import { useContext as useContext31, useEffect as
|
|
25638
|
+
import { useContext as useContext31, useEffect as useEffect23 } from "react";
|
|
25348
25639
|
import { useNavigate as useNavigate21 } from "react-router-dom";
|
|
25349
25640
|
import { CheckCircle as CheckCircle8 } from "@livechat/design-system-icons";
|
|
25350
25641
|
import {
|
|
@@ -25384,7 +25675,7 @@ var imgContainerCss = css`
|
|
|
25384
25675
|
function Waitlist() {
|
|
25385
25676
|
const { isUserFetching, userHasAccessToWorkflows } = useContext31(UserContext);
|
|
25386
25677
|
const navigate = useNavigate21();
|
|
25387
|
-
|
|
25678
|
+
useEffect23(() => {
|
|
25388
25679
|
if (userHasAccessToWorkflows) {
|
|
25389
25680
|
navigate("/workflow/list");
|
|
25390
25681
|
}
|
|
@@ -25468,11 +25759,11 @@ function Waitlist() {
|
|
|
25468
25759
|
var Waitlist_default = Waitlist;
|
|
25469
25760
|
|
|
25470
25761
|
// src/views/Flows/index.tsx
|
|
25471
|
-
import { jsx as
|
|
25762
|
+
import { jsx as jsx27, jsxs as jsxs12 } from "react/jsx-runtime";
|
|
25472
25763
|
function Flows() {
|
|
25473
25764
|
return /* @__PURE__ */ jsxs12(Routes6, { children: [
|
|
25474
|
-
/* @__PURE__ */
|
|
25475
|
-
/* @__PURE__ */
|
|
25765
|
+
/* @__PURE__ */ jsx27(Route6, { element: /* @__PURE__ */ jsx27(Definitions_default, {}), path: "*" }),
|
|
25766
|
+
/* @__PURE__ */ jsx27(Route6, { element: /* @__PURE__ */ jsx27(Waitlist_default, {}), path: "/waitlist" })
|
|
25476
25767
|
] });
|
|
25477
25768
|
}
|
|
25478
25769
|
var Flows_default = Flows;
|
|
@@ -25492,7 +25783,7 @@ import {
|
|
|
25492
25783
|
IntegrationNames as IntegrationNames31
|
|
25493
25784
|
} from "@livechat/developer-studio-api";
|
|
25494
25785
|
import { useMatch as useMatch5 } from "@livechat/developer-studio-ui-react";
|
|
25495
|
-
import { jsx as
|
|
25786
|
+
import { jsx as jsx28 } from "react/jsx-runtime";
|
|
25496
25787
|
function AccountsAction(props) {
|
|
25497
25788
|
var _a;
|
|
25498
25789
|
const match2 = useMatch5();
|
|
@@ -25500,7 +25791,7 @@ function AccountsAction(props) {
|
|
|
25500
25791
|
if (!action) {
|
|
25501
25792
|
throw new Error("Invalid action");
|
|
25502
25793
|
}
|
|
25503
|
-
return /* @__PURE__ */
|
|
25794
|
+
return /* @__PURE__ */ jsx28(
|
|
25504
25795
|
IntegrationAction_default,
|
|
25505
25796
|
{
|
|
25506
25797
|
action,
|
|
@@ -25543,14 +25834,14 @@ var Action_default5 = AccountsAction;
|
|
|
25543
25834
|
|
|
25544
25835
|
// src/views/Settings/Integrations/Accounts/Callback.tsx
|
|
25545
25836
|
import { useMatch as useMatch6 } from "@livechat/developer-studio-ui-react";
|
|
25546
|
-
import { jsx as
|
|
25837
|
+
import { jsx as jsx29 } from "react/jsx-runtime";
|
|
25547
25838
|
function AccountsCallback() {
|
|
25548
25839
|
const match2 = useMatch6();
|
|
25549
25840
|
const action = match2.params.action;
|
|
25550
25841
|
if (!action) {
|
|
25551
25842
|
throw new Error("Invalid action");
|
|
25552
25843
|
}
|
|
25553
|
-
return /* @__PURE__ */
|
|
25844
|
+
return /* @__PURE__ */ jsx29(
|
|
25554
25845
|
IntegrationCallback_default,
|
|
25555
25846
|
{
|
|
25556
25847
|
handler: (output) => accountsActionHandlers()[action](output)
|
|
@@ -25562,7 +25853,7 @@ var Callback_default = AccountsCallback;
|
|
|
25562
25853
|
// src/views/Settings/Integrations/BigCommerce/Callback.tsx
|
|
25563
25854
|
import { useContext as useContext32 } from "react";
|
|
25564
25855
|
import { useMatch as useMatch7 } from "@livechat/developer-studio-ui-react";
|
|
25565
|
-
import { jsx as
|
|
25856
|
+
import { jsx as jsx30 } from "react/jsx-runtime";
|
|
25566
25857
|
function BigCommerceCallback() {
|
|
25567
25858
|
const { login } = useContext32(AuthContext);
|
|
25568
25859
|
const match2 = useMatch7();
|
|
@@ -25570,7 +25861,7 @@ function BigCommerceCallback() {
|
|
|
25570
25861
|
if (!action) {
|
|
25571
25862
|
throw new Error("Invalid action");
|
|
25572
25863
|
}
|
|
25573
|
-
return /* @__PURE__ */
|
|
25864
|
+
return /* @__PURE__ */ jsx30(
|
|
25574
25865
|
IntegrationCallback_default,
|
|
25575
25866
|
{
|
|
25576
25867
|
handler: (output) => bigCommerceActionHandlers(login)[action](output)
|
|
@@ -25580,7 +25871,7 @@ function BigCommerceCallback() {
|
|
|
25580
25871
|
var Callback_default2 = BigCommerceCallback;
|
|
25581
25872
|
|
|
25582
25873
|
// src/views/Settings/Integrations/BigCommerce/Status.tsx
|
|
25583
|
-
import { useCallback as
|
|
25874
|
+
import { useCallback as useCallback26, useContext as useContext33, useState as useState41 } from "react";
|
|
25584
25875
|
import { BigCommerceColored as BigCommerceColored2, Delete as Delete6 } from "@livechat/design-system-icons";
|
|
25585
25876
|
import {
|
|
25586
25877
|
Button as Button40,
|
|
@@ -25596,7 +25887,7 @@ import {
|
|
|
25596
25887
|
import { useNotifications as useNotifications12 } from "@livechat/developer-studio-ui-react";
|
|
25597
25888
|
|
|
25598
25889
|
// src/views/Settings/Integrations/Common/IntegrationCredentials.tsx
|
|
25599
|
-
import { useCallback as
|
|
25890
|
+
import { useCallback as useCallback25 } from "react";
|
|
25600
25891
|
import { Delete as Delete5 } from "@livechat/design-system-icons";
|
|
25601
25892
|
import { Button as Button39, Icon as Icon46 } from "@livechat/design-system-react-components";
|
|
25602
25893
|
import { Table as Table2 } from "@livechat/developer-studio-ui-react";
|
|
@@ -25605,7 +25896,7 @@ function IntegrationStatusCredentials({
|
|
|
25605
25896
|
trigger
|
|
25606
25897
|
}) {
|
|
25607
25898
|
const removeCredentialMutation = useRemoveIntegrationCredential();
|
|
25608
|
-
const Credential =
|
|
25899
|
+
const Credential = useCallback25(
|
|
25609
25900
|
({ credential }) => /* @__PURE__ */ jsxs2("tr", { children: [
|
|
25610
25901
|
/* @__PURE__ */ jsx7("td", { children: credential.name }),
|
|
25611
25902
|
/* @__PURE__ */ jsx7("td", { children: credential.type }),
|
|
@@ -25776,12 +26067,12 @@ function BigCommerceStatus() {
|
|
|
25776
26067
|
const credentialsQuery = useFetchBigCommerceCredentials();
|
|
25777
26068
|
const removeCredentialMutation = useRemoveIntegrationCredential();
|
|
25778
26069
|
const [state, setState] = useState41();
|
|
25779
|
-
const refetch =
|
|
26070
|
+
const refetch = useCallback26(() => {
|
|
25780
26071
|
credentialsQuery.refetch();
|
|
25781
26072
|
}, [credentialsQuery]);
|
|
25782
26073
|
const oauthCredential = credentialsQuery.data.internal;
|
|
25783
26074
|
const otherCredentials = credentialsQuery.data.other;
|
|
25784
|
-
const triggerConnect =
|
|
26075
|
+
const triggerConnect = useCallback26(
|
|
25785
26076
|
(shop) => {
|
|
25786
26077
|
triggerBigCommerceAction(
|
|
25787
26078
|
{
|
|
@@ -25806,14 +26097,14 @@ function BigCommerceStatus() {
|
|
|
25806
26097
|
},
|
|
25807
26098
|
[login, refetch, notifications, user]
|
|
25808
26099
|
);
|
|
25809
|
-
const toggleModal =
|
|
26100
|
+
const toggleModal = useCallback26((isVisible) => {
|
|
25810
26101
|
setState((prevState) => __spreadProps(__spreadValues({}, prevState), {
|
|
25811
26102
|
modal: {
|
|
25812
26103
|
isVisible
|
|
25813
26104
|
}
|
|
25814
26105
|
}));
|
|
25815
26106
|
}, []);
|
|
25816
|
-
const updateShop =
|
|
26107
|
+
const updateShop = useCallback26((shop) => {
|
|
25817
26108
|
setState(
|
|
25818
26109
|
(prevState) => {
|
|
25819
26110
|
var _a2;
|
|
@@ -25825,7 +26116,7 @@ function BigCommerceStatus() {
|
|
|
25825
26116
|
}
|
|
25826
26117
|
);
|
|
25827
26118
|
}, []);
|
|
25828
|
-
const submit =
|
|
26119
|
+
const submit = useCallback26(() => {
|
|
25829
26120
|
var _a2;
|
|
25830
26121
|
setState(
|
|
25831
26122
|
(prevState) => {
|
|
@@ -25842,7 +26133,7 @@ function BigCommerceStatus() {
|
|
|
25842
26133
|
triggerConnect(state.modal.shop);
|
|
25843
26134
|
}
|
|
25844
26135
|
}, [state == null ? void 0 : state.modal, toggleModal, triggerConnect]);
|
|
25845
|
-
const Connect =
|
|
26136
|
+
const Connect = useCallback26(
|
|
25846
26137
|
({ credential }) => {
|
|
25847
26138
|
if (!credential) {
|
|
25848
26139
|
return /* @__PURE__ */ jsx7(
|
|
@@ -26105,7 +26396,7 @@ var appRepositoryBlockAmplitudeJourneyFactory = (email) => ({
|
|
|
26105
26396
|
});
|
|
26106
26397
|
|
|
26107
26398
|
// src/views/Settings/Integrations/GitHub/Action.tsx
|
|
26108
|
-
import { jsx as
|
|
26399
|
+
import { jsx as jsx31 } from "react/jsx-runtime";
|
|
26109
26400
|
function GitHubAction(props) {
|
|
26110
26401
|
var _a;
|
|
26111
26402
|
const { login } = useContext34(AuthContext);
|
|
@@ -26115,7 +26406,7 @@ function GitHubAction(props) {
|
|
|
26115
26406
|
if (!action) {
|
|
26116
26407
|
throw new Error("Invalid action");
|
|
26117
26408
|
}
|
|
26118
|
-
return /* @__PURE__ */
|
|
26409
|
+
return /* @__PURE__ */ jsx31(
|
|
26119
26410
|
IntegrationAction_default,
|
|
26120
26411
|
{
|
|
26121
26412
|
action,
|
|
@@ -26186,7 +26477,7 @@ var Action_default6 = GitHubAction;
|
|
|
26186
26477
|
// src/views/Settings/Integrations/GitHub/Callback.tsx
|
|
26187
26478
|
import { useContext as useContext35 } from "react";
|
|
26188
26479
|
import { useMatch as useMatch9 } from "@livechat/developer-studio-ui-react";
|
|
26189
|
-
import { jsx as
|
|
26480
|
+
import { jsx as jsx32 } from "react/jsx-runtime";
|
|
26190
26481
|
function GithubCallback() {
|
|
26191
26482
|
const { login } = useContext35(AuthContext);
|
|
26192
26483
|
const match2 = useMatch9();
|
|
@@ -26195,7 +26486,7 @@ function GithubCallback() {
|
|
|
26195
26486
|
if (!action) {
|
|
26196
26487
|
throw new Error("Invalid action");
|
|
26197
26488
|
}
|
|
26198
|
-
return /* @__PURE__ */
|
|
26489
|
+
return /* @__PURE__ */ jsx32(
|
|
26199
26490
|
IntegrationCallback_default,
|
|
26200
26491
|
{
|
|
26201
26492
|
handler: (output) => gitHubActionHandlers(login, user.meta.email)[action](
|
|
@@ -26207,7 +26498,7 @@ function GithubCallback() {
|
|
|
26207
26498
|
var Callback_default3 = GithubCallback;
|
|
26208
26499
|
|
|
26209
26500
|
// src/views/Settings/Integrations/GitHub/Status.tsx
|
|
26210
|
-
import { useCallback as
|
|
26501
|
+
import { useCallback as useCallback27, useContext as useContext38, useEffect as useEffect25, useState as useState43 } from "react";
|
|
26211
26502
|
import { ChevronDown as ChevronDown4, ChevronUp as ChevronUp2, Delete as Delete7 } from "@livechat/design-system-icons";
|
|
26212
26503
|
import {
|
|
26213
26504
|
ActionMenu as ActionMenu7,
|
|
@@ -26288,10 +26579,10 @@ import {
|
|
|
26288
26579
|
} from "@livechat/developer-studio-api";
|
|
26289
26580
|
|
|
26290
26581
|
// src/hooks/integrations/pusher/usePusher.ts
|
|
26291
|
-
import { useEffect as
|
|
26582
|
+
import { useEffect as useEffect24, useMemo as useMemo5, useState as useState42 } from "react";
|
|
26292
26583
|
import Pusher from "pusher-js";
|
|
26293
26584
|
function usePusher() {
|
|
26294
|
-
const pusher =
|
|
26585
|
+
const pusher = useMemo5(
|
|
26295
26586
|
() => new Pusher(getWorkflowEnv("pusherKey"), {
|
|
26296
26587
|
cluster: "eu"
|
|
26297
26588
|
}),
|
|
@@ -26302,7 +26593,7 @@ function usePusher() {
|
|
|
26302
26593
|
function usePusherChannel(channelId) {
|
|
26303
26594
|
const pusher = usePusher();
|
|
26304
26595
|
const [channel, setChannel] = useState42();
|
|
26305
|
-
|
|
26596
|
+
useEffect24(() => {
|
|
26306
26597
|
setChannel(pusher.subscribe(channelId));
|
|
26307
26598
|
return () => {
|
|
26308
26599
|
pusher.unsubscribe(channelId);
|
|
@@ -26312,7 +26603,7 @@ function usePusherChannel(channelId) {
|
|
|
26312
26603
|
}
|
|
26313
26604
|
function usePusherSubscription(channelId, eventId, callback, deps) {
|
|
26314
26605
|
const pusherChannel = usePusherChannel(channelId);
|
|
26315
|
-
|
|
26606
|
+
useEffect24(() => {
|
|
26316
26607
|
if (pusherChannel) {
|
|
26317
26608
|
pusherChannel.bind(eventId, callback);
|
|
26318
26609
|
}
|
|
@@ -26331,7 +26622,7 @@ function GitHubStatus() {
|
|
|
26331
26622
|
const amplitudeRepositoryJourney = appRepositoryBlockAmplitudeJourneyFactory(
|
|
26332
26623
|
user.meta.email
|
|
26333
26624
|
);
|
|
26334
|
-
const refetch =
|
|
26625
|
+
const refetch = useCallback27(() => {
|
|
26335
26626
|
credentialsQuery.refetch();
|
|
26336
26627
|
gitHubInstallationsQuery.refetch();
|
|
26337
26628
|
}, [credentialsQuery, gitHubInstallationsQuery]);
|
|
@@ -26339,7 +26630,7 @@ function GitHubStatus() {
|
|
|
26339
26630
|
const oauthCredential = credentialsQuery.data.internal.oauth;
|
|
26340
26631
|
const otherCredentials = credentialsQuery.data.other;
|
|
26341
26632
|
const isInstalled = ((_a = gitHubInstallationsQuery.data) != null ? _a : []).length > 0;
|
|
26342
|
-
|
|
26633
|
+
useEffect25(() => {
|
|
26343
26634
|
if (credentialsQuery.isFetching) {
|
|
26344
26635
|
return;
|
|
26345
26636
|
}
|
|
@@ -26384,7 +26675,7 @@ function GitHubStatus() {
|
|
|
26384
26675
|
},
|
|
26385
26676
|
[gitHubInstallationsQuery.data]
|
|
26386
26677
|
);
|
|
26387
|
-
const Connect =
|
|
26678
|
+
const Connect = useCallback27(
|
|
26388
26679
|
({ credential }) => /* @__PURE__ */ jsx7(
|
|
26389
26680
|
Action_default6,
|
|
26390
26681
|
{
|
|
@@ -26423,7 +26714,7 @@ function GitHubStatus() {
|
|
|
26423
26714
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
26424
26715
|
[refetch]
|
|
26425
26716
|
);
|
|
26426
|
-
const Install =
|
|
26717
|
+
const Install = useCallback27(
|
|
26427
26718
|
() => /* @__PURE__ */ jsx7(
|
|
26428
26719
|
Action_default6,
|
|
26429
26720
|
{
|
|
@@ -26579,7 +26870,7 @@ var Status_default2 = GitHubStatus;
|
|
|
26579
26870
|
// src/views/Settings/Integrations/HubSpot/Callback.tsx
|
|
26580
26871
|
import { useContext as useContext39 } from "react";
|
|
26581
26872
|
import { useMatch as useMatch10 } from "@livechat/developer-studio-ui-react";
|
|
26582
|
-
import { jsx as
|
|
26873
|
+
import { jsx as jsx33 } from "react/jsx-runtime";
|
|
26583
26874
|
function HubSpotCallback() {
|
|
26584
26875
|
const { login } = useContext39(AuthContext);
|
|
26585
26876
|
const match2 = useMatch10();
|
|
@@ -26587,7 +26878,7 @@ function HubSpotCallback() {
|
|
|
26587
26878
|
if (!action) {
|
|
26588
26879
|
throw new Error("Invalid action");
|
|
26589
26880
|
}
|
|
26590
|
-
return /* @__PURE__ */
|
|
26881
|
+
return /* @__PURE__ */ jsx33(
|
|
26591
26882
|
IntegrationCallback_default,
|
|
26592
26883
|
{
|
|
26593
26884
|
handler: (output) => hubSpotActionHandlers(login)[action](output)
|
|
@@ -26597,7 +26888,7 @@ function HubSpotCallback() {
|
|
|
26597
26888
|
var Callback_default4 = HubSpotCallback;
|
|
26598
26889
|
|
|
26599
26890
|
// src/views/Settings/Integrations/HubSpot/Status.tsx
|
|
26600
|
-
import { useCallback as
|
|
26891
|
+
import { useCallback as useCallback28 } from "react";
|
|
26601
26892
|
import { Delete as Delete8, Hubspot } from "@livechat/design-system-icons";
|
|
26602
26893
|
import { Button as Button42, Icon as Icon49 } from "@livechat/design-system-react-components";
|
|
26603
26894
|
import {
|
|
@@ -26606,12 +26897,12 @@ import {
|
|
|
26606
26897
|
function HubspotStatus() {
|
|
26607
26898
|
const credentialsQuery = useFetchHubspotCredentials();
|
|
26608
26899
|
const removeCredentialMutation = useRemoveIntegrationCredential();
|
|
26609
|
-
const refetch =
|
|
26900
|
+
const refetch = useCallback28(() => {
|
|
26610
26901
|
credentialsQuery.refetch();
|
|
26611
26902
|
}, [credentialsQuery]);
|
|
26612
26903
|
const oauthCredential = credentialsQuery.data.internal;
|
|
26613
26904
|
const otherCredentials = credentialsQuery.data.other;
|
|
26614
|
-
const Connect =
|
|
26905
|
+
const Connect = useCallback28(
|
|
26615
26906
|
({ credential }) => /* @__PURE__ */ jsx7(
|
|
26616
26907
|
Action_default2,
|
|
26617
26908
|
{
|
|
@@ -26691,7 +26982,7 @@ var Status_default3 = HubspotStatus;
|
|
|
26691
26982
|
// src/views/Settings/Integrations/Mailchimp/Callback.tsx
|
|
26692
26983
|
import { useContext as useContext40 } from "react";
|
|
26693
26984
|
import { useMatch as useMatch11 } from "@livechat/developer-studio-ui-react";
|
|
26694
|
-
import { jsx as
|
|
26985
|
+
import { jsx as jsx34 } from "react/jsx-runtime";
|
|
26695
26986
|
function MailchimpCallback() {
|
|
26696
26987
|
const { login } = useContext40(AuthContext);
|
|
26697
26988
|
const match2 = useMatch11();
|
|
@@ -26699,7 +26990,7 @@ function MailchimpCallback() {
|
|
|
26699
26990
|
if (!action) {
|
|
26700
26991
|
throw new Error("Invalid action");
|
|
26701
26992
|
}
|
|
26702
|
-
return /* @__PURE__ */
|
|
26993
|
+
return /* @__PURE__ */ jsx34(
|
|
26703
26994
|
IntegrationCallback_default,
|
|
26704
26995
|
{
|
|
26705
26996
|
handler: (output) => mailchimpActionHandlers(login)[action](output)
|
|
@@ -26709,7 +27000,7 @@ function MailchimpCallback() {
|
|
|
26709
27000
|
var Callback_default5 = MailchimpCallback;
|
|
26710
27001
|
|
|
26711
27002
|
// src/views/Settings/Integrations/Mailchimp/Status.tsx
|
|
26712
|
-
import { useCallback as
|
|
27003
|
+
import { useCallback as useCallback29 } from "react";
|
|
26713
27004
|
import { Delete as Delete9, Mailchimp as Mailchimp3 } from "@livechat/design-system-icons";
|
|
26714
27005
|
import { Button as Button43, Icon as Icon50 } from "@livechat/design-system-react-components";
|
|
26715
27006
|
import {
|
|
@@ -26718,12 +27009,12 @@ import {
|
|
|
26718
27009
|
function MailchimpStatus() {
|
|
26719
27010
|
const credentialsQuery = useFetchMailchimpCredentials();
|
|
26720
27011
|
const removeCredentialMutation = useRemoveIntegrationCredential();
|
|
26721
|
-
const refetch =
|
|
27012
|
+
const refetch = useCallback29(() => {
|
|
26722
27013
|
credentialsQuery.refetch();
|
|
26723
27014
|
}, [credentialsQuery]);
|
|
26724
27015
|
const oauthCredential = credentialsQuery.data.internal;
|
|
26725
27016
|
const otherCredentials = credentialsQuery.data.other;
|
|
26726
|
-
const Connect =
|
|
27017
|
+
const Connect = useCallback29(
|
|
26727
27018
|
({ credential }) => /* @__PURE__ */ jsx7(
|
|
26728
27019
|
Action_default3,
|
|
26729
27020
|
{
|
|
@@ -26807,7 +27098,7 @@ import {
|
|
|
26807
27098
|
IntegrationNames as IntegrationNames37
|
|
26808
27099
|
} from "@livechat/developer-studio-api";
|
|
26809
27100
|
import { useMatch as useMatch12 } from "@livechat/developer-studio-ui-react";
|
|
26810
|
-
import { jsx as
|
|
27101
|
+
import { jsx as jsx35 } from "react/jsx-runtime";
|
|
26811
27102
|
function NeonAction(props) {
|
|
26812
27103
|
var _a;
|
|
26813
27104
|
const { login } = useContext41(AuthContext);
|
|
@@ -26816,7 +27107,7 @@ function NeonAction(props) {
|
|
|
26816
27107
|
if (!action) {
|
|
26817
27108
|
throw new Error("Invalid action");
|
|
26818
27109
|
}
|
|
26819
|
-
return /* @__PURE__ */
|
|
27110
|
+
return /* @__PURE__ */ jsx35(
|
|
26820
27111
|
IntegrationAction_default,
|
|
26821
27112
|
{
|
|
26822
27113
|
action,
|
|
@@ -26863,7 +27154,7 @@ var Action_default7 = NeonAction;
|
|
|
26863
27154
|
// src/views/Settings/Integrations/Neon/Callback.tsx
|
|
26864
27155
|
import { useContext as useContext42 } from "react";
|
|
26865
27156
|
import { useMatch as useMatch13 } from "@livechat/developer-studio-ui-react";
|
|
26866
|
-
import { jsx as
|
|
27157
|
+
import { jsx as jsx36 } from "react/jsx-runtime";
|
|
26867
27158
|
function NeonCallback() {
|
|
26868
27159
|
const { login } = useContext42(AuthContext);
|
|
26869
27160
|
const match2 = useMatch13();
|
|
@@ -26871,7 +27162,7 @@ function NeonCallback() {
|
|
|
26871
27162
|
if (!action) {
|
|
26872
27163
|
throw new Error("Invalid action");
|
|
26873
27164
|
}
|
|
26874
|
-
return /* @__PURE__ */
|
|
27165
|
+
return /* @__PURE__ */ jsx36(
|
|
26875
27166
|
IntegrationCallback_default,
|
|
26876
27167
|
{
|
|
26877
27168
|
handler: (output) => neonActionHandlers(login)[action](output)
|
|
@@ -26881,7 +27172,7 @@ function NeonCallback() {
|
|
|
26881
27172
|
var Callback_default6 = NeonCallback;
|
|
26882
27173
|
|
|
26883
27174
|
// src/views/Settings/Integrations/Neon/Status.tsx
|
|
26884
|
-
import { useCallback as
|
|
27175
|
+
import { useCallback as useCallback30 } from "react";
|
|
26885
27176
|
import { Delete as Delete10 } from "@livechat/design-system-icons";
|
|
26886
27177
|
import { Button as Button44, Icon as Icon51 } from "@livechat/design-system-react-components";
|
|
26887
27178
|
import {
|
|
@@ -26943,12 +27234,12 @@ import {
|
|
|
26943
27234
|
function NeonStatus() {
|
|
26944
27235
|
const credentialsQuery = useFetchNeonCredentials();
|
|
26945
27236
|
const removeCredentialMutation = useRemoveIntegrationCredential();
|
|
26946
|
-
const refetch =
|
|
27237
|
+
const refetch = useCallback30(() => {
|
|
26947
27238
|
credentialsQuery.refetch();
|
|
26948
27239
|
}, [credentialsQuery]);
|
|
26949
27240
|
const oauthCredential = credentialsQuery.data.internal;
|
|
26950
27241
|
const otherCredentials = credentialsQuery.data.other;
|
|
26951
|
-
const Connect =
|
|
27242
|
+
const Connect = useCallback30(
|
|
26952
27243
|
({ credential }) => /* @__PURE__ */ jsx7(
|
|
26953
27244
|
Action_default7,
|
|
26954
27245
|
{
|
|
@@ -27147,7 +27438,7 @@ var appDeploymentBlockAmplitudeJourneyFactory = (email) => ({
|
|
|
27147
27438
|
});
|
|
27148
27439
|
|
|
27149
27440
|
// src/views/Settings/Integrations/Netlify/Action.tsx
|
|
27150
|
-
import { jsx as
|
|
27441
|
+
import { jsx as jsx37 } from "react/jsx-runtime";
|
|
27151
27442
|
function NetlifyAction(props) {
|
|
27152
27443
|
var _a;
|
|
27153
27444
|
const { login } = useContext46(AuthContext);
|
|
@@ -27157,7 +27448,7 @@ function NetlifyAction(props) {
|
|
|
27157
27448
|
if (!action) {
|
|
27158
27449
|
throw new Error("Invalid action");
|
|
27159
27450
|
}
|
|
27160
|
-
return /* @__PURE__ */
|
|
27451
|
+
return /* @__PURE__ */ jsx37(
|
|
27161
27452
|
IntegrationAction_default,
|
|
27162
27453
|
{
|
|
27163
27454
|
action,
|
|
@@ -27240,7 +27531,7 @@ var Action_default8 = NetlifyAction;
|
|
|
27240
27531
|
// src/views/Settings/Integrations/Netlify/Callback.tsx
|
|
27241
27532
|
import { useContext as useContext47 } from "react";
|
|
27242
27533
|
import { useMatch as useMatch15 } from "@livechat/developer-studio-ui-react";
|
|
27243
|
-
import { jsx as
|
|
27534
|
+
import { jsx as jsx38 } from "react/jsx-runtime";
|
|
27244
27535
|
function NetlifyCallback() {
|
|
27245
27536
|
const match2 = useMatch15();
|
|
27246
27537
|
const { login } = useContext47(AuthContext);
|
|
@@ -27249,7 +27540,7 @@ function NetlifyCallback() {
|
|
|
27249
27540
|
if (!action) {
|
|
27250
27541
|
throw new Error("Invalid action");
|
|
27251
27542
|
}
|
|
27252
|
-
return /* @__PURE__ */
|
|
27543
|
+
return /* @__PURE__ */ jsx38(
|
|
27253
27544
|
IntegrationCallback_default,
|
|
27254
27545
|
{
|
|
27255
27546
|
handler: (output) => netlifyActionHandlers(login, user.meta.email)[action](output)
|
|
@@ -27259,7 +27550,7 @@ function NetlifyCallback() {
|
|
|
27259
27550
|
var Callback_default7 = NetlifyCallback;
|
|
27260
27551
|
|
|
27261
27552
|
// src/views/Settings/Integrations/Netlify/Status.tsx
|
|
27262
|
-
import { useCallback as
|
|
27553
|
+
import { useCallback as useCallback31, useContext as useContext49, useEffect as useEffect26, useState as useState44 } from "react";
|
|
27263
27554
|
import { ChevronDown as ChevronDown5, ChevronUp as ChevronUp3, Delete as Delete11 } from "@livechat/design-system-icons";
|
|
27264
27555
|
import {
|
|
27265
27556
|
ActionMenu as ActionMenu8,
|
|
@@ -27386,7 +27677,7 @@ function NetlifyStatus() {
|
|
|
27386
27677
|
const amplitudeDeploymentJourney = appDeploymentBlockAmplitudeJourneyFactory(
|
|
27387
27678
|
user.meta.email
|
|
27388
27679
|
);
|
|
27389
|
-
const refetch =
|
|
27680
|
+
const refetch = useCallback31(() => {
|
|
27390
27681
|
credentialsQuery.refetch();
|
|
27391
27682
|
userIntegrationsQuery.refetch();
|
|
27392
27683
|
sitesQuery.refetch();
|
|
@@ -27401,7 +27692,7 @@ function NetlifyStatus() {
|
|
|
27401
27692
|
const doesNetlifySiteHasInstallID = (_c = sitesQuery.data) == null ? void 0 : _c.some(
|
|
27402
27693
|
(element) => element.build_settings.installation_id
|
|
27403
27694
|
);
|
|
27404
|
-
|
|
27695
|
+
useEffect26(() => {
|
|
27405
27696
|
if (credentialsQuery.isFetching) {
|
|
27406
27697
|
return;
|
|
27407
27698
|
}
|
|
@@ -27433,7 +27724,7 @@ function NetlifyStatus() {
|
|
|
27433
27724
|
},
|
|
27434
27725
|
[refetch]
|
|
27435
27726
|
);
|
|
27436
|
-
const Connect =
|
|
27727
|
+
const Connect = useCallback31(
|
|
27437
27728
|
({ credential }) => /* @__PURE__ */ jsx7(
|
|
27438
27729
|
Action_default8,
|
|
27439
27730
|
{
|
|
@@ -27472,7 +27763,7 @@ function NetlifyStatus() {
|
|
|
27472
27763
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
27473
27764
|
[refetch]
|
|
27474
27765
|
);
|
|
27475
|
-
const Install =
|
|
27766
|
+
const Install = useCallback31(
|
|
27476
27767
|
() => {
|
|
27477
27768
|
var _a2;
|
|
27478
27769
|
return /* @__PURE__ */ jsx7(
|
|
@@ -27665,7 +27956,7 @@ var Status_default6 = NetlifyStatus;
|
|
|
27665
27956
|
// src/views/Settings/Integrations/Shopify/Callback.tsx
|
|
27666
27957
|
import { useContext as useContext50 } from "react";
|
|
27667
27958
|
import { useMatch as useMatch16 } from "@livechat/developer-studio-ui-react";
|
|
27668
|
-
import { jsx as
|
|
27959
|
+
import { jsx as jsx39 } from "react/jsx-runtime";
|
|
27669
27960
|
function ShopifyCallback() {
|
|
27670
27961
|
const { login } = useContext50(AuthContext);
|
|
27671
27962
|
const match2 = useMatch16();
|
|
@@ -27673,7 +27964,7 @@ function ShopifyCallback() {
|
|
|
27673
27964
|
if (!action) {
|
|
27674
27965
|
throw new Error("Invalid action");
|
|
27675
27966
|
}
|
|
27676
|
-
return /* @__PURE__ */
|
|
27967
|
+
return /* @__PURE__ */ jsx39(
|
|
27677
27968
|
IntegrationCallback_default,
|
|
27678
27969
|
{
|
|
27679
27970
|
handler: (output) => shopifyActionHandlers(login)[action](output)
|
|
@@ -27683,7 +27974,7 @@ function ShopifyCallback() {
|
|
|
27683
27974
|
var Callback_default8 = ShopifyCallback;
|
|
27684
27975
|
|
|
27685
27976
|
// src/views/Settings/Integrations/Shopify/Status.tsx
|
|
27686
|
-
import { useCallback as
|
|
27977
|
+
import { useCallback as useCallback32, useContext as useContext51, useState as useState45 } from "react";
|
|
27687
27978
|
import { notificationConnect as notificationConnect3 } from "@livechat/design-system";
|
|
27688
27979
|
import { Delete as Delete12, ShopifyColored as ShopifyColored3 } from "@livechat/design-system-icons";
|
|
27689
27980
|
import {
|
|
@@ -27706,12 +27997,12 @@ function ShopifyStatus() {
|
|
|
27706
27997
|
const credentialsQuery = useFetchShopifyCredentials();
|
|
27707
27998
|
const removeCredentialMutation = useRemoveIntegrationCredential();
|
|
27708
27999
|
const [state, setState] = useState45();
|
|
27709
|
-
const refetch =
|
|
28000
|
+
const refetch = useCallback32(() => {
|
|
27710
28001
|
credentialsQuery.refetch();
|
|
27711
28002
|
}, [credentialsQuery]);
|
|
27712
28003
|
const oauthCredential = credentialsQuery.data.internal;
|
|
27713
28004
|
const otherCredentials = credentialsQuery.data.other;
|
|
27714
|
-
const triggerConnect =
|
|
28005
|
+
const triggerConnect = useCallback32(
|
|
27715
28006
|
(shop) => {
|
|
27716
28007
|
triggerShopifyAction(
|
|
27717
28008
|
{
|
|
@@ -27736,14 +28027,14 @@ function ShopifyStatus() {
|
|
|
27736
28027
|
},
|
|
27737
28028
|
[login, refetch, notifications, user]
|
|
27738
28029
|
);
|
|
27739
|
-
const toggleModal =
|
|
28030
|
+
const toggleModal = useCallback32((isVisible) => {
|
|
27740
28031
|
setState((prevState) => __spreadProps(__spreadValues({}, prevState), {
|
|
27741
28032
|
modal: {
|
|
27742
28033
|
isVisible
|
|
27743
28034
|
}
|
|
27744
28035
|
}));
|
|
27745
28036
|
}, []);
|
|
27746
|
-
const updateShop =
|
|
28037
|
+
const updateShop = useCallback32((shop) => {
|
|
27747
28038
|
setState(
|
|
27748
28039
|
(prevState) => {
|
|
27749
28040
|
var _a2;
|
|
@@ -27755,7 +28046,7 @@ function ShopifyStatus() {
|
|
|
27755
28046
|
}
|
|
27756
28047
|
);
|
|
27757
28048
|
}, []);
|
|
27758
|
-
const submit =
|
|
28049
|
+
const submit = useCallback32(() => {
|
|
27759
28050
|
var _a2;
|
|
27760
28051
|
setState(
|
|
27761
28052
|
(prevState) => {
|
|
@@ -27772,7 +28063,7 @@ function ShopifyStatus() {
|
|
|
27772
28063
|
triggerConnect(state.modal.shop);
|
|
27773
28064
|
}
|
|
27774
28065
|
}, [state == null ? void 0 : state.modal, toggleModal, triggerConnect]);
|
|
27775
|
-
const Connect =
|
|
28066
|
+
const Connect = useCallback32(
|
|
27776
28067
|
({ credential }) => {
|
|
27777
28068
|
if (!credential) {
|
|
27778
28069
|
return /* @__PURE__ */ jsx7(
|
|
@@ -27912,7 +28203,7 @@ import {
|
|
|
27912
28203
|
IntegrationNames as IntegrationNames46
|
|
27913
28204
|
} from "@livechat/developer-studio-api";
|
|
27914
28205
|
import { useMatch as useMatch17 } from "@livechat/developer-studio-ui-react";
|
|
27915
|
-
import { jsx as
|
|
28206
|
+
import { jsx as jsx40 } from "react/jsx-runtime";
|
|
27916
28207
|
function TextAction(props) {
|
|
27917
28208
|
var _a;
|
|
27918
28209
|
const { login } = useContext52(AuthContext);
|
|
@@ -27921,7 +28212,7 @@ function TextAction(props) {
|
|
|
27921
28212
|
if (!action) {
|
|
27922
28213
|
throw new Error("Invalid action");
|
|
27923
28214
|
}
|
|
27924
|
-
return /* @__PURE__ */
|
|
28215
|
+
return /* @__PURE__ */ jsx40(
|
|
27925
28216
|
IntegrationAction_default,
|
|
27926
28217
|
{
|
|
27927
28218
|
action,
|
|
@@ -27964,7 +28255,7 @@ var Action_default9 = TextAction;
|
|
|
27964
28255
|
// src/views/Settings/Integrations/Text/Callback.tsx
|
|
27965
28256
|
import { useContext as useContext53 } from "react";
|
|
27966
28257
|
import { useMatch as useMatch18 } from "@livechat/developer-studio-ui-react";
|
|
27967
|
-
import { jsx as
|
|
28258
|
+
import { jsx as jsx41 } from "react/jsx-runtime";
|
|
27968
28259
|
function TextCallback() {
|
|
27969
28260
|
const { login } = useContext53(AuthContext);
|
|
27970
28261
|
const match2 = useMatch18();
|
|
@@ -27972,7 +28263,7 @@ function TextCallback() {
|
|
|
27972
28263
|
if (!action) {
|
|
27973
28264
|
throw new Error("Invalid action");
|
|
27974
28265
|
}
|
|
27975
|
-
return /* @__PURE__ */
|
|
28266
|
+
return /* @__PURE__ */ jsx41(
|
|
27976
28267
|
IntegrationCallback_default,
|
|
27977
28268
|
{
|
|
27978
28269
|
handler: (output) => textActionHandlers(login)[action](output)
|
|
@@ -27982,7 +28273,7 @@ function TextCallback() {
|
|
|
27982
28273
|
var Callback_default9 = TextCallback;
|
|
27983
28274
|
|
|
27984
28275
|
// src/views/Settings/Integrations/Text/Status.tsx
|
|
27985
|
-
import { useCallback as
|
|
28276
|
+
import { useCallback as useCallback33, useContext as useContext54 } from "react";
|
|
27986
28277
|
import { Button as Button47 } from "@livechat/design-system-react-components";
|
|
27987
28278
|
import {
|
|
27988
28279
|
IntegrationDisplayNames as IntegrationDisplayNames14
|
|
@@ -27992,13 +28283,13 @@ function TextStatus() {
|
|
|
27992
28283
|
const { user } = useContext54(UserContext);
|
|
27993
28284
|
const credentialsQuery = useFetchTextCredentials();
|
|
27994
28285
|
const isInstalledQuery = useFetchUserInstalledTextIntegration(user);
|
|
27995
|
-
const refetch =
|
|
28286
|
+
const refetch = useCallback33(() => {
|
|
27996
28287
|
credentialsQuery.refetch();
|
|
27997
28288
|
isInstalledQuery.refetch();
|
|
27998
28289
|
}, [credentialsQuery, isInstalledQuery]);
|
|
27999
28290
|
const authCredential = credentialsQuery.data.internal;
|
|
28000
28291
|
const otherCredentials = credentialsQuery.data.other;
|
|
28001
|
-
const Connect =
|
|
28292
|
+
const Connect = useCallback33(
|
|
28002
28293
|
({ credential }) => /* @__PURE__ */ jsx7(
|
|
28003
28294
|
Action_default9,
|
|
28004
28295
|
{
|
|
@@ -28069,7 +28360,7 @@ import {
|
|
|
28069
28360
|
IntegrationNames as IntegrationNames47
|
|
28070
28361
|
} from "@livechat/developer-studio-api";
|
|
28071
28362
|
import { useMatch as useMatch19 } from "@livechat/developer-studio-ui-react";
|
|
28072
|
-
import { jsx as
|
|
28363
|
+
import { jsx as jsx42 } from "react/jsx-runtime";
|
|
28073
28364
|
function VercelAction(props) {
|
|
28074
28365
|
var _a;
|
|
28075
28366
|
const { login } = useContext55(AuthContext);
|
|
@@ -28079,7 +28370,7 @@ function VercelAction(props) {
|
|
|
28079
28370
|
if (!action) {
|
|
28080
28371
|
throw new Error("Invalid action");
|
|
28081
28372
|
}
|
|
28082
|
-
return /* @__PURE__ */
|
|
28373
|
+
return /* @__PURE__ */ jsx42(
|
|
28083
28374
|
IntegrationAction_default,
|
|
28084
28375
|
{
|
|
28085
28376
|
action,
|
|
@@ -28163,7 +28454,7 @@ var Action_default10 = VercelAction;
|
|
|
28163
28454
|
// src/views/Settings/Integrations/Vercel/Callback.tsx
|
|
28164
28455
|
import { useContext as useContext56 } from "react";
|
|
28165
28456
|
import { useMatch as useMatch20 } from "@livechat/developer-studio-ui-react";
|
|
28166
|
-
import { jsx as
|
|
28457
|
+
import { jsx as jsx43 } from "react/jsx-runtime";
|
|
28167
28458
|
function VercelCallback() {
|
|
28168
28459
|
const { login } = useContext56(AuthContext);
|
|
28169
28460
|
const match2 = useMatch20();
|
|
@@ -28172,7 +28463,7 @@ function VercelCallback() {
|
|
|
28172
28463
|
if (!action) {
|
|
28173
28464
|
throw new Error("Invalid action");
|
|
28174
28465
|
}
|
|
28175
|
-
return /* @__PURE__ */
|
|
28466
|
+
return /* @__PURE__ */ jsx43(
|
|
28176
28467
|
IntegrationCallback_default,
|
|
28177
28468
|
{
|
|
28178
28469
|
handler: (output) => vercelActionHandlers(login, user.meta.email)[action](
|
|
@@ -28184,7 +28475,7 @@ function VercelCallback() {
|
|
|
28184
28475
|
var Callback_default10 = VercelCallback;
|
|
28185
28476
|
|
|
28186
28477
|
// src/views/Settings/Integrations/Vercel/Status.tsx
|
|
28187
|
-
import { useCallback as
|
|
28478
|
+
import { useCallback as useCallback34, useContext as useContext57, useEffect as useEffect27, useState as useState46 } from "react";
|
|
28188
28479
|
import { ChevronDown as ChevronDown6, ChevronUp as ChevronUp4, Delete as Delete13 } from "@livechat/design-system-icons";
|
|
28189
28480
|
import {
|
|
28190
28481
|
ActionMenu as ActionMenu9,
|
|
@@ -28262,11 +28553,11 @@ function VercelStatus() {
|
|
|
28262
28553
|
const amplitudeDeploymentJourney = appDeploymentBlockAmplitudeJourneyFactory(
|
|
28263
28554
|
user.meta.email
|
|
28264
28555
|
);
|
|
28265
|
-
const refetch =
|
|
28556
|
+
const refetch = useCallback34(() => {
|
|
28266
28557
|
credentialsQuery.refetch();
|
|
28267
28558
|
namespacesQuery.refetch();
|
|
28268
28559
|
}, [credentialsQuery, namespacesQuery]);
|
|
28269
|
-
|
|
28560
|
+
useEffect27(() => {
|
|
28270
28561
|
if (credentialsQuery.isFetching) {
|
|
28271
28562
|
return;
|
|
28272
28563
|
}
|
|
@@ -28298,7 +28589,7 @@ function VercelStatus() {
|
|
|
28298
28589
|
},
|
|
28299
28590
|
[refetch]
|
|
28300
28591
|
);
|
|
28301
|
-
const Connect =
|
|
28592
|
+
const Connect = useCallback34(
|
|
28302
28593
|
({ credential }) => /* @__PURE__ */ jsx7(
|
|
28303
28594
|
Action_default10,
|
|
28304
28595
|
{
|
|
@@ -28337,7 +28628,7 @@ function VercelStatus() {
|
|
|
28337
28628
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
28338
28629
|
[refetch]
|
|
28339
28630
|
);
|
|
28340
|
-
const Install =
|
|
28631
|
+
const Install = useCallback34(
|
|
28341
28632
|
() => {
|
|
28342
28633
|
var _a2;
|
|
28343
28634
|
return /* @__PURE__ */ jsx7(
|
|
@@ -28515,7 +28806,7 @@ function VercelStatus() {
|
|
|
28515
28806
|
var Status_default9 = VercelStatus;
|
|
28516
28807
|
|
|
28517
28808
|
// src/views/Settings/index.tsx
|
|
28518
|
-
import { Fragment as Fragment26, jsx as
|
|
28809
|
+
import { Fragment as Fragment26, jsx as jsx44, jsxs as jsxs13 } from "react/jsx-runtime";
|
|
28519
28810
|
function SettingsSubNav() {
|
|
28520
28811
|
const { pathname } = useLocation11();
|
|
28521
28812
|
const { userHasAccessToWorkflows } = useUserContext();
|
|
@@ -28527,7 +28818,7 @@ function SettingsSubNav() {
|
|
|
28527
28818
|
label: "Integrations",
|
|
28528
28819
|
shouldOpenOnInit: pathname.includes("integrations"),
|
|
28529
28820
|
children: [
|
|
28530
|
-
/* @__PURE__ */
|
|
28821
|
+
/* @__PURE__ */ jsx44(
|
|
28531
28822
|
SubNavSection,
|
|
28532
28823
|
{
|
|
28533
28824
|
dataCy: `${IntegrationNames50.GitHub}-option`,
|
|
@@ -28535,7 +28826,7 @@ function SettingsSubNav() {
|
|
|
28535
28826
|
path: "/settings/integrations/github/status"
|
|
28536
28827
|
}
|
|
28537
28828
|
),
|
|
28538
|
-
/* @__PURE__ */
|
|
28829
|
+
/* @__PURE__ */ jsx44(
|
|
28539
28830
|
SubNavSection,
|
|
28540
28831
|
{
|
|
28541
28832
|
dataCy: `${IntegrationNames50.Netlify}-option`,
|
|
@@ -28543,7 +28834,7 @@ function SettingsSubNav() {
|
|
|
28543
28834
|
path: "/settings/integrations/netlify/status"
|
|
28544
28835
|
}
|
|
28545
28836
|
),
|
|
28546
|
-
/* @__PURE__ */
|
|
28837
|
+
/* @__PURE__ */ jsx44(
|
|
28547
28838
|
SubNavSection,
|
|
28548
28839
|
{
|
|
28549
28840
|
dataCy: `${IntegrationNames50.Vercel}-option`,
|
|
@@ -28551,7 +28842,7 @@ function SettingsSubNav() {
|
|
|
28551
28842
|
path: "/settings/integrations/vercel/status"
|
|
28552
28843
|
}
|
|
28553
28844
|
),
|
|
28554
|
-
/* @__PURE__ */
|
|
28845
|
+
/* @__PURE__ */ jsx44(
|
|
28555
28846
|
SubNavSection,
|
|
28556
28847
|
{
|
|
28557
28848
|
dataCy: `${IntegrationNames50.Neon}-option`,
|
|
@@ -28560,7 +28851,7 @@ function SettingsSubNav() {
|
|
|
28560
28851
|
}
|
|
28561
28852
|
),
|
|
28562
28853
|
userHasAccessToWorkflows ? /* @__PURE__ */ jsxs13(Fragment26, { children: [
|
|
28563
|
-
/* @__PURE__ */
|
|
28854
|
+
/* @__PURE__ */ jsx44(
|
|
28564
28855
|
SubNavSection,
|
|
28565
28856
|
{
|
|
28566
28857
|
dataCy: `${IntegrationNames50.Mailchimp}-option`,
|
|
@@ -28568,7 +28859,7 @@ function SettingsSubNav() {
|
|
|
28568
28859
|
path: "/settings/integrations/mailchimp/status"
|
|
28569
28860
|
}
|
|
28570
28861
|
),
|
|
28571
|
-
/* @__PURE__ */
|
|
28862
|
+
/* @__PURE__ */ jsx44(
|
|
28572
28863
|
SubNavSection,
|
|
28573
28864
|
{
|
|
28574
28865
|
dataCy: `${IntegrationNames50.Shopify}-option`,
|
|
@@ -28576,7 +28867,7 @@ function SettingsSubNav() {
|
|
|
28576
28867
|
path: "/settings/integrations/shopify/status"
|
|
28577
28868
|
}
|
|
28578
28869
|
),
|
|
28579
|
-
/* @__PURE__ */
|
|
28870
|
+
/* @__PURE__ */ jsx44(
|
|
28580
28871
|
SubNavSection,
|
|
28581
28872
|
{
|
|
28582
28873
|
dataCy: `${IntegrationNames50.HubSpot}-option`,
|
|
@@ -28584,7 +28875,7 @@ function SettingsSubNav() {
|
|
|
28584
28875
|
path: "/settings/integrations/hubspot/status"
|
|
28585
28876
|
}
|
|
28586
28877
|
),
|
|
28587
|
-
/* @__PURE__ */
|
|
28878
|
+
/* @__PURE__ */ jsx44(
|
|
28588
28879
|
SubNavSection,
|
|
28589
28880
|
{
|
|
28590
28881
|
dataCy: `${IntegrationNames50.BigCommerce}-option`,
|
|
@@ -28592,7 +28883,7 @@ function SettingsSubNav() {
|
|
|
28592
28883
|
path: "/settings/integrations/bigcommerce/status"
|
|
28593
28884
|
}
|
|
28594
28885
|
),
|
|
28595
|
-
/* @__PURE__ */
|
|
28886
|
+
/* @__PURE__ */ jsx44(
|
|
28596
28887
|
SubNavSection,
|
|
28597
28888
|
{
|
|
28598
28889
|
dataCy: `${IntegrationNames50.Text}-option`,
|
|
@@ -28607,165 +28898,165 @@ function SettingsSubNav() {
|
|
|
28607
28898
|
}
|
|
28608
28899
|
function Settings() {
|
|
28609
28900
|
return /* @__PURE__ */ jsxs13(Routes7, { children: [
|
|
28610
|
-
/* @__PURE__ */
|
|
28901
|
+
/* @__PURE__ */ jsx44(
|
|
28611
28902
|
Route7,
|
|
28612
28903
|
{
|
|
28613
|
-
element: /* @__PURE__ */
|
|
28904
|
+
element: /* @__PURE__ */ jsx44(Navigate3, { replace: true, to: "integrations/github/status" }),
|
|
28614
28905
|
path: "/"
|
|
28615
28906
|
}
|
|
28616
28907
|
),
|
|
28617
|
-
/* @__PURE__ */
|
|
28618
|
-
/* @__PURE__ */
|
|
28908
|
+
/* @__PURE__ */ jsx44(Route7, { element: /* @__PURE__ */ jsx44(Status_default2, {}), path: "integrations/github/status" }),
|
|
28909
|
+
/* @__PURE__ */ jsx44(
|
|
28619
28910
|
Route7,
|
|
28620
28911
|
{
|
|
28621
|
-
element: /* @__PURE__ */
|
|
28912
|
+
element: /* @__PURE__ */ jsx44(Action_default6, {}),
|
|
28622
28913
|
path: "integrations/github/action/:action/:data?/:context?"
|
|
28623
28914
|
}
|
|
28624
28915
|
),
|
|
28625
|
-
/* @__PURE__ */
|
|
28916
|
+
/* @__PURE__ */ jsx44(
|
|
28626
28917
|
Route7,
|
|
28627
28918
|
{
|
|
28628
|
-
element: /* @__PURE__ */
|
|
28919
|
+
element: /* @__PURE__ */ jsx44(Callback_default3, {}),
|
|
28629
28920
|
path: "integrations/github/callback/:action"
|
|
28630
28921
|
}
|
|
28631
28922
|
),
|
|
28632
|
-
/* @__PURE__ */
|
|
28633
|
-
/* @__PURE__ */
|
|
28923
|
+
/* @__PURE__ */ jsx44(Route7, { element: /* @__PURE__ */ jsx44(Status_default6, {}), path: "integrations/netlify/status" }),
|
|
28924
|
+
/* @__PURE__ */ jsx44(
|
|
28634
28925
|
Route7,
|
|
28635
28926
|
{
|
|
28636
|
-
element: /* @__PURE__ */
|
|
28927
|
+
element: /* @__PURE__ */ jsx44(Action_default8, {}),
|
|
28637
28928
|
path: "integrations/netlify/action/:action/:data?/:context?"
|
|
28638
28929
|
}
|
|
28639
28930
|
),
|
|
28640
|
-
/* @__PURE__ */
|
|
28931
|
+
/* @__PURE__ */ jsx44(
|
|
28641
28932
|
Route7,
|
|
28642
28933
|
{
|
|
28643
|
-
element: /* @__PURE__ */
|
|
28934
|
+
element: /* @__PURE__ */ jsx44(Callback_default7, {}),
|
|
28644
28935
|
path: "integrations/netlify/callback/:action"
|
|
28645
28936
|
}
|
|
28646
28937
|
),
|
|
28647
|
-
/* @__PURE__ */
|
|
28648
|
-
/* @__PURE__ */
|
|
28938
|
+
/* @__PURE__ */ jsx44(Route7, { element: /* @__PURE__ */ jsx44(Status_default9, {}), path: "integrations/vercel/status" }),
|
|
28939
|
+
/* @__PURE__ */ jsx44(
|
|
28649
28940
|
Route7,
|
|
28650
28941
|
{
|
|
28651
|
-
element: /* @__PURE__ */
|
|
28942
|
+
element: /* @__PURE__ */ jsx44(Action_default10, {}),
|
|
28652
28943
|
path: "integrations/vercel/action/:action/:data?/:context?"
|
|
28653
28944
|
}
|
|
28654
28945
|
),
|
|
28655
|
-
/* @__PURE__ */
|
|
28946
|
+
/* @__PURE__ */ jsx44(
|
|
28656
28947
|
Route7,
|
|
28657
28948
|
{
|
|
28658
|
-
element: /* @__PURE__ */
|
|
28949
|
+
element: /* @__PURE__ */ jsx44(Callback_default10, {}),
|
|
28659
28950
|
path: "integrations/vercel/callback/:action"
|
|
28660
28951
|
}
|
|
28661
28952
|
),
|
|
28662
|
-
/* @__PURE__ */
|
|
28663
|
-
/* @__PURE__ */
|
|
28953
|
+
/* @__PURE__ */ jsx44(Route7, { element: /* @__PURE__ */ jsx44(Status_default5, {}), path: "integrations/neon/status" }),
|
|
28954
|
+
/* @__PURE__ */ jsx44(
|
|
28664
28955
|
Route7,
|
|
28665
28956
|
{
|
|
28666
|
-
element: /* @__PURE__ */
|
|
28957
|
+
element: /* @__PURE__ */ jsx44(Action_default7, {}),
|
|
28667
28958
|
path: "integrations/neon/action/:action/:data?/:context?"
|
|
28668
28959
|
}
|
|
28669
28960
|
),
|
|
28670
|
-
/* @__PURE__ */
|
|
28961
|
+
/* @__PURE__ */ jsx44(
|
|
28671
28962
|
Route7,
|
|
28672
28963
|
{
|
|
28673
|
-
element: /* @__PURE__ */
|
|
28964
|
+
element: /* @__PURE__ */ jsx44(Callback_default6, {}),
|
|
28674
28965
|
path: "integrations/neon/callback/:action"
|
|
28675
28966
|
}
|
|
28676
28967
|
),
|
|
28677
|
-
/* @__PURE__ */
|
|
28678
|
-
/* @__PURE__ */
|
|
28968
|
+
/* @__PURE__ */ jsx44(Route7, { element: /* @__PURE__ */ jsx44(Status_default4, {}), path: "integrations/mailchimp/status" }),
|
|
28969
|
+
/* @__PURE__ */ jsx44(
|
|
28679
28970
|
Route7,
|
|
28680
28971
|
{
|
|
28681
|
-
element: /* @__PURE__ */
|
|
28972
|
+
element: /* @__PURE__ */ jsx44(Action_default3, {}),
|
|
28682
28973
|
path: "integrations/mailchimp/action/:action/:data?/:context?"
|
|
28683
28974
|
}
|
|
28684
28975
|
),
|
|
28685
|
-
/* @__PURE__ */
|
|
28976
|
+
/* @__PURE__ */ jsx44(
|
|
28686
28977
|
Route7,
|
|
28687
28978
|
{
|
|
28688
|
-
element: /* @__PURE__ */
|
|
28979
|
+
element: /* @__PURE__ */ jsx44(Callback_default5, {}),
|
|
28689
28980
|
path: "integrations/mailchimp/callback/:action"
|
|
28690
28981
|
}
|
|
28691
28982
|
),
|
|
28692
|
-
/* @__PURE__ */
|
|
28693
|
-
/* @__PURE__ */
|
|
28983
|
+
/* @__PURE__ */ jsx44(Route7, { element: /* @__PURE__ */ jsx44(Status_default7, {}), path: "integrations/shopify/status" }),
|
|
28984
|
+
/* @__PURE__ */ jsx44(
|
|
28694
28985
|
Route7,
|
|
28695
28986
|
{
|
|
28696
|
-
element: /* @__PURE__ */
|
|
28987
|
+
element: /* @__PURE__ */ jsx44(Action_default4, {}),
|
|
28697
28988
|
path: "integrations/shopify/action/:action/:data?/:context?"
|
|
28698
28989
|
}
|
|
28699
28990
|
),
|
|
28700
|
-
/* @__PURE__ */
|
|
28991
|
+
/* @__PURE__ */ jsx44(
|
|
28701
28992
|
Route7,
|
|
28702
28993
|
{
|
|
28703
|
-
element: /* @__PURE__ */
|
|
28994
|
+
element: /* @__PURE__ */ jsx44(Callback_default8, {}),
|
|
28704
28995
|
path: "integrations/shopify/callback/:action"
|
|
28705
28996
|
}
|
|
28706
28997
|
),
|
|
28707
|
-
/* @__PURE__ */
|
|
28708
|
-
/* @__PURE__ */
|
|
28998
|
+
/* @__PURE__ */ jsx44(Route7, { element: /* @__PURE__ */ jsx44(Status_default3, {}), path: "integrations/hubspot/status" }),
|
|
28999
|
+
/* @__PURE__ */ jsx44(
|
|
28709
29000
|
Route7,
|
|
28710
29001
|
{
|
|
28711
|
-
element: /* @__PURE__ */
|
|
29002
|
+
element: /* @__PURE__ */ jsx44(Action_default2, {}),
|
|
28712
29003
|
path: "integrations/hubspot/action/:action/:data?/:context?"
|
|
28713
29004
|
}
|
|
28714
29005
|
),
|
|
28715
|
-
/* @__PURE__ */
|
|
29006
|
+
/* @__PURE__ */ jsx44(
|
|
28716
29007
|
Route7,
|
|
28717
29008
|
{
|
|
28718
|
-
element: /* @__PURE__ */
|
|
29009
|
+
element: /* @__PURE__ */ jsx44(Callback_default4, {}),
|
|
28719
29010
|
path: "integrations/hubspot/callback/:action"
|
|
28720
29011
|
}
|
|
28721
29012
|
),
|
|
28722
|
-
/* @__PURE__ */
|
|
29013
|
+
/* @__PURE__ */ jsx44(
|
|
28723
29014
|
Route7,
|
|
28724
29015
|
{
|
|
28725
|
-
element: /* @__PURE__ */
|
|
29016
|
+
element: /* @__PURE__ */ jsx44(Status_default, {}),
|
|
28726
29017
|
path: "integrations/bigcommerce/status"
|
|
28727
29018
|
}
|
|
28728
29019
|
),
|
|
28729
|
-
/* @__PURE__ */
|
|
29020
|
+
/* @__PURE__ */ jsx44(
|
|
28730
29021
|
Route7,
|
|
28731
29022
|
{
|
|
28732
|
-
element: /* @__PURE__ */
|
|
29023
|
+
element: /* @__PURE__ */ jsx44(Action_default, {}),
|
|
28733
29024
|
path: "integrations/bigcommerce/action/:action/:data?/:context?"
|
|
28734
29025
|
}
|
|
28735
29026
|
),
|
|
28736
|
-
/* @__PURE__ */
|
|
29027
|
+
/* @__PURE__ */ jsx44(
|
|
28737
29028
|
Route7,
|
|
28738
29029
|
{
|
|
28739
|
-
element: /* @__PURE__ */
|
|
29030
|
+
element: /* @__PURE__ */ jsx44(Callback_default2, {}),
|
|
28740
29031
|
path: "integrations/bigcommerce/callback/:action"
|
|
28741
29032
|
}
|
|
28742
29033
|
),
|
|
28743
|
-
/* @__PURE__ */
|
|
28744
|
-
/* @__PURE__ */
|
|
29034
|
+
/* @__PURE__ */ jsx44(Route7, { element: /* @__PURE__ */ jsx44(Status_default8, {}), path: "integrations/text/status" }),
|
|
29035
|
+
/* @__PURE__ */ jsx44(
|
|
28745
29036
|
Route7,
|
|
28746
29037
|
{
|
|
28747
|
-
element: /* @__PURE__ */
|
|
29038
|
+
element: /* @__PURE__ */ jsx44(Action_default9, {}),
|
|
28748
29039
|
path: "integrations/text/action/:action/:data?/:context?"
|
|
28749
29040
|
}
|
|
28750
29041
|
),
|
|
28751
|
-
/* @__PURE__ */
|
|
29042
|
+
/* @__PURE__ */ jsx44(
|
|
28752
29043
|
Route7,
|
|
28753
29044
|
{
|
|
28754
|
-
element: /* @__PURE__ */
|
|
29045
|
+
element: /* @__PURE__ */ jsx44(Callback_default9, {}),
|
|
28755
29046
|
path: "integrations/text/callback/:action"
|
|
28756
29047
|
}
|
|
28757
29048
|
),
|
|
28758
|
-
/* @__PURE__ */
|
|
29049
|
+
/* @__PURE__ */ jsx44(
|
|
28759
29050
|
Route7,
|
|
28760
29051
|
{
|
|
28761
|
-
element: /* @__PURE__ */
|
|
29052
|
+
element: /* @__PURE__ */ jsx44(Action_default5, {}),
|
|
28762
29053
|
path: "integrations/accounts/action/:action/:data?"
|
|
28763
29054
|
}
|
|
28764
29055
|
),
|
|
28765
|
-
/* @__PURE__ */
|
|
29056
|
+
/* @__PURE__ */ jsx44(
|
|
28766
29057
|
Route7,
|
|
28767
29058
|
{
|
|
28768
|
-
element: /* @__PURE__ */
|
|
29059
|
+
element: /* @__PURE__ */ jsx44(Callback_default, {}),
|
|
28769
29060
|
path: "integrations/accounts/callback/:action"
|
|
28770
29061
|
}
|
|
28771
29062
|
)
|