@uniformdev/mesh-sdk-react 19.37.1 → 19.38.2
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.d.mts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.esm.js +21 -29
- package/dist/index.js +21 -29
- package/dist/index.mjs +21 -29
- package/package.json +4 -4
package/dist/index.d.mts
CHANGED
|
@@ -496,9 +496,9 @@ type InputVariablesProps = {
|
|
|
496
496
|
/** (optional) sets caption text value */
|
|
497
497
|
caption?: string;
|
|
498
498
|
/** Sets the test ID of the input */
|
|
499
|
-
'data-
|
|
499
|
+
'data-testid'?: string;
|
|
500
500
|
} & PasteTransformerPluginProps;
|
|
501
|
-
declare function InputVariables({ id, 'aria-label': ariaLabel, label, value, disableVariables, disableReset, enableEditingVariables, disableInlineMenu, onChange, transformPaste, showAddVariableMenuOption, inputWhenNoVariables, caption, errorMessage, warningMessage, infoMessage, 'data-
|
|
501
|
+
declare function InputVariables({ id, 'aria-label': ariaLabel, label, value, disableVariables, disableReset, enableEditingVariables, disableInlineMenu, onChange, transformPaste, showAddVariableMenuOption, inputWhenNoVariables, caption, errorMessage, warningMessage, infoMessage, 'data-testid': dataTestId, }: InputVariablesProps): _emotion_react_types_jsx_namespace.EmotionJSX.Element;
|
|
502
502
|
|
|
503
503
|
/** Expected prefix for variable expressions */
|
|
504
504
|
declare const variablePrefix = "${";
|
package/dist/index.d.ts
CHANGED
|
@@ -496,9 +496,9 @@ type InputVariablesProps = {
|
|
|
496
496
|
/** (optional) sets caption text value */
|
|
497
497
|
caption?: string;
|
|
498
498
|
/** Sets the test ID of the input */
|
|
499
|
-
'data-
|
|
499
|
+
'data-testid'?: string;
|
|
500
500
|
} & PasteTransformerPluginProps;
|
|
501
|
-
declare function InputVariables({ id, 'aria-label': ariaLabel, label, value, disableVariables, disableReset, enableEditingVariables, disableInlineMenu, onChange, transformPaste, showAddVariableMenuOption, inputWhenNoVariables, caption, errorMessage, warningMessage, infoMessage, 'data-
|
|
501
|
+
declare function InputVariables({ id, 'aria-label': ariaLabel, label, value, disableVariables, disableReset, enableEditingVariables, disableInlineMenu, onChange, transformPaste, showAddVariableMenuOption, inputWhenNoVariables, caption, errorMessage, warningMessage, infoMessage, 'data-testid': dataTestId, }: InputVariablesProps): _emotion_react_types_jsx_namespace.EmotionJSX.Element;
|
|
502
502
|
|
|
503
503
|
/** Expected prefix for variable expressions */
|
|
504
504
|
declare const variablePrefix = "${";
|
package/dist/index.esm.js
CHANGED
|
@@ -1076,7 +1076,7 @@ var ProductPreviewList = ({
|
|
|
1076
1076
|
"div",
|
|
1077
1077
|
{
|
|
1078
1078
|
css: productPreviewListItemDetailsContainer,
|
|
1079
|
-
"data-
|
|
1079
|
+
"data-testid": `product-item-${product.sku || product.id}`,
|
|
1080
1080
|
children: [
|
|
1081
1081
|
product.thumbnailUrl ? /* @__PURE__ */ jsx18(
|
|
1082
1082
|
"img",
|
|
@@ -1084,20 +1084,20 @@ var ProductPreviewList = ({
|
|
|
1084
1084
|
src: product.thumbnailUrl,
|
|
1085
1085
|
alt: typeof product.title === "string" ? product.title : `Product ${index}`,
|
|
1086
1086
|
css: productPreviewListImage,
|
|
1087
|
-
"data-
|
|
1087
|
+
"data-testid": "product-image"
|
|
1088
1088
|
}
|
|
1089
1089
|
) : /* @__PURE__ */ jsx18("div", { css: productPreviewListImageDefault }),
|
|
1090
|
-
/* @__PURE__ */ jsxs7("h4", { css: productPreviewListTitle, "data-
|
|
1090
|
+
/* @__PURE__ */ jsxs7("h4", { css: productPreviewListTitle, "data-testid": "product-name", children: [
|
|
1091
1091
|
product.title,
|
|
1092
1092
|
categoryName && /* @__PURE__ */ jsx18("span", { css: productPreviewListCategoryText, children: categoryName })
|
|
1093
1093
|
] }),
|
|
1094
1094
|
product && /* @__PURE__ */ jsxs7(Fragment2, { children: [
|
|
1095
|
-
/* @__PURE__ */ jsxs7("p", { css: productPreviewListDetailsText, "data-
|
|
1095
|
+
/* @__PURE__ */ jsxs7("p", { css: productPreviewListDetailsText, "data-testid": "product-sku", children: [
|
|
1096
1096
|
"SKU: ",
|
|
1097
1097
|
product.sku || product.id,
|
|
1098
1098
|
/* @__PURE__ */ jsx18("br", {})
|
|
1099
1099
|
] }),
|
|
1100
|
-
product.price !== void 0 ? /* @__PURE__ */ jsxs7("p", { css: productPreviewListDetailsText, "data-
|
|
1100
|
+
product.price !== void 0 ? /* @__PURE__ */ jsxs7("p", { css: productPreviewListDetailsText, "data-testid": "product-price", children: [
|
|
1101
1101
|
"Price: ",
|
|
1102
1102
|
product.price
|
|
1103
1103
|
] }) : null,
|
|
@@ -1109,7 +1109,7 @@ var ProductPreviewList = ({
|
|
|
1109
1109
|
title: `Go to ${product.title}`,
|
|
1110
1110
|
target: "_blank",
|
|
1111
1111
|
rel: "noopener noreferrer",
|
|
1112
|
-
"data-
|
|
1112
|
+
"data-testid": "edit-product-button",
|
|
1113
1113
|
children: [
|
|
1114
1114
|
/* @__PURE__ */ jsx18("span", { css: productPreviewListSmallText, children: "Edit" }),
|
|
1115
1115
|
logoIcon ? /* @__PURE__ */ jsx18(Image, { src: logoIcon, alt: "Logo", css: productPreviewListIcon }) : null
|
|
@@ -1393,7 +1393,7 @@ var DefaultSelectedItem = ({
|
|
|
1393
1393
|
` : ""
|
|
1394
1394
|
],
|
|
1395
1395
|
title: `ID: ${selectedItem.id}`,
|
|
1396
|
-
"data-
|
|
1396
|
+
"data-testid": "entry-id",
|
|
1397
1397
|
children: selectedItem.title || selectedItem.id || ""
|
|
1398
1398
|
}
|
|
1399
1399
|
),
|
|
@@ -1869,7 +1869,7 @@ var EntrySearch = ({
|
|
|
1869
1869
|
`,
|
|
1870
1870
|
children: [
|
|
1871
1871
|
showSearchBox ? /* @__PURE__ */ jsxs10(Fragment3, { children: [
|
|
1872
|
-
/* @__PURE__ */ jsx21("div", { css: entrySearchWrapper, "data-
|
|
1872
|
+
/* @__PURE__ */ jsx21("div", { css: entrySearchWrapper, "data-testid": "component-search", children: /* @__PURE__ */ jsxs10(
|
|
1873
1873
|
"button",
|
|
1874
1874
|
{
|
|
1875
1875
|
css: entrySearchBtn,
|
|
@@ -1966,7 +1966,7 @@ var EntrySearch = ({
|
|
|
1966
1966
|
id: listBoxId.current,
|
|
1967
1967
|
role: "listbox",
|
|
1968
1968
|
tabIndex: 0,
|
|
1969
|
-
"data-
|
|
1969
|
+
"data-testid": "entry-list",
|
|
1970
1970
|
children: [
|
|
1971
1971
|
/* @__PURE__ */ jsx21(LoadingOverlay, { isActive: showLoadingOverlay }),
|
|
1972
1972
|
Array.isArray(results) && results.length > 0 ? results.map((result) => /* @__PURE__ */ jsx21(
|
|
@@ -2029,7 +2029,7 @@ var EntrySearch = ({
|
|
|
2029
2029
|
{
|
|
2030
2030
|
disabled: !selectedListItems.length,
|
|
2031
2031
|
onClick: handleAcceptClick,
|
|
2032
|
-
"data-
|
|
2032
|
+
"data-testid": "entry-accept-button",
|
|
2033
2033
|
children: "Accept"
|
|
2034
2034
|
}
|
|
2035
2035
|
)
|
|
@@ -2680,15 +2680,7 @@ function DamSelectedItem({
|
|
|
2680
2680
|
children: /* @__PURE__ */ jsxs14("div", { css: damSelectedItemInner, children: [
|
|
2681
2681
|
/* @__PURE__ */ jsxs14("div", { css: damSelectedItemDetails, children: [
|
|
2682
2682
|
/* @__PURE__ */ jsxs14("div", { css: damSelectedItemCopy, children: [
|
|
2683
|
-
/* @__PURE__ */ jsx25(
|
|
2684
|
-
"h4",
|
|
2685
|
-
{
|
|
2686
|
-
css: [damSelectedItemTitle],
|
|
2687
|
-
title: `ID: ${selectedItem.id}`,
|
|
2688
|
-
"data-test-id": "dam-selected-item",
|
|
2689
|
-
children: selectedItem.title || selectedItem.id || ""
|
|
2690
|
-
}
|
|
2691
|
-
),
|
|
2683
|
+
/* @__PURE__ */ jsx25("h4", { css: [damSelectedItemTitle], title: `ID: ${selectedItem.id}`, "data-testid": "dam-selected-item", children: selectedItem.title || selectedItem.id || "" }),
|
|
2692
2684
|
selectedItem.popoverData ? /* @__PURE__ */ jsxs14("div", { ref: popoverRef, children: [
|
|
2693
2685
|
/* @__PURE__ */ jsx25(
|
|
2694
2686
|
"button",
|
|
@@ -3786,7 +3778,7 @@ var SelectVariableMenu = ({
|
|
|
3786
3778
|
ref: btnRef,
|
|
3787
3779
|
css: [menuBtn2, buttonCss],
|
|
3788
3780
|
type: "button",
|
|
3789
|
-
"data-
|
|
3781
|
+
"data-testid": "insert-variable",
|
|
3790
3782
|
children: /* @__PURE__ */ jsx32(CgUsbC, { size: "1.4rem" })
|
|
3791
3783
|
}
|
|
3792
3784
|
),
|
|
@@ -4074,7 +4066,7 @@ function InputVariables({
|
|
|
4074
4066
|
errorMessage,
|
|
4075
4067
|
warningMessage,
|
|
4076
4068
|
infoMessage,
|
|
4077
|
-
"data-
|
|
4069
|
+
"data-testid": dataTestId
|
|
4078
4070
|
}) {
|
|
4079
4071
|
const { variables } = useVariables(true);
|
|
4080
4072
|
const [finalId] = React11.useState(id != null ? id : () => v43());
|
|
@@ -4428,14 +4420,14 @@ function DataResourceVariablesListExplicit({
|
|
|
4428
4420
|
}
|
|
4429
4421
|
function TextVariableRenderer({ definition, value, setValue }) {
|
|
4430
4422
|
var _a;
|
|
4431
|
-
return /* @__PURE__ */ jsx39("div", { "data-
|
|
4423
|
+
return /* @__PURE__ */ jsx39("div", { "data-testid": "variable-input-container", children: /* @__PURE__ */ jsx39(
|
|
4432
4424
|
InputVariables,
|
|
4433
4425
|
{
|
|
4434
4426
|
label: definition.displayName || definition.name,
|
|
4435
4427
|
value: value != null ? value : "",
|
|
4436
4428
|
caption: (_a = definition.helpText) != null ? _a : definition.default !== "" ? `Default value: ${definition.default}` : void 0,
|
|
4437
4429
|
onChange: setValue,
|
|
4438
|
-
"data-
|
|
4430
|
+
"data-testid": "variable-input"
|
|
4439
4431
|
}
|
|
4440
4432
|
) });
|
|
4441
4433
|
}
|
|
@@ -4611,7 +4603,7 @@ function RequestBody() {
|
|
|
4611
4603
|
});
|
|
4612
4604
|
}
|
|
4613
4605
|
},
|
|
4614
|
-
"data-
|
|
4606
|
+
"data-testid": "body-select"
|
|
4615
4607
|
}
|
|
4616
4608
|
)
|
|
4617
4609
|
}
|
|
@@ -4699,7 +4691,7 @@ function RequestHeaders({ disableVariables }) {
|
|
|
4699
4691
|
dispatch({ type: "removeHeader", index });
|
|
4700
4692
|
}
|
|
4701
4693
|
},
|
|
4702
|
-
"data-
|
|
4694
|
+
"data-testid": "header-key"
|
|
4703
4695
|
}
|
|
4704
4696
|
) }),
|
|
4705
4697
|
/* @__PURE__ */ jsx43(TableCellData2, { width: "50%", children: header.key ? /* @__PURE__ */ jsx43(
|
|
@@ -4710,7 +4702,7 @@ function RequestHeaders({ disableVariables }) {
|
|
|
4710
4702
|
disableVariables,
|
|
4711
4703
|
showAddVariableMenuOption: true,
|
|
4712
4704
|
enableEditingVariables: true,
|
|
4713
|
-
"data-
|
|
4705
|
+
"data-testid": "header-value"
|
|
4714
4706
|
}
|
|
4715
4707
|
) : null })
|
|
4716
4708
|
] }, index);
|
|
@@ -4807,7 +4799,7 @@ function RequestParameters({ disableVariables }) {
|
|
|
4807
4799
|
dispatch({ type: "removeParameter", index });
|
|
4808
4800
|
}
|
|
4809
4801
|
},
|
|
4810
|
-
"data-
|
|
4802
|
+
"data-testid": "parameter-key"
|
|
4811
4803
|
}
|
|
4812
4804
|
) }),
|
|
4813
4805
|
/* @__PURE__ */ jsx45(TableCellData3, { width: "50%", children: parameter.key ? /* @__PURE__ */ jsx45(
|
|
@@ -4820,7 +4812,7 @@ function RequestParameters({ disableVariables }) {
|
|
|
4820
4812
|
index
|
|
4821
4813
|
}),
|
|
4822
4814
|
disableVariables,
|
|
4823
|
-
"data-
|
|
4815
|
+
"data-testid": "parameter-value",
|
|
4824
4816
|
showAddVariableMenuOption: true,
|
|
4825
4817
|
enableEditingVariables: true
|
|
4826
4818
|
}
|
|
@@ -4941,7 +4933,7 @@ function RequestUrlInput(props) {
|
|
|
4941
4933
|
},
|
|
4942
4934
|
showAddVariableMenuOption: true,
|
|
4943
4935
|
enableEditingVariables: true,
|
|
4944
|
-
"data-
|
|
4936
|
+
"data-testid": "field-url"
|
|
4945
4937
|
}
|
|
4946
4938
|
);
|
|
4947
4939
|
}
|
package/dist/index.js
CHANGED
|
@@ -1242,7 +1242,7 @@ var ProductPreviewList = ({
|
|
|
1242
1242
|
"div",
|
|
1243
1243
|
{
|
|
1244
1244
|
css: productPreviewListItemDetailsContainer,
|
|
1245
|
-
"data-
|
|
1245
|
+
"data-testid": `product-item-${product.sku || product.id}`,
|
|
1246
1246
|
children: [
|
|
1247
1247
|
product.thumbnailUrl ? /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
|
|
1248
1248
|
"img",
|
|
@@ -1250,20 +1250,20 @@ var ProductPreviewList = ({
|
|
|
1250
1250
|
src: product.thumbnailUrl,
|
|
1251
1251
|
alt: typeof product.title === "string" ? product.title : `Product ${index}`,
|
|
1252
1252
|
css: productPreviewListImage,
|
|
1253
|
-
"data-
|
|
1253
|
+
"data-testid": "product-image"
|
|
1254
1254
|
}
|
|
1255
1255
|
) : /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("div", { css: productPreviewListImageDefault }),
|
|
1256
|
-
/* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("h4", { css: productPreviewListTitle, "data-
|
|
1256
|
+
/* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("h4", { css: productPreviewListTitle, "data-testid": "product-name", children: [
|
|
1257
1257
|
product.title,
|
|
1258
1258
|
categoryName && /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("span", { css: productPreviewListCategoryText, children: categoryName })
|
|
1259
1259
|
] }),
|
|
1260
1260
|
product && /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)(import_jsx_runtime18.Fragment, { children: [
|
|
1261
|
-
/* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("p", { css: productPreviewListDetailsText, "data-
|
|
1261
|
+
/* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("p", { css: productPreviewListDetailsText, "data-testid": "product-sku", children: [
|
|
1262
1262
|
"SKU: ",
|
|
1263
1263
|
product.sku || product.id,
|
|
1264
1264
|
/* @__PURE__ */ (0, import_jsx_runtime18.jsx)("br", {})
|
|
1265
1265
|
] }),
|
|
1266
|
-
product.price !== void 0 ? /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("p", { css: productPreviewListDetailsText, "data-
|
|
1266
|
+
product.price !== void 0 ? /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("p", { css: productPreviewListDetailsText, "data-testid": "product-price", children: [
|
|
1267
1267
|
"Price: ",
|
|
1268
1268
|
product.price
|
|
1269
1269
|
] }) : null,
|
|
@@ -1275,7 +1275,7 @@ var ProductPreviewList = ({
|
|
|
1275
1275
|
title: `Go to ${product.title}`,
|
|
1276
1276
|
target: "_blank",
|
|
1277
1277
|
rel: "noopener noreferrer",
|
|
1278
|
-
"data-
|
|
1278
|
+
"data-testid": "edit-product-button",
|
|
1279
1279
|
children: [
|
|
1280
1280
|
/* @__PURE__ */ (0, import_jsx_runtime18.jsx)("span", { css: productPreviewListSmallText, children: "Edit" }),
|
|
1281
1281
|
logoIcon ? /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(Image, { src: logoIcon, alt: "Logo", css: productPreviewListIcon }) : null
|
|
@@ -1559,7 +1559,7 @@ var DefaultSelectedItem = ({
|
|
|
1559
1559
|
` : ""
|
|
1560
1560
|
],
|
|
1561
1561
|
title: `ID: ${selectedItem.id}`,
|
|
1562
|
-
"data-
|
|
1562
|
+
"data-testid": "entry-id",
|
|
1563
1563
|
children: selectedItem.title || selectedItem.id || ""
|
|
1564
1564
|
}
|
|
1565
1565
|
),
|
|
@@ -2025,7 +2025,7 @@ var EntrySearch = ({
|
|
|
2025
2025
|
`,
|
|
2026
2026
|
children: [
|
|
2027
2027
|
showSearchBox ? /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)(import_jsx_runtime21.Fragment, { children: [
|
|
2028
|
-
/* @__PURE__ */ (0, import_jsx_runtime21.jsx)("div", { css: entrySearchWrapper, "data-
|
|
2028
|
+
/* @__PURE__ */ (0, import_jsx_runtime21.jsx)("div", { css: entrySearchWrapper, "data-testid": "component-search", children: /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)(
|
|
2029
2029
|
"button",
|
|
2030
2030
|
{
|
|
2031
2031
|
css: entrySearchBtn,
|
|
@@ -2122,7 +2122,7 @@ var EntrySearch = ({
|
|
|
2122
2122
|
id: listBoxId.current,
|
|
2123
2123
|
role: "listbox",
|
|
2124
2124
|
tabIndex: 0,
|
|
2125
|
-
"data-
|
|
2125
|
+
"data-testid": "entry-list",
|
|
2126
2126
|
children: [
|
|
2127
2127
|
/* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_design_system7.LoadingOverlay, { isActive: showLoadingOverlay }),
|
|
2128
2128
|
Array.isArray(results) && results.length > 0 ? results.map((result) => /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
|
|
@@ -2185,7 +2185,7 @@ var EntrySearch = ({
|
|
|
2185
2185
|
{
|
|
2186
2186
|
disabled: !selectedListItems.length,
|
|
2187
2187
|
onClick: handleAcceptClick,
|
|
2188
|
-
"data-
|
|
2188
|
+
"data-testid": "entry-accept-button",
|
|
2189
2189
|
children: "Accept"
|
|
2190
2190
|
}
|
|
2191
2191
|
)
|
|
@@ -2836,15 +2836,7 @@ function DamSelectedItem({
|
|
|
2836
2836
|
children: /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("div", { css: damSelectedItemInner, children: [
|
|
2837
2837
|
/* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("div", { css: damSelectedItemDetails, children: [
|
|
2838
2838
|
/* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("div", { css: damSelectedItemCopy, children: [
|
|
2839
|
-
/* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
|
|
2840
|
-
"h4",
|
|
2841
|
-
{
|
|
2842
|
-
css: [damSelectedItemTitle],
|
|
2843
|
-
title: `ID: ${selectedItem.id}`,
|
|
2844
|
-
"data-test-id": "dam-selected-item",
|
|
2845
|
-
children: selectedItem.title || selectedItem.id || ""
|
|
2846
|
-
}
|
|
2847
|
-
),
|
|
2839
|
+
/* @__PURE__ */ (0, import_jsx_runtime25.jsx)("h4", { css: [damSelectedItemTitle], title: `ID: ${selectedItem.id}`, "data-testid": "dam-selected-item", children: selectedItem.title || selectedItem.id || "" }),
|
|
2848
2840
|
selectedItem.popoverData ? /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("div", { ref: popoverRef, children: [
|
|
2849
2841
|
/* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
|
|
2850
2842
|
"button",
|
|
@@ -3939,7 +3931,7 @@ var SelectVariableMenu = ({
|
|
|
3939
3931
|
ref: btnRef,
|
|
3940
3932
|
css: [menuBtn2, buttonCss],
|
|
3941
3933
|
type: "button",
|
|
3942
|
-
"data-
|
|
3934
|
+
"data-testid": "insert-variable",
|
|
3943
3935
|
children: /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(import_cg5.CgUsbC, { size: "1.4rem" })
|
|
3944
3936
|
}
|
|
3945
3937
|
),
|
|
@@ -4224,7 +4216,7 @@ function InputVariables({
|
|
|
4224
4216
|
errorMessage,
|
|
4225
4217
|
warningMessage,
|
|
4226
4218
|
infoMessage,
|
|
4227
|
-
"data-
|
|
4219
|
+
"data-testid": dataTestId
|
|
4228
4220
|
}) {
|
|
4229
4221
|
const { variables } = useVariables(true);
|
|
4230
4222
|
const [finalId] = React11.useState(id != null ? id : () => (0, import_uuid3.v4)());
|
|
@@ -4568,14 +4560,14 @@ function DataResourceVariablesListExplicit({
|
|
|
4568
4560
|
}
|
|
4569
4561
|
function TextVariableRenderer({ definition, value, setValue }) {
|
|
4570
4562
|
var _a;
|
|
4571
|
-
return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("div", { "data-
|
|
4563
|
+
return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("div", { "data-testid": "variable-input-container", children: /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
4572
4564
|
InputVariables,
|
|
4573
4565
|
{
|
|
4574
4566
|
label: definition.displayName || definition.name,
|
|
4575
4567
|
value: value != null ? value : "",
|
|
4576
4568
|
caption: (_a = definition.helpText) != null ? _a : definition.default !== "" ? `Default value: ${definition.default}` : void 0,
|
|
4577
4569
|
onChange: setValue,
|
|
4578
|
-
"data-
|
|
4570
|
+
"data-testid": "variable-input"
|
|
4579
4571
|
}
|
|
4580
4572
|
) });
|
|
4581
4573
|
}
|
|
@@ -4751,7 +4743,7 @@ function RequestBody() {
|
|
|
4751
4743
|
});
|
|
4752
4744
|
}
|
|
4753
4745
|
},
|
|
4754
|
-
"data-
|
|
4746
|
+
"data-testid": "body-select"
|
|
4755
4747
|
}
|
|
4756
4748
|
)
|
|
4757
4749
|
}
|
|
@@ -4830,7 +4822,7 @@ function RequestHeaders({ disableVariables }) {
|
|
|
4830
4822
|
dispatch({ type: "removeHeader", index });
|
|
4831
4823
|
}
|
|
4832
4824
|
},
|
|
4833
|
-
"data-
|
|
4825
|
+
"data-testid": "header-key"
|
|
4834
4826
|
}
|
|
4835
4827
|
) }),
|
|
4836
4828
|
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)(import_design_system22.TableCellData, { width: "50%", children: header.key ? /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
|
|
@@ -4841,7 +4833,7 @@ function RequestHeaders({ disableVariables }) {
|
|
|
4841
4833
|
disableVariables,
|
|
4842
4834
|
showAddVariableMenuOption: true,
|
|
4843
4835
|
enableEditingVariables: true,
|
|
4844
|
-
"data-
|
|
4836
|
+
"data-testid": "header-value"
|
|
4845
4837
|
}
|
|
4846
4838
|
) : null })
|
|
4847
4839
|
] }, index);
|
|
@@ -4929,7 +4921,7 @@ function RequestParameters({ disableVariables }) {
|
|
|
4929
4921
|
dispatch({ type: "removeParameter", index });
|
|
4930
4922
|
}
|
|
4931
4923
|
},
|
|
4932
|
-
"data-
|
|
4924
|
+
"data-testid": "parameter-key"
|
|
4933
4925
|
}
|
|
4934
4926
|
) }),
|
|
4935
4927
|
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)(import_design_system24.TableCellData, { width: "50%", children: parameter.key ? /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
|
|
@@ -4942,7 +4934,7 @@ function RequestParameters({ disableVariables }) {
|
|
|
4942
4934
|
index
|
|
4943
4935
|
}),
|
|
4944
4936
|
disableVariables,
|
|
4945
|
-
"data-
|
|
4937
|
+
"data-testid": "parameter-value",
|
|
4946
4938
|
showAddVariableMenuOption: true,
|
|
4947
4939
|
enableEditingVariables: true
|
|
4948
4940
|
}
|
|
@@ -5063,7 +5055,7 @@ function RequestUrlInput(props) {
|
|
|
5063
5055
|
},
|
|
5064
5056
|
showAddVariableMenuOption: true,
|
|
5065
5057
|
enableEditingVariables: true,
|
|
5066
|
-
"data-
|
|
5058
|
+
"data-testid": "field-url"
|
|
5067
5059
|
}
|
|
5068
5060
|
);
|
|
5069
5061
|
}
|
package/dist/index.mjs
CHANGED
|
@@ -1076,7 +1076,7 @@ var ProductPreviewList = ({
|
|
|
1076
1076
|
"div",
|
|
1077
1077
|
{
|
|
1078
1078
|
css: productPreviewListItemDetailsContainer,
|
|
1079
|
-
"data-
|
|
1079
|
+
"data-testid": `product-item-${product.sku || product.id}`,
|
|
1080
1080
|
children: [
|
|
1081
1081
|
product.thumbnailUrl ? /* @__PURE__ */ jsx18(
|
|
1082
1082
|
"img",
|
|
@@ -1084,20 +1084,20 @@ var ProductPreviewList = ({
|
|
|
1084
1084
|
src: product.thumbnailUrl,
|
|
1085
1085
|
alt: typeof product.title === "string" ? product.title : `Product ${index}`,
|
|
1086
1086
|
css: productPreviewListImage,
|
|
1087
|
-
"data-
|
|
1087
|
+
"data-testid": "product-image"
|
|
1088
1088
|
}
|
|
1089
1089
|
) : /* @__PURE__ */ jsx18("div", { css: productPreviewListImageDefault }),
|
|
1090
|
-
/* @__PURE__ */ jsxs7("h4", { css: productPreviewListTitle, "data-
|
|
1090
|
+
/* @__PURE__ */ jsxs7("h4", { css: productPreviewListTitle, "data-testid": "product-name", children: [
|
|
1091
1091
|
product.title,
|
|
1092
1092
|
categoryName && /* @__PURE__ */ jsx18("span", { css: productPreviewListCategoryText, children: categoryName })
|
|
1093
1093
|
] }),
|
|
1094
1094
|
product && /* @__PURE__ */ jsxs7(Fragment2, { children: [
|
|
1095
|
-
/* @__PURE__ */ jsxs7("p", { css: productPreviewListDetailsText, "data-
|
|
1095
|
+
/* @__PURE__ */ jsxs7("p", { css: productPreviewListDetailsText, "data-testid": "product-sku", children: [
|
|
1096
1096
|
"SKU: ",
|
|
1097
1097
|
product.sku || product.id,
|
|
1098
1098
|
/* @__PURE__ */ jsx18("br", {})
|
|
1099
1099
|
] }),
|
|
1100
|
-
product.price !== void 0 ? /* @__PURE__ */ jsxs7("p", { css: productPreviewListDetailsText, "data-
|
|
1100
|
+
product.price !== void 0 ? /* @__PURE__ */ jsxs7("p", { css: productPreviewListDetailsText, "data-testid": "product-price", children: [
|
|
1101
1101
|
"Price: ",
|
|
1102
1102
|
product.price
|
|
1103
1103
|
] }) : null,
|
|
@@ -1109,7 +1109,7 @@ var ProductPreviewList = ({
|
|
|
1109
1109
|
title: `Go to ${product.title}`,
|
|
1110
1110
|
target: "_blank",
|
|
1111
1111
|
rel: "noopener noreferrer",
|
|
1112
|
-
"data-
|
|
1112
|
+
"data-testid": "edit-product-button",
|
|
1113
1113
|
children: [
|
|
1114
1114
|
/* @__PURE__ */ jsx18("span", { css: productPreviewListSmallText, children: "Edit" }),
|
|
1115
1115
|
logoIcon ? /* @__PURE__ */ jsx18(Image, { src: logoIcon, alt: "Logo", css: productPreviewListIcon }) : null
|
|
@@ -1393,7 +1393,7 @@ var DefaultSelectedItem = ({
|
|
|
1393
1393
|
` : ""
|
|
1394
1394
|
],
|
|
1395
1395
|
title: `ID: ${selectedItem.id}`,
|
|
1396
|
-
"data-
|
|
1396
|
+
"data-testid": "entry-id",
|
|
1397
1397
|
children: selectedItem.title || selectedItem.id || ""
|
|
1398
1398
|
}
|
|
1399
1399
|
),
|
|
@@ -1869,7 +1869,7 @@ var EntrySearch = ({
|
|
|
1869
1869
|
`,
|
|
1870
1870
|
children: [
|
|
1871
1871
|
showSearchBox ? /* @__PURE__ */ jsxs10(Fragment3, { children: [
|
|
1872
|
-
/* @__PURE__ */ jsx21("div", { css: entrySearchWrapper, "data-
|
|
1872
|
+
/* @__PURE__ */ jsx21("div", { css: entrySearchWrapper, "data-testid": "component-search", children: /* @__PURE__ */ jsxs10(
|
|
1873
1873
|
"button",
|
|
1874
1874
|
{
|
|
1875
1875
|
css: entrySearchBtn,
|
|
@@ -1966,7 +1966,7 @@ var EntrySearch = ({
|
|
|
1966
1966
|
id: listBoxId.current,
|
|
1967
1967
|
role: "listbox",
|
|
1968
1968
|
tabIndex: 0,
|
|
1969
|
-
"data-
|
|
1969
|
+
"data-testid": "entry-list",
|
|
1970
1970
|
children: [
|
|
1971
1971
|
/* @__PURE__ */ jsx21(LoadingOverlay, { isActive: showLoadingOverlay }),
|
|
1972
1972
|
Array.isArray(results) && results.length > 0 ? results.map((result) => /* @__PURE__ */ jsx21(
|
|
@@ -2029,7 +2029,7 @@ var EntrySearch = ({
|
|
|
2029
2029
|
{
|
|
2030
2030
|
disabled: !selectedListItems.length,
|
|
2031
2031
|
onClick: handleAcceptClick,
|
|
2032
|
-
"data-
|
|
2032
|
+
"data-testid": "entry-accept-button",
|
|
2033
2033
|
children: "Accept"
|
|
2034
2034
|
}
|
|
2035
2035
|
)
|
|
@@ -2680,15 +2680,7 @@ function DamSelectedItem({
|
|
|
2680
2680
|
children: /* @__PURE__ */ jsxs14("div", { css: damSelectedItemInner, children: [
|
|
2681
2681
|
/* @__PURE__ */ jsxs14("div", { css: damSelectedItemDetails, children: [
|
|
2682
2682
|
/* @__PURE__ */ jsxs14("div", { css: damSelectedItemCopy, children: [
|
|
2683
|
-
/* @__PURE__ */ jsx25(
|
|
2684
|
-
"h4",
|
|
2685
|
-
{
|
|
2686
|
-
css: [damSelectedItemTitle],
|
|
2687
|
-
title: `ID: ${selectedItem.id}`,
|
|
2688
|
-
"data-test-id": "dam-selected-item",
|
|
2689
|
-
children: selectedItem.title || selectedItem.id || ""
|
|
2690
|
-
}
|
|
2691
|
-
),
|
|
2683
|
+
/* @__PURE__ */ jsx25("h4", { css: [damSelectedItemTitle], title: `ID: ${selectedItem.id}`, "data-testid": "dam-selected-item", children: selectedItem.title || selectedItem.id || "" }),
|
|
2692
2684
|
selectedItem.popoverData ? /* @__PURE__ */ jsxs14("div", { ref: popoverRef, children: [
|
|
2693
2685
|
/* @__PURE__ */ jsx25(
|
|
2694
2686
|
"button",
|
|
@@ -3786,7 +3778,7 @@ var SelectVariableMenu = ({
|
|
|
3786
3778
|
ref: btnRef,
|
|
3787
3779
|
css: [menuBtn2, buttonCss],
|
|
3788
3780
|
type: "button",
|
|
3789
|
-
"data-
|
|
3781
|
+
"data-testid": "insert-variable",
|
|
3790
3782
|
children: /* @__PURE__ */ jsx32(CgUsbC, { size: "1.4rem" })
|
|
3791
3783
|
}
|
|
3792
3784
|
),
|
|
@@ -4074,7 +4066,7 @@ function InputVariables({
|
|
|
4074
4066
|
errorMessage,
|
|
4075
4067
|
warningMessage,
|
|
4076
4068
|
infoMessage,
|
|
4077
|
-
"data-
|
|
4069
|
+
"data-testid": dataTestId
|
|
4078
4070
|
}) {
|
|
4079
4071
|
const { variables } = useVariables(true);
|
|
4080
4072
|
const [finalId] = React11.useState(id != null ? id : () => v43());
|
|
@@ -4428,14 +4420,14 @@ function DataResourceVariablesListExplicit({
|
|
|
4428
4420
|
}
|
|
4429
4421
|
function TextVariableRenderer({ definition, value, setValue }) {
|
|
4430
4422
|
var _a;
|
|
4431
|
-
return /* @__PURE__ */ jsx39("div", { "data-
|
|
4423
|
+
return /* @__PURE__ */ jsx39("div", { "data-testid": "variable-input-container", children: /* @__PURE__ */ jsx39(
|
|
4432
4424
|
InputVariables,
|
|
4433
4425
|
{
|
|
4434
4426
|
label: definition.displayName || definition.name,
|
|
4435
4427
|
value: value != null ? value : "",
|
|
4436
4428
|
caption: (_a = definition.helpText) != null ? _a : definition.default !== "" ? `Default value: ${definition.default}` : void 0,
|
|
4437
4429
|
onChange: setValue,
|
|
4438
|
-
"data-
|
|
4430
|
+
"data-testid": "variable-input"
|
|
4439
4431
|
}
|
|
4440
4432
|
) });
|
|
4441
4433
|
}
|
|
@@ -4611,7 +4603,7 @@ function RequestBody() {
|
|
|
4611
4603
|
});
|
|
4612
4604
|
}
|
|
4613
4605
|
},
|
|
4614
|
-
"data-
|
|
4606
|
+
"data-testid": "body-select"
|
|
4615
4607
|
}
|
|
4616
4608
|
)
|
|
4617
4609
|
}
|
|
@@ -4699,7 +4691,7 @@ function RequestHeaders({ disableVariables }) {
|
|
|
4699
4691
|
dispatch({ type: "removeHeader", index });
|
|
4700
4692
|
}
|
|
4701
4693
|
},
|
|
4702
|
-
"data-
|
|
4694
|
+
"data-testid": "header-key"
|
|
4703
4695
|
}
|
|
4704
4696
|
) }),
|
|
4705
4697
|
/* @__PURE__ */ jsx43(TableCellData2, { width: "50%", children: header.key ? /* @__PURE__ */ jsx43(
|
|
@@ -4710,7 +4702,7 @@ function RequestHeaders({ disableVariables }) {
|
|
|
4710
4702
|
disableVariables,
|
|
4711
4703
|
showAddVariableMenuOption: true,
|
|
4712
4704
|
enableEditingVariables: true,
|
|
4713
|
-
"data-
|
|
4705
|
+
"data-testid": "header-value"
|
|
4714
4706
|
}
|
|
4715
4707
|
) : null })
|
|
4716
4708
|
] }, index);
|
|
@@ -4807,7 +4799,7 @@ function RequestParameters({ disableVariables }) {
|
|
|
4807
4799
|
dispatch({ type: "removeParameter", index });
|
|
4808
4800
|
}
|
|
4809
4801
|
},
|
|
4810
|
-
"data-
|
|
4802
|
+
"data-testid": "parameter-key"
|
|
4811
4803
|
}
|
|
4812
4804
|
) }),
|
|
4813
4805
|
/* @__PURE__ */ jsx45(TableCellData3, { width: "50%", children: parameter.key ? /* @__PURE__ */ jsx45(
|
|
@@ -4820,7 +4812,7 @@ function RequestParameters({ disableVariables }) {
|
|
|
4820
4812
|
index
|
|
4821
4813
|
}),
|
|
4822
4814
|
disableVariables,
|
|
4823
|
-
"data-
|
|
4815
|
+
"data-testid": "parameter-value",
|
|
4824
4816
|
showAddVariableMenuOption: true,
|
|
4825
4817
|
enableEditingVariables: true
|
|
4826
4818
|
}
|
|
@@ -4941,7 +4933,7 @@ function RequestUrlInput(props) {
|
|
|
4941
4933
|
},
|
|
4942
4934
|
showAddVariableMenuOption: true,
|
|
4943
4935
|
enableEditingVariables: true,
|
|
4944
|
-
"data-
|
|
4936
|
+
"data-testid": "field-url"
|
|
4945
4937
|
}
|
|
4946
4938
|
);
|
|
4947
4939
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@uniformdev/mesh-sdk-react",
|
|
3
|
-
"version": "19.
|
|
3
|
+
"version": "19.38.2",
|
|
4
4
|
"description": "Uniform Mesh Framework SDK for React",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE.txt",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -45,8 +45,8 @@
|
|
|
45
45
|
"dependencies": {
|
|
46
46
|
"@hookform/resolvers": "^3.0.1",
|
|
47
47
|
"@lexical/react": "^0.11.1",
|
|
48
|
-
"@uniformdev/design-system": "19.
|
|
49
|
-
"@uniformdev/mesh-sdk": "19.
|
|
48
|
+
"@uniformdev/design-system": "19.38.2",
|
|
49
|
+
"@uniformdev/mesh-sdk": "19.38.2",
|
|
50
50
|
"lexical": "^0.11.1",
|
|
51
51
|
"mitt": "^3.0.0",
|
|
52
52
|
"react-beautiful-dnd": "13.1.1",
|
|
@@ -80,5 +80,5 @@
|
|
|
80
80
|
"publishConfig": {
|
|
81
81
|
"access": "public"
|
|
82
82
|
},
|
|
83
|
-
"gitHead": "
|
|
83
|
+
"gitHead": "b97fd17fd44e0f5bd3806e942b516cb2bd218096"
|
|
84
84
|
}
|