@commercetools-frontend/experimental-components 8.1.0 → 8.1.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/commercetools-frontend-experimental-components.cjs.dev.js +258 -756
- package/dist/commercetools-frontend-experimental-components.cjs.prod.js +251 -733
- package/dist/commercetools-frontend-experimental-components.esm.js +257 -747
- package/dist/declarations/src/hooks/index.d.ts +0 -1
- package/dist/declarations/src/index.d.ts +3 -10
- package/dist/declarations/src/utils/products/products.d.ts +4 -3
- package/package.json +28 -28
- package/dist/declarations/src/components/carousel/carousel.d.ts +0 -32
- package/dist/declarations/src/components/carousel/index.d.ts +0 -2
- package/dist/declarations/src/components/centered-loading-spinner/centered-loading-spinner.d.ts +0 -9
- package/dist/declarations/src/components/centered-loading-spinner/index.d.ts +0 -1
- package/dist/declarations/src/components/divider/divider.d.ts +0 -12
- package/dist/declarations/src/components/divider/index.d.ts +0 -1
- package/dist/declarations/src/components/formatted-date-time/formatted-date-time.d.ts +0 -17
- package/dist/declarations/src/components/required-indicator/required-indicator.d.ts +0 -10
- package/dist/declarations/src/components/scroll-to-field-error/scroll-to-field-error.d.ts +0 -2
- package/dist/declarations/src/components/selectable-field-search-input/selectable-field-search-input.d.ts +0 -14
- package/dist/declarations/src/hooks/use-db-maintenance-notification/index.d.ts +0 -1
- package/dist/declarations/src/hooks/use-db-maintenance-notification/use-db-maintenance-notification.d.ts +0 -7
|
@@ -41,26 +41,18 @@ var fastEquals = require('fast-equals');
|
|
|
41
41
|
var jsxRuntime = require('@emotion/react/jsx-runtime');
|
|
42
42
|
var _trimInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/trim');
|
|
43
43
|
var designSystem = require('@commercetools-uikit/design-system');
|
|
44
|
-
var _Reflect$construct = require('@babel/runtime-corejs3/core-js-stable/reflect/construct');
|
|
45
|
-
var _classCallCheck = require('@babel/runtime-corejs3/helpers/classCallCheck');
|
|
46
|
-
var _createClass = require('@babel/runtime-corejs3/helpers/createClass');
|
|
47
|
-
var _possibleConstructorReturn = require('@babel/runtime-corejs3/helpers/possibleConstructorReturn');
|
|
48
|
-
var _getPrototypeOf = require('@babel/runtime-corejs3/helpers/getPrototypeOf');
|
|
49
|
-
var _inherits = require('@babel/runtime-corejs3/helpers/inherits');
|
|
50
|
-
var _sliceInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/slice');
|
|
51
|
-
var _someInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/some');
|
|
52
|
-
var oneLine = require('common-tags/lib/oneLine');
|
|
53
|
-
var moment$1 = require('moment-timezone');
|
|
54
44
|
var formik = require('formik');
|
|
55
45
|
var isNil$1 = require('lodash/isNil');
|
|
56
46
|
var omitBy = require('lodash/omitBy');
|
|
57
47
|
var _Array$isArray = require('@babel/runtime-corejs3/core-js-stable/array/is-array');
|
|
48
|
+
var _sliceInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/slice');
|
|
58
49
|
var _lastIndexOfInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/last-index-of');
|
|
59
50
|
var _parseInt = require('@babel/runtime-corejs3/core-js-stable/parse-int');
|
|
60
51
|
var merge = require('lodash/merge');
|
|
61
52
|
var set = require('lodash/set');
|
|
62
53
|
var times = require('lodash/times');
|
|
63
54
|
var uuid = require('uuid');
|
|
55
|
+
var merchantCenterSharedUi = require('@commercetools/merchant-center-shared-ui');
|
|
64
56
|
var _findInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/find');
|
|
65
57
|
var reselect = require('reselect');
|
|
66
58
|
var _endsWithInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/ends-with');
|
|
@@ -76,12 +68,18 @@ var _ = require('@commercetools-frontend/ui-kit/');
|
|
|
76
68
|
var PropTypes = require('prop-types');
|
|
77
69
|
var dnd = require('@hello-pangea/dnd');
|
|
78
70
|
var ReactDOM = require('react-dom');
|
|
79
|
-
var _indexOfInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/index-of');
|
|
80
71
|
var selectUtils = require('@commercetools-uikit/select-utils');
|
|
81
72
|
var utils = require('@commercetools-uikit/utils');
|
|
82
73
|
require('react-required-if');
|
|
74
|
+
var _someInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/some');
|
|
83
75
|
var _Object$values = require('@babel/runtime-corejs3/core-js-stable/object/values');
|
|
84
76
|
var _sortInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/sort');
|
|
77
|
+
var _Reflect$construct = require('@babel/runtime-corejs3/core-js-stable/reflect/construct');
|
|
78
|
+
var _classCallCheck = require('@babel/runtime-corejs3/helpers/classCallCheck');
|
|
79
|
+
var _createClass = require('@babel/runtime-corejs3/helpers/createClass');
|
|
80
|
+
var _possibleConstructorReturn = require('@babel/runtime-corejs3/helpers/possibleConstructorReturn');
|
|
81
|
+
var _getPrototypeOf = require('@babel/runtime-corejs3/helpers/getPrototypeOf');
|
|
82
|
+
var _inherits = require('@babel/runtime-corejs3/helpers/inherits');
|
|
85
83
|
var classnames = require('classnames');
|
|
86
84
|
var commonTags = require('common-tags');
|
|
87
85
|
var has = require('lodash/has');
|
|
@@ -90,6 +88,7 @@ var _concatInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/ins
|
|
|
90
88
|
var _Math$trunc = require('@babel/runtime-corejs3/core-js-stable/math/trunc');
|
|
91
89
|
var _Number$isNaN = require('@babel/runtime-corejs3/core-js-stable/number/is-nan');
|
|
92
90
|
var Cleave = require('cleave.js/react');
|
|
91
|
+
var oneLine = require('common-tags/lib/oneLine');
|
|
93
92
|
var isFinite = require('lodash/isFinite');
|
|
94
93
|
var isUndefined = require('lodash/isUndefined');
|
|
95
94
|
var camelCase = require('lodash/camelCase');
|
|
@@ -102,14 +101,12 @@ var originalOmitDeep = require('omit-deep');
|
|
|
102
101
|
var compact = require('lodash/compact');
|
|
103
102
|
var _Set = require('@babel/runtime-corejs3/core-js-stable/set');
|
|
104
103
|
var flatMap = require('lodash/flatMap');
|
|
104
|
+
var moment$1 = require('moment-timezone');
|
|
105
105
|
require('@babel/runtime-corejs3/helpers/get');
|
|
106
106
|
var _Date$now = require('@babel/runtime-corejs3/core-js-stable/date/now');
|
|
107
107
|
var _spliceInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/splice');
|
|
108
108
|
var memoize = require('memoize-one');
|
|
109
109
|
var omitEmpty = require('omit-empty-es');
|
|
110
|
-
var shuffle = require('lodash/shuffle');
|
|
111
|
-
var reactSnapCarousel = require('react-snap-carousel');
|
|
112
|
-
var applicationShell = require('@commercetools-frontend/application-shell');
|
|
113
110
|
var hoc = require('@apollo/client/react/hoc');
|
|
114
111
|
var flatten = require('lodash/flatten');
|
|
115
112
|
var flowRight = require('lodash/flowRight');
|
|
@@ -118,7 +115,9 @@ var invariant = require('tiny-invariant');
|
|
|
118
115
|
var hoistNonReactStatics = require('hoist-non-react-statics');
|
|
119
116
|
var hooks = require('@apollo/client/react/hooks');
|
|
120
117
|
var reactRedux = require('react-redux');
|
|
118
|
+
var applicationShell = require('@commercetools-frontend/application-shell');
|
|
121
119
|
var get = require('lodash/get');
|
|
120
|
+
var _indexOfInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/index-of');
|
|
122
121
|
|
|
123
122
|
function _interopDefault (e) { return e && e.__esModule ? e : { 'default': e }; }
|
|
124
123
|
|
|
@@ -165,14 +164,10 @@ var _Promise__default = /*#__PURE__*/_interopDefault(_Promise);
|
|
|
165
164
|
var _setTimeout__default = /*#__PURE__*/_interopDefault(_setTimeout);
|
|
166
165
|
var _bindInstanceProperty__default = /*#__PURE__*/_interopDefault(_bindInstanceProperty);
|
|
167
166
|
var _trimInstanceProperty__default = /*#__PURE__*/_interopDefault(_trimInstanceProperty);
|
|
168
|
-
var _Reflect$construct__default = /*#__PURE__*/_interopDefault(_Reflect$construct);
|
|
169
|
-
var _sliceInstanceProperty__default = /*#__PURE__*/_interopDefault(_sliceInstanceProperty);
|
|
170
|
-
var _someInstanceProperty__default = /*#__PURE__*/_interopDefault(_someInstanceProperty);
|
|
171
|
-
var oneLine__default = /*#__PURE__*/_interopDefault(oneLine);
|
|
172
|
-
var moment__default$1 = /*#__PURE__*/_interopDefault(moment$1);
|
|
173
167
|
var isNil__default = /*#__PURE__*/_interopDefault(isNil$1);
|
|
174
168
|
var omitBy__default = /*#__PURE__*/_interopDefault(omitBy);
|
|
175
169
|
var _Array$isArray__default = /*#__PURE__*/_interopDefault(_Array$isArray);
|
|
170
|
+
var _sliceInstanceProperty__default = /*#__PURE__*/_interopDefault(_sliceInstanceProperty);
|
|
176
171
|
var _lastIndexOfInstanceProperty__default = /*#__PURE__*/_interopDefault(_lastIndexOfInstanceProperty);
|
|
177
172
|
var _parseInt__default = /*#__PURE__*/_interopDefault(_parseInt);
|
|
178
173
|
var merge__default = /*#__PURE__*/_interopDefault(merge);
|
|
@@ -185,15 +180,17 @@ var debounce__default = /*#__PURE__*/_interopDefault(debounce);
|
|
|
185
180
|
var keyBy__default = /*#__PURE__*/_interopDefault(keyBy);
|
|
186
181
|
var PropTypes__default = /*#__PURE__*/_interopDefault(PropTypes);
|
|
187
182
|
var ReactDOM__default = /*#__PURE__*/_interopDefault(ReactDOM);
|
|
188
|
-
var
|
|
183
|
+
var _someInstanceProperty__default = /*#__PURE__*/_interopDefault(_someInstanceProperty);
|
|
189
184
|
var _Object$values__default = /*#__PURE__*/_interopDefault(_Object$values);
|
|
190
185
|
var _sortInstanceProperty__default = /*#__PURE__*/_interopDefault(_sortInstanceProperty);
|
|
186
|
+
var _Reflect$construct__default = /*#__PURE__*/_interopDefault(_Reflect$construct);
|
|
191
187
|
var classnames__default = /*#__PURE__*/_interopDefault(classnames);
|
|
192
188
|
var has__default = /*#__PURE__*/_interopDefault(has);
|
|
193
189
|
var _concatInstanceProperty__default = /*#__PURE__*/_interopDefault(_concatInstanceProperty);
|
|
194
190
|
var _Math$trunc__default = /*#__PURE__*/_interopDefault(_Math$trunc);
|
|
195
191
|
var _Number$isNaN__default = /*#__PURE__*/_interopDefault(_Number$isNaN);
|
|
196
192
|
var Cleave__default = /*#__PURE__*/_interopDefault(Cleave);
|
|
193
|
+
var oneLine__default = /*#__PURE__*/_interopDefault(oneLine);
|
|
197
194
|
var isFinite__default = /*#__PURE__*/_interopDefault(isFinite);
|
|
198
195
|
var isUndefined__default = /*#__PURE__*/_interopDefault(isUndefined);
|
|
199
196
|
var camelCase__default = /*#__PURE__*/_interopDefault(camelCase);
|
|
@@ -206,29 +203,18 @@ var originalOmitDeep__default = /*#__PURE__*/_interopDefault(originalOmitDeep);
|
|
|
206
203
|
var compact__default = /*#__PURE__*/_interopDefault(compact);
|
|
207
204
|
var _Set__default = /*#__PURE__*/_interopDefault(_Set);
|
|
208
205
|
var flatMap__default = /*#__PURE__*/_interopDefault(flatMap);
|
|
206
|
+
var moment__default$1 = /*#__PURE__*/_interopDefault(moment$1);
|
|
209
207
|
var _Date$now__default = /*#__PURE__*/_interopDefault(_Date$now);
|
|
210
208
|
var _spliceInstanceProperty__default = /*#__PURE__*/_interopDefault(_spliceInstanceProperty);
|
|
211
209
|
var memoize__default = /*#__PURE__*/_interopDefault(memoize);
|
|
212
210
|
var omitEmpty__default = /*#__PURE__*/_interopDefault(omitEmpty);
|
|
213
|
-
var shuffle__default = /*#__PURE__*/_interopDefault(shuffle);
|
|
214
211
|
var flatten__default = /*#__PURE__*/_interopDefault(flatten);
|
|
215
212
|
var flowRight__default = /*#__PURE__*/_interopDefault(flowRight);
|
|
216
213
|
var uniqBy__default = /*#__PURE__*/_interopDefault(uniqBy);
|
|
217
214
|
var invariant__default = /*#__PURE__*/_interopDefault(invariant);
|
|
218
215
|
var hoistNonReactStatics__default = /*#__PURE__*/_interopDefault(hoistNonReactStatics);
|
|
219
216
|
var get__default = /*#__PURE__*/_interopDefault(get);
|
|
220
|
-
|
|
221
|
-
var _ref$f = {
|
|
222
|
-
name: "1tmmbhs",
|
|
223
|
-
styles: "height:100%;display:flex;flex-grow:1;align-items:center;justify-content:center"
|
|
224
|
-
} ;
|
|
225
|
-
const CenteredLoadingSpinner = () => jsxRuntime.jsx("div", {
|
|
226
|
-
css: _ref$f,
|
|
227
|
-
"data-testid": "centered-loading-spinner",
|
|
228
|
-
children: jsxRuntime.jsx(uiKit.LoadingSpinner, {})
|
|
229
|
-
});
|
|
230
|
-
CenteredLoadingSpinner.displayName = 'CenteredLoadingSpinner';
|
|
231
|
-
var CenteredLoadingSpinner$1 = CenteredLoadingSpinner;
|
|
217
|
+
var _indexOfInstanceProperty__default = /*#__PURE__*/_interopDefault(_indexOfInstanceProperty);
|
|
232
218
|
|
|
233
219
|
const LOWER_STORES_LIMIT = 60;
|
|
234
220
|
const UPPER_STORES_LIMIT = 500;
|
|
@@ -298,7 +284,7 @@ var commonPickerMessages = reactIntl.defineMessages({
|
|
|
298
284
|
}
|
|
299
285
|
});
|
|
300
286
|
|
|
301
|
-
var messages$
|
|
287
|
+
var messages$Q = reactIntl.defineMessages({
|
|
302
288
|
noChannelsFound: {
|
|
303
289
|
id: 'Products.ChannelPickerInput.noChannelsFound',
|
|
304
290
|
description: 'The message to display when no channels were found',
|
|
@@ -311,8 +297,8 @@ var messages$S = reactIntl.defineMessages({
|
|
|
311
297
|
}
|
|
312
298
|
});
|
|
313
299
|
|
|
314
|
-
function ownKeys$
|
|
315
|
-
function _objectSpread$
|
|
300
|
+
function ownKeys$1t(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
301
|
+
function _objectSpread$1t(e) { for (var r = 1; r < arguments.length; r++) { var _context2, _context3; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context2 = ownKeys$1t(Object(t), !0)).call(_context2, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context3 = ownKeys$1t(Object(t))).call(_context3, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
316
302
|
var GetChannelsQuery = { kind: "Document", definitions: [{ kind: "OperationDefinition", operation: "query", name: { kind: "Name", value: "GetChannelsQuery" }, variableDefinitions: [{ kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "where" } }, type: { kind: "NamedType", name: { kind: "Name", value: "String" } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "sortByNamePath" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "String" } } }, directives: [] }], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "channels" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "where" }, value: { kind: "Variable", name: { kind: "Name", value: "where" } } }, { kind: "Argument", name: { kind: "Name", value: "sort" }, value: { kind: "ListValue", values: [{ kind: "Variable", name: { kind: "Name", value: "sortByNamePath" } }, { kind: "StringValue", value: "key", block: false }] } }, { kind: "Argument", name: { kind: "Name", value: "limit" }, value: { kind: "IntValue", value: "60" } }], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "total" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "results" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "FragmentSpread", name: { kind: "Name", value: "PickerInputChannel" }, directives: [] }] } }] } }] } }, { kind: "FragmentDefinition", name: { kind: "Name", value: "PickerInputChannel" }, typeCondition: { kind: "NamedType", name: { kind: "Name", value: "Channel" } }, directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "id" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "key" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "nameAllLocales" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "locale" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "value" }, arguments: [], directives: [] }] } }] } }], loc: { start: 0, end: 392, source: { body: "fragment PickerInputChannel on Channel {\n id\n key\n nameAllLocales {\n locale\n value\n }\n}\n\nquery GetChannelsQuery($where: String, $sortByNamePath: String!) {\n channels(where: $where, sort: [$sortByNamePath, \"key\"], limit: 60) {\n total\n results {\n ...PickerInputChannel\n }\n }\n}\n\nquery GetChannelQuery($id: String) {\n channel(id: $id) {\n ...PickerInputChannel\n }\n}\n", name: "GraphQL request", locationOffset: { line: 1, column: 1 } } } };
|
|
317
303
|
var GetChannelQuery = { kind: "Document", definitions: [{ kind: "OperationDefinition", operation: "query", name: { kind: "Name", value: "GetChannelQuery" }, variableDefinitions: [{ kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "id" } }, type: { kind: "NamedType", name: { kind: "Name", value: "String" } }, directives: [] }], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "channel" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "id" }, value: { kind: "Variable", name: { kind: "Name", value: "id" } } }], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "FragmentSpread", name: { kind: "Name", value: "PickerInputChannel" }, directives: [] }] } }] } }, { kind: "FragmentDefinition", name: { kind: "Name", value: "PickerInputChannel" }, typeCondition: { kind: "NamedType", name: { kind: "Name", value: "Channel" } }, directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "id" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "key" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "nameAllLocales" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "locale" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "value" }, arguments: [], directives: [] }] } }] } }], loc: { start: 0, end: 392, source: { body: "fragment PickerInputChannel on Channel {\n id\n key\n nameAllLocales {\n locale\n value\n }\n}\n\nquery GetChannelsQuery($where: String, $sortByNamePath: String!) {\n channels(where: $where, sort: [$sortByNamePath, \"key\"], limit: 60) {\n total\n results {\n ...PickerInputChannel\n }\n }\n}\n\nquery GetChannelQuery($id: String) {\n channel(id: $id) {\n ...PickerInputChannel\n }\n}\n", name: "GraphQL request", locationOffset: { line: 1, column: 1 } } } };
|
|
318
304
|
var PickerInputChannel = { kind: "Document", definitions: [{ kind: "FragmentDefinition", name: { kind: "Name", value: "PickerInputChannel" }, typeCondition: { kind: "NamedType", name: { kind: "Name", value: "Channel" } }, directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "id" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "key" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "nameAllLocales" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "locale" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "value" }, arguments: [], directives: [] }] } }] } }], loc: { start: 0, end: 392, source: { body: "fragment PickerInputChannel on Channel {\n id\n key\n nameAllLocales {\n locale\n value\n }\n}\n\nquery GetChannelsQuery($where: String, $sortByNamePath: String!) {\n channels(where: $where, sort: [$sortByNamePath, \"key\"], limit: 60) {\n total\n results {\n ...PickerInputChannel\n }\n }\n}\n\nquery GetChannelQuery($id: String) {\n channel(id: $id) {\n ...PickerInputChannel\n }\n}\n", name: "GraphQL request", locationOffset: { line: 1, column: 1 } } } };
|
|
@@ -341,7 +327,7 @@ const ChannelPickerInput = _ref => {
|
|
|
341
327
|
const dataLocale = applicationShellConnectors.useApplicationContext(applicationContext => applicationContext.dataLocale);
|
|
342
328
|
const variables = React.useMemo(() => {
|
|
343
329
|
const rolesClause = getRolesClause(roles);
|
|
344
|
-
return _objectSpread$
|
|
330
|
+
return _objectSpread$1t({
|
|
345
331
|
sortByNamePath: `name.${dataLocale}`
|
|
346
332
|
}, rolesClause && {
|
|
347
333
|
extraWhere: rolesClause
|
|
@@ -417,7 +403,7 @@ const ChannelPickerInput = _ref => {
|
|
|
417
403
|
if (isCurrentOptionLoadingFailed && onError) onError(currentOptions.error);
|
|
418
404
|
}, [isCurrentOptionLoadingFailed, onError, currentOptions]);
|
|
419
405
|
const isLoadingFailed = isCurrentOptionLoadingFailed || Boolean(loadingError);
|
|
420
|
-
const handleNoOptions = React.useCallback(() => loadingError ? null : formatMessage(messages$
|
|
406
|
+
const handleNoOptions = React.useCallback(() => loadingError ? null : formatMessage(messages$Q.noChannelsFound), [loadingError, formatMessage]);
|
|
421
407
|
const tooltipTitle = !isMulti ? currentSingleOption?.data?.label ?? '' : '';
|
|
422
408
|
const selectedValue = currentOptions.data ?? (isMulti ? [] : null);
|
|
423
409
|
return jsxRuntime.jsx(uiKit.Constraints.Horizontal, {
|
|
@@ -429,7 +415,7 @@ const ChannelPickerInput = _ref => {
|
|
|
429
415
|
children: jsxRuntime.jsx(uiKit.AsyncSelectInput, {
|
|
430
416
|
id: name,
|
|
431
417
|
name: name,
|
|
432
|
-
placeholder: placeholder ?? formatMessage(messages$
|
|
418
|
+
placeholder: placeholder ?? formatMessage(messages$Q.placeholder),
|
|
433
419
|
loadOptions: loadOptionsDebounced,
|
|
434
420
|
defaultOptions: true,
|
|
435
421
|
showOptionGroupDivider: true,
|
|
@@ -459,33 +445,7 @@ const ChannelPickerInput = _ref => {
|
|
|
459
445
|
};
|
|
460
446
|
var ChannelPickerInput$1 = ChannelPickerInput;
|
|
461
447
|
|
|
462
|
-
|
|
463
|
-
function _isNativeReflectConstruct$7() { try { var t = !Boolean.prototype.valueOf.call(_Reflect$construct__default["default"](Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct$7 = function () { return !!t; })(); }
|
|
464
|
-
let FormattedDateTime = /*#__PURE__*/function (_PureComponent) {
|
|
465
|
-
function FormattedDateTime() {
|
|
466
|
-
_classCallCheck(this, FormattedDateTime);
|
|
467
|
-
return _callSuper$7(this, FormattedDateTime, arguments);
|
|
468
|
-
}
|
|
469
|
-
_inherits(FormattedDateTime, _PureComponent);
|
|
470
|
-
return _createClass(FormattedDateTime, [{
|
|
471
|
-
key: "render",
|
|
472
|
-
value: function render() {
|
|
473
|
-
return jsxRuntime.jsx(applicationShellConnectors.ApplicationContext, {
|
|
474
|
-
render: _ref => {
|
|
475
|
-
let user = _ref.user;
|
|
476
|
-
return formatDateTime$1(this.props.type, this.props.value, {
|
|
477
|
-
timeZone: this?.props?.timeZone || user?.timeZone,
|
|
478
|
-
locale: this.props.intl.locale
|
|
479
|
-
});
|
|
480
|
-
}
|
|
481
|
-
});
|
|
482
|
-
}
|
|
483
|
-
}]);
|
|
484
|
-
}(React.PureComponent);
|
|
485
|
-
FormattedDateTime.displayName = 'FormattedDateTime';
|
|
486
|
-
var FormattedDateTime$1 = reactIntl.injectIntl(FormattedDateTime);
|
|
487
|
-
|
|
488
|
-
var messages$R = reactIntl.defineMessages({
|
|
448
|
+
var messages$P = reactIntl.defineMessages({
|
|
489
449
|
noProductTypesFound: {
|
|
490
450
|
id: 'Products.ProductTypePickerInput.noProductTypesFound',
|
|
491
451
|
description: 'The message to display when no product types were found',
|
|
@@ -567,14 +527,14 @@ const ProductTypePickerInput = _ref => {
|
|
|
567
527
|
const tooltipTitle = currentOption?.data?.label ?? '';
|
|
568
528
|
return jsxRuntime.jsx(uiKit.Constraints.Horizontal, {
|
|
569
529
|
max: "scale",
|
|
570
|
-
children: currentOption.loading ? jsxRuntime.jsx(CenteredLoadingSpinner
|
|
530
|
+
children: currentOption.loading ? jsxRuntime.jsx(merchantCenterSharedUi.CenteredLoadingSpinner, {}) : jsxRuntime.jsxs(uiKit.Spacings.Stack, {
|
|
571
531
|
scale: "xs",
|
|
572
532
|
children: [jsxRuntime.jsx(CustomFieldTooltip$1, {
|
|
573
533
|
title: tooltipTitle,
|
|
574
534
|
children: jsxRuntime.jsx(uiKit.AsyncSelectInput, {
|
|
575
535
|
id: name,
|
|
576
536
|
name: name,
|
|
577
|
-
placeholder: formatMessage(messages$
|
|
537
|
+
placeholder: formatMessage(messages$P.placeholder),
|
|
578
538
|
loadOptions: loadOptionsDebounced,
|
|
579
539
|
defaultOptions: [],
|
|
580
540
|
isClearable: isClearable,
|
|
@@ -587,7 +547,7 @@ const ProductTypePickerInput = _ref => {
|
|
|
587
547
|
onInputChange: handleInputChange,
|
|
588
548
|
onBlur: onBlur,
|
|
589
549
|
value: currentOption.data,
|
|
590
|
-
noOptionsMessage: () => loadingError ? null : formatMessage(messages$
|
|
550
|
+
noOptionsMessage: () => loadingError ? null : formatMessage(messages$P.noProductTypesFound),
|
|
591
551
|
hasError: hasError || isLoadingFailed,
|
|
592
552
|
menuPortalZIndex: Z_INDEX_DROPDOWN,
|
|
593
553
|
menuPortalTarget: document.body,
|
|
@@ -603,7 +563,7 @@ const ProductTypePickerInput = _ref => {
|
|
|
603
563
|
ProductTypePickerInput.displayName = 'ProductTypePickerInput';
|
|
604
564
|
var ProductTypePickerInput$1 = ProductTypePickerInput;
|
|
605
565
|
|
|
606
|
-
var messages$
|
|
566
|
+
var messages$O = reactIntl.defineMessages({
|
|
607
567
|
noStatesFound: {
|
|
608
568
|
id: 'Products.StatePickerInput.noStatesFound',
|
|
609
569
|
description: 'The message to display when no states were found',
|
|
@@ -687,11 +647,11 @@ const StatePickerInput = _ref => {
|
|
|
687
647
|
if (isCurrentOptionLoadingFailed) onError(currentOption.error);
|
|
688
648
|
}, [isCurrentOptionLoadingFailed, onError, currentOption]);
|
|
689
649
|
const isLoadingFailed = isCurrentOptionLoadingFailed || Boolean(loadingError);
|
|
690
|
-
const handleNoOptions = React.useCallback(() => loadingError ? null : formatMessage(messages$
|
|
650
|
+
const handleNoOptions = React.useCallback(() => loadingError ? null : formatMessage(messages$O.noStatesFound), [loadingError, formatMessage]);
|
|
691
651
|
const tooltipTitle = currentOption?.data?.label ?? '';
|
|
692
652
|
return jsxRuntime.jsx(uiKit.Constraints.Horizontal, {
|
|
693
653
|
max: "scale",
|
|
694
|
-
children: currentOption.loading ? jsxRuntime.jsx(CenteredLoadingSpinner
|
|
654
|
+
children: currentOption.loading ? jsxRuntime.jsx(merchantCenterSharedUi.CenteredLoadingSpinner, {}) : jsxRuntime.jsxs(uiKit.Spacings.Stack, {
|
|
695
655
|
scale: "xs",
|
|
696
656
|
children: [jsxRuntime.jsx(CustomFieldTooltip$1, {
|
|
697
657
|
title: tooltipTitle,
|
|
@@ -699,7 +659,7 @@ const StatePickerInput = _ref => {
|
|
|
699
659
|
id: name,
|
|
700
660
|
name: name,
|
|
701
661
|
horizontalConstraint: "scale",
|
|
702
|
-
placeholder: formatMessage(messages$
|
|
662
|
+
placeholder: formatMessage(messages$O.placeholder),
|
|
703
663
|
loadOptions: loadOptionsDebounced,
|
|
704
664
|
defaultOptions: true,
|
|
705
665
|
showOptionGroupDivider: true,
|
|
@@ -729,9 +689,9 @@ const StatePickerInput = _ref => {
|
|
|
729
689
|
StatePickerInput.displayName = 'StatePickerInput';
|
|
730
690
|
var StatePickerInput$1 = StatePickerInput;
|
|
731
691
|
|
|
732
|
-
function ownKeys$
|
|
733
|
-
function _objectSpread$
|
|
734
|
-
const TooltipWrapper = /*#__PURE__*/React__namespace["default"].forwardRef((props, ref) => jsxRuntime.jsx("div", _objectSpread$
|
|
692
|
+
function ownKeys$1s(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
693
|
+
function _objectSpread$1s(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$1s(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$1s(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
694
|
+
const TooltipWrapper = /*#__PURE__*/React__namespace["default"].forwardRef((props, ref) => jsxRuntime.jsx("div", _objectSpread$1s({
|
|
735
695
|
ref: ref,
|
|
736
696
|
style: {
|
|
737
697
|
display: 'block',
|
|
@@ -756,7 +716,7 @@ const CustomFieldTooltip = _ref => {
|
|
|
756
716
|
};
|
|
757
717
|
var CustomFieldTooltip$1 = CustomFieldTooltip;
|
|
758
718
|
|
|
759
|
-
var messages$
|
|
719
|
+
var messages$N = reactIntl.defineMessages({
|
|
760
720
|
bottomOption: {
|
|
761
721
|
id: 'Products.Pickers.bottomOption',
|
|
762
722
|
description: 'The message to display at the end of the options menu',
|
|
@@ -764,11 +724,11 @@ var messages$P = reactIntl.defineMessages({
|
|
|
764
724
|
}
|
|
765
725
|
});
|
|
766
726
|
|
|
767
|
-
function ownKeys$
|
|
768
|
-
function _objectSpread$
|
|
727
|
+
function ownKeys$1r(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
728
|
+
function _objectSpread$1r(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$1r(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$1r(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
769
729
|
const getBottomOption = formatMessage => ({
|
|
770
730
|
options: [{
|
|
771
|
-
label: formatMessage ? formatMessage(messages$
|
|
731
|
+
label: formatMessage ? formatMessage(messages$N.bottomOption) : messages$N.bottomOption,
|
|
772
732
|
isBottomOption: true,
|
|
773
733
|
isDisabled: true
|
|
774
734
|
}]
|
|
@@ -776,7 +736,7 @@ const getBottomOption = formatMessage => ({
|
|
|
776
736
|
const Option$2 = props => {
|
|
777
737
|
const _useIntl = reactIntl.useIntl(),
|
|
778
738
|
formatMessage = _useIntl.formatMessage;
|
|
779
|
-
return jsxRuntime.jsx(uiKit.AsyncSelectInput.Option, _objectSpread$
|
|
739
|
+
return jsxRuntime.jsx(uiKit.AsyncSelectInput.Option, _objectSpread$1r(_objectSpread$1r({}, props), {}, {
|
|
780
740
|
children: props.data.isBottomOption ? jsxRuntime.jsx(uiKit.Text.Detail, {
|
|
781
741
|
tone: "secondary",
|
|
782
742
|
children: formatMessage(props.data.label)
|
|
@@ -793,8 +753,8 @@ const Option$2 = props => {
|
|
|
793
753
|
};
|
|
794
754
|
Option$2.displayName = 'Option';
|
|
795
755
|
|
|
796
|
-
function ownKeys$
|
|
797
|
-
function _objectSpread$
|
|
756
|
+
function ownKeys$1q(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
757
|
+
function _objectSpread$1q(e) { for (var r = 1; r < arguments.length; r++) { var _context2, _context3; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context2 = ownKeys$1q(Object(t), !0)).call(_context2, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context3 = ownKeys$1q(Object(t))).call(_context3, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
798
758
|
const useHandlers = onChange => {
|
|
799
759
|
const _useState = React.useState(),
|
|
800
760
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -805,8 +765,8 @@ const useHandlers = onChange => {
|
|
|
805
765
|
}, []);
|
|
806
766
|
const handleChange = useEventCallback$1(event => {
|
|
807
767
|
var _context;
|
|
808
|
-
const eventWithExtractedValue = _objectSpread$
|
|
809
|
-
target: _objectSpread$
|
|
768
|
+
const eventWithExtractedValue = _objectSpread$1q(_objectSpread$1q({}, event), {}, {
|
|
769
|
+
target: _objectSpread$1q(_objectSpread$1q({}, event.target), {}, {
|
|
810
770
|
value: _Array$isArray__default["default"](event.target.value) ? _mapInstanceProperty__default["default"](_context = event.target.value).call(_context, item => item?.value) : event.target.value?.value
|
|
811
771
|
})
|
|
812
772
|
});
|
|
@@ -816,9 +776,9 @@ const useHandlers = onChange => {
|
|
|
816
776
|
};
|
|
817
777
|
var useHandlers$1 = useHandlers;
|
|
818
778
|
|
|
819
|
-
const _excluded$
|
|
820
|
-
function ownKeys$
|
|
821
|
-
function _objectSpread$
|
|
779
|
+
const _excluded$d = ["extraWhere"];
|
|
780
|
+
function ownKeys$1p(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
781
|
+
function _objectSpread$1p(e) { for (var r = 1; r < arguments.length; r++) { var _context3, _context4; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context3 = ownKeys$1p(Object(t), !0)).call(_context3, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context4 = ownKeys$1p(Object(t))).call(_context4, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
822
782
|
function _arrayLikeToArray$1(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
|
|
823
783
|
const constructPrefixSearchPredicate$1 = function () {
|
|
824
784
|
let prefixSearchFields = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
|
|
@@ -860,13 +820,13 @@ const useLoadOptions = _ref => {
|
|
|
860
820
|
}
|
|
861
821
|
const _ref2 = variables ?? {},
|
|
862
822
|
extraWhere = _ref2.extraWhere,
|
|
863
|
-
restVariables = _objectWithoutProperties(_ref2, _excluded$
|
|
823
|
+
restVariables = _objectWithoutProperties(_ref2, _excluded$d);
|
|
864
824
|
if (typeof extraWhere === 'string') {
|
|
865
825
|
where = where ? `(${where}) and ${variables.extraWhere}` : variables.extraWhere;
|
|
866
826
|
}
|
|
867
827
|
return client$1.query({
|
|
868
828
|
query,
|
|
869
|
-
variables: _objectSpread$
|
|
829
|
+
variables: _objectSpread$1p({
|
|
870
830
|
where
|
|
871
831
|
}, restVariables),
|
|
872
832
|
context: {
|
|
@@ -1169,8 +1129,8 @@ var setDisplayName$1 = setDisplayName;
|
|
|
1169
1129
|
const wrapDisplayName = (BaseComponent, hocName) => `${hocName}(${getDisplayName$1(BaseComponent)})`;
|
|
1170
1130
|
var wrapDisplayName$1 = wrapDisplayName;
|
|
1171
1131
|
|
|
1172
|
-
function ownKeys$
|
|
1173
|
-
function _objectSpread$
|
|
1132
|
+
function ownKeys$1o(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
1133
|
+
function _objectSpread$1o(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$1o(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$1o(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
1174
1134
|
const injectDataTablePaginationState = initialValues => Component => {
|
|
1175
1135
|
const WithDataTablePaginationState = props => {
|
|
1176
1136
|
const _usePaginationState = uiKit.usePaginationState({
|
|
@@ -1183,7 +1143,7 @@ const injectDataTablePaginationState = initialValues => Component => {
|
|
|
1183
1143
|
key: initialValues?.tableSorting?.key,
|
|
1184
1144
|
order: initialValues?.tableSorting?.order
|
|
1185
1145
|
});
|
|
1186
|
-
return jsxRuntime.jsx(Component, _objectSpread$
|
|
1146
|
+
return jsxRuntime.jsx(Component, _objectSpread$1o(_objectSpread$1o({}, props), {}, {
|
|
1187
1147
|
dataTablePaginationState: {
|
|
1188
1148
|
page,
|
|
1189
1149
|
perPage,
|
|
@@ -1196,8 +1156,8 @@ const injectDataTablePaginationState = initialValues => Component => {
|
|
|
1196
1156
|
};
|
|
1197
1157
|
var injectDataTablePaginationState$1 = injectDataTablePaginationState;
|
|
1198
1158
|
|
|
1199
|
-
function ownKeys$
|
|
1200
|
-
function _objectSpread$
|
|
1159
|
+
function ownKeys$1n(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
1160
|
+
function _objectSpread$1n(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$1n(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$1n(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
1201
1161
|
const injectNotifications = function () {
|
|
1202
1162
|
let propName = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'notifications';
|
|
1203
1163
|
return Component => {
|
|
@@ -1212,7 +1172,7 @@ const injectNotifications = function () {
|
|
|
1212
1172
|
onActionError,
|
|
1213
1173
|
hideAllPageNotifications
|
|
1214
1174
|
};
|
|
1215
|
-
return jsxRuntime.jsx(Component, _objectSpread$
|
|
1175
|
+
return jsxRuntime.jsx(Component, _objectSpread$1n(_objectSpread$1n({}, props), {}, {
|
|
1216
1176
|
[propName]: notifications
|
|
1217
1177
|
}));
|
|
1218
1178
|
};
|
|
@@ -1222,23 +1182,23 @@ const injectNotifications = function () {
|
|
|
1222
1182
|
};
|
|
1223
1183
|
var injectNotifications$1 = injectNotifications;
|
|
1224
1184
|
|
|
1225
|
-
function ownKeys$
|
|
1226
|
-
function _objectSpread$
|
|
1185
|
+
function ownKeys$1m(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
1186
|
+
function _objectSpread$1m(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$1m(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$1m(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
1227
1187
|
function isPropsMapper(mapProps) {
|
|
1228
1188
|
return typeof mapProps === 'function';
|
|
1229
1189
|
}
|
|
1230
1190
|
const withProps = mapProps => Component => {
|
|
1231
1191
|
const EnhancedWithProps = ownProps => {
|
|
1232
|
-
const enhancedProps = isPropsMapper(mapProps) ? _objectSpread$
|
|
1233
|
-
return jsxRuntime.jsx(Component, _objectSpread$
|
|
1192
|
+
const enhancedProps = isPropsMapper(mapProps) ? _objectSpread$1m(_objectSpread$1m({}, ownProps), mapProps(ownProps)) : _objectSpread$1m(_objectSpread$1m({}, ownProps), mapProps);
|
|
1193
|
+
return jsxRuntime.jsx(Component, _objectSpread$1m({}, enhancedProps));
|
|
1234
1194
|
};
|
|
1235
1195
|
EnhancedWithProps.displayName = wrapDisplayName$1(Component, 'withProps');
|
|
1236
1196
|
return EnhancedWithProps;
|
|
1237
1197
|
};
|
|
1238
1198
|
var withProps$1 = withProps;
|
|
1239
1199
|
|
|
1240
|
-
function ownKeys$
|
|
1241
|
-
function _objectSpread$
|
|
1200
|
+
function ownKeys$1l(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
1201
|
+
function _objectSpread$1l(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$1l(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$1l(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
1242
1202
|
const useRedirectEffect = _ref => {
|
|
1243
1203
|
let goTo = _ref.goTo;
|
|
1244
1204
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
@@ -1258,31 +1218,31 @@ const defaultOptions$5 = {
|
|
|
1258
1218
|
skip: () => false
|
|
1259
1219
|
};
|
|
1260
1220
|
const withRedirectTo = options => Component => {
|
|
1261
|
-
const mergedOptions = _objectSpread$
|
|
1221
|
+
const mergedOptions = _objectSpread$1l(_objectSpread$1l({}, defaultOptions$5), options);
|
|
1262
1222
|
const WithRedirectTo = props => {
|
|
1263
1223
|
if (!mergedOptions.skip(props)) {
|
|
1264
1224
|
return jsxRuntime.jsx(RedirectTo, {
|
|
1265
1225
|
goTo: options.selectGoTo(props)
|
|
1266
1226
|
});
|
|
1267
1227
|
}
|
|
1268
|
-
return jsxRuntime.jsx(Component, _objectSpread$
|
|
1228
|
+
return jsxRuntime.jsx(Component, _objectSpread$1l({}, props));
|
|
1269
1229
|
};
|
|
1270
1230
|
WithRedirectTo.displayName = 'WithFirstStepRedirect';
|
|
1271
1231
|
return WithRedirectTo;
|
|
1272
1232
|
};
|
|
1273
1233
|
var withRedirectTo$1 = withRedirectTo;
|
|
1274
1234
|
|
|
1275
|
-
function ownKeys$
|
|
1276
|
-
function _objectSpread$
|
|
1235
|
+
function ownKeys$1k(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
1236
|
+
function _objectSpread$1k(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$1k(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$1k(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
1277
1237
|
const defaultOptions$4 = {
|
|
1278
1238
|
propName: 'modalState',
|
|
1279
1239
|
isInitiallyOpen: false
|
|
1280
1240
|
};
|
|
1281
1241
|
const injectModalState$2 = options => Component => {
|
|
1282
|
-
const mergedOptions = _objectSpread$
|
|
1242
|
+
const mergedOptions = _objectSpread$1k(_objectSpread$1k({}, defaultOptions$4), options);
|
|
1283
1243
|
const WithModalState = props => {
|
|
1284
1244
|
const modalState = applicationComponents.useModalState(mergedOptions.isInitiallyOpen);
|
|
1285
|
-
return jsxRuntime.jsx(Component, _objectSpread$
|
|
1245
|
+
return jsxRuntime.jsx(Component, _objectSpread$1k(_objectSpread$1k({}, props), {}, {
|
|
1286
1246
|
[mergedOptions.propName]: modalState
|
|
1287
1247
|
}));
|
|
1288
1248
|
};
|
|
@@ -1291,17 +1251,17 @@ const injectModalState$2 = options => Component => {
|
|
|
1291
1251
|
};
|
|
1292
1252
|
var injectModalState$3 = injectModalState$2;
|
|
1293
1253
|
|
|
1294
|
-
function ownKeys$
|
|
1295
|
-
function _objectSpread$
|
|
1254
|
+
function ownKeys$1j(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
1255
|
+
function _objectSpread$1j(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$1j(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$1j(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
1296
1256
|
const defaultOptions$3 = {
|
|
1297
1257
|
propName: 'toggleState',
|
|
1298
1258
|
isInitiallyOpen: false
|
|
1299
1259
|
};
|
|
1300
1260
|
const injectModalState = options => Component => {
|
|
1301
|
-
const mergedOptions = _objectSpread$
|
|
1261
|
+
const mergedOptions = _objectSpread$1j(_objectSpread$1j({}, defaultOptions$3), options);
|
|
1302
1262
|
const WithToggleState = props => {
|
|
1303
1263
|
const toggleState = uiKit.useToggleState(mergedOptions.isInitiallyOpen);
|
|
1304
|
-
return jsxRuntime.jsx(Component, _objectSpread$
|
|
1264
|
+
return jsxRuntime.jsx(Component, _objectSpread$1j(_objectSpread$1j({}, props), {}, {
|
|
1305
1265
|
[mergedOptions.propName]: toggleState
|
|
1306
1266
|
}));
|
|
1307
1267
|
};
|
|
@@ -1310,8 +1270,8 @@ const injectModalState = options => Component => {
|
|
|
1310
1270
|
};
|
|
1311
1271
|
var injectModalState$1 = injectModalState;
|
|
1312
1272
|
|
|
1313
|
-
function ownKeys$
|
|
1314
|
-
function _objectSpread$
|
|
1273
|
+
function ownKeys$1i(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
1274
|
+
function _objectSpread$1i(e) { for (var r = 1; r < arguments.length; r++) { var _context2, _context3; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context2 = ownKeys$1i(Object(t), !0)).call(_context2, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context3 = ownKeys$1i(Object(t))).call(_context3, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
1315
1275
|
const defaultOptions$2 = {
|
|
1316
1276
|
storageType: 'local',
|
|
1317
1277
|
segregateByUser: true
|
|
@@ -1329,7 +1289,7 @@ const getStorage = storageType => storageType === 'session' ? sessionStorage : l
|
|
|
1329
1289
|
const isNil = value => typeof value === 'undefined' || value === null;
|
|
1330
1290
|
const useStorage = (storageKey, initialStorageValue, options) => {
|
|
1331
1291
|
var _context;
|
|
1332
|
-
const mergedOptions = _objectSpread$
|
|
1292
|
+
const mergedOptions = _objectSpread$1i(_objectSpread$1i({}, defaultOptions$2), options);
|
|
1333
1293
|
const userId = applicationShellConnectors.useApplicationContext(context => context.user?.id);
|
|
1334
1294
|
const scopedStorageKey = _filterInstanceProperty__default["default"](_context = [mergedOptions.segregateByUser && userId, storageKey]).call(_context, Boolean).join('/');
|
|
1335
1295
|
const readFromStorage = React.useCallback(() => {
|
|
@@ -1374,8 +1334,8 @@ const useStorage = (storageKey, initialStorageValue, options) => {
|
|
|
1374
1334
|
};
|
|
1375
1335
|
var useStorage$1 = useStorage;
|
|
1376
1336
|
|
|
1377
|
-
function ownKeys$
|
|
1378
|
-
function _objectSpread$
|
|
1337
|
+
function ownKeys$1h(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
1338
|
+
function _objectSpread$1h(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$1h(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$1h(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
1379
1339
|
const defaultOptions$1 = {
|
|
1380
1340
|
propName: 'storage',
|
|
1381
1341
|
storageKey: '',
|
|
@@ -1388,7 +1348,7 @@ const injectStorage = options => WrappedComponent => {
|
|
|
1388
1348
|
* Options are being merged by spreading as destructuring and defaulting in
|
|
1389
1349
|
* argument position does not allow passing specification of option(s).
|
|
1390
1350
|
*/
|
|
1391
|
-
const mergedOptions = _objectSpread$
|
|
1351
|
+
const mergedOptions = _objectSpread$1h(_objectSpread$1h({}, defaultOptions$1), options);
|
|
1392
1352
|
const WithStorage = props => {
|
|
1393
1353
|
const _useStorage = useStorage$1(mergedOptions.storageKey(props), mergedOptions.initalStorageValue, mergedOptions.options),
|
|
1394
1354
|
_useStorage2 = _slicedToArray(_useStorage, 3),
|
|
@@ -1402,7 +1362,7 @@ const injectStorage = options => WrappedComponent => {
|
|
|
1402
1362
|
readFromStorage
|
|
1403
1363
|
}
|
|
1404
1364
|
};
|
|
1405
|
-
return jsxRuntime.jsx(WrappedComponent, _objectSpread$
|
|
1365
|
+
return jsxRuntime.jsx(WrappedComponent, _objectSpread$1h(_objectSpread$1h({}, props), storageProp));
|
|
1406
1366
|
};
|
|
1407
1367
|
WithStorage.displayName = wrapDisplayName$1(WrappedComponent, 'WithStorage');
|
|
1408
1368
|
return WithStorage;
|
|
@@ -1447,8 +1407,8 @@ function useFormatLocalizedFieldToString() {
|
|
|
1447
1407
|
return formatLocalizedFieldToString;
|
|
1448
1408
|
}
|
|
1449
1409
|
|
|
1450
|
-
function ownKeys$
|
|
1451
|
-
function _objectSpread$
|
|
1410
|
+
function ownKeys$1g(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
1411
|
+
function _objectSpread$1g(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$1g(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$1g(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
1452
1412
|
var FetchResourceTypeDuplicatedField = { kind: "Document", definitions: [{ kind: "OperationDefinition", operation: "query", name: { kind: "Name", value: "FetchResourceTypeDuplicatedField" }, variableDefinitions: [{ kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "where" } }, type: { kind: "NamedType", name: { kind: "Name", value: "String" } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "skipAssociateRoles" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "skipAttributeGroups" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "skipBusinessUnits" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "skipCarts" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "skipCartDiscounts" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "skipCategories" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "skipChannels" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "skipCustomers" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "skipCustomerGroups" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "skipDiscountCodes" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "skipInventoryEntries" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "skipOrders" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "skipPayments" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "skipProducts" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "skipProductDiscounts" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "skipProductSelections" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "skipProductTypes" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "skipShippingMethods" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "skipShoppingLists" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "skipStores" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "skipTaxCategories" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "skipZones" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "associateRoles" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "where" }, value: { kind: "Variable", name: { kind: "Name", value: "where" } } }], directives: [{ kind: "Directive", name: { kind: "Name", value: "skip" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "skipAssociateRoles" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "total" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "attributeGroups" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "where" }, value: { kind: "Variable", name: { kind: "Name", value: "where" } } }], directives: [{ kind: "Directive", name: { kind: "Name", value: "skip" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "skipAttributeGroups" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "total" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "businessUnits" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "where" }, value: { kind: "Variable", name: { kind: "Name", value: "where" } } }], directives: [{ kind: "Directive", name: { kind: "Name", value: "skip" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "skipBusinessUnits" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "total" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "carts" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "where" }, value: { kind: "Variable", name: { kind: "Name", value: "where" } } }], directives: [{ kind: "Directive", name: { kind: "Name", value: "skip" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "skipCarts" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "total" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "cartDiscounts" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "where" }, value: { kind: "Variable", name: { kind: "Name", value: "where" } } }], directives: [{ kind: "Directive", name: { kind: "Name", value: "skip" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "skipCartDiscounts" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "total" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "categories" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "where" }, value: { kind: "Variable", name: { kind: "Name", value: "where" } } }], directives: [{ kind: "Directive", name: { kind: "Name", value: "skip" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "skipCategories" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "total" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "channels" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "where" }, value: { kind: "Variable", name: { kind: "Name", value: "where" } } }], directives: [{ kind: "Directive", name: { kind: "Name", value: "skip" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "skipChannels" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "total" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "customers" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "where" }, value: { kind: "Variable", name: { kind: "Name", value: "where" } } }], directives: [{ kind: "Directive", name: { kind: "Name", value: "skip" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "skipCustomers" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "total" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "customerGroups" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "where" }, value: { kind: "Variable", name: { kind: "Name", value: "where" } } }], directives: [{ kind: "Directive", name: { kind: "Name", value: "skip" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "skipCustomerGroups" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "total" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "discountCodes" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "where" }, value: { kind: "Variable", name: { kind: "Name", value: "where" } } }], directives: [{ kind: "Directive", name: { kind: "Name", value: "skip" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "skipDiscountCodes" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "total" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "inventoryEntries" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "where" }, value: { kind: "Variable", name: { kind: "Name", value: "where" } } }], directives: [{ kind: "Directive", name: { kind: "Name", value: "skip" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "skipInventoryEntries" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "total" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "orders" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "where" }, value: { kind: "Variable", name: { kind: "Name", value: "where" } } }], directives: [{ kind: "Directive", name: { kind: "Name", value: "skip" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "skipOrders" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "total" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "payments" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "where" }, value: { kind: "Variable", name: { kind: "Name", value: "where" } } }], directives: [{ kind: "Directive", name: { kind: "Name", value: "skip" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "skipPayments" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "total" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "products" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "where" }, value: { kind: "Variable", name: { kind: "Name", value: "where" } } }], directives: [{ kind: "Directive", name: { kind: "Name", value: "skip" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "skipProducts" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "total" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "productDiscounts" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "where" }, value: { kind: "Variable", name: { kind: "Name", value: "where" } } }], directives: [{ kind: "Directive", name: { kind: "Name", value: "skip" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "skipProductDiscounts" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "total" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "productSelections" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "where" }, value: { kind: "Variable", name: { kind: "Name", value: "where" } } }], directives: [{ kind: "Directive", name: { kind: "Name", value: "skip" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "skipProductSelections" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "total" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "productTypes" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "where" }, value: { kind: "Variable", name: { kind: "Name", value: "where" } } }], directives: [{ kind: "Directive", name: { kind: "Name", value: "skip" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "skipProductTypes" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "total" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "shippingMethods" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "where" }, value: { kind: "Variable", name: { kind: "Name", value: "where" } } }], directives: [{ kind: "Directive", name: { kind: "Name", value: "skip" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "skipShippingMethods" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "total" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "shoppingLists" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "where" }, value: { kind: "Variable", name: { kind: "Name", value: "where" } } }], directives: [{ kind: "Directive", name: { kind: "Name", value: "skip" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "skipShoppingLists" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "total" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "stores" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "where" }, value: { kind: "Variable", name: { kind: "Name", value: "where" } } }], directives: [{ kind: "Directive", name: { kind: "Name", value: "skip" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "skipStores" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "total" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "taxCategories" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "where" }, value: { kind: "Variable", name: { kind: "Name", value: "where" } } }], directives: [{ kind: "Directive", name: { kind: "Name", value: "skip" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "skipTaxCategories" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "total" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "zones" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "where" }, value: { kind: "Variable", name: { kind: "Name", value: "where" } } }], directives: [{ kind: "Directive", name: { kind: "Name", value: "skip" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "skipZones" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "total" }, arguments: [], directives: [] }] } }] } }], loc: { start: 0, end: 2328, source: { body: "query FetchResourceTypeDuplicatedField(\n $where: String\n $skipAssociateRoles: Boolean!\n $skipAttributeGroups: Boolean!\n $skipBusinessUnits: Boolean!\n $skipCarts: Boolean!\n $skipCartDiscounts: Boolean!\n $skipCategories: Boolean!\n $skipChannels: Boolean!\n $skipCustomers: Boolean!\n $skipCustomerGroups: Boolean!\n $skipDiscountCodes: Boolean!\n $skipInventoryEntries: Boolean!\n $skipOrders: Boolean!\n $skipPayments: Boolean!\n $skipProducts: Boolean!\n $skipProductDiscounts: Boolean!\n $skipProductSelections: Boolean!\n $skipProductTypes: Boolean!\n $skipShippingMethods: Boolean!\n $skipShoppingLists: Boolean!\n $skipStores: Boolean!\n $skipTaxCategories: Boolean!\n $skipZones: Boolean!\n) {\n associateRoles(where: $where) @skip(if: $skipAssociateRoles) {\n total\n }\n attributeGroups(where: $where) @skip(if: $skipAttributeGroups) {\n total\n }\n businessUnits(where: $where) @skip(if: $skipBusinessUnits) {\n total\n }\n carts(where: $where) @skip(if: $skipCarts) {\n total\n }\n cartDiscounts(where: $where) @skip(if: $skipCartDiscounts) {\n total\n }\n categories(where: $where) @skip(if: $skipCategories) {\n total\n }\n channels(where: $where) @skip(if: $skipChannels) {\n total\n }\n customers(where: $where) @skip(if: $skipCustomers) {\n total\n }\n customerGroups(where: $where) @skip(if: $skipCustomerGroups) {\n total\n }\n discountCodes(where: $where) @skip(if: $skipDiscountCodes) {\n total\n }\n inventoryEntries(where: $where) @skip(if: $skipInventoryEntries) {\n total\n }\n orders(where: $where) @skip(if: $skipOrders) {\n total\n }\n payments(where: $where) @skip(if: $skipPayments) {\n total\n }\n products(where: $where) @skip(if: $skipProducts) {\n total\n }\n productDiscounts(where: $where) @skip(if: $skipProductDiscounts) {\n total\n }\n productSelections(where: $where) @skip(if: $skipProductSelections) {\n total\n }\n productTypes(where: $where) @skip(if: $skipProductTypes) {\n total\n }\n shippingMethods(where: $where) @skip(if: $skipShippingMethods) {\n total\n }\n shoppingLists(where: $where) @skip(if: $skipShoppingLists) {\n total\n }\n stores(where: $where) @skip(if: $skipStores) {\n total\n }\n taxCategories(where: $where) @skip(if: $skipTaxCategories) {\n total\n }\n zones(where: $where) @skip(if: $skipZones) {\n total\n }\n}\n", name: "GraphQL request", locationOffset: { line: 1, column: 1 } } } };
|
|
1453
1413
|
const MC_RESOURCES_WITH_KEYS = {
|
|
1454
1414
|
ASSOCIATE_ROLE: 'ASSOCIATE_ROLE',
|
|
@@ -1523,7 +1483,7 @@ const DEFAULT_SKIP_RESOURCE_TYPES_VARIABLES = {
|
|
|
1523
1483
|
[BASE_SKIP_RESOURCE_TYPES_VARIABLES.ZONE]: true
|
|
1524
1484
|
};
|
|
1525
1485
|
const getSkipVariables = resourceType => {
|
|
1526
|
-
return _objectSpread$
|
|
1486
|
+
return _objectSpread$1g(_objectSpread$1g({}, DEFAULT_SKIP_RESOURCE_TYPES_VARIABLES), {}, {
|
|
1527
1487
|
[BASE_SKIP_RESOURCE_TYPES_VARIABLES[resourceType]]: false
|
|
1528
1488
|
});
|
|
1529
1489
|
};
|
|
@@ -1548,7 +1508,7 @@ const getQueryVariables = _ref2 => {
|
|
|
1548
1508
|
fieldValue,
|
|
1549
1509
|
id
|
|
1550
1510
|
});
|
|
1551
|
-
return _objectSpread$
|
|
1511
|
+
return _objectSpread$1g({
|
|
1552
1512
|
where
|
|
1553
1513
|
}, skipVariables);
|
|
1554
1514
|
};
|
|
@@ -1582,8 +1542,8 @@ const usePrevious = value => {
|
|
|
1582
1542
|
};
|
|
1583
1543
|
var usePrevious$1 = usePrevious;
|
|
1584
1544
|
|
|
1585
|
-
function ownKeys$
|
|
1586
|
-
function _objectSpread$
|
|
1545
|
+
function ownKeys$1f(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
1546
|
+
function _objectSpread$1f(e) { for (var r = 1; r < arguments.length; r++) { var _context7, _context8; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context7 = ownKeys$1f(Object(t), !0)).call(_context7, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context8 = ownKeys$1f(Object(t))).call(_context8, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
1587
1547
|
var FetchStoresQuery = { kind: "Document", definitions: [{ kind: "OperationDefinition", operation: "query", name: { kind: "Name", value: "FetchStoresQuery" }, variableDefinitions: [{ kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "limit" } }, type: { kind: "NamedType", name: { kind: "Name", value: "Int" } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "offset" } }, type: { kind: "NamedType", name: { kind: "Name", value: "Int" } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "sort" } }, type: { kind: "ListType", type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "String" } } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "where" } }, type: { kind: "NamedType", name: { kind: "Name", value: "String" } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "excludeExtendedStoresList" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "excludeProductSelections" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "stores" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "limit" }, value: { kind: "Variable", name: { kind: "Name", value: "limit" } } }, { kind: "Argument", name: { kind: "Name", value: "offset" }, value: { kind: "Variable", name: { kind: "Name", value: "offset" } } }, { kind: "Argument", name: { kind: "Name", value: "sort" }, value: { kind: "Variable", name: { kind: "Name", value: "sort" } } }, { kind: "Argument", name: { kind: "Name", value: "where" }, value: { kind: "Variable", name: { kind: "Name", value: "where" } } }], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "total" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "count" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "offset" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "results" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "FragmentSpread", name: { kind: "Name", value: "StoreBasicInfo" }, directives: [] }, { kind: "Field", name: { kind: "Name", value: "countries" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "code" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "languages" }, arguments: [], directives: [{ kind: "Directive", name: { kind: "Name", value: "skip" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "excludeExtendedStoresList" } } }] }] }, { kind: "Field", name: { kind: "Name", value: "distributionChannelsRef" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "id" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "distributionChannels" }, arguments: [], directives: [{ kind: "Directive", name: { kind: "Name", value: "skip" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "excludeExtendedStoresList" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "id" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "key" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "nameAllLocales" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "locale" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "value" }, arguments: [], directives: [] }] } }] } }, { kind: "Field", name: { kind: "Name", value: "supplyChannels" }, arguments: [], directives: [{ kind: "Directive", name: { kind: "Name", value: "skip" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "excludeExtendedStoresList" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "id" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "key" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "nameAllLocales" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "locale" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "value" }, arguments: [], directives: [] }] } }] } }, { kind: "Field", name: { kind: "Name", value: "productSelections" }, arguments: [], directives: [{ kind: "Directive", name: { kind: "Name", value: "skip" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "excludeProductSelections" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "active" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "productSelection" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "id" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "mode" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "nameAllLocales" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "locale" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "value" }, arguments: [], directives: [] }] } }] } }] } }] } }] } }] } }, { kind: "FragmentDefinition", name: { kind: "Name", value: "StoreBasicInfo" }, typeCondition: { kind: "NamedType", name: { kind: "Name", value: "Store" } }, directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "id" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "key" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "version" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "nameAllLocales" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "locale" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "value" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "createdAt" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "lastModifiedAt" }, arguments: [], directives: [] }] } }], loc: { start: 0, end: 1089, source: { body: "#import '../../utils/graphql/fragments/store-basic-info.ctp.graphql'\n\nquery FetchStoresQuery(\n $limit: Int\n $offset: Int\n $sort: [String!]\n $where: String\n $excludeExtendedStoresList: Boolean!\n $excludeProductSelections: Boolean!\n) {\n stores(limit: $limit, offset: $offset, sort: $sort, where: $where) {\n total\n count\n offset\n results {\n ...StoreBasicInfo\n countries {\n code\n }\n languages @skip(if: $excludeExtendedStoresList)\n distributionChannelsRef {\n id\n }\n distributionChannels @skip(if: $excludeExtendedStoresList) {\n id\n key\n nameAllLocales {\n locale\n value\n }\n }\n supplyChannels @skip(if: $excludeExtendedStoresList) {\n id\n key\n nameAllLocales {\n locale\n value\n }\n }\n productSelections @skip(if: $excludeProductSelections) {\n active\n productSelection {\n id\n mode\n nameAllLocales {\n locale\n value\n }\n }\n }\n }\n }\n}\n", name: "GraphQL request", locationOffset: { line: 1, column: 1 } } } };
|
|
1588
1548
|
const filterStoresOutdatedDanglingProductSelections = storesQueryResult => {
|
|
1589
1549
|
var _context, _context2;
|
|
@@ -1594,7 +1554,7 @@ const filterStoresOutdatedDanglingProductSelections = storesQueryResult => {
|
|
|
1594
1554
|
offset: storesQueryResult.offset,
|
|
1595
1555
|
results: ((_context = storesQueryResult.results) == null ? void 0 : _bindInstanceProperty__default["default"](_context2 = Function.call).call(_context2, _mapInstanceProperty__default["default"](_context), _context))?.(store => {
|
|
1596
1556
|
var _context3, _context4;
|
|
1597
|
-
return _objectSpread$
|
|
1557
|
+
return _objectSpread$1f(_objectSpread$1f({}, store), {}, {
|
|
1598
1558
|
productSelections: ((_context3 = store.productSelections) == null ? void 0 : _bindInstanceProperty__default["default"](_context4 = Function.call).call(_context4, _filterInstanceProperty__default["default"](_context3), _context3))?.(productSelectionRef => Boolean(productSelectionRef.productSelection))
|
|
1599
1559
|
});
|
|
1600
1560
|
})
|
|
@@ -1602,7 +1562,7 @@ const filterStoresOutdatedDanglingProductSelections = storesQueryResult => {
|
|
|
1602
1562
|
};
|
|
1603
1563
|
const createQueryVariables$6 = ownProps => {
|
|
1604
1564
|
var _context5, _context6;
|
|
1605
|
-
return _objectSpread$
|
|
1565
|
+
return _objectSpread$1f(_objectSpread$1f(_objectSpread$1f({
|
|
1606
1566
|
limit: ownProps.limit,
|
|
1607
1567
|
offset: ownProps.offset,
|
|
1608
1568
|
sort: _sortInstanceProperty__default["default"](ownProps)
|
|
@@ -1655,8 +1615,8 @@ const useStoresListFetcher = props => {
|
|
|
1655
1615
|
};
|
|
1656
1616
|
var useStoresListFetcher$1 = useStoresListFetcher;
|
|
1657
1617
|
|
|
1658
|
-
function ownKeys$
|
|
1659
|
-
function _objectSpread$
|
|
1618
|
+
function ownKeys$1e(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
1619
|
+
function _objectSpread$1e(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$1e(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$1e(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
1660
1620
|
const createSearchQuery = (searchBy, searchTerm, language) => {
|
|
1661
1621
|
if (searchBy === 'key/name') {
|
|
1662
1622
|
return {
|
|
@@ -1675,7 +1635,7 @@ const createSearchQuery = (searchBy, searchTerm, language) => {
|
|
|
1675
1635
|
};
|
|
1676
1636
|
} else {
|
|
1677
1637
|
return {
|
|
1678
|
-
fullTextPrefix: _objectSpread$
|
|
1638
|
+
fullTextPrefix: _objectSpread$1e(_objectSpread$1e({
|
|
1679
1639
|
field: searchBy
|
|
1680
1640
|
}, searchBy === 'name' ? {
|
|
1681
1641
|
language: language
|
|
@@ -1751,7 +1711,7 @@ const useStoresSearchFetcher = () => {
|
|
|
1751
1711
|
});
|
|
1752
1712
|
setIsLoading(false);
|
|
1753
1713
|
} catch (error) {
|
|
1754
|
-
setStoreSearchResults(prev => _objectSpread$
|
|
1714
|
+
setStoreSearchResults(prev => _objectSpread$1e(_objectSpread$1e({}, prev), {}, {
|
|
1755
1715
|
hits: [],
|
|
1756
1716
|
total: 0
|
|
1757
1717
|
}));
|
|
@@ -1762,7 +1722,7 @@ const useStoresSearchFetcher = () => {
|
|
|
1762
1722
|
fetchStoreSearchResults,
|
|
1763
1723
|
storeSearchResults,
|
|
1764
1724
|
isLoading,
|
|
1765
|
-
resetStoreSearchResults: () => setStoreSearchResults(prev => _objectSpread$
|
|
1725
|
+
resetStoreSearchResults: () => setStoreSearchResults(prev => _objectSpread$1e(_objectSpread$1e({}, prev), {}, {
|
|
1766
1726
|
hits: [],
|
|
1767
1727
|
total: 0
|
|
1768
1728
|
}))
|
|
@@ -1853,8 +1813,8 @@ const useStoreKeysInDataFences = _ref => {
|
|
|
1853
1813
|
};
|
|
1854
1814
|
var useStoreKeysInDataFences$1 = useStoreKeysInDataFences;
|
|
1855
1815
|
|
|
1856
|
-
function ownKeys$
|
|
1857
|
-
function _objectSpread$
|
|
1816
|
+
function ownKeys$1d(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
1817
|
+
function _objectSpread$1d(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$1d(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$1d(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
1858
1818
|
const TEN_MINUTES_IN_MS = 600000;
|
|
1859
1819
|
const defaultOptions = {
|
|
1860
1820
|
reminderInterval: REMINDER_OPTION_1_DAY,
|
|
@@ -1882,7 +1842,7 @@ const useHasReminderExpired = readReminderInterval => {
|
|
|
1882
1842
|
};
|
|
1883
1843
|
const usePersistedReminder = function () {
|
|
1884
1844
|
let options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
1885
|
-
const mergedOptions = _objectSpread$
|
|
1845
|
+
const mergedOptions = _objectSpread$1d(_objectSpread$1d({}, defaultOptions), options);
|
|
1886
1846
|
const _useStorage = useStorage$1(mergedOptions.storageKey, null),
|
|
1887
1847
|
_useStorage2 = _slicedToArray(_useStorage, 3),
|
|
1888
1848
|
initialChosenReminderInterval = _useStorage2[0],
|
|
@@ -1929,7 +1889,7 @@ const usePersistedReminder = function () {
|
|
|
1929
1889
|
};
|
|
1930
1890
|
var usePersistedReminder$1 = usePersistedReminder;
|
|
1931
1891
|
|
|
1932
|
-
var messages$
|
|
1892
|
+
var messages$M = reactIntl.defineMessages({
|
|
1933
1893
|
profileUpdated: {
|
|
1934
1894
|
id: 'NotificationText.profileUpdated',
|
|
1935
1895
|
description: 'Label for the notification header',
|
|
@@ -1947,8 +1907,8 @@ var messages$O = reactIntl.defineMessages({
|
|
|
1947
1907
|
}
|
|
1948
1908
|
});
|
|
1949
1909
|
|
|
1950
|
-
function ownKeys$
|
|
1951
|
-
function _objectSpread$
|
|
1910
|
+
function ownKeys$1c(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
1911
|
+
function _objectSpread$1c(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$1c(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$1c(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
1952
1912
|
const LinkToProfile = props => {
|
|
1953
1913
|
return jsxRuntime.jsx(uiKit.Link, {
|
|
1954
1914
|
to: "/account/profile",
|
|
@@ -1966,9 +1926,9 @@ const NotificationText = () => jsxRuntime.jsxs(uiKit.Spacings.Stack, {
|
|
|
1966
1926
|
children: [jsxRuntime.jsx(uiKit.Text.Body, {
|
|
1967
1927
|
as: "p",
|
|
1968
1928
|
isBold: true,
|
|
1969
|
-
intlMessage: messages$
|
|
1929
|
+
intlMessage: messages$M.profileUpdated
|
|
1970
1930
|
}), jsxRuntime.jsx(uiKit.Text.Body, {
|
|
1971
|
-
intlMessage: _objectSpread$
|
|
1931
|
+
intlMessage: _objectSpread$1c(_objectSpread$1c({}, messages$M.addMoreInformation), {}, {
|
|
1972
1932
|
values: {
|
|
1973
1933
|
newline: getNewLine
|
|
1974
1934
|
}
|
|
@@ -1977,7 +1937,7 @@ const NotificationText = () => jsxRuntime.jsxs(uiKit.Spacings.Stack, {
|
|
|
1977
1937
|
}), jsxRuntime.jsx(uiKit.Spacings.Stack, {
|
|
1978
1938
|
scale: "xs",
|
|
1979
1939
|
children: jsxRuntime.jsx(uiKit.Text.Body, {
|
|
1980
|
-
intlMessage: _objectSpread$
|
|
1940
|
+
intlMessage: _objectSpread$1c(_objectSpread$1c({}, messages$M.informationAndProfileLink), {}, {
|
|
1981
1941
|
values: {
|
|
1982
1942
|
newline: getNewLine,
|
|
1983
1943
|
link: getLinkToProfile
|
|
@@ -2054,76 +2014,6 @@ const useRoleNotificationEffect = () => {
|
|
|
2054
2014
|
};
|
|
2055
2015
|
var useRoleNotificationEffect$1 = useRoleNotificationEffect;
|
|
2056
2016
|
|
|
2057
|
-
var messages$N = reactIntl.defineMessages({
|
|
2058
|
-
dbMaintenanceNotification: {
|
|
2059
|
-
id: 'Global.dbMaintenanceNotification',
|
|
2060
|
-
description: 'Database maintenance notification',
|
|
2061
|
-
defaultMessage: "A <linkDocs>database maintenance</linkDocs> is scheduled for January 22-23 2026. Some of the functionalities of the Merchant Center won't be available during that time, including customizations. Please plan your work accordingly."
|
|
2062
|
-
},
|
|
2063
|
-
dbMaintenanceOngoingNotification: {
|
|
2064
|
-
id: 'Global.dbMaintenanceOngoingNotification',
|
|
2065
|
-
description: 'Ongoing database maintenance notification',
|
|
2066
|
-
defaultMessage: 'Merchant Center database is currently under <linkDocs>planned maintenance</linkDocs>. Some of the functionalities of the Merchant Center are not available, including customizations. Thank you for your patience.'
|
|
2067
|
-
}
|
|
2068
|
-
});
|
|
2069
|
-
|
|
2070
|
-
// Hardcode feature flag name here instead of importing it from the private `constants` package.
|
|
2071
|
-
const ENABLE_DB_MAINTENANCE_NOTIFICATION = 'enableDbMaintenanceNotification';
|
|
2072
|
-
|
|
2073
|
-
// eslint-disable-next-line react/display-name
|
|
2074
|
-
const getLinkDocs = () => msg => jsxRuntime.jsx(uiKit.Link, {
|
|
2075
|
-
isExternal: true,
|
|
2076
|
-
to: "https://docs.commercetools.com/merchant-center/releases/2026-01-19-database-maintenance-on-22-23-january",
|
|
2077
|
-
children: msg
|
|
2078
|
-
}, 'db-maintenance-doc-link');
|
|
2079
|
-
const DISMISSED_DB_MAINTENANCE_UPCOMING = 'dismissed-db-maintenance-upcoming';
|
|
2080
|
-
const DISMISSED_DB_MAINTENANCE_ONGOING = 'dismissed-db-maintenance-ongoing';
|
|
2081
|
-
const PENDING_DB_MAINTENANCE_BANNER = 'pending-db-maintenance-banner';
|
|
2082
|
-
const useDbMaintenanceNotification = () => {
|
|
2083
|
-
const isDbMaintenanceNotificationEnabled = applicationShell.useFlagVariation(ENABLE_DB_MAINTENANCE_NOTIFICATION);
|
|
2084
|
-
const intl = reactIntl.useIntl();
|
|
2085
|
-
const showNotification = actionsGlobal.useShowNotification();
|
|
2086
|
-
const hasShownRef = React.useRef(false);
|
|
2087
|
-
React.useEffect(() => {
|
|
2088
|
-
// If running in Cypress, skip the notification
|
|
2089
|
-
if (typeof window !== 'undefined' && window.Cypress) {
|
|
2090
|
-
localStorage.setItem(DISMISSED_DB_MAINTENANCE_UPCOMING, 'true');
|
|
2091
|
-
return;
|
|
2092
|
-
}
|
|
2093
|
-
|
|
2094
|
-
// Show notification if:
|
|
2095
|
-
// 1. value is true (upcoming maintenance), OR
|
|
2096
|
-
// 2. value is false with reason "ongoing" (maintenance is happening now)
|
|
2097
|
-
const isUpcoming = isDbMaintenanceNotificationEnabled?.value === true;
|
|
2098
|
-
const isOngoing = isDbMaintenanceNotificationEnabled?.value === false && isDbMaintenanceNotificationEnabled?.reason === 'ongoing';
|
|
2099
|
-
if (!isUpcoming && !isOngoing) return;
|
|
2100
|
-
const dismissedFlag = isOngoing ? DISMISSED_DB_MAINTENANCE_ONGOING : DISMISSED_DB_MAINTENANCE_UPCOMING;
|
|
2101
|
-
const hasDismissedBanner = !!localStorage.getItem(dismissedFlag);
|
|
2102
|
-
const isPending = !!localStorage.getItem(PENDING_DB_MAINTENANCE_BANNER);
|
|
2103
|
-
if (!hasDismissedBanner && !isPending && !hasShownRef.current || isPending && !hasShownRef.current) {
|
|
2104
|
-
hasShownRef.current = true;
|
|
2105
|
-
localStorage.setItem(PENDING_DB_MAINTENANCE_BANNER, 'true');
|
|
2106
|
-
const notificationKind = isOngoing ? constants.NOTIFICATION_KINDS_SIDE.warning : constants.NOTIFICATION_KINDS_SIDE.info;
|
|
2107
|
-
const messageKey = isOngoing ? 'dbMaintenanceOngoingNotification' : 'dbMaintenanceNotification';
|
|
2108
|
-
const messageObj = messages$N[messageKey];
|
|
2109
|
-
const formattedText = intl.formatMessage(messageObj, {
|
|
2110
|
-
linkDocs: getLinkDocs()
|
|
2111
|
-
});
|
|
2112
|
-
showNotification({
|
|
2113
|
-
kind: notificationKind,
|
|
2114
|
-
domain: constants.DOMAINS.GLOBAL,
|
|
2115
|
-
text: formattedText
|
|
2116
|
-
}, {
|
|
2117
|
-
onDismiss: () => {
|
|
2118
|
-
localStorage.setItem(dismissedFlag, 'true');
|
|
2119
|
-
localStorage.removeItem(PENDING_DB_MAINTENANCE_BANNER);
|
|
2120
|
-
hasShownRef.current = false;
|
|
2121
|
-
}
|
|
2122
|
-
});
|
|
2123
|
-
}
|
|
2124
|
-
}, [showNotification, intl, isDbMaintenanceNotificationEnabled]);
|
|
2125
|
-
};
|
|
2126
|
-
|
|
2127
2017
|
function usePendingRequests() {
|
|
2128
2018
|
const _useState = React.useState(0),
|
|
2129
2019
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -2175,7 +2065,7 @@ const useEventCallback = (fn, dependencies) => {
|
|
|
2175
2065
|
};
|
|
2176
2066
|
var useEventCallback$1 = useEventCallback;
|
|
2177
2067
|
|
|
2178
|
-
var messages$
|
|
2068
|
+
var messages$L = reactIntl.defineMessages({
|
|
2179
2069
|
fallbackHint: {
|
|
2180
2070
|
id: 'KeyFallback.fallbackHint',
|
|
2181
2071
|
description: 'key fallback for a specified resource key (e.g name)',
|
|
@@ -2199,7 +2089,7 @@ const useLocalizedKeyFallback = () => {
|
|
|
2199
2089
|
return values => {
|
|
2200
2090
|
if (!values.resource) return null;
|
|
2201
2091
|
const localizedString = values.resource[values.localizedStringFieldName];
|
|
2202
|
-
const fallbackHintWithKey = intl.formatMessage(messages$
|
|
2092
|
+
const fallbackHintWithKey = intl.formatMessage(messages$L.fallbackHint, {
|
|
2203
2093
|
key: values.resource.key
|
|
2204
2094
|
});
|
|
2205
2095
|
if (!localizedString) return fallbackHintWithKey;
|
|
@@ -2208,13 +2098,11 @@ const useLocalizedKeyFallback = () => {
|
|
|
2208
2098
|
};
|
|
2209
2099
|
var useLocalizedKeyFallback$1 = useLocalizedKeyFallback;
|
|
2210
2100
|
|
|
2211
|
-
const useDebouncedPromiseCallback = (promiseCallback, wait) =>
|
|
2212
|
-
// eslint-disable-next-line testing-library/await-async-utils
|
|
2213
|
-
React.useCallback(debounce__default["default"](promiseCallback, wait), [promiseCallback]);
|
|
2101
|
+
const useDebouncedPromiseCallback = (promiseCallback, wait) => React.useCallback(debounce__default["default"](promiseCallback, wait), [promiseCallback]);
|
|
2214
2102
|
var useDebouncedPromiseCallback$1 = useDebouncedPromiseCallback;
|
|
2215
2103
|
|
|
2216
|
-
function ownKeys$
|
|
2217
|
-
function _objectSpread$
|
|
2104
|
+
function ownKeys$1b(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
2105
|
+
function _objectSpread$1b(e) { for (var r = 1; r < arguments.length; r++) { var _context2, _context3; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context2 = ownKeys$1b(Object(t), !0)).call(_context2, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context3 = ownKeys$1b(Object(t))).call(_context3, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
2218
2106
|
const prepareMutableColumnProps = (columnConfig, mutableColumnProps) => {
|
|
2219
2107
|
const updatedColumnProps = {};
|
|
2220
2108
|
_forEachInstanceProperty__default["default"](mutableColumnProps).call(mutableColumnProps, columnProp => {
|
|
@@ -2234,14 +2122,14 @@ const retrieveColumnsWithCachedConfiguration = _ref => {
|
|
|
2234
2122
|
mutableColumnProps = _ref.mutableColumnProps;
|
|
2235
2123
|
return _mapInstanceProperty__default["default"](_context = _filterInstanceProperty__default["default"](cachedVisibleTableConfiguration).call(cachedVisibleTableConfiguration, cachedColumn => _findInstanceProperty__default["default"](allAvailableColumnsConfiguration).call(allAvailableColumnsConfiguration, initialConfig => initialConfig.key === cachedColumn.key))).call(_context, cachedConfig => {
|
|
2236
2124
|
const initialColumnConfig = _findInstanceProperty__default["default"](allAvailableColumnsConfiguration).call(allAvailableColumnsConfiguration, initialConfig => initialConfig.key === cachedConfig.key);
|
|
2237
|
-
return _objectSpread$
|
|
2125
|
+
return _objectSpread$1b(_objectSpread$1b({}, initialColumnConfig), prepareMutableColumnProps(cachedConfig, mutableColumnProps));
|
|
2238
2126
|
});
|
|
2239
2127
|
};
|
|
2240
2128
|
const handleCacheUpdate = _ref2 => {
|
|
2241
2129
|
let update = _ref2.update,
|
|
2242
2130
|
cachedVisibleTableConfiguration = _ref2.cachedVisibleTableConfiguration,
|
|
2243
2131
|
updateCachedTableConfiguration = _ref2.updateCachedTableConfiguration;
|
|
2244
|
-
return updateCachedTableConfiguration(_objectSpread$
|
|
2132
|
+
return updateCachedTableConfiguration(_objectSpread$1b(_objectSpread$1b({}, pick__default["default"](cachedVisibleTableConfiguration, ['columnsConfig', 'displaySettings'])), update));
|
|
2245
2133
|
};
|
|
2246
2134
|
|
|
2247
2135
|
// Signature:
|
|
@@ -2270,7 +2158,7 @@ const usePersistedTableConfiguration = props => {
|
|
|
2270
2158
|
return {
|
|
2271
2159
|
columnsConfig: _mapInstanceProperty__default["default"](initialVisibleColumnKeys).call(initialVisibleColumnKeys, visibleColumnKey => {
|
|
2272
2160
|
const visibleColumnConfig = _findInstanceProperty__default["default"](allAvailableColumnsConfiguration).call(allAvailableColumnsConfiguration, columnConfig => columnConfig.key === visibleColumnKey);
|
|
2273
|
-
return _objectSpread$
|
|
2161
|
+
return _objectSpread$1b({
|
|
2274
2162
|
key: visibleColumnKey
|
|
2275
2163
|
}, prepareMutableColumnProps(visibleColumnConfig, mutableColumnProps));
|
|
2276
2164
|
}),
|
|
@@ -2333,14 +2221,14 @@ const useProductSelectionsTotalFetcher = props => {
|
|
|
2333
2221
|
};
|
|
2334
2222
|
var useProductSelectionsTotalFetcher$1 = useProductSelectionsTotalFetcher;
|
|
2335
2223
|
|
|
2336
|
-
function ownKeys$
|
|
2337
|
-
function _objectSpread$
|
|
2224
|
+
function ownKeys$1a(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
2225
|
+
function _objectSpread$1a(e) { for (var r = 1; r < arguments.length; r++) { var _context2, _context3; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context2 = ownKeys$1a(Object(t), !0)).call(_context2, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context3 = ownKeys$1a(Object(t))).call(_context3, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
2338
2226
|
|
|
2339
2227
|
// eslint-disable-next-line import/prefer-default-export
|
|
2340
2228
|
const convertProductSelectionsFromGraphQl = productSelections => {
|
|
2341
2229
|
var _context;
|
|
2342
|
-
return productSelections?.results && _objectSpread$
|
|
2343
|
-
results: _mapInstanceProperty__default["default"](_context = productSelections.results).call(_context, productSelection => _objectSpread$
|
|
2230
|
+
return productSelections?.results && _objectSpread$1a(_objectSpread$1a({}, productSelections), {}, {
|
|
2231
|
+
results: _mapInstanceProperty__default["default"](_context = productSelections.results).call(_context, productSelection => _objectSpread$1a({}, l10n.applyTransformedLocalizedFields(productSelection, [{
|
|
2344
2232
|
from: 'nameAllLocales',
|
|
2345
2233
|
to: 'name'
|
|
2346
2234
|
}])))
|
|
@@ -3825,8 +3713,8 @@ const getData = (code, field) => {
|
|
|
3825
3713
|
};
|
|
3826
3714
|
const getFractionDigit = code => getData(code, 'fractionDigit');
|
|
3827
3715
|
|
|
3828
|
-
function ownKeys$
|
|
3829
|
-
function _objectSpread$
|
|
3716
|
+
function ownKeys$19(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
3717
|
+
function _objectSpread$19(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$19(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$19(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
3830
3718
|
function formatMoneyRangeValue(value, intl) {
|
|
3831
3719
|
if (value.from === value.to) return formatMoneyValue(value.from, value.currency, intl);
|
|
3832
3720
|
if (value.from && value.to) return `${formatMoneyValue(value.from, value.currency, intl)} -
|
|
@@ -3836,7 +3724,7 @@ function formatMoneyRangeValue(value, intl) {
|
|
|
3836
3724
|
return '';
|
|
3837
3725
|
}
|
|
3838
3726
|
function formatMoneyValue(amount, currency, intl) {
|
|
3839
|
-
return formatMoney$2(_objectSpread$
|
|
3727
|
+
return formatMoney$2(_objectSpread$19({
|
|
3840
3728
|
centAmount: amount,
|
|
3841
3729
|
fractionDigits: getFractionDigit(currency)
|
|
3842
3730
|
}, currency ? {
|
|
@@ -3852,14 +3740,14 @@ function getFractionedAmount(moneyValue) {
|
|
|
3852
3740
|
return amount / 10 ** fractionDigits;
|
|
3853
3741
|
}
|
|
3854
3742
|
function formatMoney$2(moneyValue, intl, options) {
|
|
3855
|
-
return intl.formatNumber(moneyValue.fractionedAmount ?? getFractionedAmount(moneyValue), _objectSpread$
|
|
3743
|
+
return intl.formatNumber(moneyValue.fractionedAmount ?? getFractionedAmount(moneyValue), _objectSpread$19({
|
|
3856
3744
|
style: 'currency',
|
|
3857
3745
|
currency: moneyValue.currencyCode,
|
|
3858
3746
|
minimumFractionDigits: moneyValue.fractionDigits
|
|
3859
3747
|
}, options));
|
|
3860
3748
|
}
|
|
3861
3749
|
|
|
3862
|
-
var messages$
|
|
3750
|
+
var messages$K = reactIntl.defineMessages({
|
|
3863
3751
|
booleanYes: {
|
|
3864
3752
|
id: 'AttributeTypeFormats.boolean.yes',
|
|
3865
3753
|
description: 'The label for boolean attribute `true` value',
|
|
@@ -3941,7 +3829,7 @@ const formatDateTime = _ref7 => {
|
|
|
3941
3829
|
const formatBoolean = _ref8 => {
|
|
3942
3830
|
let value = _ref8.value,
|
|
3943
3831
|
intl = _ref8.intl;
|
|
3944
|
-
return value ? intl.formatMessage(messages$
|
|
3832
|
+
return value ? intl.formatMessage(messages$K.booleanYes) : intl.formatMessage(messages$K.booleanNo);
|
|
3945
3833
|
};
|
|
3946
3834
|
const formatNilType = _ref9 => {
|
|
3947
3835
|
let value = _ref9.value,
|
|
@@ -4125,9 +4013,9 @@ const getPrefixSearchBounds = input => {
|
|
|
4125
4013
|
};
|
|
4126
4014
|
var getPrefixSearchBounds$1 = getPrefixSearchBounds;
|
|
4127
4015
|
|
|
4128
|
-
const _excluded$
|
|
4129
|
-
function ownKeys$
|
|
4130
|
-
function _objectSpread$
|
|
4016
|
+
const _excluded$c = ["action"];
|
|
4017
|
+
function ownKeys$18(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
4018
|
+
function _objectSpread$18(e) { for (var r = 1; r < arguments.length; r++) { var _context0, _context1; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context0 = ownKeys$18(Object(t), !0)).call(_context0, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context1 = ownKeys$18(Object(t))).call(_context1, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
4131
4019
|
|
|
4132
4020
|
/**
|
|
4133
4021
|
* Checks if a value is a LocalizedString
|
|
@@ -4149,7 +4037,7 @@ const getIsLocalizedString = maybeLocalizedString => {
|
|
|
4149
4037
|
*/
|
|
4150
4038
|
const transformCustomFieldsRawToCustomFields = customFieldsRaw => {
|
|
4151
4039
|
if (!customFieldsRaw || customFieldsRaw.length === 0) return null;
|
|
4152
|
-
return _reduceInstanceProperty__default["default"](customFieldsRaw).call(customFieldsRaw, (customFields, customField) => _objectSpread$
|
|
4040
|
+
return _reduceInstanceProperty__default["default"](customFieldsRaw).call(customFieldsRaw, (customFields, customField) => _objectSpread$18(_objectSpread$18({}, customFields), {}, {
|
|
4153
4041
|
[customField.name]: customField.value
|
|
4154
4042
|
}), {});
|
|
4155
4043
|
};
|
|
@@ -4173,7 +4061,7 @@ function transformLocalizedFieldsForCategory(category) {
|
|
|
4173
4061
|
const transformedData = l10n.applyTransformedLocalizedFields(category, transformationOptions);
|
|
4174
4062
|
const parent = category.parent ? transformLocalizedFieldsForCategory(category.parent) : null;
|
|
4175
4063
|
const ancestors = category.ancestors ? _mapInstanceProperty__default["default"](_context = category.ancestors).call(_context, ancestor => transformLocalizedFieldsForCategory(ancestor)) : null;
|
|
4176
|
-
return _objectSpread$
|
|
4064
|
+
return _objectSpread$18(_objectSpread$18(_objectSpread$18({}, transformedData), parent ? {
|
|
4177
4065
|
parent
|
|
4178
4066
|
} : {}), ancestors ? {
|
|
4179
4067
|
ancestors
|
|
@@ -4266,7 +4154,7 @@ const formatMoney = valueType => money => {
|
|
|
4266
4154
|
case 'fixed':
|
|
4267
4155
|
case 'fixedCart':
|
|
4268
4156
|
return {
|
|
4269
|
-
[money.type]: _objectSpread$
|
|
4157
|
+
[money.type]: _objectSpread$18({
|
|
4270
4158
|
centAmount: money.centAmount,
|
|
4271
4159
|
currencyCode: money.currencyCode
|
|
4272
4160
|
}, money.type === PRECISION_TYPES.highPrecision && {
|
|
@@ -4448,7 +4336,7 @@ const convertAction = (actionName, actionPayload) => {
|
|
|
4448
4336
|
case 'addAttributeDefinition':
|
|
4449
4337
|
return {
|
|
4450
4338
|
[actionName]: {
|
|
4451
|
-
attributeDefinition: _objectSpread$
|
|
4339
|
+
attributeDefinition: _objectSpread$18(_objectSpread$18({}, actionPayload.attribute), {}, {
|
|
4452
4340
|
label: l10n.transformLocalizedStringToLocalizedField(actionPayload.attribute.label),
|
|
4453
4341
|
inputTip: l10n.transformLocalizedStringToLocalizedField(actionPayload.attribute.inputTip),
|
|
4454
4342
|
type: createAttributeTypeValue(actionPayload.attribute)
|
|
@@ -4544,7 +4432,7 @@ const convertAction = (actionName, actionPayload) => {
|
|
|
4544
4432
|
return {
|
|
4545
4433
|
[actionName]: {
|
|
4546
4434
|
attributeName: actionPayload.attributeName,
|
|
4547
|
-
value: _objectSpread$
|
|
4435
|
+
value: _objectSpread$18(_objectSpread$18({}, actionPayload.value), {}, {
|
|
4548
4436
|
label: l10n.transformLocalizedStringToLocalizedField(actionPayload.value.label)
|
|
4549
4437
|
})
|
|
4550
4438
|
}
|
|
@@ -4553,7 +4441,7 @@ const convertAction = (actionName, actionPayload) => {
|
|
|
4553
4441
|
return {
|
|
4554
4442
|
[actionName]: {
|
|
4555
4443
|
attributeName: actionPayload.attributeName,
|
|
4556
|
-
newValue: _objectSpread$
|
|
4444
|
+
newValue: _objectSpread$18(_objectSpread$18({}, actionPayload.newValue), {}, {
|
|
4557
4445
|
label: l10n.transformLocalizedStringToLocalizedField(actionPayload.newValue.label)
|
|
4558
4446
|
})
|
|
4559
4447
|
}
|
|
@@ -4580,7 +4468,7 @@ const convertAction = (actionName, actionPayload) => {
|
|
|
4580
4468
|
name: l10n.transformLocalizedStringToLocalizedField(actionPayload.name),
|
|
4581
4469
|
taxCategory: actionPayload.taxCategory,
|
|
4582
4470
|
money: {
|
|
4583
|
-
[actionPayload.money.type]: _objectSpread$
|
|
4471
|
+
[actionPayload.money.type]: _objectSpread$18({
|
|
4584
4472
|
centAmount: actionPayload.money.centAmount,
|
|
4585
4473
|
currencyCode: actionPayload.money.currencyCode
|
|
4586
4474
|
}, actionPayload.money.type === PRECISION_TYPES.highPrecision && {
|
|
@@ -4608,7 +4496,7 @@ const convertAction = (actionName, actionPayload) => {
|
|
|
4608
4496
|
return {
|
|
4609
4497
|
[actionName]: {
|
|
4610
4498
|
target: {
|
|
4611
|
-
[actionPayload.target.type]: _objectSpread$
|
|
4499
|
+
[actionPayload.target.type]: _objectSpread$18(_objectSpread$18(_objectSpread$18({}, omit__default["default"](actionPayload.target, ['type', '__typename'])), actionPayload.target.triggerPattern && {
|
|
4612
4500
|
triggerPattern: _mapInstanceProperty__default["default"](_context6 = actionPayload.target.triggerPattern).call(_context6, pattern => ({
|
|
4613
4501
|
[pattern.type]: omit__default["default"](pattern, ['type', '__typename'])
|
|
4614
4502
|
}))
|
|
@@ -4643,8 +4531,8 @@ const convertAction = (actionName, actionPayload) => {
|
|
|
4643
4531
|
fields: customFields
|
|
4644
4532
|
} : null;
|
|
4645
4533
|
return {
|
|
4646
|
-
[actionName]: _objectSpread$
|
|
4647
|
-
address: _objectSpread$
|
|
4534
|
+
[actionName]: _objectSpread$18(_objectSpread$18({}, actionPayload), {}, {
|
|
4535
|
+
address: _objectSpread$18(_objectSpread$18({}, omit__default["default"](actionPayload.address, ['__typename'])), {}, {
|
|
4648
4536
|
custom
|
|
4649
4537
|
})
|
|
4650
4538
|
})
|
|
@@ -4686,7 +4574,7 @@ const convertAction = (actionName, actionPayload) => {
|
|
|
4686
4574
|
};
|
|
4687
4575
|
const createGraphQlUpdateActions = actions => _reduceInstanceProperty__default["default"](actions).call(actions, (previousActions, _ref9) => {
|
|
4688
4576
|
let actionName = _ref9.action,
|
|
4689
|
-
actionPayload = _objectWithoutProperties(_ref9, _excluded$
|
|
4577
|
+
actionPayload = _objectWithoutProperties(_ref9, _excluded$c);
|
|
4690
4578
|
return [...previousActions, convertAction(actionName, actionPayload)];
|
|
4691
4579
|
}, []);
|
|
4692
4580
|
const extractErrorFromGraphQlResponse = graphQlResponse => {
|
|
@@ -4752,8 +4640,8 @@ function omitDeep(obj, fieldsToOmit) {
|
|
|
4752
4640
|
return originalOmitDeep__default["default"](obj, fieldsToOmit);
|
|
4753
4641
|
}
|
|
4754
4642
|
|
|
4755
|
-
function ownKeys$
|
|
4756
|
-
function _objectSpread$
|
|
4643
|
+
function ownKeys$17(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
4644
|
+
function _objectSpread$17(e) { for (var r = 1; r < arguments.length; r++) { var _context5, _context6; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context5 = ownKeys$17(Object(t), !0)).call(_context5, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context6 = ownKeys$17(Object(t))).call(_context6, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
4757
4645
|
function getPriceChannelName(price) {
|
|
4758
4646
|
return price.channel?.name ?? price.channel?.key ?? null;
|
|
4759
4647
|
}
|
|
@@ -4765,11 +4653,11 @@ function getDiscountValue(price) {
|
|
|
4765
4653
|
} else if (price.value?.type === PRECISION_TYPES.highPrecision && price.discounted?.value?.type === PRECISION_TYPES.centPrecision) {
|
|
4766
4654
|
fractionedAmount = getFractionedAmount(price.value) - getFractionedAmount(price.discounted.value);
|
|
4767
4655
|
}
|
|
4768
|
-
return price.discounted ? _objectSpread$
|
|
4656
|
+
return price.discounted ? _objectSpread$17(_objectSpread$17({}, price.value), {}, {
|
|
4769
4657
|
fractionedAmount,
|
|
4770
4658
|
centAmount: price.value.centAmount - price.discounted.value.centAmount,
|
|
4771
4659
|
preciseAmount
|
|
4772
|
-
}) : _objectSpread$
|
|
4660
|
+
}) : _objectSpread$17(_objectSpread$17({}, price.value), {}, {
|
|
4773
4661
|
centAmount: 0
|
|
4774
4662
|
});
|
|
4775
4663
|
}
|
|
@@ -4800,7 +4688,7 @@ function getNetUnitPrice(_ref) {
|
|
|
4800
4688
|
}
|
|
4801
4689
|
let preciseAmount;
|
|
4802
4690
|
if (price.value?.type === PRECISION_TYPES.highPrecision) preciseAmount = price.value.preciseAmount / (1 + taxRate.amount);
|
|
4803
|
-
return _objectSpread$
|
|
4691
|
+
return _objectSpread$17(_objectSpread$17({}, price.value), {}, {
|
|
4804
4692
|
centAmount,
|
|
4805
4693
|
preciseAmount
|
|
4806
4694
|
});
|
|
@@ -4816,7 +4704,7 @@ function getNetUnitPrice(_ref) {
|
|
|
4816
4704
|
}
|
|
4817
4705
|
let preciseAmount;
|
|
4818
4706
|
if (price.value?.type === PRECISION_TYPES.highPrecision) preciseAmount = price.value.preciseAmount / (1 + lineItem.taxRate.amount);
|
|
4819
|
-
return _objectSpread$
|
|
4707
|
+
return _objectSpread$17(_objectSpread$17({}, price.value), {}, {
|
|
4820
4708
|
centAmount,
|
|
4821
4709
|
preciseAmount
|
|
4822
4710
|
});
|
|
@@ -4828,7 +4716,7 @@ function getMinimumPricesByCurrencyCode(prices) {
|
|
|
4828
4716
|
const currencyCode = price.value.currencyCode;
|
|
4829
4717
|
const fractionedAmount = getFractionedAmount(price.value);
|
|
4830
4718
|
if (currencyCode && !isNil__default["default"](fractionedAmount)) {
|
|
4831
|
-
if (!minPrices[currencyCode] || fractionedAmount < getFractionedAmount(minPrices[currencyCode])) return _objectSpread$
|
|
4719
|
+
if (!minPrices[currencyCode] || fractionedAmount < getFractionedAmount(minPrices[currencyCode])) return _objectSpread$17(_objectSpread$17({}, minPrices), {}, {
|
|
4832
4720
|
[currencyCode]: price.value
|
|
4833
4721
|
});
|
|
4834
4722
|
}
|
|
@@ -4837,8 +4725,8 @@ function getMinimumPricesByCurrencyCode(prices) {
|
|
|
4837
4725
|
return _Object$values__default["default"](minPricesByCurrency);
|
|
4838
4726
|
}
|
|
4839
4727
|
|
|
4840
|
-
function ownKeys$
|
|
4841
|
-
function _objectSpread$
|
|
4728
|
+
function ownKeys$16(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
4729
|
+
function _objectSpread$16(e) { for (var r = 1; r < arguments.length; r++) { var _context5, _context6; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context5 = ownKeys$16(Object(t), !0)).call(_context5, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context6 = ownKeys$16(Object(t))).call(_context6, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
4842
4730
|
const transformCustomFieldFromGraphQLResponse = resource => {
|
|
4843
4731
|
var _context, _context4;
|
|
4844
4732
|
return {
|
|
@@ -4853,14 +4741,14 @@ const transformCustomFieldFromGraphQLResponse = resource => {
|
|
|
4853
4741
|
return {
|
|
4854
4742
|
name: fieldDefinition.name,
|
|
4855
4743
|
required: fieldDefinition.required,
|
|
4856
|
-
type: fieldDefinition.type?.elementType?.name === 'LocalizedEnum' ? _objectSpread$
|
|
4857
|
-
elementType: _objectSpread$
|
|
4744
|
+
type: fieldDefinition.type?.elementType?.name === 'LocalizedEnum' ? _objectSpread$16(_objectSpread$16({}, fieldDefinition.type), {}, {
|
|
4745
|
+
elementType: _objectSpread$16(_objectSpread$16({}, fieldDefinition.type.elementType), {}, {
|
|
4858
4746
|
values: _mapInstanceProperty__default["default"](_context2 = _valuesInstanceProperty__default["default"](fieldDefinition.type.elementType)).call(_context2, value => ({
|
|
4859
4747
|
key: value.key,
|
|
4860
4748
|
label: l10n.transformLocalizedFieldToLocalizedString(value.labelAllLocales)
|
|
4861
4749
|
}))
|
|
4862
4750
|
})
|
|
4863
|
-
}) : fieldDefinition.type?.name === 'LocalizedEnum' ? _objectSpread$
|
|
4751
|
+
}) : fieldDefinition.type?.name === 'LocalizedEnum' ? _objectSpread$16(_objectSpread$16({}, fieldDefinition.type), {}, {
|
|
4864
4752
|
values: _mapInstanceProperty__default["default"](_context3 = _valuesInstanceProperty__default["default"](fieldDefinition.type)).call(_context3, value => ({
|
|
4865
4753
|
key: value.key,
|
|
4866
4754
|
label: l10n.transformLocalizedFieldToLocalizedString(value.labelAllLocales)
|
|
@@ -4871,7 +4759,7 @@ const transformCustomFieldFromGraphQLResponse = resource => {
|
|
|
4871
4759
|
})
|
|
4872
4760
|
}
|
|
4873
4761
|
},
|
|
4874
|
-
fields: _reduceInstanceProperty__default["default"](_context4 = resource.custom.customFieldsRaw).call(_context4, (fields, customField) => _objectSpread$
|
|
4762
|
+
fields: _reduceInstanceProperty__default["default"](_context4 = resource.custom.customFieldsRaw).call(_context4, (fields, customField) => _objectSpread$16(_objectSpread$16({}, fields), {}, {
|
|
4875
4763
|
[customField.name]: customField.value
|
|
4876
4764
|
}), {})
|
|
4877
4765
|
};
|
|
@@ -4883,7 +4771,7 @@ const convertProductSelectionFromGraphQl = productSelection => {
|
|
|
4883
4771
|
// Incase the product selection is not missing or if the current project dose not yet have access to the feature,
|
|
4884
4772
|
// in either case we return null
|
|
4885
4773
|
if (!productSelection) return null;
|
|
4886
|
-
return _objectSpread$
|
|
4774
|
+
return _objectSpread$16(_objectSpread$16({}, l10n.applyTransformedLocalizedFields(productSelection, [{
|
|
4887
4775
|
from: 'nameAllLocales',
|
|
4888
4776
|
to: 'name'
|
|
4889
4777
|
}])), {}, {
|
|
@@ -4906,8 +4794,8 @@ const transformAllToProperNounCase = text => {
|
|
|
4906
4794
|
return _mapInstanceProperty__default["default"](_context = text.split(' ')).call(_context, term => transformToProperNounCase(term)).join(' ');
|
|
4907
4795
|
};
|
|
4908
4796
|
|
|
4909
|
-
function ownKeys$
|
|
4910
|
-
function _objectSpread$
|
|
4797
|
+
function ownKeys$15(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
4798
|
+
function _objectSpread$15(e) { for (var r = 1; r < arguments.length; r++) { var _context3, _context4; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context3 = ownKeys$15(Object(t), !0)).call(_context3, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context4 = ownKeys$15(Object(t))).call(_context4, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
4911
4799
|
const REGEX_ISO8601 = /(\d{4}-\d{2}-\d{2}[T]\d{2}:\d{2}:\d{2}(\.\d{3}[Z]?))/;
|
|
4912
4800
|
const REGEX_TIME = /\d{2}:\d{2}/;
|
|
4913
4801
|
const REGEX_DATE = /\d{4}-\d{2}-\d{2}/;
|
|
@@ -4924,7 +4812,7 @@ function filterCustomTypeUpdateActionValues() {
|
|
|
4924
4812
|
if (updateAction.action === 'setCustomField' && _Array$isArray__default["default"](updateAction.value)) {
|
|
4925
4813
|
const definition = _findInstanceProperty__default["default"](fieldDefinitions).call(fieldDefinitions, field => field.name === updateAction.name);
|
|
4926
4814
|
const definitionName = definition.type.elementType.name;
|
|
4927
|
-
return _objectSpread$
|
|
4815
|
+
return _objectSpread$15(_objectSpread$15({}, updateAction), {}, {
|
|
4928
4816
|
value: filterNotDefinedValues(updateAction.value, definitionName)
|
|
4929
4817
|
});
|
|
4930
4818
|
}
|
|
@@ -5097,7 +4985,7 @@ function uniqueObjects(items) {
|
|
|
5097
4985
|
|
|
5098
4986
|
*/
|
|
5099
4987
|
|
|
5100
|
-
const messages$
|
|
4988
|
+
const messages$J = reactIntl.defineMessages({
|
|
5101
4989
|
unique: {
|
|
5102
4990
|
id: 'Validation.unique',
|
|
5103
4991
|
description: 'An error message to show if the field must be unique',
|
|
@@ -5139,7 +5027,7 @@ const messages$K = reactIntl.defineMessages({
|
|
|
5139
5027
|
defaultMessage: 'Invalid ID format. Please enter a valid ID.'
|
|
5140
5028
|
}
|
|
5141
5029
|
});
|
|
5142
|
-
var validationMessages = messages$
|
|
5030
|
+
var validationMessages = messages$J;
|
|
5143
5031
|
|
|
5144
5032
|
function getIndexesOfInvalidValues(values) {
|
|
5145
5033
|
let invalidValues = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];
|
|
@@ -5329,7 +5217,7 @@ const useReferenceSearchItems = _ref2 => {
|
|
|
5329
5217
|
items
|
|
5330
5218
|
};
|
|
5331
5219
|
};
|
|
5332
|
-
var _ref$
|
|
5220
|
+
var _ref$d = {
|
|
5333
5221
|
name: "befiq5",
|
|
5334
5222
|
styles: "width:100%;>div{width:100%;}"
|
|
5335
5223
|
} ;
|
|
@@ -5361,7 +5249,7 @@ function ReferenceSearch(props) {
|
|
|
5361
5249
|
const option = props.isMulti ? _mapInstanceProperty__default["default"](_context3 = event.target.value).call(_context3, item => item.value) : event.target.value?.value || null;
|
|
5362
5250
|
props.onChange(option);
|
|
5363
5251
|
};
|
|
5364
|
-
const containerStyles = _ref$
|
|
5252
|
+
const containerStyles = _ref$d;
|
|
5365
5253
|
return jsxRuntime.jsxs("div", {
|
|
5366
5254
|
css: containerStyles,
|
|
5367
5255
|
children: [areSomeItemsMissing && jsxRuntime.jsx("div", {
|
|
@@ -5399,7 +5287,7 @@ function ReferenceSearch(props) {
|
|
|
5399
5287
|
});
|
|
5400
5288
|
}
|
|
5401
5289
|
|
|
5402
|
-
const messages$
|
|
5290
|
+
const messages$H = reactIntl.defineMessages({
|
|
5403
5291
|
placeholder: {
|
|
5404
5292
|
id: 'CartDiscountReferenceSearch.placeholder',
|
|
5405
5293
|
description: 'Placeholder for search for a cart discount',
|
|
@@ -5426,10 +5314,10 @@ const messages$I = reactIntl.defineMessages({
|
|
|
5426
5314
|
defaultMessage: 'Enter search term'
|
|
5427
5315
|
}
|
|
5428
5316
|
});
|
|
5429
|
-
var messages$
|
|
5317
|
+
var messages$I = messages$H;
|
|
5430
5318
|
|
|
5431
|
-
function ownKeys$
|
|
5432
|
-
function _objectSpread$
|
|
5319
|
+
function ownKeys$14(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
5320
|
+
function _objectSpread$14(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$14(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$14(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
5433
5321
|
function Option$1(props) {
|
|
5434
5322
|
const _useApplicationContex = applicationShellConnectors.useApplicationContext(applicationContext => ({
|
|
5435
5323
|
language: applicationContext.dataLocale,
|
|
@@ -5440,7 +5328,7 @@ function Option$1(props) {
|
|
|
5440
5328
|
const _useIntl = reactIntl.useIntl(),
|
|
5441
5329
|
formatMessage = _useIntl.formatMessage;
|
|
5442
5330
|
const cartDiscount = props.data;
|
|
5443
|
-
return jsxRuntime.jsx(uiKit.AsyncSelectInput.Option, _objectSpread$
|
|
5331
|
+
return jsxRuntime.jsx(uiKit.AsyncSelectInput.Option, _objectSpread$14(_objectSpread$14({}, props), {}, {
|
|
5444
5332
|
children: jsxRuntime.jsxs("div", {
|
|
5445
5333
|
"data-testid": "cart-discount-option",
|
|
5446
5334
|
children: [jsxRuntime.jsx(uiKit.Text.Detail, {
|
|
@@ -5451,14 +5339,14 @@ function Option$1(props) {
|
|
|
5451
5339
|
fallbackOrder: languages
|
|
5452
5340
|
})
|
|
5453
5341
|
}), jsxRuntime.jsxs(uiKit.Text.Detail, {
|
|
5454
|
-
children: [formatMessage(messages$
|
|
5342
|
+
children: [formatMessage(messages$I.key), ": ", cartDiscount.key || constants.NO_VALUE_FALLBACK]
|
|
5455
5343
|
})]
|
|
5456
5344
|
})
|
|
5457
5345
|
}));
|
|
5458
5346
|
}
|
|
5459
5347
|
|
|
5460
|
-
function ownKeys$
|
|
5461
|
-
function _objectSpread$
|
|
5348
|
+
function ownKeys$13(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
5349
|
+
function _objectSpread$13(e) { for (var r = 1; r < arguments.length; r++) { var _context2, _context3; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context2 = ownKeys$13(Object(t), !0)).call(_context2, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context3 = ownKeys$13(Object(t))).call(_context3, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
5462
5350
|
var CartDiscountsCount$1 = { kind: "Document", definitions: [{ kind: "OperationDefinition", operation: "query", name: { kind: "Name", value: "CartDiscountsCount" }, variableDefinitions: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "cartDiscounts" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "total" }, arguments: [], directives: [] }] } }] } }], loc: { start: 0, end: 425, source: { body: "query SearchCartDiscount($where: String) {\n cartDiscounts(limit: 500, where: $where) {\n total\n results {\n id\n key\n nameAllLocales {\n locale\n value\n }\n }\n }\n}\n\nquery CartDiscountsCount {\n cartDiscounts {\n total\n }\n}\n\nquery FetchCartDiscountById($cartDiscountId: String!) {\n cartDiscount(id: $cartDiscountId) {\n id\n nameAllLocales {\n locale\n value\n }\n }\n}\n", name: "GraphQL request", locationOffset: { line: 1, column: 1 } } } };
|
|
5463
5351
|
const returnNullIfEmpty = value => value && value.id === '' ? null : value;
|
|
5464
5352
|
const filterOption$1 = (option, text) => {
|
|
@@ -5484,7 +5372,7 @@ function CartDiscountReferenceSearch(props) {
|
|
|
5484
5372
|
})),
|
|
5485
5373
|
language = _useApplicationContex.language,
|
|
5486
5374
|
languages = _useApplicationContex.languages;
|
|
5487
|
-
const mapItemToOption = React.useCallback(cartDiscount => _objectSpread$
|
|
5375
|
+
const mapItemToOption = React.useCallback(cartDiscount => _objectSpread$13(_objectSpread$13({}, cartDiscount), {}, {
|
|
5488
5376
|
value: cartDiscount.id,
|
|
5489
5377
|
key: cartDiscount.key,
|
|
5490
5378
|
label: l10n.formatLocalizedString(cartDiscount, {
|
|
@@ -5527,10 +5415,10 @@ function CartDiscountReferenceSearch(props) {
|
|
|
5527
5415
|
onBlur: props.onBlur,
|
|
5528
5416
|
onChange: props.onChange,
|
|
5529
5417
|
value: returnNullIfEmpty(props.value),
|
|
5530
|
-
placeholderLabel: formatMessage(messages$
|
|
5531
|
-
searchPromptLabel: formatMessage(messages$
|
|
5532
|
-
noResultsLabel: formatMessage(messages$
|
|
5533
|
-
referenceIsMissingLabel: formatMessage(messages$
|
|
5418
|
+
placeholderLabel: formatMessage(messages$I.placeholder),
|
|
5419
|
+
searchPromptLabel: formatMessage(messages$I.searchPrompt),
|
|
5420
|
+
noResultsLabel: formatMessage(messages$I.noResults),
|
|
5421
|
+
referenceIsMissingLabel: formatMessage(messages$I.isMissing),
|
|
5534
5422
|
mapItemToOption: mapItemToOption,
|
|
5535
5423
|
loadItemsBySearchTerm: loadItemsBySearchTerm,
|
|
5536
5424
|
loadItemsByIds: loadItemsByIds,
|
|
@@ -5540,7 +5428,7 @@ function CartDiscountReferenceSearch(props) {
|
|
|
5540
5428
|
});
|
|
5541
5429
|
}
|
|
5542
5430
|
|
|
5543
|
-
const messages$
|
|
5431
|
+
const messages$F = reactIntl.defineMessages({
|
|
5544
5432
|
placeholder: {
|
|
5545
5433
|
id: 'CategoryReferenceSearch.placeholder',
|
|
5546
5434
|
description: 'Placeholder for search for a category',
|
|
@@ -5572,10 +5460,10 @@ const messages$G = reactIntl.defineMessages({
|
|
|
5572
5460
|
defaultMessage: 'Parent Category'
|
|
5573
5461
|
}
|
|
5574
5462
|
});
|
|
5575
|
-
var messages$
|
|
5463
|
+
var messages$G = messages$F;
|
|
5576
5464
|
|
|
5577
|
-
function ownKeys$
|
|
5578
|
-
function _objectSpread$
|
|
5465
|
+
function ownKeys$12(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
5466
|
+
function _objectSpread$12(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$12(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$12(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
5579
5467
|
function Option(props) {
|
|
5580
5468
|
const _useApplicationContex = applicationShellConnectors.useApplicationContext(applicationContext => ({
|
|
5581
5469
|
language: applicationContext.dataLocale,
|
|
@@ -5586,7 +5474,7 @@ function Option(props) {
|
|
|
5586
5474
|
const _useIntl = reactIntl.useIntl(),
|
|
5587
5475
|
formatMessage = _useIntl.formatMessage;
|
|
5588
5476
|
const category = props.data;
|
|
5589
|
-
return jsxRuntime.jsx(uiKit.AsyncSelectInput.Option, _objectSpread$
|
|
5477
|
+
return jsxRuntime.jsx(uiKit.AsyncSelectInput.Option, _objectSpread$12(_objectSpread$12({}, props), {}, {
|
|
5590
5478
|
children: jsxRuntime.jsxs("div", {
|
|
5591
5479
|
"data-testid": "category-option",
|
|
5592
5480
|
children: [jsxRuntime.jsx(uiKit.Text.Body, {
|
|
@@ -5597,7 +5485,7 @@ function Option(props) {
|
|
|
5597
5485
|
fallbackOrder: languages
|
|
5598
5486
|
})
|
|
5599
5487
|
}), category.parent && jsxRuntime.jsx(uiKit.Text.Detail, {
|
|
5600
|
-
children: `${formatMessage(messages$
|
|
5488
|
+
children: `${formatMessage(messages$G.parentCategory)}: ${l10n.formatLocalizedString(category.parent, {
|
|
5601
5489
|
key: 'name',
|
|
5602
5490
|
locale: language,
|
|
5603
5491
|
fallbackOrder: languages
|
|
@@ -5609,14 +5497,14 @@ function Option(props) {
|
|
|
5609
5497
|
fallbackOrder: languages
|
|
5610
5498
|
})}`
|
|
5611
5499
|
}), category.externalId && jsxRuntime.jsx(uiKit.Text.Detail, {
|
|
5612
|
-
children: `${formatMessage(messages$
|
|
5500
|
+
children: `${formatMessage(messages$G.externalId)}: ${category.externalId || constants.NO_VALUE_FALLBACK}`
|
|
5613
5501
|
})]
|
|
5614
5502
|
})
|
|
5615
5503
|
}));
|
|
5616
5504
|
}
|
|
5617
5505
|
|
|
5618
|
-
function ownKeys$
|
|
5619
|
-
function _objectSpread$
|
|
5506
|
+
function ownKeys$11(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
5507
|
+
function _objectSpread$11(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$11(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$11(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
5620
5508
|
const filterOption = () => true;
|
|
5621
5509
|
function CategoryReferenceSearch(props) {
|
|
5622
5510
|
const _useIntl = reactIntl.useIntl(),
|
|
@@ -5628,7 +5516,7 @@ function CategoryReferenceSearch(props) {
|
|
|
5628
5516
|
})),
|
|
5629
5517
|
language = _useApplicationContex.language,
|
|
5630
5518
|
languages = _useApplicationContex.languages;
|
|
5631
|
-
const mapItemToOption = React.useCallback(category => _objectSpread$
|
|
5519
|
+
const mapItemToOption = React.useCallback(category => _objectSpread$11(_objectSpread$11({}, category), {}, {
|
|
5632
5520
|
value: category.id,
|
|
5633
5521
|
label: l10n.formatLocalizedString(category, {
|
|
5634
5522
|
key: 'name',
|
|
@@ -5646,7 +5534,7 @@ function CategoryReferenceSearch(props) {
|
|
|
5646
5534
|
}), [apolloClient]);
|
|
5647
5535
|
return jsxRuntime.jsx(ReferenceSearch, {
|
|
5648
5536
|
id: props.id,
|
|
5649
|
-
components: _objectSpread$
|
|
5537
|
+
components: _objectSpread$11({
|
|
5650
5538
|
Option
|
|
5651
5539
|
}, props.components),
|
|
5652
5540
|
isClearable: props.isClearable,
|
|
@@ -5657,10 +5545,10 @@ function CategoryReferenceSearch(props) {
|
|
|
5657
5545
|
onBlur: props.onBlur,
|
|
5658
5546
|
onChange: props.onChange,
|
|
5659
5547
|
value: props.value,
|
|
5660
|
-
placeholderLabel: formatMessage(messages$
|
|
5661
|
-
searchPromptLabel: formatMessage(messages$
|
|
5662
|
-
noResultsLabel: formatMessage(messages$
|
|
5663
|
-
referenceIsMissingLabel: formatMessage(messages$
|
|
5548
|
+
placeholderLabel: formatMessage(messages$G.placeholder),
|
|
5549
|
+
searchPromptLabel: formatMessage(messages$G.searchPrompt),
|
|
5550
|
+
noResultsLabel: formatMessage(messages$G.noResults),
|
|
5551
|
+
referenceIsMissingLabel: formatMessage(messages$G.isMissing),
|
|
5664
5552
|
mapItemToOption: mapItemToOption,
|
|
5665
5553
|
loadItemsBySearchTerm: loadItemsBySearchTerm,
|
|
5666
5554
|
loadItemsByIds: loadItemsByIds,
|
|
@@ -5687,7 +5575,7 @@ function useCachedCategoryOptions(ids) {
|
|
|
5687
5575
|
|
|
5688
5576
|
const getFileInputStyles = () => /*#__PURE__*/react$1.css("display:inline-flex;background-color:", designSystem.designTokens.colorSurface, ";border:1px solid ", designSystem.designTokens.colorNeutral, ";box-shadow:none;border-radius:", designSystem.designTokens.borderRadius4, ";color:", designSystem.designTokens.colorSolid, ";height:", designSystem.designTokens.heightForButtonAsBig, ";font-size:", designSystem.designTokens.fontSize20, ";font-weight:", designSystem.designTokens.fontWeight500, ";align-items:center;transition:background-color ", designSystem.designTokens.transitionLinear80Ms, ";padding:0 ", designSystem.designTokens.spacingM, ";&:hover,&:focus{cursor:pointer;background-color:", designSystem.designTokens.backgroundColorForButtonWhenHovered, ";box-shadow:none;}&:active{box-shadow:", designSystem.designTokens.shadow9, ";background-color:", designSystem.designTokens.colorSurface, ";}" + ("" ), "" );
|
|
5689
5577
|
|
|
5690
|
-
var messages$
|
|
5578
|
+
var messages$E = reactIntl.defineMessages({
|
|
5691
5579
|
chooseFile: {
|
|
5692
5580
|
id: 'ButtonFileInput.chooseFile',
|
|
5693
5581
|
description: 'The label text of the field for upload local file',
|
|
@@ -5695,26 +5583,26 @@ var messages$F = reactIntl.defineMessages({
|
|
|
5695
5583
|
}
|
|
5696
5584
|
});
|
|
5697
5585
|
|
|
5698
|
-
const _excluded$
|
|
5699
|
-
function ownKeys$
|
|
5700
|
-
function _objectSpread$
|
|
5701
|
-
var _ref$
|
|
5586
|
+
const _excluded$b = ["children", "allowMultiple", "acceptTypes"];
|
|
5587
|
+
function ownKeys$10(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
5588
|
+
function _objectSpread$10(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$10(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$10(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
5589
|
+
var _ref$c = {
|
|
5702
5590
|
name: "1wq0eh7",
|
|
5703
5591
|
styles: "visibility:hidden;width:1px;height:1px"
|
|
5704
5592
|
} ;
|
|
5705
5593
|
const FileInput = _ref2 => {
|
|
5706
5594
|
let _ref2$children = _ref2.children,
|
|
5707
|
-
children = _ref2$children === void 0 ? jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$
|
|
5595
|
+
children = _ref2$children === void 0 ? jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$10({}, messages$E.chooseFile)) : _ref2$children,
|
|
5708
5596
|
_ref2$allowMultiple = _ref2.allowMultiple,
|
|
5709
5597
|
allowMultiple = _ref2$allowMultiple === void 0 ? false : _ref2$allowMultiple,
|
|
5710
5598
|
_ref2$acceptTypes = _ref2.acceptTypes,
|
|
5711
5599
|
acceptTypes = _ref2$acceptTypes === void 0 ? 'image/png,image/jpeg,image/gif' : _ref2$acceptTypes,
|
|
5712
|
-
props = _objectWithoutProperties(_ref2, _excluded$
|
|
5600
|
+
props = _objectWithoutProperties(_ref2, _excluded$b);
|
|
5713
5601
|
return jsxRuntime.jsx("label", {
|
|
5714
5602
|
children: jsxRuntime.jsxs("span", {
|
|
5715
5603
|
css: getFileInputStyles(),
|
|
5716
5604
|
children: [jsxRuntime.jsx("input", {
|
|
5717
|
-
css: _ref$
|
|
5605
|
+
css: _ref$c,
|
|
5718
5606
|
type: "file",
|
|
5719
5607
|
accept: acceptTypes,
|
|
5720
5608
|
name: props.name,
|
|
@@ -5727,245 +5615,7 @@ const FileInput = _ref2 => {
|
|
|
5727
5615
|
FileInput.displayName = 'FileInput';
|
|
5728
5616
|
var FileInput$1 = FileInput;
|
|
5729
5617
|
|
|
5730
|
-
|
|
5731
|
-
const baseButtonStyles = {
|
|
5732
|
-
name: "it1691",
|
|
5733
|
-
styles: "color:inherit;padding:0;font:inherit;cursor:pointer;outline:inherit;border:none;background:none"
|
|
5734
|
-
} ;
|
|
5735
|
-
|
|
5736
|
-
const _excluded$c = ["animationOrientation", "children", "onClick"];
|
|
5737
|
-
function ownKeys$11(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
5738
|
-
function _objectSpread$11(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$11(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$11(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
5739
|
-
const ICON_COLOR$1 = '#6359ff';
|
|
5740
|
-
const PaginationIconButton = _ref => {
|
|
5741
|
-
let animationOrientation = _ref.animationOrientation,
|
|
5742
|
-
children = _ref.children,
|
|
5743
|
-
onClick = _ref.onClick,
|
|
5744
|
-
rest = _objectWithoutProperties(_ref, _excluded$c);
|
|
5745
|
-
return jsxRuntime.jsx("button", _objectSpread$11(_objectSpread$11({
|
|
5746
|
-
css: [baseButtonStyles, /*#__PURE__*/react$1.css("svg{fill:", ICON_COLOR$1, ";}transition:transform ", uiKit.designTokens.transitionStandard, ";:hover{transform:translateX(\n ", animationOrientation === 'left' ? `calc(0px - var(--spacing-10))` : `var(--spacing-10)`, "\n );}padding-left:1px;padding-right:1px;:focus{border:1px solid ", ICON_COLOR$1, ";border-radius:", uiKit.designTokens.borderRadius1, ";padding-left:0px;padding-right:0px;}" + ("" ), "" ), "" , "" ],
|
|
5747
|
-
onClick: onClick
|
|
5748
|
-
}, rest), {}, {
|
|
5749
|
-
children: children
|
|
5750
|
-
}));
|
|
5751
|
-
};
|
|
5752
|
-
var PaginationIconButton$1 = PaginationIconButton;
|
|
5753
|
-
|
|
5754
|
-
const _excluded$b = ["isFilled", "onClick"];
|
|
5755
|
-
function ownKeys$10(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
5756
|
-
function _objectSpread$10(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$10(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$10(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
5757
|
-
const ICON_HEIGHT = '10px';
|
|
5758
|
-
const ICON_WIDTH = ICON_HEIGHT;
|
|
5759
|
-
// TODO: Integrate design tokens when redesign is complete
|
|
5760
|
-
const ICON_COLOR = '#6359FF';
|
|
5761
|
-
const ICON_HOVER_COLOR = '#B1ACFF';
|
|
5762
|
-
const PaginationSelectionButton = _ref => {
|
|
5763
|
-
let _ref$isFilled = _ref.isFilled,
|
|
5764
|
-
isFilled = _ref$isFilled === void 0 ? false : _ref$isFilled,
|
|
5765
|
-
onClick = _ref.onClick,
|
|
5766
|
-
rest = _objectWithoutProperties(_ref, _excluded$b);
|
|
5767
|
-
return jsxRuntime.jsx("button", _objectSpread$10({
|
|
5768
|
-
css: [baseButtonStyles, /*#__PURE__*/react$1.css("height:", ICON_HEIGHT, ";width:", ICON_WIDTH, ";border-radius:", uiKit.designTokens.borderRadius6, ";border:", isFilled ? 'none' : `${uiKit.designTokens.borderWidth1} solid ${uiKit.designTokens.colorNeutral}`, ";background:", isFilled ? ICON_COLOR : 'none', ";transition:", uiKit.designTokens.transitionStandard, ";:hover{background:", isFilled ? undefined : ICON_HOVER_COLOR, ";}:focus{border:", uiKit.designTokens.borderWidth1, " solid ", ICON_COLOR, ";}" + ("" ), "" ), "" , "" ],
|
|
5769
|
-
onClick: onClick
|
|
5770
|
-
}, rest));
|
|
5771
|
-
};
|
|
5772
|
-
var PaginationSelectionButton$1 = PaginationSelectionButton;
|
|
5773
|
-
|
|
5774
|
-
const CAROUSEL_WIDTH = 384;
|
|
5775
|
-
const PAGINATION_CONTROL_HEIGHT = 26;
|
|
5776
|
-
const IMAGE_AREA_HEIGHT = 200;
|
|
5777
|
-
const BaseCarousel = _ref2 => {
|
|
5778
|
-
let items = _ref2.items,
|
|
5779
|
-
renderItem = _ref2.renderItem,
|
|
5780
|
-
_ref2$fullWidth = _ref2.fullWidth,
|
|
5781
|
-
fullWidth = _ref2$fullWidth === void 0 ? false : _ref2$fullWidth,
|
|
5782
|
-
_ref2$borderless = _ref2.borderless,
|
|
5783
|
-
borderless = _ref2$borderless === void 0 ? false : _ref2$borderless;
|
|
5784
|
-
// Randomize input array and cache across rerenders
|
|
5785
|
-
const _useState = React.useState(shuffle__default["default"](items)),
|
|
5786
|
-
_useState2 = _slicedToArray(_useState, 2),
|
|
5787
|
-
shuffledItems = _useState2[0],
|
|
5788
|
-
setShuffledItems = _useState2[1];
|
|
5789
|
-
const _useApplicationContex = applicationShellConnectors.useApplicationContext(context => ({
|
|
5790
|
-
projectKey: context.project?.key
|
|
5791
|
-
})),
|
|
5792
|
-
projectKey = _useApplicationContex.projectKey;
|
|
5793
|
-
const handleFilterItemsWhenFlagDisabled = idx => {
|
|
5794
|
-
const newItems = _filterInstanceProperty__default["default"](shuffledItems).call(shuffledItems, (_, idx1) => idx !== idx1);
|
|
5795
|
-
setShuffledItems(newItems);
|
|
5796
|
-
};
|
|
5797
|
-
const _useSnapCarousel = reactSnapCarousel.useSnapCarousel(),
|
|
5798
|
-
scrollRef = _useSnapCarousel.scrollRef,
|
|
5799
|
-
pages = _useSnapCarousel.pages,
|
|
5800
|
-
activePageIndex = _useSnapCarousel.activePageIndex,
|
|
5801
|
-
prev = _useSnapCarousel.prev,
|
|
5802
|
-
next = _useSnapCarousel.next,
|
|
5803
|
-
goTo = _useSnapCarousel.goTo;
|
|
5804
|
-
const handlePrev = () => {
|
|
5805
|
-
if (activePageIndex === 0) {
|
|
5806
|
-
goTo(pages.length - 1);
|
|
5807
|
-
} else {
|
|
5808
|
-
prev();
|
|
5809
|
-
}
|
|
5810
|
-
};
|
|
5811
|
-
const handleNext = () => {
|
|
5812
|
-
if (activePageIndex === pages.length - 1) {
|
|
5813
|
-
goTo(0);
|
|
5814
|
-
} else {
|
|
5815
|
-
next();
|
|
5816
|
-
}
|
|
5817
|
-
};
|
|
5818
|
-
const getLinkTo = activeItem => {
|
|
5819
|
-
if (!activeItem?.linkTo) return undefined;
|
|
5820
|
-
return activeItem.isExternal ? activeItem.linkTo() : activeItem.linkTo(projectKey);
|
|
5821
|
-
};
|
|
5822
|
-
|
|
5823
|
-
// Get the current item safely
|
|
5824
|
-
const currentItem = shuffledItems[activePageIndex];
|
|
5825
|
-
|
|
5826
|
-
// Don't render if there's no current item
|
|
5827
|
-
if (!currentItem) {
|
|
5828
|
-
return null;
|
|
5829
|
-
}
|
|
5830
|
-
return jsxRuntime.jsxs("div", {
|
|
5831
|
-
css: /*#__PURE__*/react$1.css("width:", fullWidth ? '100%' : `${CAROUSEL_WIDTH}px`, ";position:relative;" + ("" ), "" ),
|
|
5832
|
-
role: "region",
|
|
5833
|
-
"aria-roledescription": "carousel",
|
|
5834
|
-
"aria-label": "rotunda",
|
|
5835
|
-
children: [currentItem.linkTo ? jsxRuntime.jsx("a", {
|
|
5836
|
-
href: getLinkTo(currentItem),
|
|
5837
|
-
target: currentItem.isExternal ? '_blank' : '_self',
|
|
5838
|
-
rel: "noopener noreferrer",
|
|
5839
|
-
children: jsxRuntime.jsx(uiKit.Card, {
|
|
5840
|
-
insetScale: 'none',
|
|
5841
|
-
onClick: () => {},
|
|
5842
|
-
type: borderless ? 'flat' : undefined,
|
|
5843
|
-
children: jsxRuntime.jsx("div", {
|
|
5844
|
-
css: /*#__PURE__*/react$1.css("position:relative;display:flex;scroll-snap-type:x mandatory;overflow:hidden;margin:0;padding-bottom:", uiKit.designTokens.spacing60, ";" + ("" ), "" ),
|
|
5845
|
-
ref: scrollRef,
|
|
5846
|
-
children: _mapInstanceProperty__default["default"](shuffledItems).call(shuffledItems, (item, idx) => renderItem({
|
|
5847
|
-
item
|
|
5848
|
-
}, handleFilterItemsWhenFlagDisabled, idx))
|
|
5849
|
-
})
|
|
5850
|
-
})
|
|
5851
|
-
}) : jsxRuntime.jsx(uiKit.Card, {
|
|
5852
|
-
insetScale: 'none',
|
|
5853
|
-
onClick: () => {},
|
|
5854
|
-
type: borderless ? 'flat' : undefined,
|
|
5855
|
-
children: jsxRuntime.jsx("div", {
|
|
5856
|
-
css: /*#__PURE__*/react$1.css("position:relative;display:flex;scroll-snap-type:x mandatory;overflow:hidden;margin:0;padding-bottom:", uiKit.designTokens.spacing60, ";" + ("" ), "" ),
|
|
5857
|
-
ref: scrollRef,
|
|
5858
|
-
children: _mapInstanceProperty__default["default"](shuffledItems).call(shuffledItems, (item, idx) => renderItem({
|
|
5859
|
-
item
|
|
5860
|
-
}, handleFilterItemsWhenFlagDisabled, idx))
|
|
5861
|
-
})
|
|
5862
|
-
}), jsxRuntime.jsx("div", {
|
|
5863
|
-
css: /*#__PURE__*/react$1.css("position:absolute;bottom:", uiKit.designTokens.spacingM, ";left:50%;pointer-events:none;" + ("" ), "" ),
|
|
5864
|
-
children: jsxRuntime.jsx("div", {
|
|
5865
|
-
css: /*#__PURE__*/react$1.css("position:relative;left:-50%;background-color:", uiKit.designTokens.colorSurface, ";pointer-events:auto;height:", PAGINATION_CONTROL_HEIGHT, "px;border-radius:", uiKit.designTokens.borderRadius4, ";padding-left:", uiKit.designTokens.spacing25, ";padding-right:", uiKit.designTokens.spacing25, ";display:flex;align-items:center;" + ("" ), "" ),
|
|
5866
|
-
children: jsxRuntime.jsxs(uiKit.Spacings.Inline, {
|
|
5867
|
-
scale: "m",
|
|
5868
|
-
justifyContent: "center",
|
|
5869
|
-
alignItems: "center",
|
|
5870
|
-
children: [jsxRuntime.jsx(PaginationIconButton$1, {
|
|
5871
|
-
animationOrientation: "left",
|
|
5872
|
-
onClick: handlePrev,
|
|
5873
|
-
"aria-label": "go to previous slide",
|
|
5874
|
-
"data-testid": "go-to-previous-slide-button",
|
|
5875
|
-
children: jsxRuntime.jsx(uiKit.AngleLeftIcon, {
|
|
5876
|
-
size: "small"
|
|
5877
|
-
})
|
|
5878
|
-
}), _mapInstanceProperty__default["default"](pages).call(pages, (_, i) => jsxRuntime.jsx(PaginationSelectionButton$1, {
|
|
5879
|
-
isFilled: activePageIndex === i,
|
|
5880
|
-
onClick: () => goTo(i),
|
|
5881
|
-
"aria-label": `go to slide ${i + 1}`,
|
|
5882
|
-
"data-testid": `go-to-slide-${i + 1}-button`
|
|
5883
|
-
}, i)), jsxRuntime.jsx(PaginationIconButton$1, {
|
|
5884
|
-
animationOrientation: "right",
|
|
5885
|
-
onClick: handleNext,
|
|
5886
|
-
"aria-label": "go to next slide",
|
|
5887
|
-
"data-testid": "go-to-next-slide-button",
|
|
5888
|
-
children: jsxRuntime.jsx(uiKit.AngleRightIcon, {
|
|
5889
|
-
size: "small"
|
|
5890
|
-
})
|
|
5891
|
-
})]
|
|
5892
|
-
})
|
|
5893
|
-
})
|
|
5894
|
-
})]
|
|
5895
|
-
});
|
|
5896
|
-
};
|
|
5897
|
-
var _ref$c = {
|
|
5898
|
-
name: "97rk2e",
|
|
5899
|
-
styles: "width:100%;height:100%;flex-shrink:0;scroll-snap-align:start"
|
|
5900
|
-
} ;
|
|
5901
|
-
const CarouselContent = _ref3 => {
|
|
5902
|
-
let item = _ref3.item,
|
|
5903
|
-
handleFilterItemsWhenFlagDisabled = _ref3.handleFilterItemsWhenFlagDisabled,
|
|
5904
|
-
idx = _ref3.idx,
|
|
5905
|
-
hasPadding = _ref3.hasPadding;
|
|
5906
|
-
const isEnabled = applicationShell.useFeatureToggle(item.flag || '');
|
|
5907
|
-
const intl = reactIntl.useIntl();
|
|
5908
|
-
React.useEffect(() => {
|
|
5909
|
-
if (item.flag && !isEnabled) {
|
|
5910
|
-
handleFilterItemsWhenFlagDisabled(idx);
|
|
5911
|
-
}
|
|
5912
|
-
}, [isEnabled, handleFilterItemsWhenFlagDisabled, idx, item]);
|
|
5913
|
-
if (item.flag && !isEnabled) {
|
|
5914
|
-
return null;
|
|
5915
|
-
}
|
|
5916
|
-
return jsxRuntime.jsx("div", {
|
|
5917
|
-
role: "group",
|
|
5918
|
-
"aria-roledescription": "slide",
|
|
5919
|
-
"aria-label": `slide-${idx + 1}`,
|
|
5920
|
-
css: _ref$c,
|
|
5921
|
-
children: jsxRuntime.jsxs(uiKit.Spacings.Stack, {
|
|
5922
|
-
children: [item.imgSrc && item.imgAlt && jsxRuntime.jsx("img", {
|
|
5923
|
-
css: /*#__PURE__*/react$1.css("width:100%;height:", IMAGE_AREA_HEIGHT, "px;" + ("" ), "" ),
|
|
5924
|
-
src: item.imgSrc,
|
|
5925
|
-
alt: intl.formatMessage(item.imgAlt)
|
|
5926
|
-
}), jsxRuntime.jsx("div", {
|
|
5927
|
-
css: /*#__PURE__*/react$1.css("padding:0 ", hasPadding ? uiKit.designTokens.spacingL : 0, " 0 ", hasPadding ? uiKit.designTokens.spacingL : 0, ";" + ("" ), "" ),
|
|
5928
|
-
children: jsxRuntime.jsxs(uiKit.Spacings.Stack, {
|
|
5929
|
-
scale: "xs",
|
|
5930
|
-
alignItems: "flex-start",
|
|
5931
|
-
children: [item.stampLabel && item.stampTone && jsxRuntime.jsx(uiKit.Stamp, {
|
|
5932
|
-
tone: item.stampTone,
|
|
5933
|
-
label: intl.formatMessage(item.stampLabel),
|
|
5934
|
-
isCondensed: !!item?.isStampCondensed
|
|
5935
|
-
}), jsxRuntime.jsx(uiKit.Text.Body, {
|
|
5936
|
-
intlMessage: item.textContent
|
|
5937
|
-
})]
|
|
5938
|
-
})
|
|
5939
|
-
})]
|
|
5940
|
-
})
|
|
5941
|
-
});
|
|
5942
|
-
};
|
|
5943
|
-
const Carousel = _ref4 => {
|
|
5944
|
-
let items = _ref4.items,
|
|
5945
|
-
_ref4$fullWidth = _ref4.fullWidth,
|
|
5946
|
-
fullWidth = _ref4$fullWidth === void 0 ? false : _ref4$fullWidth,
|
|
5947
|
-
_ref4$borderless = _ref4.borderless,
|
|
5948
|
-
borderless = _ref4$borderless === void 0 ? true : _ref4$borderless,
|
|
5949
|
-
_ref4$hasPadding = _ref4.hasPadding,
|
|
5950
|
-
hasPadding = _ref4$hasPadding === void 0 ? true : _ref4$hasPadding;
|
|
5951
|
-
return jsxRuntime.jsx(BaseCarousel, {
|
|
5952
|
-
fullWidth: fullWidth,
|
|
5953
|
-
borderless: borderless,
|
|
5954
|
-
items: items,
|
|
5955
|
-
renderItem: (_ref5, handleFilterItemsWhenFlagDisabled, idx) => {
|
|
5956
|
-
let item = _ref5.item;
|
|
5957
|
-
return jsxRuntime.jsx(CarouselContent, {
|
|
5958
|
-
handleFilterItemsWhenFlagDisabled: handleFilterItemsWhenFlagDisabled,
|
|
5959
|
-
item: item,
|
|
5960
|
-
idx: idx,
|
|
5961
|
-
hasPadding: hasPadding
|
|
5962
|
-
}, item.id);
|
|
5963
|
-
}
|
|
5964
|
-
});
|
|
5965
|
-
};
|
|
5966
|
-
var Carousel$1 = Carousel;
|
|
5967
|
-
|
|
5968
|
-
var messages$E = reactIntl.defineMessages({
|
|
5618
|
+
var messages$D = reactIntl.defineMessages({
|
|
5969
5619
|
countriesBasicSelectPlaceholder: {
|
|
5970
5620
|
id: 'CountriesPicker.countriesBasicSelectPlaceholder',
|
|
5971
5621
|
description: 'Placeholder of the basic field for countries',
|
|
@@ -5986,7 +5636,7 @@ var messages$E = reactIntl.defineMessages({
|
|
|
5986
5636
|
function ownKeys$$(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
5987
5637
|
function _objectSpread$$(e) { for (var r = 1; r < arguments.length; r++) { var _context8, _context9; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context8 = ownKeys$$(Object(t), !0)).call(_context8, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context9 = ownKeys$$(Object(t))).call(_context9, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
5988
5638
|
const emptyCountryOption = intl => [{
|
|
5989
|
-
label: intl.formatMessage(messages$
|
|
5639
|
+
label: intl.formatMessage(messages$D.countriesAsyncSelectDropdownTypeAheadPrompt),
|
|
5990
5640
|
value: undefined,
|
|
5991
5641
|
isDisabled: true
|
|
5992
5642
|
}];
|
|
@@ -6029,7 +5679,7 @@ function CountriesAsyncSelectDropdown(props) {
|
|
|
6029
5679
|
var _context7;
|
|
6030
5680
|
return _findInstanceProperty__default["default"](_context7 = props.options).call(_context7, country => country.value === countryCode);
|
|
6031
5681
|
}),
|
|
6032
|
-
placeholder: intl.formatMessage(messages$
|
|
5682
|
+
placeholder: intl.formatMessage(messages$D.countriesAsyncSelectPlaceholder),
|
|
6033
5683
|
loadOptions: handleLoadOptions,
|
|
6034
5684
|
onChange: onOptionChange,
|
|
6035
5685
|
isDisabled: props.isDisabled,
|
|
@@ -6049,7 +5699,7 @@ function CountriesBasicSelectDropdown(props) {
|
|
|
6049
5699
|
value: props.value,
|
|
6050
5700
|
isRequired: props.isRequired,
|
|
6051
5701
|
description: props.description,
|
|
6052
|
-
placeholder: intl.formatMessage(messages$
|
|
5702
|
+
placeholder: intl.formatMessage(messages$D.countriesBasicSelectPlaceholder),
|
|
6053
5703
|
options: props.options,
|
|
6054
5704
|
onChange: props.onChange,
|
|
6055
5705
|
isDisabled: props.isDisabled,
|
|
@@ -6085,7 +5735,7 @@ function CountriesPicker(_ref) {
|
|
|
6085
5735
|
});
|
|
6086
5736
|
}
|
|
6087
5737
|
|
|
6088
|
-
var messages$
|
|
5738
|
+
var messages$C = reactIntl.defineMessages({
|
|
6089
5739
|
noCustomerGroupsFound: {
|
|
6090
5740
|
id: 'Prices.CustomerGroupPickerInput.noCustomerGroupsFound',
|
|
6091
5741
|
description: 'The message to display when no customer groups were found',
|
|
@@ -6175,7 +5825,7 @@ const CustomerGroupPickerInput = _ref => {
|
|
|
6175
5825
|
if (isCurrentOptionLoadingFailed) onError(currentOption.error);
|
|
6176
5826
|
}, [isCurrentOptionLoadingFailed, onError, currentOption]);
|
|
6177
5827
|
const isLoadingFailed = isCurrentOptionLoadingFailed || Boolean(loadingError);
|
|
6178
|
-
const handleNoOptions = React.useCallback(() => loadingError ? null : formatMessage(messages$
|
|
5828
|
+
const handleNoOptions = React.useCallback(() => loadingError ? null : formatMessage(messages$C.noCustomerGroupsFound), [loadingError, formatMessage]);
|
|
6179
5829
|
const tooltipTitle = currentOption?.data?.label ?? '';
|
|
6180
5830
|
return jsxRuntime.jsx(uiKit.Constraints.Horizontal, {
|
|
6181
5831
|
max: "scale",
|
|
@@ -6186,7 +5836,7 @@ const CustomerGroupPickerInput = _ref => {
|
|
|
6186
5836
|
children: jsxRuntime.jsx(uiKit.AsyncSelectInput, {
|
|
6187
5837
|
id: name,
|
|
6188
5838
|
name: name,
|
|
6189
|
-
placeholder: placeholder ?? formatMessage(messages$
|
|
5839
|
+
placeholder: placeholder ?? formatMessage(messages$C.placeholder),
|
|
6190
5840
|
loadOptions: loadOptionsDebounced,
|
|
6191
5841
|
defaultOptions: true,
|
|
6192
5842
|
showOptionGroupDivider: true,
|
|
@@ -6213,25 +5863,6 @@ const CustomerGroupPickerInput = _ref => {
|
|
|
6213
5863
|
CustomerGroupPickerInput.displayName = 'CustomerGroupPickerInput';
|
|
6214
5864
|
var CustomerGroupPickerInput$1 = CustomerGroupPickerInput;
|
|
6215
5865
|
|
|
6216
|
-
function Divider(_ref) {
|
|
6217
|
-
let _ref$isDashed = _ref.isDashed,
|
|
6218
|
-
isDashed = _ref$isDashed === void 0 ? false : _ref$isDashed,
|
|
6219
|
-
_ref$orientation = _ref.orientation,
|
|
6220
|
-
orientation = _ref$orientation === void 0 ? 'horizontal' : _ref$orientation;
|
|
6221
|
-
const dividerStyles = /*#__PURE__*/react$1.css("box-sizing:border-box;margin:0;border:0;border-color:var(--color-neutral-90);border-style:", isDashed ? 'dashed' : 'solid', ";", orientation === 'horizontal' ? `
|
|
6222
|
-
width: 100%;
|
|
6223
|
-
border-top-width: 1px;
|
|
6224
|
-
` : `
|
|
6225
|
-
width: 1px;
|
|
6226
|
-
height: 2vmax;
|
|
6227
|
-
border-left-width: 1px;
|
|
6228
|
-
`, ";" + ("" ), "" );
|
|
6229
|
-
return jsxRuntime.jsx("hr", {
|
|
6230
|
-
css: dividerStyles
|
|
6231
|
-
});
|
|
6232
|
-
}
|
|
6233
|
-
Divider.displayName = 'Divider';
|
|
6234
|
-
|
|
6235
5866
|
const FormattedLocalizedString = /*#__PURE__*/React__namespace.memo(_ref => {
|
|
6236
5867
|
let value = _ref.value,
|
|
6237
5868
|
fallback = _ref.fallback;
|
|
@@ -6325,7 +5956,7 @@ const makeChangeHandler = setValue => event => {
|
|
|
6325
5956
|
// attributes.
|
|
6326
5957
|
const omitUnknownValues = (valuesAsMap, fieldDefinitionsAsMap) => omitBy__default["default"](valuesAsMap, (value, key) => isNil__default["default"](fieldDefinitionsAsMap[key]));
|
|
6327
5958
|
|
|
6328
|
-
var messages$
|
|
5959
|
+
var messages$B = reactIntl.defineMessages({
|
|
6329
5960
|
booleanSetInputYesLabel: {
|
|
6330
5961
|
id: 'CustomBooleanInputSet.booleanSetInputYesLabel',
|
|
6331
5962
|
description: 'Custom boolean input set Yes label',
|
|
@@ -6367,13 +5998,13 @@ function CustomBooleanInputSet(props) {
|
|
|
6367
5998
|
formatMessage = _useIntl.formatMessage;
|
|
6368
5999
|
const options = React.useMemo(() => [{
|
|
6369
6000
|
value: 'true',
|
|
6370
|
-
label: formatMessage(messages$
|
|
6001
|
+
label: formatMessage(messages$B.booleanSetInputYesLabel)
|
|
6371
6002
|
}, {
|
|
6372
6003
|
value: 'false',
|
|
6373
|
-
label: formatMessage(messages$
|
|
6004
|
+
label: formatMessage(messages$B.booleanSetInputNoLabel)
|
|
6374
6005
|
}, {
|
|
6375
6006
|
value: 'all',
|
|
6376
|
-
label: formatMessage(messages$
|
|
6007
|
+
label: formatMessage(messages$B.booleanSetInputAllLabel)
|
|
6377
6008
|
}], [formatMessage]);
|
|
6378
6009
|
const handleChange = makeChangeHandler(rawValue => {
|
|
6379
6010
|
const nullifiedIfNeeded = !rawValue ? undefined : valueToBooleanSet(rawValue);
|
|
@@ -6401,7 +6032,7 @@ const ExpandButton = props => props.totalValues > 1 ? jsxRuntime.jsxs(uiKit.Spac
|
|
|
6401
6032
|
scale: "s",
|
|
6402
6033
|
alignItems: "center",
|
|
6403
6034
|
children: [jsxRuntime.jsx(uiKit.Constraints.Horizontal, {
|
|
6404
|
-
children: jsxRuntime.jsx(Divider, {})
|
|
6035
|
+
children: jsxRuntime.jsx(merchantCenterSharedUi.Divider, {})
|
|
6405
6036
|
}), jsxRuntime.jsx(uiKit.FlatButton, {
|
|
6406
6037
|
tone: "primary",
|
|
6407
6038
|
icon: props.isExpanded ? jsxRuntime.jsx(uiKit.AngleUpIcon, {}) : jsxRuntime.jsx(uiKit.AngleDownIcon, {}),
|
|
@@ -6672,7 +6303,7 @@ function CustomDateTimeInput(props) {
|
|
|
6672
6303
|
}
|
|
6673
6304
|
CustomDateTimeInput.displayName = 'CustomDateTimeInput';
|
|
6674
6305
|
|
|
6675
|
-
const convertTypeValuesToOptions$1 = reselect.
|
|
6306
|
+
const convertTypeValuesToOptions$1 = reselect.lruMemoize(typeValues => _mapInstanceProperty__default["default"](typeValues).call(typeValues, typeValue => ({
|
|
6676
6307
|
label: typeValue.label || `${typeValue.key} (key)`,
|
|
6677
6308
|
value: typeValue.key
|
|
6678
6309
|
})));
|
|
@@ -6704,7 +6335,7 @@ function CustomEnumInput(props) {
|
|
|
6704
6335
|
}
|
|
6705
6336
|
CustomEnumInput.displayName = 'CustomEnumInput';
|
|
6706
6337
|
|
|
6707
|
-
const convertTypeValuesToOptions = reselect.
|
|
6338
|
+
const convertTypeValuesToOptions = reselect.lruMemoize((type, dataLocale, languages) => {
|
|
6708
6339
|
var _context;
|
|
6709
6340
|
return _mapInstanceProperty__default["default"](_context = _valuesInstanceProperty__default["default"](type)).call(_context, value => ({
|
|
6710
6341
|
label: l10n.formatLocalizedString(value, {
|
|
@@ -6957,7 +6588,7 @@ const NestingLevelContext = /*#__PURE__*/React.createContext(0);
|
|
|
6957
6588
|
var NestingLevelContext$1 = NestingLevelContext;
|
|
6958
6589
|
|
|
6959
6590
|
// eslint-disable-next-line import/prefer-default-export
|
|
6960
|
-
const messages$
|
|
6591
|
+
const messages$A = reactIntl.defineMessages({
|
|
6961
6592
|
aboveFifthLevelWarning: {
|
|
6962
6593
|
id: 'attributeInputByType.nestedAttributes.aboveFifthLevelWarning',
|
|
6963
6594
|
description: 'Warning message shown when nested attribute are above the fifth level',
|
|
@@ -6969,9 +6600,9 @@ const messages$B = reactIntl.defineMessages({
|
|
|
6969
6600
|
defaultMessage: 'Empty'
|
|
6970
6601
|
}
|
|
6971
6602
|
});
|
|
6972
|
-
var customFieldsMessages = messages$
|
|
6603
|
+
var customFieldsMessages = messages$A;
|
|
6973
6604
|
|
|
6974
|
-
var messages$
|
|
6605
|
+
var messages$z = reactIntl.defineMessages({
|
|
6975
6606
|
updateButton: {
|
|
6976
6607
|
id: 'NestedAttributes.Details.updateButton',
|
|
6977
6608
|
description: 'Update button label',
|
|
@@ -7056,7 +6687,7 @@ const EditButton = props => {
|
|
|
7056
6687
|
formatMessage = _useIntl.formatMessage;
|
|
7057
6688
|
return jsxRuntime.jsx(uiKit.Tooltip, {
|
|
7058
6689
|
placement: "top",
|
|
7059
|
-
title: formatMessage(messages$
|
|
6690
|
+
title: formatMessage(messages$z.editTooltip),
|
|
7060
6691
|
children: jsxRuntime.jsx(uiKit.IconButton, {
|
|
7061
6692
|
label: "Edit",
|
|
7062
6693
|
isDisabled: props.isDisabled,
|
|
@@ -7072,12 +6703,12 @@ const DropChangesConfirmation = props => {
|
|
|
7072
6703
|
formatMessage = _useIntl2.formatMessage;
|
|
7073
6704
|
return jsxRuntime.jsx(applicationComponents.ConfirmationDialog, {
|
|
7074
6705
|
isOpen: props.isOpen || false,
|
|
7075
|
-
title: formatMessage(messages$
|
|
7076
|
-
labelPrimary: formatMessage(messages$
|
|
6706
|
+
title: formatMessage(messages$z.confirmationDialogTitle),
|
|
6707
|
+
labelPrimary: formatMessage(messages$z.nestedAttributesConfirmLabel),
|
|
7077
6708
|
onConfirm: props.onConfirm,
|
|
7078
6709
|
onCancel: props.onCancel,
|
|
7079
6710
|
children: jsxRuntime.jsx(uiKit.Text.Body, {
|
|
7080
|
-
intlMessage: messages$
|
|
6711
|
+
intlMessage: messages$z.confirmationDialogBody
|
|
7081
6712
|
})
|
|
7082
6713
|
});
|
|
7083
6714
|
};
|
|
@@ -7102,11 +6733,11 @@ const NestedAttributeModalPage = props => {
|
|
|
7102
6733
|
children: [jsxRuntime.jsx(uiKit.SecondaryButton, {
|
|
7103
6734
|
isDisabled: !formik$1.dirty,
|
|
7104
6735
|
iconLeft: jsxRuntime.jsx(uiKit.RevertIcon, {}),
|
|
7105
|
-
label: formatMessage(messages$
|
|
6736
|
+
label: formatMessage(messages$z.cancelButton),
|
|
7106
6737
|
onClick: formik$1.resetForm
|
|
7107
6738
|
}), jsxRuntime.jsx(applicationComponents.CustomFormModalPage.FormPrimaryButton, {
|
|
7108
6739
|
isDisabled: !formik$1.dirty,
|
|
7109
|
-
label: formatMessage(messages$
|
|
6740
|
+
label: formatMessage(messages$z.updateButton),
|
|
7110
6741
|
onClick: formik$1.handleSubmit
|
|
7111
6742
|
})]
|
|
7112
6743
|
}),
|
|
@@ -7148,7 +6779,7 @@ const NestedInputControls = props => {
|
|
|
7148
6779
|
if (nextNestingLevel >= 6) return jsxRuntime.jsx(MaxNestingLevelReached, {});
|
|
7149
6780
|
const hasAttributes = props.productType.attributeDefinitions.length > 0;
|
|
7150
6781
|
if (!hasAttributes) return jsxRuntime.jsx(uiKit.Text.Body, {
|
|
7151
|
-
intlMessage: messages$
|
|
6782
|
+
intlMessage: messages$z.emptyProductType,
|
|
7152
6783
|
tone: "secondary"
|
|
7153
6784
|
});
|
|
7154
6785
|
return jsxRuntime.jsxs(uiKit.Spacings.Inline, {
|
|
@@ -7224,7 +6855,7 @@ const CustomNestedInput = /*#__PURE__*/React.memo(props => {
|
|
|
7224
6855
|
if (nestingLevel !== 0) parentFormik.submitForm();else showNotification({
|
|
7225
6856
|
kind: 'success',
|
|
7226
6857
|
domain: constants.DOMAINS.SIDE,
|
|
7227
|
-
text: formatMessage(messages$
|
|
6858
|
+
text: formatMessage(messages$z.attributeUpdateSucceeded)
|
|
7228
6859
|
});
|
|
7229
6860
|
setSubmitting(false);
|
|
7230
6861
|
},
|
|
@@ -7343,7 +6974,7 @@ function CustomChannelReferenceInput(props) {
|
|
|
7343
6974
|
}
|
|
7344
6975
|
CustomChannelReferenceInput.displayName = 'CustomChannelReferenceInput';
|
|
7345
6976
|
|
|
7346
|
-
var messages$
|
|
6977
|
+
var messages$y = reactIntl.defineMessages({
|
|
7347
6978
|
noProductsFound: {
|
|
7348
6979
|
id: 'Shared.ProductPickerInput.noProductsFound',
|
|
7349
6980
|
description: 'The message to display when no products were found',
|
|
@@ -7434,14 +7065,14 @@ const ProductPickerInput = _ref => {
|
|
|
7434
7065
|
const tooltipTitle = currentOption?.data?.label ?? '';
|
|
7435
7066
|
return jsxRuntime.jsx(uiKit.Constraints.Horizontal, {
|
|
7436
7067
|
max: "scale",
|
|
7437
|
-
children: currentOption.loading ? jsxRuntime.jsx(CenteredLoadingSpinner
|
|
7068
|
+
children: currentOption.loading ? jsxRuntime.jsx(merchantCenterSharedUi.CenteredLoadingSpinner, {}) : jsxRuntime.jsxs(uiKit.Spacings.Stack, {
|
|
7438
7069
|
scale: "xs",
|
|
7439
7070
|
children: [jsxRuntime.jsx(CustomFieldTooltip$1, {
|
|
7440
7071
|
title: tooltipTitle,
|
|
7441
7072
|
children: jsxRuntime.jsx(uiKit.AsyncSelectInput, {
|
|
7442
7073
|
id: name,
|
|
7443
7074
|
name: name,
|
|
7444
|
-
placeholder: formatMessage(messages$
|
|
7075
|
+
placeholder: formatMessage(messages$y.placeholder),
|
|
7445
7076
|
loadOptions: loadOptionsDebounced,
|
|
7446
7077
|
defaultOptions: [],
|
|
7447
7078
|
isClearable: isClearable,
|
|
@@ -7455,7 +7086,7 @@ const ProductPickerInput = _ref => {
|
|
|
7455
7086
|
onInputChange: handleInputChange,
|
|
7456
7087
|
onBlur: onBlur,
|
|
7457
7088
|
value: currentOption.data,
|
|
7458
|
-
noOptionsMessage: () => isLoadingFailed ? null : formatMessage(messages$
|
|
7089
|
+
noOptionsMessage: () => isLoadingFailed ? null : formatMessage(messages$y.noProductsFound),
|
|
7459
7090
|
hasError: hasError || isLoadingFailed,
|
|
7460
7091
|
menuPortalZIndex: Z_INDEX_DROPDOWN,
|
|
7461
7092
|
menuPortalTarget: document.body,
|
|
@@ -7705,7 +7336,7 @@ function truncate (text) {
|
|
|
7705
7336
|
return `${text.substring(0, length)}${end}`;
|
|
7706
7337
|
}
|
|
7707
7338
|
|
|
7708
|
-
var messages$
|
|
7339
|
+
var messages$x = reactIntl.defineMessages({
|
|
7709
7340
|
productReferenceLabel: {
|
|
7710
7341
|
id: 'CustomFieldsLabel.productReferenceLabel',
|
|
7711
7342
|
description: 'Label shown above the product picker input.',
|
|
@@ -7773,7 +7404,7 @@ const CustomFieldsLabelHint = _ref2 => {
|
|
|
7773
7404
|
children: [jsxRuntime.jsx(uiKit.WarningIcon, {
|
|
7774
7405
|
size: "medium",
|
|
7775
7406
|
color: "warning"
|
|
7776
|
-
}), jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$T({}, messages$
|
|
7407
|
+
}), jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$T({}, messages$x.cartDiscountMoreThan500))]
|
|
7777
7408
|
});
|
|
7778
7409
|
}
|
|
7779
7410
|
return l10n.formatLocalizedString(fieldDefinition, {
|
|
@@ -7787,8 +7418,8 @@ function CustomFieldsProductTypeReferenceSubtitle() {
|
|
|
7787
7418
|
formatMessage = _useIntl.formatMessage;
|
|
7788
7419
|
const _usePimStatus = usePimStatus(),
|
|
7789
7420
|
isProjectIndexed = _usePimStatus.isProjectIndexed;
|
|
7790
|
-
if (isProjectIndexed) return formatMessage(messages$
|
|
7791
|
-
return formatMessage(messages$
|
|
7421
|
+
if (isProjectIndexed) return formatMessage(messages$x.productTypeReferenceLabelI);
|
|
7422
|
+
return formatMessage(messages$x.productTypeReferenceLabel);
|
|
7792
7423
|
}
|
|
7793
7424
|
|
|
7794
7425
|
// TODO(pa3): this logic may be misplaced and probably
|
|
@@ -7805,13 +7436,13 @@ function CustomFieldsLabelSubtitle(_ref3) {
|
|
|
7805
7436
|
const referenceTypeName = capitalizeFirst(referenceTypeId);
|
|
7806
7437
|
if (_includesInstanceProperty__default["default"](_context = [SEARCHABLE_REFERENCES.category, SEARCHABLE_REFERENCES.cartDiscount]).call(_context, referenceTypeId)) return referenceTypeName;
|
|
7807
7438
|
if (referenceTypeId === SEARCHABLE_REFERENCES.product) {
|
|
7808
|
-
return formatMessage(messages$
|
|
7439
|
+
return formatMessage(messages$x.productReferenceLabel);
|
|
7809
7440
|
} else if (referenceTypeId === SEARCHABLE_REFERENCES.productType) {
|
|
7810
7441
|
return jsxRuntime.jsx(CustomFieldsProductTypeReferenceSubtitle, {});
|
|
7811
7442
|
} else if (referenceTypeId === SEARCHABLE_REFERENCES.channel) {
|
|
7812
|
-
return formatMessage(messages$
|
|
7443
|
+
return formatMessage(messages$x.channelReferenceLabel);
|
|
7813
7444
|
} else if (referenceTypeId === SEARCHABLE_REFERENCES.state) {
|
|
7814
|
-
return formatMessage(messages$
|
|
7445
|
+
return formatMessage(messages$x.stateReferenceLabel);
|
|
7815
7446
|
} else {
|
|
7816
7447
|
return `${referenceTypeName} ID`;
|
|
7817
7448
|
}
|
|
@@ -7827,7 +7458,7 @@ function CustomFieldsCountIndicator(_ref4) {
|
|
|
7827
7458
|
const _useIntl3 = reactIntl.useIntl(),
|
|
7828
7459
|
formatMessage = _useIntl3.formatMessage;
|
|
7829
7460
|
return assignedAttributeGroups?.length > 1 ? jsxRuntime.jsx(uiKit.Tooltip, {
|
|
7830
|
-
title: formatMessage(messages$
|
|
7461
|
+
title: formatMessage(messages$x.attributeGroupCountTooltip, {
|
|
7831
7462
|
attributeGroups: _mapInstanceProperty__default["default"](assignedAttributeGroups).call(assignedAttributeGroups, assignedAttributeGroup => formatLocalizedField(assignedAttributeGroup.nameAllLocales)).join(', '),
|
|
7832
7463
|
count: assignedAttributeGroups.length
|
|
7833
7464
|
}),
|
|
@@ -7886,7 +7517,7 @@ const CustomFieldsLabel = /*#__PURE__*/React.memo(_ref5 => {
|
|
|
7886
7517
|
CustomFieldsLabel.displayName = 'CustomFieldsTitle';
|
|
7887
7518
|
var CustomFieldsLabel$1 = CustomFieldsLabel;
|
|
7888
7519
|
|
|
7889
|
-
var messages$
|
|
7520
|
+
var messages$w = reactIntl.defineMessages({
|
|
7890
7521
|
referencedProductType: {
|
|
7891
7522
|
id: 'NestedAttributes.referencedProductType',
|
|
7892
7523
|
description: 'Product type referenced hint',
|
|
@@ -7897,7 +7528,7 @@ var messages$x = reactIntl.defineMessages({
|
|
|
7897
7528
|
function ownKeys$S(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
7898
7529
|
function _objectSpread$S(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$S(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$S(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
7899
7530
|
function ProductTypeReference(props) {
|
|
7900
|
-
const productTypeMessage = _objectSpread$S(_objectSpread$S({}, messages$
|
|
7531
|
+
const productTypeMessage = _objectSpread$S(_objectSpread$S({}, messages$w.referencedProductType), {}, {
|
|
7901
7532
|
values: {
|
|
7902
7533
|
productTypeName: props.productType.name
|
|
7903
7534
|
}
|
|
@@ -8489,7 +8120,7 @@ function ProductSelectionsAsyncSelectDropdown(props) {
|
|
|
8489
8120
|
options: emptyStoreOption$1(intl)
|
|
8490
8121
|
}];
|
|
8491
8122
|
};
|
|
8492
|
-
if (productSelectionsFetcher.isLoading) return jsxRuntime.jsx(CenteredLoadingSpinner
|
|
8123
|
+
if (productSelectionsFetcher.isLoading) return jsxRuntime.jsx(merchantCenterSharedUi.CenteredLoadingSpinner, {});
|
|
8493
8124
|
return jsxRuntime.jsx(uiKit.AsyncSelectField, {
|
|
8494
8125
|
id: props.id,
|
|
8495
8126
|
name: props.name,
|
|
@@ -8559,7 +8190,7 @@ function ProductSelectionBasicSelectDropdown(props) {
|
|
|
8559
8190
|
})),
|
|
8560
8191
|
projectLanguages = _useApplicationContex.projectLanguages,
|
|
8561
8192
|
dataLocale = _useApplicationContex.dataLocale;
|
|
8562
|
-
if (productSelectionsFetcher.isLoading) return jsxRuntime.jsx(CenteredLoadingSpinner
|
|
8193
|
+
if (productSelectionsFetcher.isLoading) return jsxRuntime.jsx(merchantCenterSharedUi.CenteredLoadingSpinner, {});
|
|
8563
8194
|
const productSelections = productSelectionsFetcher.productSelections?.results ?? [];
|
|
8564
8195
|
const filteredProductSelections = _filterInstanceProperty__default["default"](productSelections).call(productSelections, ps => {
|
|
8565
8196
|
var _context;
|
|
@@ -8723,7 +8354,7 @@ function ProductSelectionsSearchSelectDropdown(props) {
|
|
|
8723
8354
|
const currentProductSelection = _findInstanceProperty__default["default"](productionSelectionResults).call(productionSelectionResults, productSelection => productSelection.id === productSelectionId);
|
|
8724
8355
|
props.onChange(currentProductSelection);
|
|
8725
8356
|
};
|
|
8726
|
-
if (productSelectionsByFieldFetcher.isLoading) return jsxRuntime.jsx(CenteredLoadingSpinner
|
|
8357
|
+
if (productSelectionsByFieldFetcher.isLoading) return jsxRuntime.jsx(merchantCenterSharedUi.CenteredLoadingSpinner, {});
|
|
8727
8358
|
return jsxRuntime.jsx(uiKit.SearchSelectField, {
|
|
8728
8359
|
id: props.id,
|
|
8729
8360
|
name: props.name,
|
|
@@ -8829,7 +8460,7 @@ function ProductSelectionsPicker(_ref) {
|
|
|
8829
8460
|
}
|
|
8830
8461
|
};
|
|
8831
8462
|
}, [optionType]);
|
|
8832
|
-
if (productSelectionsTotalFetcher.isLoading) return jsxRuntime.jsx(CenteredLoadingSpinner
|
|
8463
|
+
if (productSelectionsTotalFetcher.isLoading) return jsxRuntime.jsx(merchantCenterSharedUi.CenteredLoadingSpinner, {});
|
|
8833
8464
|
let CustomProductSelectionsPicker;
|
|
8834
8465
|
if (productSelectionsTotalFetcher.total <= lowerProductSelectionsLimit) CustomProductSelectionsPicker = ProductSelectionBasicSelectDropdown;else if (productSelectionsTotalFetcher.total <= upperProductSelectionsLimit) CustomProductSelectionsPicker = ProductSelectionsAsyncSelectDropdown;else CustomProductSelectionsPicker = ProductSelectionsSearchSelectDropdown;
|
|
8835
8466
|
return jsxRuntime.jsx(uiKit.Spacings.Stack, {
|
|
@@ -8853,7 +8484,7 @@ function ProductSelectionsPicker(_ref) {
|
|
|
8853
8484
|
});
|
|
8854
8485
|
}
|
|
8855
8486
|
|
|
8856
|
-
var messages$
|
|
8487
|
+
var messages$v = reactIntl.defineMessages({
|
|
8857
8488
|
placeholder: {
|
|
8858
8489
|
id: 'RecurrentIntervalPicker.placeholder',
|
|
8859
8490
|
description: 'The placeholder of the input',
|
|
@@ -8966,7 +8597,7 @@ const RecurrentIntervalPicker = _ref => {
|
|
|
8966
8597
|
const valueArray = _Array$isArray__default["default"](value) ? value : [value];
|
|
8967
8598
|
const missingOptions = _mapInstanceProperty__default["default"](_context = _filterInstanceProperty__default["default"](valueArray).call(valueArray, val => !_someInstanceProperty__default["default"](recurrencePolicies).call(recurrencePolicies, policy => policy.id === val))).call(_context, val => ({
|
|
8968
8599
|
value: val,
|
|
8969
|
-
label: formatMessage(messages$
|
|
8600
|
+
label: formatMessage(messages$v.missingOptionLabel, {
|
|
8970
8601
|
value: val
|
|
8971
8602
|
})
|
|
8972
8603
|
}));
|
|
@@ -8986,7 +8617,7 @@ const RecurrentIntervalPicker = _ref => {
|
|
|
8986
8617
|
id: name,
|
|
8987
8618
|
name: name,
|
|
8988
8619
|
value: value,
|
|
8989
|
-
placeholder: messages$
|
|
8620
|
+
placeholder: formatMessage(messages$v.placeholder),
|
|
8990
8621
|
options: options,
|
|
8991
8622
|
isClearable: isClearable,
|
|
8992
8623
|
isReadOnly: isReadOnly,
|
|
@@ -9001,11 +8632,11 @@ const RecurrentIntervalPicker = _ref => {
|
|
|
9001
8632
|
intlMessage: commonPickerMessages.loadingErrorMessage
|
|
9002
8633
|
}) : selectedIsMissingInData ? jsxRuntime.jsx(uiKit.Text.Body, {
|
|
9003
8634
|
tone: "negative",
|
|
9004
|
-
intlMessage: messages$
|
|
8635
|
+
intlMessage: messages$v.missingSelectedWarning
|
|
9005
8636
|
}) : null, !error && noRecurrentIntervalsConfigured && jsxRuntime.jsx(uiKit.ContentNotification, {
|
|
9006
8637
|
type: "info",
|
|
9007
8638
|
children: jsxRuntime.jsx(uiKit.Text.Detail, {
|
|
9008
|
-
intlMessage: _objectSpread$H(_objectSpread$H({}, messages$
|
|
8639
|
+
intlMessage: _objectSpread$H(_objectSpread$H({}, messages$v.noRecurrentIntervalsConfigured), {}, {
|
|
9009
8640
|
values: {
|
|
9010
8641
|
linkToSettings: msg => jsxRuntime.jsx(uiKit.Link, {
|
|
9011
8642
|
to: `/${projectKey}/settings/project/intervals`,
|
|
@@ -9019,114 +8650,6 @@ const RecurrentIntervalPicker = _ref => {
|
|
|
9019
8650
|
};
|
|
9020
8651
|
var RecurrentIntervalPicker$1 = RecurrentIntervalPicker;
|
|
9021
8652
|
|
|
9022
|
-
// NOTE: this component is duplicated in `app-shell/from-core`.
|
|
9023
|
-
const RequiredIndicator = _ref => {
|
|
9024
|
-
let uncolored = _ref.uncolored;
|
|
9025
|
-
return jsxRuntime.jsx("em", {
|
|
9026
|
-
css: /*#__PURE__*/react$1.css("color:", uncolored ? uiKit.designTokens.colorNeutral90 : uiKit.designTokens.colorWarning, ";font-style:normal;margin-left:2px;" + ("" ), "" ),
|
|
9027
|
-
children: '*'
|
|
9028
|
-
});
|
|
9029
|
-
};
|
|
9030
|
-
RequiredIndicator.displayName = 'RequiredIndicator';
|
|
9031
|
-
var RequiredIndicator$1 = RequiredIndicator;
|
|
9032
|
-
|
|
9033
|
-
const ScrollToFieldError = () => {
|
|
9034
|
-
const formik$1 = formik.useFormikContext();
|
|
9035
|
-
const isValid = formik$1.isValid,
|
|
9036
|
-
submitCount = formik$1.submitCount;
|
|
9037
|
-
const _useApplicationContex = applicationShellConnectors.useApplicationContext(applicationContext => ({
|
|
9038
|
-
dataLocale: applicationContext.dataLocale
|
|
9039
|
-
})),
|
|
9040
|
-
dataLocale = _useApplicationContex.dataLocale;
|
|
9041
|
-
React.useEffect(() => {
|
|
9042
|
-
// Do not run the effect if the form hasn't been submitted yet.
|
|
9043
|
-
if (submitCount === 0) return;
|
|
9044
|
-
// Do not run the effect if the form is valid.
|
|
9045
|
-
if (isValid) return;
|
|
9046
|
-
const firstErrorElement = document.querySelector('[aria-invalid="true"]');
|
|
9047
|
-
if (firstErrorElement) {
|
|
9048
|
-
// Get a reference to the label.
|
|
9049
|
-
const firstElementId = firstErrorElement.getAttribute('id');
|
|
9050
|
-
if (firstElementId) {
|
|
9051
|
-
const localizedInputIndex = _indexOfInstanceProperty__default["default"](firstElementId).call(firstElementId, `.${dataLocale}`);
|
|
9052
|
-
|
|
9053
|
-
// check if locale is appended then remove it from id
|
|
9054
|
-
const id = localizedInputIndex > -1 ? firstElementId.replace(`.${dataLocale}`, '') : firstElementId;
|
|
9055
|
-
|
|
9056
|
-
// Scroll to the label (if found), otherwise to the input element itself.
|
|
9057
|
-
|
|
9058
|
-
const elementToScrollTo =
|
|
9059
|
-
// div is used only for custom fields
|
|
9060
|
-
document.querySelector(`div[aria-errormessage="${firstElementId}"]`) ?? document.querySelector(`label[for="${id}"]`) ?? document.querySelector(`label#${id}`) ?? firstErrorElement;
|
|
9061
|
-
elementToScrollTo.scrollIntoView?.({
|
|
9062
|
-
behavior: 'smooth',
|
|
9063
|
-
block: 'center'
|
|
9064
|
-
});
|
|
9065
|
-
}
|
|
9066
|
-
}
|
|
9067
|
-
}, [dataLocale, isValid, submitCount]);
|
|
9068
|
-
return null;
|
|
9069
|
-
};
|
|
9070
|
-
var ScrollToFieldError$1 = ScrollToFieldError;
|
|
9071
|
-
|
|
9072
|
-
var messages$v = reactIntl.defineMessages({
|
|
9073
|
-
buttonLabel: {
|
|
9074
|
-
id: 'SearchInput.buttonLabel',
|
|
9075
|
-
description: 'Label for "Search" button.',
|
|
9076
|
-
defaultMessage: 'Search'
|
|
9077
|
-
},
|
|
9078
|
-
placeholder: {
|
|
9079
|
-
id: 'SearchInput.placeholder',
|
|
9080
|
-
description: 'Placeholder for "Search" input field',
|
|
9081
|
-
defaultMessage: 'Search'
|
|
9082
|
-
}
|
|
9083
|
-
});
|
|
9084
|
-
|
|
9085
|
-
const SelectableFieldSearchInput = props => {
|
|
9086
|
-
const _useState = React.useState(props.initialValue ?? ''),
|
|
9087
|
-
_useState2 = _slicedToArray(_useState, 2),
|
|
9088
|
-
searchText = _useState2[0],
|
|
9089
|
-
setSearchText = _useState2[1];
|
|
9090
|
-
const intl = reactIntl.useIntl();
|
|
9091
|
-
return jsxRuntime.jsx("div", {
|
|
9092
|
-
css: /*#__PURE__*/react$1.css("width:100%;position:relative;display:flex;z-index:3;max-width:", uiKit.designTokens.constraint15, ";" + ("" ), "" ),
|
|
9093
|
-
children: jsxRuntime.jsx(uiKit.SelectableSearchInput, {
|
|
9094
|
-
menuHorizontalConstraint: 5,
|
|
9095
|
-
options: props.options,
|
|
9096
|
-
value: {
|
|
9097
|
-
text: searchText,
|
|
9098
|
-
option: props.searchMode
|
|
9099
|
-
},
|
|
9100
|
-
onChange: _ref => {
|
|
9101
|
-
let _ref$target = _ref.target,
|
|
9102
|
-
id = _ref$target.id,
|
|
9103
|
-
value = _ref$target.value;
|
|
9104
|
-
if (_endsWithInstanceProperty__default["default"](id).call(id, 'dropdown')) {
|
|
9105
|
-
props.onChange({
|
|
9106
|
-
option: value,
|
|
9107
|
-
value: searchText
|
|
9108
|
-
});
|
|
9109
|
-
} else {
|
|
9110
|
-
setSearchText(value);
|
|
9111
|
-
}
|
|
9112
|
-
},
|
|
9113
|
-
onSubmit: _ref2 => {
|
|
9114
|
-
let text = _ref2.text,
|
|
9115
|
-
option = _ref2.option;
|
|
9116
|
-
props.onChange({
|
|
9117
|
-
option: option,
|
|
9118
|
-
value: text
|
|
9119
|
-
});
|
|
9120
|
-
},
|
|
9121
|
-
onReset: props.onReset,
|
|
9122
|
-
placeholder: props.placeholder ?? intl.formatMessage(messages$v.placeholder),
|
|
9123
|
-
isDisabled: props.disabled
|
|
9124
|
-
})
|
|
9125
|
-
});
|
|
9126
|
-
};
|
|
9127
|
-
SelectableFieldSearchInput.displayName = 'SelectableFieldSearchInput';
|
|
9128
|
-
var SelectableFieldSearchInput$1 = SelectableFieldSearchInput;
|
|
9129
|
-
|
|
9130
8653
|
var messages$u = reactIntl.defineMessages({
|
|
9131
8654
|
basicSelectInputPlaceholder: {
|
|
9132
8655
|
id: 'Shared.StoreSelectInput.basicSelectInputPlaceholder',
|
|
@@ -9290,7 +8813,7 @@ const StoresAsyncSelectInput = _ref2 => {
|
|
|
9290
8813
|
options: emptyStoreOption(intl)
|
|
9291
8814
|
}];
|
|
9292
8815
|
};
|
|
9293
|
-
if (storesListFetcher.isLoading) return jsxRuntime.jsx(CenteredLoadingSpinner
|
|
8816
|
+
if (storesListFetcher.isLoading) return jsxRuntime.jsx(merchantCenterSharedUi.CenteredLoadingSpinner, {});
|
|
9294
8817
|
return jsxRuntime.jsxs(jsxRuntime.Fragment, {
|
|
9295
8818
|
children: [jsxRuntime.jsx(uiKit.AsyncSelectInput, _objectSpread$G(_objectSpread$G(_objectSpread$G({
|
|
9296
8819
|
id: props.id,
|
|
@@ -9395,7 +8918,7 @@ const StoresBasicSelectInput = _ref => {
|
|
|
9395
8918
|
});
|
|
9396
8919
|
}
|
|
9397
8920
|
};
|
|
9398
|
-
if (storesListFetcher.isLoading) return jsxRuntime.jsx(CenteredLoadingSpinner
|
|
8921
|
+
if (storesListFetcher.isLoading) return jsxRuntime.jsx(merchantCenterSharedUi.CenteredLoadingSpinner, {});
|
|
9399
8922
|
return jsxRuntime.jsxs(jsxRuntime.Fragment, {
|
|
9400
8923
|
children: [jsxRuntime.jsx(uiKit.SelectInput, _objectSpread$F(_objectSpread$F(_objectSpread$F({
|
|
9401
8924
|
id: props.id,
|
|
@@ -9613,7 +9136,7 @@ const StoresSearchSelectInput = _ref4 => {
|
|
|
9613
9136
|
})]
|
|
9614
9137
|
});
|
|
9615
9138
|
};
|
|
9616
|
-
if (storesByFieldFetcher.isLoading) return jsxRuntime.jsx(CenteredLoadingSpinner
|
|
9139
|
+
if (storesByFieldFetcher.isLoading) return jsxRuntime.jsx(merchantCenterSharedUi.CenteredLoadingSpinner, {});
|
|
9617
9140
|
return jsxRuntime.jsxs(jsxRuntime.Fragment, {
|
|
9618
9141
|
children: [jsxRuntime.jsx(uiKit.SearchSelectInput, _objectSpread$E(_objectSpread$E({
|
|
9619
9142
|
id: props.id,
|
|
@@ -9699,7 +9222,7 @@ const StoreSelectInput = _ref2 => {
|
|
|
9699
9222
|
}
|
|
9700
9223
|
};
|
|
9701
9224
|
}, [optionType, totalNumberOfStoresFetcher.total, upperStoresLimit]);
|
|
9702
|
-
if (totalNumberOfStoresFetcher.isLoading) return jsxRuntime.jsx(CenteredLoadingSpinner
|
|
9225
|
+
if (totalNumberOfStoresFetcher.isLoading) return jsxRuntime.jsx(merchantCenterSharedUi.CenteredLoadingSpinner, {});
|
|
9703
9226
|
let CustomStoreSelectInput;
|
|
9704
9227
|
// GIVEN total number of available stores <= lowerStoresLimit
|
|
9705
9228
|
// THEN render basic SelectField with all available stores as options
|
|
@@ -14401,7 +13924,7 @@ const getAttributeValueByType = _ref10 => {
|
|
|
14401
13924
|
case 'time':
|
|
14402
13925
|
case 'datetime':
|
|
14403
13926
|
case 'date':
|
|
14404
|
-
return jsxRuntime.jsx(FormattedDateTime
|
|
13927
|
+
return jsxRuntime.jsx(merchantCenterSharedUi.FormattedDateTime, {
|
|
14405
13928
|
type: type,
|
|
14406
13929
|
value: value
|
|
14407
13930
|
});
|
|
@@ -14428,13 +13951,15 @@ const getAttributeValueByType = _ref10 => {
|
|
|
14428
13951
|
};
|
|
14429
13952
|
|
|
14430
13953
|
// TODO: rename to isProductLevelAttribute since it returns a boolean
|
|
14431
|
-
const getProductLevelAttributes =
|
|
14432
|
-
return
|
|
13954
|
+
const getProductLevelAttributes = attributeDefinition => {
|
|
13955
|
+
return attributeDefinition?.level === ATTRIBUTE_LEVELS.PRODUCT;
|
|
13956
|
+
};
|
|
13957
|
+
const isVariantLevelAttribute = attributeDefinition => {
|
|
13958
|
+
return attributeDefinition?.level === ATTRIBUTE_LEVELS.VARIANT;
|
|
14433
13959
|
};
|
|
14434
|
-
|
|
14435
13960
|
// TODO: rename to isProductAttribute since it returns a boolean
|
|
14436
|
-
const getProductAttributes =
|
|
14437
|
-
return
|
|
13961
|
+
const getProductAttributes = attributeDefinition => {
|
|
13962
|
+
return attributeDefinition?.attributeConstraint === ATTRIBUTE_CONSTRAINTS.SAME_FOR_ALL || getProductLevelAttributes(attributeDefinition);
|
|
14438
13963
|
};
|
|
14439
13964
|
|
|
14440
13965
|
let RequestCache = /*#__PURE__*/function () {
|
|
@@ -14600,11 +14125,9 @@ var CategorySearchPickerOptionFragment = { kind: "Document", definitions: [{ kin
|
|
|
14600
14125
|
|
|
14601
14126
|
exports.BooleanField = booleanField;
|
|
14602
14127
|
exports.CUSTOM_FIELD_TYPES = CUSTOM_FIELD_TYPES;
|
|
14603
|
-
exports.Carousel = Carousel$1;
|
|
14604
14128
|
exports.CartDiscountReferenceSearch = CartDiscountReferenceSearch;
|
|
14605
14129
|
exports.CategoryReferenceSearch = CategoryReferenceSearch;
|
|
14606
14130
|
exports.CategorySearchPickerOptionFragment = CategorySearchPickerOptionFragment;
|
|
14607
|
-
exports.CenteredLoadingSpinner = CenteredLoadingSpinner$1;
|
|
14608
14131
|
exports.ChannelPickerInput = ChannelPickerInput$1;
|
|
14609
14132
|
exports.CountriesPicker = CountriesPicker;
|
|
14610
14133
|
exports.CustomFieldDefinitionsConnector = customFieldDefinitionsConnector;
|
|
@@ -14616,11 +14139,9 @@ exports.CustomFieldsErrorTextNotification = CustomFieldsErrorTextNotification$1;
|
|
|
14616
14139
|
exports.CustomFieldsFormField = CustomFieldsFormField$1;
|
|
14617
14140
|
exports.CustomerGroupPickerInput = CustomerGroupPickerInput$1;
|
|
14618
14141
|
exports.DefaultPageSizes = DefaultPageSizes;
|
|
14619
|
-
exports.Divider = Divider;
|
|
14620
14142
|
exports.EMAIL_REGEX = EMAIL_REGEX;
|
|
14621
14143
|
exports.FILTER_TYPES = FILTER_TYPES;
|
|
14622
14144
|
exports.FileInput = FileInput$1;
|
|
14623
|
-
exports.FormattedDateTime = FormattedDateTime$1;
|
|
14624
14145
|
exports.FormattedLocalizedString = FormattedLocalizedString;
|
|
14625
14146
|
exports.LOWER_STORES_LIMIT = LOWER_STORES_LIMIT;
|
|
14626
14147
|
exports.LabelRange = LabelRange$1;
|
|
@@ -14641,9 +14162,6 @@ exports.QUERY_MAX_LIMIT = QUERY_MAX_LIMIT;
|
|
|
14641
14162
|
exports.RESOURCES_WITH_PLATFORM_LIMITS = RESOURCES_WITH_PLATFORM_LIMITS;
|
|
14642
14163
|
exports.RecurrentIntervalPicker = RecurrentIntervalPicker$1;
|
|
14643
14164
|
exports.RequestCache = RequestCache$1;
|
|
14644
|
-
exports.RequiredIndicator = RequiredIndicator$1;
|
|
14645
|
-
exports.ScrollToFieldError = ScrollToFieldError$1;
|
|
14646
|
-
exports.SelectableFieldSearchInput = SelectableFieldSearchInput$1;
|
|
14647
14165
|
exports.StoreSelectField = StoreSelectField$1;
|
|
14648
14166
|
exports.StoreSelectInput = StoreSelectInput$1;
|
|
14649
14167
|
exports.ThrottledField = ThrottledField$1;
|
|
@@ -14746,6 +14264,7 @@ exports.isUUID = isUUID$1;
|
|
|
14746
14264
|
exports.isValidISODate = isValidISODate;
|
|
14747
14265
|
exports.isValidISODateTime = isValidISODateTime;
|
|
14748
14266
|
exports.isValidISOTime = isValidISOTime;
|
|
14267
|
+
exports.isVariantLevelAttribute = isVariantLevelAttribute;
|
|
14749
14268
|
exports.keepDisplayName = keepDisplayName$1;
|
|
14750
14269
|
exports.mapShippingRateTierToGraphQL = mapShippingRateTierToGraphQL;
|
|
14751
14270
|
exports.mapStoresToOptions = mapStoresToOptions;
|
|
@@ -14789,7 +14308,6 @@ exports.useCurrentOption = useCurrentOption;
|
|
|
14789
14308
|
exports.useCustomFieldsDnDContext = useDnDContext;
|
|
14790
14309
|
exports.useCustomerGroupsPlatformLimits = useCustomerGroupsPlatformLimits$1;
|
|
14791
14310
|
exports.useCustomersPlatformLimits = useCustomersPlatformLimits$1;
|
|
14792
|
-
exports.useDbMaintenanceNotification = useDbMaintenanceNotification;
|
|
14793
14311
|
exports.useDebouncedPromiseCallback = useDebouncedPromiseCallback$1;
|
|
14794
14312
|
exports.useFormatCustomField = useFormatCustomField;
|
|
14795
14313
|
exports.useFormatLocalizedFieldToString = useFormatLocalizedFieldToString;
|