@commercetools-frontend/experimental-components 8.0.3 → 8.0.4
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 +487 -759
- package/dist/commercetools-frontend-experimental-components.cjs.prod.js +451 -705
- package/dist/commercetools-frontend-experimental-components.esm.js +509 -778
- package/dist/declarations/src/custom-fields/custom-fields-form-field/custom-fields-form-field.d.ts +3 -1
- package/dist/declarations/src/index.d.ts +1 -4
- package/package.json +9 -9
- package/dist/declarations/src/components/buttons/button/button.d.ts +0 -19
- package/dist/declarations/src/fields/search-input/messages.d.ts +0 -16
- package/dist/declarations/src/fields/search-input/search-input.d.ts +0 -54
|
@@ -40,8 +40,6 @@ var react$1 = require('@emotion/react');
|
|
|
40
40
|
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
|
-
var classnames = require('classnames');
|
|
44
|
-
var camelCase = require('lodash/camelCase');
|
|
45
43
|
var designSystem = require('@commercetools-uikit/design-system');
|
|
46
44
|
var _Reflect$construct = require('@babel/runtime-corejs3/core-js-stable/reflect/construct');
|
|
47
45
|
var _classCallCheck = require('@babel/runtime-corejs3/helpers/classCallCheck');
|
|
@@ -84,6 +82,7 @@ var utils = require('@commercetools-uikit/utils');
|
|
|
84
82
|
require('react-required-if');
|
|
85
83
|
var _Object$values = require('@babel/runtime-corejs3/core-js-stable/object/values');
|
|
86
84
|
var _sortInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/sort');
|
|
85
|
+
var classnames = require('classnames');
|
|
87
86
|
var commonTags = require('common-tags');
|
|
88
87
|
var has = require('lodash/has');
|
|
89
88
|
require('tiny-warning');
|
|
@@ -93,7 +92,7 @@ var _Number$isNaN = require('@babel/runtime-corejs3/core-js-stable/number/is-nan
|
|
|
93
92
|
var Cleave = require('cleave.js/react');
|
|
94
93
|
var isFinite = require('lodash/isFinite');
|
|
95
94
|
var isUndefined = require('lodash/isUndefined');
|
|
96
|
-
var
|
|
95
|
+
var camelCase = require('lodash/camelCase');
|
|
97
96
|
var Textarea = require('react-textarea-autosize');
|
|
98
97
|
var _Object$assign = require('@babel/runtime-corejs3/core-js-stable/object/assign');
|
|
99
98
|
var _findIndexInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/find-index');
|
|
@@ -113,6 +112,7 @@ var reactSnapCarousel = require('react-snap-carousel');
|
|
|
113
112
|
var applicationShell = require('@commercetools-frontend/application-shell');
|
|
114
113
|
var hoc = require('@apollo/client/react/hoc');
|
|
115
114
|
var flatten = require('lodash/flatten');
|
|
115
|
+
var flowRight = require('lodash/flowRight');
|
|
116
116
|
var uniqBy = require('lodash/uniqBy');
|
|
117
117
|
var invariant = require('tiny-invariant');
|
|
118
118
|
var hoistNonReactStatics = require('hoist-non-react-statics');
|
|
@@ -165,8 +165,6 @@ var _Promise__default = /*#__PURE__*/_interopDefault(_Promise);
|
|
|
165
165
|
var _setTimeout__default = /*#__PURE__*/_interopDefault(_setTimeout);
|
|
166
166
|
var _bindInstanceProperty__default = /*#__PURE__*/_interopDefault(_bindInstanceProperty);
|
|
167
167
|
var _trimInstanceProperty__default = /*#__PURE__*/_interopDefault(_trimInstanceProperty);
|
|
168
|
-
var classnames__default = /*#__PURE__*/_interopDefault(classnames);
|
|
169
|
-
var camelCase__default = /*#__PURE__*/_interopDefault(camelCase);
|
|
170
168
|
var _Reflect$construct__default = /*#__PURE__*/_interopDefault(_Reflect$construct);
|
|
171
169
|
var _sliceInstanceProperty__default = /*#__PURE__*/_interopDefault(_sliceInstanceProperty);
|
|
172
170
|
var _someInstanceProperty__default = /*#__PURE__*/_interopDefault(_someInstanceProperty);
|
|
@@ -190,6 +188,7 @@ var ReactDOM__default = /*#__PURE__*/_interopDefault(ReactDOM);
|
|
|
190
188
|
var _indexOfInstanceProperty__default = /*#__PURE__*/_interopDefault(_indexOfInstanceProperty);
|
|
191
189
|
var _Object$values__default = /*#__PURE__*/_interopDefault(_Object$values);
|
|
192
190
|
var _sortInstanceProperty__default = /*#__PURE__*/_interopDefault(_sortInstanceProperty);
|
|
191
|
+
var classnames__default = /*#__PURE__*/_interopDefault(classnames);
|
|
193
192
|
var has__default = /*#__PURE__*/_interopDefault(has);
|
|
194
193
|
var _concatInstanceProperty__default = /*#__PURE__*/_interopDefault(_concatInstanceProperty);
|
|
195
194
|
var _Math$trunc__default = /*#__PURE__*/_interopDefault(_Math$trunc);
|
|
@@ -197,7 +196,7 @@ var _Number$isNaN__default = /*#__PURE__*/_interopDefault(_Number$isNaN);
|
|
|
197
196
|
var Cleave__default = /*#__PURE__*/_interopDefault(Cleave);
|
|
198
197
|
var isFinite__default = /*#__PURE__*/_interopDefault(isFinite);
|
|
199
198
|
var isUndefined__default = /*#__PURE__*/_interopDefault(isUndefined);
|
|
200
|
-
var
|
|
199
|
+
var camelCase__default = /*#__PURE__*/_interopDefault(camelCase);
|
|
201
200
|
var Textarea__default = /*#__PURE__*/_interopDefault(Textarea);
|
|
202
201
|
var _Object$assign__default = /*#__PURE__*/_interopDefault(_Object$assign);
|
|
203
202
|
var _findIndexInstanceProperty__default = /*#__PURE__*/_interopDefault(_findIndexInstanceProperty);
|
|
@@ -213,17 +212,18 @@ var memoize__default = /*#__PURE__*/_interopDefault(memoize);
|
|
|
213
212
|
var omitEmpty__default = /*#__PURE__*/_interopDefault(omitEmpty);
|
|
214
213
|
var shuffle__default = /*#__PURE__*/_interopDefault(shuffle);
|
|
215
214
|
var flatten__default = /*#__PURE__*/_interopDefault(flatten);
|
|
215
|
+
var flowRight__default = /*#__PURE__*/_interopDefault(flowRight);
|
|
216
216
|
var uniqBy__default = /*#__PURE__*/_interopDefault(uniqBy);
|
|
217
217
|
var invariant__default = /*#__PURE__*/_interopDefault(invariant);
|
|
218
218
|
var hoistNonReactStatics__default = /*#__PURE__*/_interopDefault(hoistNonReactStatics);
|
|
219
219
|
var get__default = /*#__PURE__*/_interopDefault(get);
|
|
220
220
|
|
|
221
|
-
var _ref$
|
|
221
|
+
var _ref$f = {
|
|
222
222
|
name: "1tmmbhs",
|
|
223
223
|
styles: "height:100%;display:flex;flex-grow:1;align-items:center;justify-content:center"
|
|
224
224
|
} ;
|
|
225
225
|
const CenteredLoadingSpinner = () => jsxRuntime.jsx("div", {
|
|
226
|
-
css: _ref$
|
|
226
|
+
css: _ref$f,
|
|
227
227
|
"data-testid": "centered-loading-spinner",
|
|
228
228
|
children: jsxRuntime.jsx(uiKit.LoadingSpinner, {})
|
|
229
229
|
});
|
|
@@ -298,7 +298,7 @@ var commonPickerMessages = reactIntl.defineMessages({
|
|
|
298
298
|
}
|
|
299
299
|
});
|
|
300
300
|
|
|
301
|
-
var messages$
|
|
301
|
+
var messages$S = reactIntl.defineMessages({
|
|
302
302
|
noChannelsFound: {
|
|
303
303
|
id: 'Products.ChannelPickerInput.noChannelsFound',
|
|
304
304
|
description: 'The message to display when no channels were found',
|
|
@@ -311,8 +311,8 @@ var messages$T = reactIntl.defineMessages({
|
|
|
311
311
|
}
|
|
312
312
|
});
|
|
313
313
|
|
|
314
|
-
function ownKeys$
|
|
315
|
-
function _objectSpread$
|
|
314
|
+
function ownKeys$1u(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; }
|
|
315
|
+
function _objectSpread$1u(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$1u(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$1u(Object(t))).call(_context3, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
316
316
|
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
317
|
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
318
|
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 +341,7 @@ const ChannelPickerInput = _ref => {
|
|
|
341
341
|
const dataLocale = applicationShellConnectors.useApplicationContext(applicationContext => applicationContext.dataLocale);
|
|
342
342
|
const variables = React.useMemo(() => {
|
|
343
343
|
const rolesClause = getRolesClause(roles);
|
|
344
|
-
return _objectSpread$
|
|
344
|
+
return _objectSpread$1u({
|
|
345
345
|
sortByNamePath: `name.${dataLocale}`
|
|
346
346
|
}, rolesClause && {
|
|
347
347
|
extraWhere: rolesClause
|
|
@@ -417,7 +417,7 @@ const ChannelPickerInput = _ref => {
|
|
|
417
417
|
if (isCurrentOptionLoadingFailed && onError) onError(currentOptions.error);
|
|
418
418
|
}, [isCurrentOptionLoadingFailed, onError, currentOptions]);
|
|
419
419
|
const isLoadingFailed = isCurrentOptionLoadingFailed || Boolean(loadingError);
|
|
420
|
-
const handleNoOptions = React.useCallback(() => loadingError ? null : formatMessage(messages$
|
|
420
|
+
const handleNoOptions = React.useCallback(() => loadingError ? null : formatMessage(messages$S.noChannelsFound), [loadingError, formatMessage]);
|
|
421
421
|
const tooltipTitle = !isMulti ? currentSingleOption?.data?.label ?? '' : '';
|
|
422
422
|
const selectedValue = currentOptions.data ?? (isMulti ? [] : null);
|
|
423
423
|
return jsxRuntime.jsx(uiKit.Constraints.Horizontal, {
|
|
@@ -429,7 +429,7 @@ const ChannelPickerInput = _ref => {
|
|
|
429
429
|
children: jsxRuntime.jsx(uiKit.AsyncSelectInput, {
|
|
430
430
|
id: name,
|
|
431
431
|
name: name,
|
|
432
|
-
placeholder: placeholder ?? formatMessage(messages$
|
|
432
|
+
placeholder: placeholder ?? formatMessage(messages$S.placeholder),
|
|
433
433
|
loadOptions: loadOptionsDebounced,
|
|
434
434
|
defaultOptions: true,
|
|
435
435
|
showOptionGroupDivider: true,
|
|
@@ -459,12 +459,12 @@ const ChannelPickerInput = _ref => {
|
|
|
459
459
|
};
|
|
460
460
|
var ChannelPickerInput$1 = ChannelPickerInput;
|
|
461
461
|
|
|
462
|
-
function _callSuper$
|
|
463
|
-
function _isNativeReflectConstruct$
|
|
462
|
+
function _callSuper$7(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct$7() ? _Reflect$construct__default["default"](o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
|
|
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
464
|
let FormattedDateTime = /*#__PURE__*/function (_PureComponent) {
|
|
465
465
|
function FormattedDateTime() {
|
|
466
466
|
_classCallCheck(this, FormattedDateTime);
|
|
467
|
-
return _callSuper$
|
|
467
|
+
return _callSuper$7(this, FormattedDateTime, arguments);
|
|
468
468
|
}
|
|
469
469
|
_inherits(FormattedDateTime, _PureComponent);
|
|
470
470
|
return _createClass(FormattedDateTime, [{
|
|
@@ -485,7 +485,7 @@ let FormattedDateTime = /*#__PURE__*/function (_PureComponent) {
|
|
|
485
485
|
FormattedDateTime.displayName = 'FormattedDateTime';
|
|
486
486
|
var FormattedDateTime$1 = reactIntl.injectIntl(FormattedDateTime);
|
|
487
487
|
|
|
488
|
-
var messages$
|
|
488
|
+
var messages$R = reactIntl.defineMessages({
|
|
489
489
|
noProductTypesFound: {
|
|
490
490
|
id: 'Products.ProductTypePickerInput.noProductTypesFound',
|
|
491
491
|
description: 'The message to display when no product types were found',
|
|
@@ -574,7 +574,7 @@ const ProductTypePickerInput = _ref => {
|
|
|
574
574
|
children: jsxRuntime.jsx(uiKit.AsyncSelectInput, {
|
|
575
575
|
id: name,
|
|
576
576
|
name: name,
|
|
577
|
-
placeholder: formatMessage(messages$
|
|
577
|
+
placeholder: formatMessage(messages$R.placeholder),
|
|
578
578
|
loadOptions: loadOptionsDebounced,
|
|
579
579
|
defaultOptions: [],
|
|
580
580
|
isClearable: isClearable,
|
|
@@ -587,7 +587,7 @@ const ProductTypePickerInput = _ref => {
|
|
|
587
587
|
onInputChange: handleInputChange,
|
|
588
588
|
onBlur: onBlur,
|
|
589
589
|
value: currentOption.data,
|
|
590
|
-
noOptionsMessage: () => loadingError ? null : formatMessage(messages$
|
|
590
|
+
noOptionsMessage: () => loadingError ? null : formatMessage(messages$R.noProductTypesFound),
|
|
591
591
|
hasError: hasError || isLoadingFailed,
|
|
592
592
|
menuPortalZIndex: Z_INDEX_DROPDOWN,
|
|
593
593
|
menuPortalTarget: document.body,
|
|
@@ -603,7 +603,7 @@ const ProductTypePickerInput = _ref => {
|
|
|
603
603
|
ProductTypePickerInput.displayName = 'ProductTypePickerInput';
|
|
604
604
|
var ProductTypePickerInput$1 = ProductTypePickerInput;
|
|
605
605
|
|
|
606
|
-
var messages$
|
|
606
|
+
var messages$Q = reactIntl.defineMessages({
|
|
607
607
|
noStatesFound: {
|
|
608
608
|
id: 'Products.StatePickerInput.noStatesFound',
|
|
609
609
|
description: 'The message to display when no states were found',
|
|
@@ -687,7 +687,7 @@ const StatePickerInput = _ref => {
|
|
|
687
687
|
if (isCurrentOptionLoadingFailed) onError(currentOption.error);
|
|
688
688
|
}, [isCurrentOptionLoadingFailed, onError, currentOption]);
|
|
689
689
|
const isLoadingFailed = isCurrentOptionLoadingFailed || Boolean(loadingError);
|
|
690
|
-
const handleNoOptions = React.useCallback(() => loadingError ? null : formatMessage(messages$
|
|
690
|
+
const handleNoOptions = React.useCallback(() => loadingError ? null : formatMessage(messages$Q.noStatesFound), [loadingError, formatMessage]);
|
|
691
691
|
const tooltipTitle = currentOption?.data?.label ?? '';
|
|
692
692
|
return jsxRuntime.jsx(uiKit.Constraints.Horizontal, {
|
|
693
693
|
max: "scale",
|
|
@@ -699,7 +699,7 @@ const StatePickerInput = _ref => {
|
|
|
699
699
|
id: name,
|
|
700
700
|
name: name,
|
|
701
701
|
horizontalConstraint: "scale",
|
|
702
|
-
placeholder: formatMessage(messages$
|
|
702
|
+
placeholder: formatMessage(messages$Q.placeholder),
|
|
703
703
|
loadOptions: loadOptionsDebounced,
|
|
704
704
|
defaultOptions: true,
|
|
705
705
|
showOptionGroupDivider: true,
|
|
@@ -729,9 +729,9 @@ const StatePickerInput = _ref => {
|
|
|
729
729
|
StatePickerInput.displayName = 'StatePickerInput';
|
|
730
730
|
var StatePickerInput$1 = StatePickerInput;
|
|
731
731
|
|
|
732
|
-
function ownKeys$
|
|
733
|
-
function _objectSpread$
|
|
734
|
-
const TooltipWrapper = /*#__PURE__*/React__namespace["default"].forwardRef((props, ref) => jsxRuntime.jsx("div", _objectSpread$
|
|
732
|
+
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; }
|
|
733
|
+
function _objectSpread$1t(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$1t(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$1t(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
734
|
+
const TooltipWrapper = /*#__PURE__*/React__namespace["default"].forwardRef((props, ref) => jsxRuntime.jsx("div", _objectSpread$1t({
|
|
735
735
|
ref: ref,
|
|
736
736
|
style: {
|
|
737
737
|
display: 'block',
|
|
@@ -756,7 +756,7 @@ const CustomFieldTooltip = _ref => {
|
|
|
756
756
|
};
|
|
757
757
|
var CustomFieldTooltip$1 = CustomFieldTooltip;
|
|
758
758
|
|
|
759
|
-
var messages$
|
|
759
|
+
var messages$P = reactIntl.defineMessages({
|
|
760
760
|
bottomOption: {
|
|
761
761
|
id: 'Products.Pickers.bottomOption',
|
|
762
762
|
description: 'The message to display at the end of the options menu',
|
|
@@ -764,11 +764,11 @@ var messages$Q = reactIntl.defineMessages({
|
|
|
764
764
|
}
|
|
765
765
|
});
|
|
766
766
|
|
|
767
|
-
function ownKeys$
|
|
768
|
-
function _objectSpread$
|
|
767
|
+
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; }
|
|
768
|
+
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; }
|
|
769
769
|
const getBottomOption = formatMessage => ({
|
|
770
770
|
options: [{
|
|
771
|
-
label: formatMessage ? formatMessage(messages$
|
|
771
|
+
label: formatMessage ? formatMessage(messages$P.bottomOption) : messages$P.bottomOption,
|
|
772
772
|
isBottomOption: true,
|
|
773
773
|
isDisabled: true
|
|
774
774
|
}]
|
|
@@ -776,7 +776,7 @@ const getBottomOption = formatMessage => ({
|
|
|
776
776
|
const Option$2 = props => {
|
|
777
777
|
const _useIntl = reactIntl.useIntl(),
|
|
778
778
|
formatMessage = _useIntl.formatMessage;
|
|
779
|
-
return jsxRuntime.jsx(uiKit.AsyncSelectInput.Option, _objectSpread$
|
|
779
|
+
return jsxRuntime.jsx(uiKit.AsyncSelectInput.Option, _objectSpread$1s(_objectSpread$1s({}, props), {}, {
|
|
780
780
|
children: props.data.isBottomOption ? jsxRuntime.jsx(uiKit.Text.Detail, {
|
|
781
781
|
tone: "secondary",
|
|
782
782
|
children: formatMessage(props.data.label)
|
|
@@ -793,8 +793,8 @@ const Option$2 = props => {
|
|
|
793
793
|
};
|
|
794
794
|
Option$2.displayName = 'Option';
|
|
795
795
|
|
|
796
|
-
function ownKeys$
|
|
797
|
-
function _objectSpread$
|
|
796
|
+
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; }
|
|
797
|
+
function _objectSpread$1r(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$1r(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$1r(Object(t))).call(_context3, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
798
798
|
const useHandlers = onChange => {
|
|
799
799
|
const _useState = React.useState(),
|
|
800
800
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -805,8 +805,8 @@ const useHandlers = onChange => {
|
|
|
805
805
|
}, []);
|
|
806
806
|
const handleChange = useEventCallback$1(event => {
|
|
807
807
|
var _context;
|
|
808
|
-
const eventWithExtractedValue = _objectSpread$
|
|
809
|
-
target: _objectSpread$
|
|
808
|
+
const eventWithExtractedValue = _objectSpread$1r(_objectSpread$1r({}, event), {}, {
|
|
809
|
+
target: _objectSpread$1r(_objectSpread$1r({}, event.target), {}, {
|
|
810
810
|
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
811
|
})
|
|
812
812
|
});
|
|
@@ -816,9 +816,9 @@ const useHandlers = onChange => {
|
|
|
816
816
|
};
|
|
817
817
|
var useHandlers$1 = useHandlers;
|
|
818
818
|
|
|
819
|
-
const _excluded$
|
|
820
|
-
function ownKeys$
|
|
821
|
-
function _objectSpread$
|
|
819
|
+
const _excluded$f = ["extraWhere"];
|
|
820
|
+
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; }
|
|
821
|
+
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; }
|
|
822
822
|
const constructPrefixSearchPredicate$1 = function () {
|
|
823
823
|
let prefixSearchFields = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
|
|
824
824
|
let lowerBound = arguments.length > 1 ? arguments[1] : undefined;
|
|
@@ -859,13 +859,13 @@ const useLoadOptions = _ref => {
|
|
|
859
859
|
}
|
|
860
860
|
const _ref2 = variables ?? {},
|
|
861
861
|
extraWhere = _ref2.extraWhere,
|
|
862
|
-
restVariables = _objectWithoutProperties(_ref2, _excluded$
|
|
862
|
+
restVariables = _objectWithoutProperties(_ref2, _excluded$f);
|
|
863
863
|
if (typeof extraWhere === 'string') {
|
|
864
864
|
where = where ? `(${where}) and ${variables.extraWhere}` : variables.extraWhere;
|
|
865
865
|
}
|
|
866
866
|
return client$1.query({
|
|
867
867
|
query,
|
|
868
|
-
variables: _objectSpread$
|
|
868
|
+
variables: _objectSpread$1q({
|
|
869
869
|
where
|
|
870
870
|
}, restVariables),
|
|
871
871
|
context: {
|
|
@@ -1164,374 +1164,9 @@ const setDisplayName = nextDisplayName => Component => {
|
|
|
1164
1164
|
};
|
|
1165
1165
|
var setDisplayName$1 = setDisplayName;
|
|
1166
1166
|
|
|
1167
|
-
const keepDisplayName = component => setDisplayName$1(getDisplayName$1(component));
|
|
1168
|
-
var keepDisplayName$1 = keepDisplayName;
|
|
1169
|
-
|
|
1170
1167
|
const wrapDisplayName = (BaseComponent, hocName) => `${hocName}(${getDisplayName$1(BaseComponent)})`;
|
|
1171
1168
|
var wrapDisplayName$1 = wrapDisplayName;
|
|
1172
1169
|
|
|
1173
|
-
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; }
|
|
1174
|
-
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; }
|
|
1175
|
-
function _callSuper$8(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct$8() ? _Reflect$construct__default["default"](o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
|
|
1176
|
-
function _isNativeReflectConstruct$8() { try { var t = !Boolean.prototype.valueOf.call(_Reflect$construct__default["default"](Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct$8 = function () { return !!t; })(); }
|
|
1177
|
-
const withMouseOverState = BaseComponent => {
|
|
1178
|
-
let WithMouseOverState = /*#__PURE__*/function (_Component) {
|
|
1179
|
-
function WithMouseOverState() {
|
|
1180
|
-
var _this;
|
|
1181
|
-
_classCallCheck(this, WithMouseOverState);
|
|
1182
|
-
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
1183
|
-
args[_key] = arguments[_key];
|
|
1184
|
-
}
|
|
1185
|
-
_this = _callSuper$8(this, WithMouseOverState, [...args]);
|
|
1186
|
-
_this.state = {
|
|
1187
|
-
isMouseOver: false
|
|
1188
|
-
};
|
|
1189
|
-
_this.setMouseOver = nextMouseOver => _this.setState({
|
|
1190
|
-
isMouseOver: nextMouseOver
|
|
1191
|
-
});
|
|
1192
|
-
_this.handleMouseOver = () => _this.setMouseOver(true);
|
|
1193
|
-
_this.handleMouseOut = () => _this.setMouseOver(false);
|
|
1194
|
-
return _this;
|
|
1195
|
-
}
|
|
1196
|
-
_inherits(WithMouseOverState, _Component);
|
|
1197
|
-
return _createClass(WithMouseOverState, [{
|
|
1198
|
-
key: "render",
|
|
1199
|
-
value: function render() {
|
|
1200
|
-
const injectedProps = {
|
|
1201
|
-
isMouseOver: this.state.isMouseOver,
|
|
1202
|
-
handleMouseOver: this.handleMouseOver,
|
|
1203
|
-
handleMouseOut: this.handleMouseOut
|
|
1204
|
-
};
|
|
1205
|
-
return jsxRuntime.jsx(BaseComponent, _objectSpread$1r({}, _objectSpread$1r(_objectSpread$1r({}, this.props), injectedProps)));
|
|
1206
|
-
}
|
|
1207
|
-
}]);
|
|
1208
|
-
}(React.Component);
|
|
1209
|
-
WithMouseOverState.displayName = wrapDisplayName$1(BaseComponent, 'withMouseOverState');
|
|
1210
|
-
return WithMouseOverState;
|
|
1211
|
-
};
|
|
1212
|
-
var withMouseOverState$1 = withMouseOverState;
|
|
1213
|
-
|
|
1214
|
-
const getTextareaStyles = props => /*#__PURE__*/react$1.css("transition:0.2s ease;border-radius:", designSystem.designTokens.borderRadiusForInput, ";border-style:solid;border-width:1px;color:", designSystem.designTokens.colorSolid, ";font-weight:", designSystem.designTokens.fontWeight500, ";font-size:", designSystem.designTokens.fontSize10, ";font-family:", designSystem.designTokens.fontFamily, ";padding:", designSystem.designTokens.spacingS, " ", designSystem.designTokens.spacingM, ";outline:none;box-shadow:none;appearance:none;width:100%;min-height:", designSystem.designTokens.heightForInput, ";resize:vertical;", props.style === 'primary' && /*#__PURE__*/react$1.css("border-color:", designSystem.designTokens.colorNeutral, ";background-color:", designSystem.designTokens.colorSurface, ";" + ("" ), "" ), " ", props.style === 'secondary' && /*#__PURE__*/react$1.css("background-color:", designSystem.designTokens.colorNeutral95, ";border-color:", designSystem.designTokens.colorSurface, ";" + ("" ), "" ), " ", props.disabled && /*#__PURE__*/react$1.css("cursor:not-allowed;background-color:", designSystem.designTokens.colorAccent98, ";color:", designSystem.designTokens.colorSolid, ";opacity:1;" + ("" ), "" ), " ", !props.isValid && /*#__PURE__*/react$1.css("border-color:", designSystem.designTokens.colorError, ";border:1px solid;" + ("" ), "" ), ";" + ("" ), "" );
|
|
1215
|
-
var _ref$g = {
|
|
1216
|
-
name: "7g7czh",
|
|
1217
|
-
styles: "border-top-left-radius:0;border-bottom-left-radius:0;margin-left:0"
|
|
1218
|
-
} ;
|
|
1219
|
-
const getInputStyles = props => /*#__PURE__*/react$1.css("transition:0.2s ease;border-radius:", designSystem.designTokens.borderRadiusForInput, ";border-style:solid;border-width:1px;color:", designSystem.designTokens.colorSolid, ";font-weight:", designSystem.designTokens.fontWeight500, ";font-size:", designSystem.designTokens.fontSize10, ";font-family:", designSystem.designTokens.fontFamily, ";padding:", designSystem.designTokens.spacingS, " ", designSystem.designTokens.spacingM, ";outline:none;box-shadow:none;appearance:none;width:100%;min-height:", designSystem.designTokens.heightForInput, ";", props.style === 'primary' && /*#__PURE__*/react$1.css("border-color:", designSystem.designTokens.colorNeutral, ";background-color:", designSystem.designTokens.colorSurface, ";" + ("" ), "" ), " ", props.style === 'secondary' && /*#__PURE__*/react$1.css("background-color:", designSystem.designTokens.colorNeutral95, ";border-color:", designSystem.designTokens.colorSurface, ";" + ("" ), "" ), " ", props.disabled && /*#__PURE__*/react$1.css("cursor:not-allowed;background-color:", designSystem.designTokens.colorAccent98, ";color:", designSystem.designTokens.colorSolid, ";opacity:1;" + ("" ), "" ), " ", !props.isValid && /*#__PURE__*/react$1.css("border-color:", designSystem.designTokens.colorError, "!important;border:1px solid;" + ("" ), "" ), " ", props.isGranular && _ref$g, ";" + ("" ), "" );
|
|
1220
|
-
|
|
1221
|
-
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; }
|
|
1222
|
-
function _objectSpread$1q(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$1q(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$1q(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
1223
|
-
function _callSuper$7(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct$7() ? _Reflect$construct__default["default"](o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
|
|
1224
|
-
function _isNativeReflectConstruct$7() { try { var t = !Boolean.prototype.valueOf.call(_Reflect$construct__default["default"](Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct$7 = function () { return !!t; })(); }
|
|
1225
|
-
let ThrottledField = /*#__PURE__*/function (_PureComponent) {
|
|
1226
|
-
function ThrottledField() {
|
|
1227
|
-
var _this;
|
|
1228
|
-
_classCallCheck(this, ThrottledField);
|
|
1229
|
-
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
1230
|
-
args[_key] = arguments[_key];
|
|
1231
|
-
}
|
|
1232
|
-
_this = _callSuper$7(this, ThrottledField, [...args]);
|
|
1233
|
-
_this.state = {
|
|
1234
|
-
draftValue: '',
|
|
1235
|
-
prevValue: ''
|
|
1236
|
-
};
|
|
1237
|
-
_this.clearPendingUpdates = () => {
|
|
1238
|
-
clearTimeout(_this.changeTimeout);
|
|
1239
|
-
clearTimeout(_this.blurTimeout);
|
|
1240
|
-
_this.changeTimeout = null;
|
|
1241
|
-
_this.blurTimeout = null;
|
|
1242
|
-
};
|
|
1243
|
-
_this.handleChange = event => {
|
|
1244
|
-
// The `SyntheticEvent` is pooled by default for perf reasons.
|
|
1245
|
-
// See https://facebook.github.io/react/docs/events.html#event-pooling
|
|
1246
|
-
// To access the event in an async way we need to persist it.
|
|
1247
|
-
event.persist();
|
|
1248
|
-
_this.setState({
|
|
1249
|
-
draftValue: event.target.value
|
|
1250
|
-
});
|
|
1251
|
-
_this.doDelayedUpdate(_this.props.onChange, event, 'change');
|
|
1252
|
-
};
|
|
1253
|
-
_this.handleEnter = event => {
|
|
1254
|
-
if (event.keyCode !== 13) return;
|
|
1255
|
-
if (_this.changeTimeout) {
|
|
1256
|
-
// Since there are still are some pending updates that are not sent to the
|
|
1257
|
-
// parent yet we need to call the update here explicitly and clear the
|
|
1258
|
-
// pending updates
|
|
1259
|
-
_this.props.onChange({
|
|
1260
|
-
target: {
|
|
1261
|
-
value: _this.state.draftValue
|
|
1262
|
-
}
|
|
1263
|
-
});
|
|
1264
|
-
// we can savely clear the timeout and thus abort all pending changes
|
|
1265
|
-
// because we just update the parent with the current state
|
|
1266
|
-
clearTimeout(_this.changeTimeout);
|
|
1267
|
-
_this.changeTimeout = null;
|
|
1268
|
-
}
|
|
1269
|
-
_this.props.onEnter(_this.state.draftValue);
|
|
1270
|
-
};
|
|
1271
|
-
_this.handleBlur = event => {
|
|
1272
|
-
// The `SyntheticEvent` is pooled by default for perf reasons.
|
|
1273
|
-
// See https://facebook.github.io/react/docs/events.html#event-pooling
|
|
1274
|
-
// To access the event in an async way we need to persist it.
|
|
1275
|
-
if (_this.props.onBlurValue) {
|
|
1276
|
-
event.persist();
|
|
1277
|
-
_this.doDelayedUpdate(e => _this.props.onBlurValue(e.target.value), event, 'blur');
|
|
1278
|
-
}
|
|
1279
|
-
};
|
|
1280
|
-
_this.doDelayedUpdate = (updateFunction, event, eventType) => {
|
|
1281
|
-
const self = _this;
|
|
1282
|
-
const timeoutKey = `${eventType}Timeout`;
|
|
1283
|
-
// TODO: can't we just use one variable?
|
|
1284
|
-
clearTimeout(_this[timeoutKey]);
|
|
1285
|
-
_this[timeoutKey] = _setTimeout__default["default"](() => {
|
|
1286
|
-
updateFunction.call(self, event);
|
|
1287
|
-
_this[timeoutKey] = null;
|
|
1288
|
-
}, _this.props.throttleMS);
|
|
1289
|
-
};
|
|
1290
|
-
return _this;
|
|
1291
|
-
}
|
|
1292
|
-
_inherits(ThrottledField, _PureComponent);
|
|
1293
|
-
return _createClass(ThrottledField, [{
|
|
1294
|
-
key: "componentWillUnmount",
|
|
1295
|
-
value: function componentWillUnmount() {
|
|
1296
|
-
this.clearPendingUpdates();
|
|
1297
|
-
}
|
|
1298
|
-
}, {
|
|
1299
|
-
key: "render",
|
|
1300
|
-
value: function render() {
|
|
1301
|
-
const commonProps = _objectSpread$1q(_objectSpread$1q({
|
|
1302
|
-
value: this.state.draftValue,
|
|
1303
|
-
autoComplete: this.props.autoComplete,
|
|
1304
|
-
onChange: this.handleChange,
|
|
1305
|
-
onBlur: this.handleBlur,
|
|
1306
|
-
disabled: this.props.disabled,
|
|
1307
|
-
name: this.props.name,
|
|
1308
|
-
placeholder: this.props.placeholder,
|
|
1309
|
-
autoFocus: this.props.autoFocus
|
|
1310
|
-
}, this.props.onEnter ? {
|
|
1311
|
-
onKeyDown: this.handleEnter
|
|
1312
|
-
} : {}), filterDataAttributes(this.props));
|
|
1313
|
-
const inputId = `throttled-field-${this.props.name}`;
|
|
1314
|
-
return jsxRuntime.jsxs(jsxRuntime.Fragment, {
|
|
1315
|
-
children: [jsxRuntime.jsx(uiKit.AccessibleHidden, {
|
|
1316
|
-
children: jsxRuntime.jsx("label", {
|
|
1317
|
-
htmlFor: inputId,
|
|
1318
|
-
children: this.props.label
|
|
1319
|
-
})
|
|
1320
|
-
}), this.props.as === 'textarea' ? jsxRuntime.jsx(Textarea__default["default"], _objectSpread$1q(_objectSpread$1q({}, commonProps), {}, {
|
|
1321
|
-
id: inputId,
|
|
1322
|
-
css: getTextareaStyles(this.props),
|
|
1323
|
-
rows: 1,
|
|
1324
|
-
maxRows: this.props.autoSize ? undefined : 1,
|
|
1325
|
-
cacheMeasurements: true
|
|
1326
|
-
})) : jsxRuntime.jsx("input", _objectSpread$1q(_objectSpread$1q({}, commonProps), {}, {
|
|
1327
|
-
id: inputId,
|
|
1328
|
-
ref: this.props.inputRef,
|
|
1329
|
-
type: this.props.as,
|
|
1330
|
-
css: getInputStyles(this.props)
|
|
1331
|
-
}))]
|
|
1332
|
-
});
|
|
1333
|
-
}
|
|
1334
|
-
}], [{
|
|
1335
|
-
key: "getDerivedStateFromProps",
|
|
1336
|
-
value: function getDerivedStateFromProps(nextProps, prevState) {
|
|
1337
|
-
if (nextProps.value !== prevState.prevValue) {
|
|
1338
|
-
return {
|
|
1339
|
-
draftValue: nextProps.value || nextProps.value === 0 ? nextProps.value : '',
|
|
1340
|
-
prevValue: nextProps.value
|
|
1341
|
-
};
|
|
1342
|
-
}
|
|
1343
|
-
return null;
|
|
1344
|
-
}
|
|
1345
|
-
}]);
|
|
1346
|
-
}(React.PureComponent);
|
|
1347
|
-
ThrottledField.displayName = 'ThrottledField';
|
|
1348
|
-
ThrottledField.defaultProps = {
|
|
1349
|
-
as: 'text',
|
|
1350
|
-
style: 'secondary',
|
|
1351
|
-
throttleMS: 300,
|
|
1352
|
-
isValid: true,
|
|
1353
|
-
disabled: false,
|
|
1354
|
-
autoSize: true,
|
|
1355
|
-
autoFocus: false,
|
|
1356
|
-
label: 'Throttled field'
|
|
1357
|
-
};
|
|
1358
|
-
var ThrottledField$1 = ThrottledField;
|
|
1359
|
-
|
|
1360
|
-
var messages$P = reactIntl.defineMessages({
|
|
1361
|
-
buttonLabel: {
|
|
1362
|
-
id: 'SearchInput.buttonLabel',
|
|
1363
|
-
description: 'Label for "Search" button.',
|
|
1364
|
-
defaultMessage: 'Search'
|
|
1365
|
-
},
|
|
1366
|
-
placeholder: {
|
|
1367
|
-
id: 'SearchInput.placeholder',
|
|
1368
|
-
description: 'Placeholder for "Search" input field',
|
|
1369
|
-
defaultMessage: 'Search'
|
|
1370
|
-
}
|
|
1371
|
-
});
|
|
1372
|
-
|
|
1373
|
-
const getInputContainerStyles = props => /*#__PURE__*/react$1.css("border-color:", props.isGranular ? designSystem.designTokens.colorPrimary : designSystem.designTokens.borderColorForInput, ";height:", designSystem.designTokens.heightForInput, ";position:relative;&>input{padding-right:", designSystem.designTokens.spacing70, ";padding-left:", designSystem.designTokens.spacing55, ";font-size:", designSystem.designTokens.fontSize30, ";}&>input::placeholder{font-weight:", designSystem.designTokens.fontWeight400, ";font-size:", designSystem.designTokens.fontSize30, ";font-family:", designSystem.designTokens.fontFamily, ";color:", designSystem.designTokens.colorNeutral60, ";}", !props.disabled && `
|
|
1374
|
-
& > input:hover {
|
|
1375
|
-
border: 1px solid ${designSystem.designTokens.borderColorForInput};
|
|
1376
|
-
background-color: ${designSystem.designTokens.backgroundColorForInputWhenHovered};
|
|
1377
|
-
}
|
|
1378
|
-
|
|
1379
|
-
& > input:focus {
|
|
1380
|
-
box-shadow: inset 0 0 0 1px ${designSystem.designTokens.colorPrimary};
|
|
1381
|
-
border-color: ${designSystem.designTokens.borderColorForInputWhenFocused};
|
|
1382
|
-
}
|
|
1383
|
-
`, " ", props.disabled && props.enableDisabledStyle && `
|
|
1384
|
-
& > input {
|
|
1385
|
-
border-color: ${designSystem.designTokens.colorNeutral};
|
|
1386
|
-
}
|
|
1387
|
-
`, " ", props.isGranular && `
|
|
1388
|
-
right: 3px;
|
|
1389
|
-
`, ";" + ("" ), "" );
|
|
1390
|
-
const getSecondaryIconButtonStyles = props => /*#__PURE__*/react$1.css("background-color:transparent;border-color:transparent;position:absolute;right:20px;top:50%;transform:translateY(-50%);z-index:2;&:hover svg{fill:", designSystem.designTokens.colorError, "!important;}", props.isGranular && `
|
|
1391
|
-
right: 41px;
|
|
1392
|
-
`, ";" + ("" ), "" );
|
|
1393
|
-
const getSearchButtonStyles = props => /*#__PURE__*/react$1.css("background-color:transparent;border-color:transparent;position:absolute;left:10px;top:50%;transform:translateY(-50%);z-index:2;display:inline-flex;align-items:center;justify-content:center;", props.isGranular && `
|
|
1394
|
-
right: 15px;
|
|
1395
|
-
`, " ", !props.disabled && `
|
|
1396
|
-
cursor: pointer;
|
|
1397
|
-
`, ";" + ("" ), "" );
|
|
1398
|
-
|
|
1399
|
-
function _callSuper$6(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct$6() ? _Reflect$construct__default["default"](o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
|
|
1400
|
-
function _isNativeReflectConstruct$6() { try { var t = !Boolean.prototype.valueOf.call(_Reflect$construct__default["default"](Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct$6 = function () { return !!t; })(); }
|
|
1401
|
-
var _ref$f = {
|
|
1402
|
-
name: "kbieq5",
|
|
1403
|
-
styles: "position:relative;flex-grow:1"
|
|
1404
|
-
} ;
|
|
1405
|
-
var _ref2$1 = {
|
|
1406
|
-
name: "n2lgmn",
|
|
1407
|
-
styles: "display:inline-flex;flex-direction:row;align-items:flex-start;width:100%;max-width:800px"
|
|
1408
|
-
} ;
|
|
1409
|
-
let SearchInput = /*#__PURE__*/function (_Component) {
|
|
1410
|
-
function SearchInput() {
|
|
1411
|
-
var _this;
|
|
1412
|
-
_classCallCheck(this, SearchInput);
|
|
1413
|
-
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
1414
|
-
args[_key] = arguments[_key];
|
|
1415
|
-
}
|
|
1416
|
-
_this = _callSuper$6(this, SearchInput, [...args]);
|
|
1417
|
-
_this.state = {
|
|
1418
|
-
initialValue: _this.props.initialValue,
|
|
1419
|
-
text: _this.props.initialValue || ''
|
|
1420
|
-
};
|
|
1421
|
-
_this.handleInputChange = event => {
|
|
1422
|
-
const value = event.target.value;
|
|
1423
|
-
_this.setState({
|
|
1424
|
-
text: value
|
|
1425
|
-
}, () => {
|
|
1426
|
-
if (_this.props.shouldSubmitOnInputChange) _this.props.onSubmit(value, _this.props.searchMode);
|
|
1427
|
-
if (_this.props.onChange) _this.props.onChange(value);
|
|
1428
|
-
});
|
|
1429
|
-
};
|
|
1430
|
-
_this.handleEnter = value => {
|
|
1431
|
-
_this.setState({
|
|
1432
|
-
text: _this.props.shouldClearOnSubmit ? '' : value
|
|
1433
|
-
});
|
|
1434
|
-
_this.props.onSubmit(value, _this.props.searchMode);
|
|
1435
|
-
};
|
|
1436
|
-
_this.handleSubmit = () => {
|
|
1437
|
-
_this.props.onSubmit(_this.state.text, _this.props.searchMode);
|
|
1438
|
-
_this.props.shouldClearOnSubmit && _this.setState({
|
|
1439
|
-
text: ''
|
|
1440
|
-
});
|
|
1441
|
-
};
|
|
1442
|
-
_this.handleClear = () => {
|
|
1443
|
-
_this.inputRef?.focus();
|
|
1444
|
-
_this.props.onChange(null);
|
|
1445
|
-
_this.props.onReset();
|
|
1446
|
-
_this.setState({
|
|
1447
|
-
text: ''
|
|
1448
|
-
});
|
|
1449
|
-
};
|
|
1450
|
-
_this.setInputRef = inputRef => {
|
|
1451
|
-
_this.inputRef = inputRef;
|
|
1452
|
-
};
|
|
1453
|
-
return _this;
|
|
1454
|
-
}
|
|
1455
|
-
_inherits(SearchInput, _Component);
|
|
1456
|
-
return _createClass(SearchInput, [{
|
|
1457
|
-
key: "shouldComponentUpdate",
|
|
1458
|
-
value: function shouldComponentUpdate(nextProps, nextState) {
|
|
1459
|
-
// ignore state, since it is only use to keep track of the text in the child
|
|
1460
|
-
// component, in order to have it ready when the submit button is pressed
|
|
1461
|
-
return !fastEquals.deepEqual(this.props, nextProps, {
|
|
1462
|
-
strict: true
|
|
1463
|
-
}) || nextState.text !== this.state.text;
|
|
1464
|
-
}
|
|
1465
|
-
}, {
|
|
1466
|
-
key: "render",
|
|
1467
|
-
value: function render() {
|
|
1468
|
-
return jsxRuntime.jsx("div", {
|
|
1469
|
-
className: classnames__default["default"](this.props.blockClassName),
|
|
1470
|
-
css: _ref2$1,
|
|
1471
|
-
children: jsxRuntime.jsxs("div", {
|
|
1472
|
-
className: classnames__default["default"](this.props.containerClassName),
|
|
1473
|
-
css: _ref$f,
|
|
1474
|
-
children: [jsxRuntime.jsx("div", {
|
|
1475
|
-
"data-testid": "search-button",
|
|
1476
|
-
css: getSearchButtonStyles(this.props),
|
|
1477
|
-
onClick: this.props.disabled ? null : this.handleSubmit,
|
|
1478
|
-
label: "search-button",
|
|
1479
|
-
onMouseOver: this.props.handleMouseOver,
|
|
1480
|
-
onMouseOut: this.props.handleMouseOut,
|
|
1481
|
-
children: jsxRuntime.jsx(uiKit.SearchIcon, {
|
|
1482
|
-
color: this.props.iconColor || this.props.isMouseOver && !this.props.disabled ? 'primary' : 'neutral60',
|
|
1483
|
-
size: "big"
|
|
1484
|
-
})
|
|
1485
|
-
}), jsxRuntime.jsx("div", {
|
|
1486
|
-
css: getInputContainerStyles(this.props),
|
|
1487
|
-
children: jsxRuntime.jsx(ThrottledField$1, {
|
|
1488
|
-
style: "primary",
|
|
1489
|
-
name: "search-text",
|
|
1490
|
-
"data-testid": this.props.testId || 'search-input',
|
|
1491
|
-
value: this.state.text,
|
|
1492
|
-
label: this.props.label,
|
|
1493
|
-
placeholder: this.props.placeholder || this.props.intl.formatMessage(messages$P.placeholder),
|
|
1494
|
-
inputRef: this.props.inputRef || this.setInputRef,
|
|
1495
|
-
onChange: this.handleInputChange,
|
|
1496
|
-
onEnter: this.handleEnter,
|
|
1497
|
-
onBlurValue: this.props.onBlur,
|
|
1498
|
-
throttleMS: this.props.throttleMS,
|
|
1499
|
-
disabled: this.props.disabled,
|
|
1500
|
-
isGranular: this.props.isGranular
|
|
1501
|
-
})
|
|
1502
|
-
}), this.state.text && jsxRuntime.jsx(uiKit.SecondaryIconButton, {
|
|
1503
|
-
css: getSecondaryIconButtonStyles(this.props),
|
|
1504
|
-
icon: jsxRuntime.jsx(uiKit.CloseIcon, {}),
|
|
1505
|
-
size: "20",
|
|
1506
|
-
label: "clear-button",
|
|
1507
|
-
color: "solid",
|
|
1508
|
-
onClick: this.handleClear
|
|
1509
|
-
})]
|
|
1510
|
-
})
|
|
1511
|
-
});
|
|
1512
|
-
}
|
|
1513
|
-
}], [{
|
|
1514
|
-
key: "getDerivedStateFromProps",
|
|
1515
|
-
value: function getDerivedStateFromProps(nextProps, prevState) {
|
|
1516
|
-
if (prevState.initialValue !== nextProps.initialValue) {
|
|
1517
|
-
return {
|
|
1518
|
-
initialValue: nextProps.initialValue,
|
|
1519
|
-
text: nextProps.initialValue || ''
|
|
1520
|
-
};
|
|
1521
|
-
}
|
|
1522
|
-
return null;
|
|
1523
|
-
}
|
|
1524
|
-
}]);
|
|
1525
|
-
}(React.Component);
|
|
1526
|
-
SearchInput.displayName = 'SearchInput';
|
|
1527
|
-
SearchInput.defaultProps = {
|
|
1528
|
-
throttleMS: 300,
|
|
1529
|
-
onReset: () => null,
|
|
1530
|
-
label: 'Search input',
|
|
1531
|
-
onChange: () => null
|
|
1532
|
-
};
|
|
1533
|
-
var searchInput = flowRight__default["default"](keepDisplayName$1(SearchInput), withMouseOverState$1, reactIntl.injectIntl)(SearchInput);
|
|
1534
|
-
|
|
1535
1170
|
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; }
|
|
1536
1171
|
function _objectSpread$1p(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$1p(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$1p(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
1537
1172
|
const injectDataTablePaginationState = initialValues => Component => {
|
|
@@ -4473,7 +4108,7 @@ const getPrefixSearchBounds = input => {
|
|
|
4473
4108
|
};
|
|
4474
4109
|
var getPrefixSearchBounds$1 = getPrefixSearchBounds;
|
|
4475
4110
|
|
|
4476
|
-
const _excluded$
|
|
4111
|
+
const _excluded$e = ["action"];
|
|
4477
4112
|
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; }
|
|
4478
4113
|
function _objectSpread$19(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$19(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$19(Object(t))).call(_context1, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
4479
4114
|
|
|
@@ -5034,7 +4669,7 @@ const convertAction = (actionName, actionPayload) => {
|
|
|
5034
4669
|
};
|
|
5035
4670
|
const createGraphQlUpdateActions = actions => _reduceInstanceProperty__default["default"](actions).call(actions, (previousActions, _ref9) => {
|
|
5036
4671
|
let actionName = _ref9.action,
|
|
5037
|
-
actionPayload = _objectWithoutProperties(_ref9, _excluded$
|
|
4672
|
+
actionPayload = _objectWithoutProperties(_ref9, _excluded$e);
|
|
5038
4673
|
return [...previousActions, convertAction(actionName, actionPayload)];
|
|
5039
4674
|
}, []);
|
|
5040
4675
|
const extractErrorFromGraphQlResponse = graphQlResponse => {
|
|
@@ -6033,45 +5668,6 @@ function useCachedCategoryOptions(ids) {
|
|
|
6033
5668
|
}]));
|
|
6034
5669
|
}
|
|
6035
5670
|
|
|
6036
|
-
var _ref$d = {
|
|
6037
|
-
name: "1d3w5wq",
|
|
6038
|
-
styles: "width:100%"
|
|
6039
|
-
} ;
|
|
6040
|
-
var _ref2 = {
|
|
6041
|
-
name: "164dmm0",
|
|
6042
|
-
styles: "pointer-events:none;opacity:0.5"
|
|
6043
|
-
} ;
|
|
6044
|
-
const getButtonStyles = props => /*#__PURE__*/react$1.css("transition:background-color 0.08s linear;border:none;border-radius:", designSystem.designTokens.borderRadiusForInput, ";color:", designSystem.designTokens.colorSolid, ";cursor:pointer;display:inline-block;font-family:", designSystem.designTokens.fontFamily, ";font-size:", designSystem.designTokens.fontSize10, ";padding:", designSystem.designTokens.spacingS, " ", designSystem.designTokens.spacingM, ";vertical-align:middle;min-height:", designSystem.designTokens.heightForInput, ";", props.variant === 'cancel' && /*#__PURE__*/react$1.css("background:", designSystem.designTokens.colorSurface, ";border:1px solid ", designSystem.designTokens.colorNeutral, ";&:hover{border-color:", designSystem.designTokens.colorPrimary, ";color:", designSystem.designTokens.colorPrimary, ";}" + ("" ), "" ), " ", props.variant === 'confirm' && /*#__PURE__*/react$1.css("background:", designSystem.designTokens.colorPrimary, ";color:", designSystem.designTokens.colorSurface, ";&:hover{background:", designSystem.designTokens.colorPrimary25, ";}" + ("" ), "" ), " ", props.variant === 'save' && /*#__PURE__*/react$1.css("background:", designSystem.designTokens.colorPrimary, ";color:", designSystem.designTokens.colorSurface, "!important;&:hover{background:", designSystem.designTokens.colorPrimary25, ";}" + ("" ), "" ), " ", props.variant === 'add' && /*#__PURE__*/react$1.css("background:", designSystem.designTokens.colorSurface, ";border:1px solid ", designSystem.designTokens.colorNeutral, ";color:", designSystem.designTokens.colorSolid, ";padding:5.5px 15px 5.5px 10px;&:hover{background:", designSystem.designTokens.colorPrimary, ";border-color:", designSystem.designTokens.colorPrimary, ";color:", designSystem.designTokens.colorSurface, ";}" + ("" ), "" ), " ", props.isDisabled && _ref2, " ", props.fullWidth && _ref$d, " ", props.isAlt && /*#__PURE__*/react$1.css("color:", designSystem.designTokens.colorSurface, ";border-radius:20px;border:2px ", designSystem.designTokens.colorSurface, " solid;padding-left:30px;padding-right:30px;" + ("" ), "" ), ";" + ("" ), "" );
|
|
6045
|
-
var getButtonStyles$1 = getButtonStyles;
|
|
6046
|
-
|
|
6047
|
-
const _excluded$e = ["type"];
|
|
6048
|
-
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; }
|
|
6049
|
-
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; }
|
|
6050
|
-
const Button = _ref => {
|
|
6051
|
-
let _ref$type = _ref.type,
|
|
6052
|
-
type = _ref$type === void 0 ? 'button' : _ref$type,
|
|
6053
|
-
props = _objectWithoutProperties(_ref, _excluded$e);
|
|
6054
|
-
const className = props.className,
|
|
6055
|
-
onClick = props.onClick,
|
|
6056
|
-
isDisabled = props.isDisabled,
|
|
6057
|
-
children = props.children;
|
|
6058
|
-
|
|
6059
|
-
// Pass only `data-*` props
|
|
6060
|
-
const dataProps = filterDataAttributes(props);
|
|
6061
|
-
return jsxRuntime.jsx("button", _objectSpread$11(_objectSpread$11({
|
|
6062
|
-
onClick: isDisabled ? null : onClick,
|
|
6063
|
-
type: type,
|
|
6064
|
-
className: classnames__default["default"](className),
|
|
6065
|
-
css: getButtonStyles$1(props),
|
|
6066
|
-
disabled: isDisabled,
|
|
6067
|
-
"aria-label": props['aria-label']
|
|
6068
|
-
}, dataProps), {}, {
|
|
6069
|
-
children: children
|
|
6070
|
-
}));
|
|
6071
|
-
};
|
|
6072
|
-
Button.displayName = 'Button';
|
|
6073
|
-
var Button$1 = Button;
|
|
6074
|
-
|
|
6075
5671
|
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, ";}" + ("" ), "" );
|
|
6076
5672
|
|
|
6077
5673
|
var messages$F = reactIntl.defineMessages({
|
|
@@ -6083,15 +5679,15 @@ var messages$F = reactIntl.defineMessages({
|
|
|
6083
5679
|
});
|
|
6084
5680
|
|
|
6085
5681
|
const _excluded$d = ["children", "allowMultiple", "acceptTypes"];
|
|
6086
|
-
function ownKeys$
|
|
6087
|
-
function _objectSpread$
|
|
6088
|
-
var _ref$
|
|
5682
|
+
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; }
|
|
5683
|
+
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; }
|
|
5684
|
+
var _ref$d = {
|
|
6089
5685
|
name: "1wq0eh7",
|
|
6090
5686
|
styles: "visibility:hidden;width:1px;height:1px"
|
|
6091
5687
|
} ;
|
|
6092
5688
|
const FileInput = _ref2 => {
|
|
6093
5689
|
let _ref2$children = _ref2.children,
|
|
6094
|
-
children = _ref2$children === void 0 ? jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$
|
|
5690
|
+
children = _ref2$children === void 0 ? jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$11({}, messages$F.chooseFile)) : _ref2$children,
|
|
6095
5691
|
_ref2$allowMultiple = _ref2.allowMultiple,
|
|
6096
5692
|
allowMultiple = _ref2$allowMultiple === void 0 ? false : _ref2$allowMultiple,
|
|
6097
5693
|
_ref2$acceptTypes = _ref2.acceptTypes,
|
|
@@ -6101,7 +5697,7 @@ const FileInput = _ref2 => {
|
|
|
6101
5697
|
children: jsxRuntime.jsxs("span", {
|
|
6102
5698
|
css: getFileInputStyles(),
|
|
6103
5699
|
children: [jsxRuntime.jsx("input", {
|
|
6104
|
-
css: _ref$
|
|
5700
|
+
css: _ref$d,
|
|
6105
5701
|
type: "file",
|
|
6106
5702
|
accept: acceptTypes,
|
|
6107
5703
|
name: props.name,
|
|
@@ -6121,15 +5717,15 @@ const baseButtonStyles = {
|
|
|
6121
5717
|
} ;
|
|
6122
5718
|
|
|
6123
5719
|
const _excluded$c = ["animationOrientation", "children", "onClick"];
|
|
6124
|
-
function ownKeys
|
|
6125
|
-
function _objectSpread
|
|
5720
|
+
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; }
|
|
5721
|
+
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; }
|
|
6126
5722
|
const ICON_COLOR$1 = '#6359ff';
|
|
6127
5723
|
const PaginationIconButton = _ref => {
|
|
6128
5724
|
let animationOrientation = _ref.animationOrientation,
|
|
6129
5725
|
children = _ref.children,
|
|
6130
5726
|
onClick = _ref.onClick,
|
|
6131
5727
|
rest = _objectWithoutProperties(_ref, _excluded$c);
|
|
6132
|
-
return jsxRuntime.jsx("button", _objectSpread
|
|
5728
|
+
return jsxRuntime.jsx("button", _objectSpread$10(_objectSpread$10({
|
|
6133
5729
|
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;}" + ("" ), "" ), "" , "" ],
|
|
6134
5730
|
onClick: onClick
|
|
6135
5731
|
}, rest), {}, {
|
|
@@ -6139,8 +5735,8 @@ const PaginationIconButton = _ref => {
|
|
|
6139
5735
|
var PaginationIconButton$1 = PaginationIconButton;
|
|
6140
5736
|
|
|
6141
5737
|
const _excluded$b = ["isFilled", "onClick"];
|
|
6142
|
-
function ownKeys
|
|
6143
|
-
function _objectSpread
|
|
5738
|
+
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; }
|
|
5739
|
+
function _objectSpread$$(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$$(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$$(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
6144
5740
|
const ICON_HEIGHT = '10px';
|
|
6145
5741
|
const ICON_WIDTH = ICON_HEIGHT;
|
|
6146
5742
|
// TODO: Integrate design tokens when redesign is complete
|
|
@@ -6151,7 +5747,7 @@ const PaginationSelectionButton = _ref => {
|
|
|
6151
5747
|
isFilled = _ref$isFilled === void 0 ? false : _ref$isFilled,
|
|
6152
5748
|
onClick = _ref.onClick,
|
|
6153
5749
|
rest = _objectWithoutProperties(_ref, _excluded$b);
|
|
6154
|
-
return jsxRuntime.jsx("button", _objectSpread
|
|
5750
|
+
return jsxRuntime.jsx("button", _objectSpread$$({
|
|
6155
5751
|
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, ";}" + ("" ), "" ), "" , "" ],
|
|
6156
5752
|
onClick: onClick
|
|
6157
5753
|
}, rest));
|
|
@@ -6281,7 +5877,7 @@ const BaseCarousel = _ref2 => {
|
|
|
6281
5877
|
})]
|
|
6282
5878
|
});
|
|
6283
5879
|
};
|
|
6284
|
-
var _ref$
|
|
5880
|
+
var _ref$c = {
|
|
6285
5881
|
name: "97rk2e",
|
|
6286
5882
|
styles: "width:100%;height:100%;flex-shrink:0;scroll-snap-align:start"
|
|
6287
5883
|
} ;
|
|
@@ -6304,7 +5900,7 @@ const CarouselContent = _ref3 => {
|
|
|
6304
5900
|
role: "group",
|
|
6305
5901
|
"aria-roledescription": "slide",
|
|
6306
5902
|
"aria-label": `slide-${idx + 1}`,
|
|
6307
|
-
css: _ref$
|
|
5903
|
+
css: _ref$c,
|
|
6308
5904
|
children: jsxRuntime.jsxs(uiKit.Spacings.Stack, {
|
|
6309
5905
|
children: [item.imgSrc && item.imgAlt && jsxRuntime.jsx("img", {
|
|
6310
5906
|
css: /*#__PURE__*/react$1.css("width:100%;height:", IMAGE_AREA_HEIGHT, "px;" + ("" ), "" ),
|
|
@@ -6370,8 +5966,8 @@ var messages$E = reactIntl.defineMessages({
|
|
|
6370
5966
|
}
|
|
6371
5967
|
});
|
|
6372
5968
|
|
|
6373
|
-
function ownKeys$
|
|
6374
|
-
function _objectSpread$
|
|
5969
|
+
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; }
|
|
5970
|
+
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; }
|
|
6375
5971
|
const emptyCountryOption = intl => [{
|
|
6376
5972
|
label: intl.formatMessage(messages$E.countriesAsyncSelectDropdownTypeAheadPrompt),
|
|
6377
5973
|
value: undefined,
|
|
@@ -6398,7 +5994,7 @@ function CountriesAsyncSelectDropdown(props) {
|
|
|
6398
5994
|
const onOptionChange = event => {
|
|
6399
5995
|
const countries = event.target.value;
|
|
6400
5996
|
props.onChange({
|
|
6401
|
-
target: _objectSpread$
|
|
5997
|
+
target: _objectSpread$_(_objectSpread$_({}, event.target), {}, {
|
|
6402
5998
|
value: _mapInstanceProperty__default["default"](countries).call(countries, country => country?.value ?? country)
|
|
6403
5999
|
})
|
|
6404
6000
|
});
|
|
@@ -6449,8 +6045,8 @@ function CountriesBasicSelectDropdown(props) {
|
|
|
6449
6045
|
const COUNTRIES_ASYNC_LOADING_LIMIT = 60;
|
|
6450
6046
|
|
|
6451
6047
|
const _excluded$a = ["countriesAsyncLoadingLimit", "isMulti", "isRequired", "hasWarning"];
|
|
6452
|
-
function ownKeys$
|
|
6453
|
-
function _objectSpread$
|
|
6048
|
+
function ownKeys$Z(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; }
|
|
6049
|
+
function _objectSpread$Z(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$Z(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$Z(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
6454
6050
|
function CountriesPicker(_ref) {
|
|
6455
6051
|
let _ref$countriesAsyncLo = _ref.countriesAsyncLoadingLimit,
|
|
6456
6052
|
countriesAsyncLoadingLimit = _ref$countriesAsyncLo === void 0 ? COUNTRIES_ASYNC_LOADING_LIMIT : _ref$countriesAsyncLo,
|
|
@@ -6463,7 +6059,7 @@ function CountriesPicker(_ref) {
|
|
|
6463
6059
|
props = _objectWithoutProperties(_ref, _excluded$a);
|
|
6464
6060
|
const CustomCountriesPicker = props.options?.length <= countriesAsyncLoadingLimit ? CountriesBasicSelectDropdown : CountriesAsyncSelectDropdown;
|
|
6465
6061
|
return jsxRuntime.jsx(uiKit.Spacings.Stack, {
|
|
6466
|
-
children: jsxRuntime.jsx(CustomCountriesPicker, _objectSpread$
|
|
6062
|
+
children: jsxRuntime.jsx(CustomCountriesPicker, _objectSpread$Z({
|
|
6467
6063
|
countriesAsyncLoadingLimit: countriesAsyncLoadingLimit,
|
|
6468
6064
|
isMulti: isMulti,
|
|
6469
6065
|
isRequired: isRequired,
|
|
@@ -6632,6 +6228,9 @@ const FormattedLocalizedString = /*#__PURE__*/React__namespace.memo(_ref => {
|
|
|
6632
6228
|
});
|
|
6633
6229
|
FormattedLocalizedString.displayName = 'FormattedLocalizedString';
|
|
6634
6230
|
|
|
6231
|
+
const keepDisplayName = component => setDisplayName$1(getDisplayName$1(component));
|
|
6232
|
+
var keepDisplayName$1 = keepDisplayName;
|
|
6233
|
+
|
|
6635
6234
|
// eslint-disable-next-line import/prefer-default-export
|
|
6636
6235
|
const CUSTOM_FIELD_TYPES = {
|
|
6637
6236
|
text: 'text',
|
|
@@ -6669,9 +6268,9 @@ const REFERENCED_TYPES = {
|
|
|
6669
6268
|
const ATTRIBUTE_TYPES = ['text', 'ltext', 'number', 'enum', 'lenum', 'money', 'boolean', 'date', 'datetime', 'reference', 'time'];
|
|
6670
6269
|
const SET_ATTRIBUTE_TYPES = ['text', 'ltext', 'number', 'enum', 'lenum', 'money', 'boolean', 'date', 'time', 'datetime', 'reference'];
|
|
6671
6270
|
|
|
6672
|
-
function ownKeys$
|
|
6673
|
-
function _objectSpread$
|
|
6674
|
-
const mergeSetItemsErrors = errors => _reduceInstanceProperty__default["default"](errors).call(errors, (result, itemErrors) => _objectSpread$
|
|
6271
|
+
function ownKeys$Y(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; }
|
|
6272
|
+
function _objectSpread$Y(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$Y(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$Y(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
6273
|
+
const mergeSetItemsErrors = errors => _reduceInstanceProperty__default["default"](errors).call(errors, (result, itemErrors) => _objectSpread$Y(_objectSpread$Y({}, result), itemErrors), {});
|
|
6675
6274
|
|
|
6676
6275
|
// TODO(pa3): worth splitting in two components: one of set errors and one for
|
|
6677
6276
|
// all the other types of fields. So that there will be no isArray check.
|
|
@@ -6796,7 +6395,7 @@ const ExpandButton = props => props.totalValues > 1 ? jsxRuntime.jsxs(uiKit.Spac
|
|
|
6796
6395
|
ExpandButton.displayName = 'ExpandButton';
|
|
6797
6396
|
var ExpandButton$1 = ExpandButton;
|
|
6798
6397
|
|
|
6799
|
-
var _ref$
|
|
6398
|
+
var _ref$b = {
|
|
6800
6399
|
name: "1yjx7km",
|
|
6801
6400
|
styles: "padding:20px"
|
|
6802
6401
|
} ;
|
|
@@ -6816,7 +6415,7 @@ const SetButtons = props => {
|
|
|
6816
6415
|
size: "big",
|
|
6817
6416
|
icon: jsxRuntime.jsx(uiKit.PlusBoldIcon, {})
|
|
6818
6417
|
}) : jsxRuntime.jsx("div", {
|
|
6819
|
-
css: _ref$
|
|
6418
|
+
css: _ref$b
|
|
6820
6419
|
})]
|
|
6821
6420
|
})
|
|
6822
6421
|
});
|
|
@@ -6824,8 +6423,8 @@ const SetButtons = props => {
|
|
|
6824
6423
|
SetButtons.displayName = 'SetButtons';
|
|
6825
6424
|
var SetButtons$1 = SetButtons;
|
|
6826
6425
|
|
|
6827
|
-
function ownKeys$
|
|
6828
|
-
function _objectSpread$
|
|
6426
|
+
function ownKeys$X(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; }
|
|
6427
|
+
function _objectSpread$X(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$X(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$X(Object(t))).call(_context3, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
6829
6428
|
const getDuplicateErrors = setValues => {
|
|
6830
6429
|
/* eslint-disable no-plusplus */
|
|
6831
6430
|
const result = [];
|
|
@@ -6878,7 +6477,7 @@ function CustomInputSet(props) {
|
|
|
6878
6477
|
touched = _useFormikContext.touched,
|
|
6879
6478
|
isSubmitting = _useFormikContext.isSubmitting,
|
|
6880
6479
|
dirty = _useFormikContext.dirty;
|
|
6881
|
-
const itemFieldDefinition = _objectSpread$
|
|
6480
|
+
const itemFieldDefinition = _objectSpread$X(_objectSpread$X({}, props.fieldDefinition), {}, {
|
|
6882
6481
|
type: props.fieldDefinition.type.elementType
|
|
6883
6482
|
});
|
|
6884
6483
|
const value = React.useMemo(() => props.value || [undefined], [props.value]);
|
|
@@ -7134,8 +6733,8 @@ function CustomLocalizedEnumInput(props) {
|
|
|
7134
6733
|
}
|
|
7135
6734
|
CustomLocalizedEnumInput.displayName = 'CustomLocalizedEnumInput';
|
|
7136
6735
|
|
|
7137
|
-
function ownKeys$
|
|
7138
|
-
function _objectSpread$
|
|
6736
|
+
function ownKeys$W(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; }
|
|
6737
|
+
function _objectSpread$W(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$W(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$W(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
7139
6738
|
const getSubfieldLanguage = subfieldName => {
|
|
7140
6739
|
const lastDotIndex = _lastIndexOfInstanceProperty__default["default"](subfieldName).call(subfieldName, '.');
|
|
7141
6740
|
return subfieldName.substring(lastDotIndex + 1);
|
|
@@ -7158,7 +6757,7 @@ function CustomLocalizedTextInput(props) {
|
|
|
7158
6757
|
// as a whole.
|
|
7159
6758
|
|
|
7160
6759
|
const fieldLanguage = getSubfieldLanguage(subfieldName);
|
|
7161
|
-
const newValue = _objectSpread$
|
|
6760
|
+
const newValue = _objectSpread$W(_objectSpread$W({}, props.value), {}, {
|
|
7162
6761
|
[fieldLanguage]: rawValue
|
|
7163
6762
|
});
|
|
7164
6763
|
const nullifiedIfNeeded = uiKit.LocalizedTextInput.isEmpty(newValue) ? undefined : newValue;
|
|
@@ -7186,18 +6785,18 @@ function CustomLocalizedTextInput(props) {
|
|
|
7186
6785
|
}
|
|
7187
6786
|
CustomLocalizedTextInput.displayName = 'CustomLocalizedTextInput';
|
|
7188
6787
|
|
|
7189
|
-
function ownKeys$
|
|
7190
|
-
function _objectSpread$
|
|
6788
|
+
function ownKeys$V(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; }
|
|
6789
|
+
function _objectSpread$V(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$V(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$V(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
7191
6790
|
const fixCurrencyCode = (value, currencies) => {
|
|
7192
6791
|
if (value.currencyCode) return value;
|
|
7193
6792
|
const firstCurrency = currencies[0];
|
|
7194
|
-
return _objectSpread$
|
|
6793
|
+
return _objectSpread$V(_objectSpread$V({}, value), {}, {
|
|
7195
6794
|
currencyCode: firstCurrency
|
|
7196
6795
|
});
|
|
7197
6796
|
};
|
|
7198
6797
|
const fixAmount = value => {
|
|
7199
6798
|
if (!value.amount) {
|
|
7200
|
-
return _objectSpread$
|
|
6799
|
+
return _objectSpread$V(_objectSpread$V({}, value), {}, {
|
|
7201
6800
|
amount: '0'
|
|
7202
6801
|
});
|
|
7203
6802
|
}
|
|
@@ -7218,7 +6817,7 @@ const fixEnteredValue = (newValue, initialValue, currencies) => {
|
|
|
7218
6817
|
}
|
|
7219
6818
|
return withFixedCurrency;
|
|
7220
6819
|
};
|
|
7221
|
-
var _ref$
|
|
6820
|
+
var _ref$a = {
|
|
7222
6821
|
name: "1d3w5wq",
|
|
7223
6822
|
styles: "width:100%"
|
|
7224
6823
|
} ;
|
|
@@ -7243,7 +6842,7 @@ function CustomMoneyInput(props) {
|
|
|
7243
6842
|
}
|
|
7244
6843
|
const handleChange = makeChangeHandler((rawValue, subfieldName) => {
|
|
7245
6844
|
const isAmount = _endsWithInstanceProperty__default["default"](subfieldName).call(subfieldName, 'amount');
|
|
7246
|
-
const newValue = _objectSpread$
|
|
6845
|
+
const newValue = _objectSpread$V({}, internalValue.current);
|
|
7247
6846
|
if (isAmount) newValue.amount = rawValue;else newValue.currencyCode = rawValue;
|
|
7248
6847
|
const fixedValue = fixEnteredValue(newValue, internalValue.current, currencies);
|
|
7249
6848
|
internalValue.current = fixedValue;
|
|
@@ -7254,7 +6853,7 @@ function CustomMoneyInput(props) {
|
|
|
7254
6853
|
|
|
7255
6854
|
// TODO(pa3): fix setting proper id in UIKit
|
|
7256
6855
|
return jsxRuntime.jsxs("div", {
|
|
7257
|
-
css: _ref$
|
|
6856
|
+
css: _ref$a,
|
|
7258
6857
|
"aria-labelledby": props.name,
|
|
7259
6858
|
children: [jsxRuntime.jsx(uiKit.AccessibleHidden, {
|
|
7260
6859
|
children: jsxRuntime.jsx("label", {
|
|
@@ -7280,23 +6879,23 @@ function CustomMoneyInput(props) {
|
|
|
7280
6879
|
}
|
|
7281
6880
|
CustomMoneyInput.displayName = 'CustomMoneyInput';
|
|
7282
6881
|
|
|
7283
|
-
function ownKeys$
|
|
7284
|
-
function _objectSpread$
|
|
6882
|
+
function ownKeys$U(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; }
|
|
6883
|
+
function _objectSpread$U(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$U(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$U(Object(t))).call(_context9, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
7285
6884
|
var FetchProductTypeQuery = { kind: "Document", definitions: [{ kind: "OperationDefinition", operation: "query", name: { kind: "Name", value: "FetchProductTypeQuery" }, variableDefinitions: [{ kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "id" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "String" } } }, directives: [] }], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "productType" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "id" }, value: { kind: "Variable", name: { kind: "Name", value: "id" } } }], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "name" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "attributeDefinitions" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "limit" }, value: { kind: "IntValue", value: "100" } }], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "results" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "name" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "isRequired" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "inputHint" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "inputTipAllLocales" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "value" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "locale" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "labelAllLocales" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "value" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "locale" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "type" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "name" }, arguments: [], directives: [] }, { kind: "InlineFragment", typeCondition: { kind: "NamedType", name: { kind: "Name", value: "SetAttributeDefinitionType" } }, directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "elementType" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "name" }, arguments: [], directives: [] }, { kind: "InlineFragment", typeCondition: { kind: "NamedType", name: { kind: "Name", value: "NestedAttributeDefinitionType" } }, directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "typeRef" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "id" }, arguments: [], directives: [] }] } }] } }, { kind: "InlineFragment", typeCondition: { kind: "NamedType", name: { kind: "Name", value: "EnumAttributeDefinitionType" } }, directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "values" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "results" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "key" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "label" }, arguments: [], directives: [] }] } }] } }] } }, { kind: "InlineFragment", typeCondition: { kind: "NamedType", name: { kind: "Name", value: "LocalizableEnumAttributeDefinitionType" } }, directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "values" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "results" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "key" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "labelAllLocales" }, 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: "InlineFragment", typeCondition: { kind: "NamedType", name: { kind: "Name", value: "ReferenceAttributeDefinitionType" } }, directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "referenceTypeId" }, arguments: [], directives: [] }] } }] } }] } }, { kind: "InlineFragment", typeCondition: { kind: "NamedType", name: { kind: "Name", value: "ReferenceAttributeDefinitionType" } }, directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "referenceTypeId" }, arguments: [], directives: [] }] } }, { kind: "InlineFragment", typeCondition: { kind: "NamedType", name: { kind: "Name", value: "NestedAttributeDefinitionType" } }, directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "typeRef" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "id" }, arguments: [], directives: [] }] } }] } }, { kind: "InlineFragment", typeCondition: { kind: "NamedType", name: { kind: "Name", value: "EnumAttributeDefinitionType" } }, directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "values" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "results" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "key" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "label" }, arguments: [], directives: [] }] } }] } }] } }, { kind: "InlineFragment", typeCondition: { kind: "NamedType", name: { kind: "Name", value: "LocalizableEnumAttributeDefinitionType" } }, directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "values" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "results" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "key" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "labelAllLocales" }, 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: 1905, source: { body: "query FetchProductTypeQuery($id: String!) {\n productType(id: $id) {\n name\n attributeDefinitions(limit: 100) {\n results {\n name\n isRequired\n inputHint\n inputTipAllLocales {\n value\n locale\n }\n labelAllLocales {\n value\n locale\n }\n type {\n name\n ... on SetAttributeDefinitionType {\n elementType {\n name\n ... on NestedAttributeDefinitionType {\n typeRef {\n id\n }\n }\n ... on EnumAttributeDefinitionType {\n values {\n results {\n key\n label\n }\n }\n }\n ... on LocalizableEnumAttributeDefinitionType {\n values {\n results {\n key\n labelAllLocales {\n locale\n value\n }\n }\n }\n }\n ... on ReferenceAttributeDefinitionType {\n referenceTypeId\n }\n }\n }\n ... on ReferenceAttributeDefinitionType {\n referenceTypeId\n }\n ... on NestedAttributeDefinitionType {\n typeRef {\n id\n }\n }\n ... on EnumAttributeDefinitionType {\n values {\n results {\n key\n label\n }\n }\n }\n ... on LocalizableEnumAttributeDefinitionType {\n values {\n results {\n key\n labelAllLocales {\n locale\n value\n }\n }\n }\n }\n }\n }\n }\n }\n}\n", name: "GraphQL request", locationOffset: { line: 1, column: 1 } } } };
|
|
7286
6885
|
const mapAttributeDefinition = definition => {
|
|
7287
6886
|
var _context, _context2, _context3, _context4;
|
|
7288
|
-
return _objectSpread$
|
|
6887
|
+
return _objectSpread$U(_objectSpread$U({}, definition), {}, {
|
|
7289
6888
|
required: definition.isRequired,
|
|
7290
6889
|
inputTip: l10n.transformLocalizedFieldToLocalizedString(definition.inputTipAllLocales),
|
|
7291
6890
|
label: l10n.transformLocalizedFieldToLocalizedString(definition.labelAllLocales),
|
|
7292
|
-
type: _includesInstanceProperty__default["default"](_context = ['enum', 'lenum']).call(_context, definition.type?.elementType?.name) ? _objectSpread$
|
|
7293
|
-
elementType: _objectSpread$
|
|
6891
|
+
type: _includesInstanceProperty__default["default"](_context = ['enum', 'lenum']).call(_context, definition.type?.elementType?.name) ? _objectSpread$U(_objectSpread$U({}, definition.type), {}, {
|
|
6892
|
+
elementType: _objectSpread$U(_objectSpread$U({}, definition.type.elementType), {}, {
|
|
7294
6893
|
values: _mapInstanceProperty__default["default"](_context2 = _valuesInstanceProperty__default["default"](definition.type.elementType).results).call(_context2, value => ({
|
|
7295
6894
|
key: value.key,
|
|
7296
6895
|
label: value.label || l10n.transformLocalizedFieldToLocalizedString(value.labelAllLocales)
|
|
7297
6896
|
}))
|
|
7298
6897
|
})
|
|
7299
|
-
}) : _includesInstanceProperty__default["default"](_context3 = ['enum', 'lenum']).call(_context3, definition.type?.name) ? _objectSpread$
|
|
6898
|
+
}) : _includesInstanceProperty__default["default"](_context3 = ['enum', 'lenum']).call(_context3, definition.type?.name) ? _objectSpread$U(_objectSpread$U({}, definition.type), {}, {
|
|
7300
6899
|
values: _mapInstanceProperty__default["default"](_context4 = _valuesInstanceProperty__default["default"](definition.type).results).call(_context4, value => ({
|
|
7301
6900
|
key: value.key,
|
|
7302
6901
|
label: value.label || l10n.transformLocalizedFieldToLocalizedString(value.labelAllLocales)
|
|
@@ -7433,8 +7032,8 @@ var messages$A = reactIntl.defineMessages({
|
|
|
7433
7032
|
}
|
|
7434
7033
|
});
|
|
7435
7034
|
|
|
7436
|
-
function ownKeys$
|
|
7437
|
-
function _objectSpread$
|
|
7035
|
+
function ownKeys$T(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; }
|
|
7036
|
+
function _objectSpread$T(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$T(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$T(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
7438
7037
|
const EditButton = props => {
|
|
7439
7038
|
const _useIntl = reactIntl.useIntl(),
|
|
7440
7039
|
formatMessage = _useIntl.formatMessage;
|
|
@@ -7582,13 +7181,13 @@ const CustomNestedInput = /*#__PURE__*/React.memo(props => {
|
|
|
7582
7181
|
const valuesAsMap = nameValuePairsToMap(value);
|
|
7583
7182
|
const initialValues = omitUnknownValues(valuesAsMap, attributeDefinitionsAsMap);
|
|
7584
7183
|
const openNestedAttributesForm = () => {
|
|
7585
|
-
if (nestingLevel === 0) parentFormik.setStatus(_objectSpread$
|
|
7184
|
+
if (nestingLevel === 0) parentFormik.setStatus(_objectSpread$T(_objectSpread$T({}, parentFormik.status), {}, {
|
|
7586
7185
|
hideSaveToolbar: true
|
|
7587
7186
|
}));
|
|
7588
7187
|
attributesForm.openModal();
|
|
7589
7188
|
};
|
|
7590
7189
|
const closeNestedAttributesForm = () => {
|
|
7591
|
-
if (nestingLevel === 0) parentFormik.setStatus(_objectSpread$
|
|
7190
|
+
if (nestingLevel === 0) parentFormik.setStatus(_objectSpread$T(_objectSpread$T({}, parentFormik.status), {}, {
|
|
7592
7191
|
hideSaveToolbar: false
|
|
7593
7192
|
}));
|
|
7594
7193
|
attributesForm.closeModal();
|
|
@@ -8127,8 +7726,8 @@ var messages$y = reactIntl.defineMessages({
|
|
|
8127
7726
|
}
|
|
8128
7727
|
});
|
|
8129
7728
|
|
|
8130
|
-
function ownKeys$
|
|
8131
|
-
function _objectSpread$
|
|
7729
|
+
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; }
|
|
7730
|
+
function _objectSpread$S(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$S(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$S(Object(t))).call(_context3, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
8132
7731
|
var CartDiscountsCount = { 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: 61, source: { body: "query CartDiscountsCount {\n cartDiscounts {\n total\n }\n}\n", name: "GraphQL request", locationOffset: { line: 1, column: 1 } } } };
|
|
8133
7732
|
const CustomFieldsLabelHint = _ref2 => {
|
|
8134
7733
|
let fieldDefinition = _ref2.fieldDefinition;
|
|
@@ -8157,7 +7756,7 @@ const CustomFieldsLabelHint = _ref2 => {
|
|
|
8157
7756
|
children: [jsxRuntime.jsx(uiKit.WarningIcon, {
|
|
8158
7757
|
size: "medium",
|
|
8159
7758
|
color: "warning"
|
|
8160
|
-
}), jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$
|
|
7759
|
+
}), jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$S({}, messages$y.cartDiscountMoreThan500))]
|
|
8161
7760
|
});
|
|
8162
7761
|
}
|
|
8163
7762
|
return l10n.formatLocalizedString(fieldDefinition, {
|
|
@@ -8201,7 +7800,7 @@ function CustomFieldsLabelSubtitle(_ref3) {
|
|
|
8201
7800
|
}
|
|
8202
7801
|
}
|
|
8203
7802
|
const Portal = props => /*#__PURE__*/ReactDOM__default["default"].createPortal(props.children, document.body);
|
|
8204
|
-
var _ref$
|
|
7803
|
+
var _ref$9 = {
|
|
8205
7804
|
name: "ar8y70",
|
|
8206
7805
|
styles: "cursor:pointer;line-height:normal"
|
|
8207
7806
|
} ;
|
|
@@ -8220,7 +7819,7 @@ function CustomFieldsCountIndicator(_ref4) {
|
|
|
8220
7819
|
TooltipWrapperComponent: Portal
|
|
8221
7820
|
},
|
|
8222
7821
|
children: jsxRuntime.jsx("div", {
|
|
8223
|
-
css: _ref$
|
|
7822
|
+
css: _ref$9,
|
|
8224
7823
|
children: jsxRuntime.jsx(uiKit.SwitcherIcon, {
|
|
8225
7824
|
color: "info",
|
|
8226
7825
|
size: "medium"
|
|
@@ -8278,10 +7877,10 @@ var messages$x = reactIntl.defineMessages({
|
|
|
8278
7877
|
}
|
|
8279
7878
|
});
|
|
8280
7879
|
|
|
8281
|
-
function ownKeys$
|
|
8282
|
-
function _objectSpread$
|
|
7880
|
+
function ownKeys$R(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; }
|
|
7881
|
+
function _objectSpread$R(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$R(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$R(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
8283
7882
|
function ProductTypeReference(props) {
|
|
8284
|
-
const productTypeMessage = _objectSpread$
|
|
7883
|
+
const productTypeMessage = _objectSpread$R(_objectSpread$R({}, messages$x.referencedProductType), {}, {
|
|
8285
7884
|
values: {
|
|
8286
7885
|
productTypeName: props.productType.name
|
|
8287
7886
|
}
|
|
@@ -8330,10 +7929,10 @@ function CustomNestedFieldInput(props) {
|
|
|
8330
7929
|
}
|
|
8331
7930
|
CustomNestedFieldInput.displayName = 'CustomNestedFieldInput';
|
|
8332
7931
|
|
|
8333
|
-
function ownKeys$
|
|
8334
|
-
function _objectSpread$
|
|
7932
|
+
function ownKeys$Q(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; }
|
|
7933
|
+
function _objectSpread$Q(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$Q(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$Q(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
8335
7934
|
function DragHandle(props) {
|
|
8336
|
-
return jsxRuntime.jsx("div", _objectSpread$
|
|
7935
|
+
return jsxRuntime.jsx("div", _objectSpread$Q(_objectSpread$Q({}, props), {}, {
|
|
8337
7936
|
children: jsxRuntime.jsx(uiKit.IconButton, {
|
|
8338
7937
|
icon: jsxRuntime.jsx(uiKit.DragIcon, {}),
|
|
8339
7938
|
size: "medium",
|
|
@@ -8343,9 +7942,9 @@ function DragHandle(props) {
|
|
|
8343
7942
|
}
|
|
8344
7943
|
DragHandle.displayName = 'DragHandle';
|
|
8345
7944
|
|
|
8346
|
-
function ownKeys$
|
|
8347
|
-
function _objectSpread$
|
|
8348
|
-
var _ref$
|
|
7945
|
+
function ownKeys$P(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; }
|
|
7946
|
+
function _objectSpread$P(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$P(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$P(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
7947
|
+
var _ref$8 = {
|
|
8349
7948
|
name: "1onfs6j",
|
|
8350
7949
|
styles: "z-index:100000!important"
|
|
8351
7950
|
} ;
|
|
@@ -8374,10 +7973,10 @@ const DraggableWrapper = _ref2 => {
|
|
|
8374
7973
|
draggableId: draggableId,
|
|
8375
7974
|
index: index,
|
|
8376
7975
|
children: (provided, snapshot) => {
|
|
8377
|
-
const child = jsxRuntime.jsx("div", _objectSpread$
|
|
7976
|
+
const child = jsxRuntime.jsx("div", _objectSpread$P(_objectSpread$P({
|
|
8378
7977
|
ref: provided.innerRef
|
|
8379
7978
|
}, provided.draggableProps), {}, {
|
|
8380
|
-
css: _ref$
|
|
7979
|
+
css: _ref$8,
|
|
8381
7980
|
children: jsxRuntime.jsx(DraggingCard, {
|
|
8382
7981
|
isDragging: snapshot.isDragging,
|
|
8383
7982
|
children: jsxRuntime.jsxs(uiKit.Grid, {
|
|
@@ -8385,7 +7984,7 @@ const DraggableWrapper = _ref2 => {
|
|
|
8385
7984
|
gridTemplateRows: "auto 1fr auto",
|
|
8386
7985
|
gridGap: snapshot.isDragging ? uiKit.customProperties.spacingS : uiKit.customProperties.spacingM,
|
|
8387
7986
|
children: [jsxRuntime.jsx(uiKit.Grid.Item, {
|
|
8388
|
-
children: jsxRuntime.jsx(DragHandle, _objectSpread$
|
|
7987
|
+
children: jsxRuntime.jsx(DragHandle, _objectSpread$P({}, provided.dragHandleProps))
|
|
8389
7988
|
}), jsxRuntime.jsx(uiKit.Grid.Item, {
|
|
8390
7989
|
children: children
|
|
8391
7990
|
})]
|
|
@@ -8404,8 +8003,8 @@ const DraggableWrapper = _ref2 => {
|
|
|
8404
8003
|
}, draggableKey);
|
|
8405
8004
|
};
|
|
8406
8005
|
|
|
8407
|
-
function ownKeys$
|
|
8408
|
-
function _objectSpread$
|
|
8006
|
+
function ownKeys$O(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; }
|
|
8007
|
+
function _objectSpread$O(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$O(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$O(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
8409
8008
|
const DroppableWrapper = _ref => {
|
|
8410
8009
|
let children = _ref.children,
|
|
8411
8010
|
onDragEnd = _ref.onDragEnd;
|
|
@@ -8413,7 +8012,7 @@ const DroppableWrapper = _ref => {
|
|
|
8413
8012
|
onDragEnd: onDragEnd,
|
|
8414
8013
|
children: jsxRuntime.jsx(dnd.Droppable, {
|
|
8415
8014
|
droppableId: "droppable",
|
|
8416
|
-
children: provided => jsxRuntime.jsxs("div", _objectSpread$
|
|
8015
|
+
children: provided => jsxRuntime.jsxs("div", _objectSpread$O(_objectSpread$O({
|
|
8417
8016
|
ref: provided.innerRef
|
|
8418
8017
|
}, provided.droppableProps), {}, {
|
|
8419
8018
|
children: [children, provided.placeholder]
|
|
@@ -8422,8 +8021,8 @@ const DroppableWrapper = _ref => {
|
|
|
8422
8021
|
});
|
|
8423
8022
|
};
|
|
8424
8023
|
|
|
8425
|
-
function ownKeys$
|
|
8426
|
-
function _objectSpread$
|
|
8024
|
+
function ownKeys$N(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; }
|
|
8025
|
+
function _objectSpread$N(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$N(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$N(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
8427
8026
|
const DefaultWrapper = _ref => {
|
|
8428
8027
|
let children = _ref.children;
|
|
8429
8028
|
return jsxRuntime.jsx(jsxRuntime.Fragment, {
|
|
@@ -8459,7 +8058,7 @@ const DndProvider = _ref2 => {
|
|
|
8459
8058
|
});
|
|
8460
8059
|
}
|
|
8461
8060
|
return jsxRuntime.jsx(DnDContext.Provider, {
|
|
8462
|
-
value: _objectSpread$
|
|
8061
|
+
value: _objectSpread$N(_objectSpread$N({}, dndContextDefaultValues), {}, {
|
|
8463
8062
|
isDnDMode,
|
|
8464
8063
|
setDnDMode
|
|
8465
8064
|
}),
|
|
@@ -8471,8 +8070,8 @@ const useDnDContext = () => {
|
|
|
8471
8070
|
};
|
|
8472
8071
|
|
|
8473
8072
|
const _excluded$9 = ["renderCustomWarnings", "WrapperComponent"];
|
|
8474
|
-
function ownKeys$
|
|
8475
|
-
function _objectSpread$
|
|
8073
|
+
function ownKeys$M(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; }
|
|
8074
|
+
function _objectSpread$M(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$M(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$M(Object(t))).call(_context3, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
8476
8075
|
const ENABLED_FALLBACK_ATTRIBUTE_TYPES = [CUSTOM_FIELD_TYPES.enum, CUSTOM_FIELD_TYPES.lenum, CUSTOM_FIELD_TYPES.number, CUSTOM_FIELD_TYPES.text, CUSTOM_FIELD_TYPES.boolean, CUSTOM_FIELD_TYPES.money, CUSTOM_FIELD_TYPES.datetime, CUSTOM_FIELD_TYPES.date, CUSTOM_FIELD_TYPES.reference, CUSTOM_FIELD_TYPES.time, CUSTOM_FIELD_TYPES.set];
|
|
8477
8076
|
const getFieldName = (parentName, fieldName) => {
|
|
8478
8077
|
if (!parentName) return fieldName;
|
|
@@ -8554,7 +8153,7 @@ const CustomFieldsInternal = _ref => {
|
|
|
8554
8153
|
renderWarnings: props.renderWarnings,
|
|
8555
8154
|
additionalInfo: shouldUseAdditionalInfoProp && props?.additionalInfoHandler ? props.additionalInfoHandler(fieldDefinition, locale, timeZone, userLocale) : undefined
|
|
8556
8155
|
};
|
|
8557
|
-
const Field = jsxRuntime.jsx(FieldComponent, _objectSpread$
|
|
8156
|
+
const Field = jsxRuntime.jsx(FieldComponent, _objectSpread$M({}, fieldProps));
|
|
8558
8157
|
// the several values inside the key are needed to make sure the field is re-rendered when those values change
|
|
8559
8158
|
return jsxRuntime.jsx(formik.FastField, {
|
|
8560
8159
|
name: fieldName,
|
|
@@ -8597,8 +8196,8 @@ const CustomFieldsInternal = _ref => {
|
|
|
8597
8196
|
CustomFieldsInternal.displayName = 'CustomFieldsInternal';
|
|
8598
8197
|
var CustomFieldsInternal$1 = CustomFieldsInternal;
|
|
8599
8198
|
|
|
8600
|
-
function ownKeys$
|
|
8601
|
-
function _objectSpread$
|
|
8199
|
+
function ownKeys$L(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; }
|
|
8200
|
+
function _objectSpread$L(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$L(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$L(Object(t))).call(_context8, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
8602
8201
|
const getTypeName = type => type.name.toLowerCase();
|
|
8603
8202
|
const findLabel = (enumType, key) => {
|
|
8604
8203
|
var _context;
|
|
@@ -8649,7 +8248,7 @@ const attributeDefinitionToFieldDefinition = attributeDefinition => ({
|
|
|
8649
8248
|
const nameValuePairsToMap = pairs => _reduceInstanceProperty__default["default"](pairs).call(pairs, (result, _ref2) => {
|
|
8650
8249
|
let name = _ref2.name,
|
|
8651
8250
|
value = _ref2.value;
|
|
8652
|
-
return _objectSpread$
|
|
8251
|
+
return _objectSpread$L(_objectSpread$L({}, result), {}, {
|
|
8653
8252
|
[name]: value
|
|
8654
8253
|
});
|
|
8655
8254
|
}, {});
|
|
@@ -8767,8 +8366,8 @@ var pickerMessages = reactIntl.defineMessages({
|
|
|
8767
8366
|
}
|
|
8768
8367
|
});
|
|
8769
8368
|
|
|
8770
|
-
function ownKeys$
|
|
8771
|
-
function _objectSpread$
|
|
8369
|
+
function ownKeys$K(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; }
|
|
8370
|
+
function _objectSpread$K(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$K(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$K(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
8772
8371
|
const PRODUCT_SELECTION_MODES = {
|
|
8773
8372
|
INCLUSION: 'Individual',
|
|
8774
8373
|
EXCLUSION: 'IndividualExclusion'
|
|
@@ -8781,7 +8380,7 @@ const getMode = mode => mode === PRODUCT_SELECTION_MODES.INCLUSION || mode === P
|
|
|
8781
8380
|
const addModeToLabel = function (ps) {
|
|
8782
8381
|
let enableExcludingProducts = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
|
|
8783
8382
|
if (!ps) return undefined;
|
|
8784
|
-
return _objectSpread$
|
|
8383
|
+
return _objectSpread$K(_objectSpread$K({}, ps), {}, {
|
|
8785
8384
|
label: `${ps?.label}${enableExcludingProducts ? ` (type: ${getMode(ps?.mode)})` : ''}`
|
|
8786
8385
|
});
|
|
8787
8386
|
};
|
|
@@ -9145,12 +8744,12 @@ function ProductSelectionsSearchSelectDropdown(props) {
|
|
|
9145
8744
|
});
|
|
9146
8745
|
}
|
|
9147
8746
|
|
|
9148
|
-
function ownKeys$
|
|
9149
|
-
function _objectSpread$
|
|
8747
|
+
function ownKeys$J(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; }
|
|
8748
|
+
function _objectSpread$J(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$J(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$J(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
9150
8749
|
function ModeSelectInputOption(props) {
|
|
9151
8750
|
const data = props.data;
|
|
9152
8751
|
const noValueFallback = props.noValueFallback || constants.NO_VALUE_FALLBACK;
|
|
9153
|
-
return jsxRuntime.jsx(uiKit.SelectInput.Option, _objectSpread$
|
|
8752
|
+
return jsxRuntime.jsx(uiKit.SelectInput.Option, _objectSpread$J(_objectSpread$J({}, props), {}, {
|
|
9154
8753
|
children: jsxRuntime.jsxs(uiKit.Spacings.Stack, {
|
|
9155
8754
|
scale: "xs",
|
|
9156
8755
|
children: [jsxRuntime.jsx(uiKit.Text.Detail, {
|
|
@@ -9166,8 +8765,8 @@ function ModeSelectInputOption(props) {
|
|
|
9166
8765
|
}
|
|
9167
8766
|
|
|
9168
8767
|
const _excluded$7 = ["lowerProductSelectionsLimit", "upperProductSelectionsLimit", "renderSelectInputOptionValuesByField", "optionType", "isMulti", "isRequired", "hasWarning", "hasError", "isClearable", "isReadOnly", "isDisabled", "excludedProductSelectionIds", "title"];
|
|
9169
|
-
function ownKeys$
|
|
9170
|
-
function _objectSpread$
|
|
8768
|
+
function ownKeys$I(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; }
|
|
8769
|
+
function _objectSpread$I(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$I(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$I(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
9171
8770
|
function ProductSelectionsPicker(_ref) {
|
|
9172
8771
|
let _ref$lowerProductSele = _ref.lowerProductSelectionsLimit,
|
|
9173
8772
|
lowerProductSelectionsLimit = _ref$lowerProductSele === void 0 ? LOWER_PRODUCT_SELECTIONS_LIMIT : _ref$lowerProductSele,
|
|
@@ -9201,10 +8800,10 @@ function ProductSelectionsPicker(_ref) {
|
|
|
9201
8800
|
return {
|
|
9202
8801
|
Option: optionInnerProps => {
|
|
9203
8802
|
if (optionInnerProps.isDisabled) {
|
|
9204
|
-
return jsxRuntime.jsx(uiKit.SelectInput.Option, _objectSpread$
|
|
8803
|
+
return jsxRuntime.jsx(uiKit.SelectInput.Option, _objectSpread$I({}, optionInnerProps));
|
|
9205
8804
|
}
|
|
9206
8805
|
if (optionType === TYPE_PROPERTY) {
|
|
9207
|
-
return jsxRuntime.jsx(ModeSelectInputOption, _objectSpread$
|
|
8806
|
+
return jsxRuntime.jsx(ModeSelectInputOption, _objectSpread$I({}, optionInnerProps));
|
|
9208
8807
|
}
|
|
9209
8808
|
return jsxRuntime.jsx(selectUtils.CustomSelectInputOption, {
|
|
9210
8809
|
optionType: optionType,
|
|
@@ -9217,7 +8816,7 @@ function ProductSelectionsPicker(_ref) {
|
|
|
9217
8816
|
let CustomProductSelectionsPicker;
|
|
9218
8817
|
if (productSelectionsTotalFetcher.total <= lowerProductSelectionsLimit) CustomProductSelectionsPicker = ProductSelectionBasicSelectDropdown;else if (productSelectionsTotalFetcher.total <= upperProductSelectionsLimit) CustomProductSelectionsPicker = ProductSelectionsAsyncSelectDropdown;else CustomProductSelectionsPicker = ProductSelectionsSearchSelectDropdown;
|
|
9219
8818
|
return jsxRuntime.jsx(uiKit.Spacings.Stack, {
|
|
9220
|
-
children: jsxRuntime.jsx(CustomProductSelectionsPicker, _objectSpread$
|
|
8819
|
+
children: jsxRuntime.jsx(CustomProductSelectionsPicker, _objectSpread$I(_objectSpread$I({
|
|
9221
8820
|
lowerProductSelectionsLimit: lowerProductSelectionsLimit,
|
|
9222
8821
|
upperProductSelectionsLimit: upperProductSelectionsLimit,
|
|
9223
8822
|
renderSelectInputOptionValuesByField: renderSelectInputOptionValuesByField,
|
|
@@ -9260,8 +8859,8 @@ var messages$w = reactIntl.defineMessages({
|
|
|
9260
8859
|
}
|
|
9261
8860
|
});
|
|
9262
8861
|
|
|
9263
|
-
function ownKeys$
|
|
9264
|
-
function _objectSpread$
|
|
8862
|
+
function ownKeys$H(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; }
|
|
8863
|
+
function _objectSpread$H(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$H(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$H(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
9265
8864
|
var FetchRecurrencePolicies = { kind: "Document", definitions: [{ kind: "OperationDefinition", operation: "query", name: { kind: "Name", value: "FetchRecurrencePolicies" }, 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: "limit" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Int" } } }, directives: [] }], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "recurrencePolicies" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "where" }, value: { kind: "Variable", name: { kind: "Name", value: "where" } } }, { kind: "Argument", name: { kind: "Name", value: "limit" }, value: { kind: "Variable", name: { kind: "Name", value: "limit" } } }], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "results" }, arguments: [], 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: 220, source: { body: "query FetchRecurrencePolicies($where: String, $limit: Int!) {\n recurrencePolicies(where: $where, limit: $limit) {\n results {\n id\n key\n nameAllLocales {\n locale\n value\n }\n }\n }\n}\n", name: "GraphQL request", locationOffset: { line: 1, column: 1 } } } };
|
|
9266
8865
|
const useRecurrenceIntervals = _ref => {
|
|
9267
8866
|
let where = _ref.where,
|
|
@@ -9272,7 +8871,7 @@ const useRecurrenceIntervals = _ref => {
|
|
|
9272
8871
|
target: constants.GRAPHQL_TARGETS.COMMERCETOOLS_PLATFORM
|
|
9273
8872
|
},
|
|
9274
8873
|
fetchPolicy: 'cache-and-network',
|
|
9275
|
-
variables: _objectSpread$
|
|
8874
|
+
variables: _objectSpread$H({
|
|
9276
8875
|
limit: 500
|
|
9277
8876
|
}, where && {
|
|
9278
8877
|
where
|
|
@@ -9554,8 +9153,8 @@ const getCustomGroupLabelOption = customLabel => [{
|
|
|
9554
9153
|
}];
|
|
9555
9154
|
|
|
9556
9155
|
const _excluded$6 = ["shouldFetchProductSelections"];
|
|
9557
|
-
function ownKeys$
|
|
9558
|
-
function _objectSpread$
|
|
9156
|
+
function ownKeys$G(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; }
|
|
9157
|
+
function _objectSpread$G(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$G(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$G(Object(t))).call(_context8, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
9559
9158
|
const hasErrors$2 = errors => {
|
|
9560
9159
|
var _context;
|
|
9561
9160
|
return errors && _someInstanceProperty__default["default"](_context = _Object$values__default["default"](errors)).call(_context, Boolean);
|
|
@@ -9643,7 +9242,7 @@ const StoresAsyncSelectInput = _ref2 => {
|
|
|
9643
9242
|
};
|
|
9644
9243
|
if (storesListFetcher.isLoading) return jsxRuntime.jsx(CenteredLoadingSpinner$1, {});
|
|
9645
9244
|
return jsxRuntime.jsxs(jsxRuntime.Fragment, {
|
|
9646
|
-
children: [jsxRuntime.jsx(uiKit.AsyncSelectInput, _objectSpread$
|
|
9245
|
+
children: [jsxRuntime.jsx(uiKit.AsyncSelectInput, _objectSpread$G(_objectSpread$G(_objectSpread$G({
|
|
9647
9246
|
id: props.id,
|
|
9648
9247
|
name: props.name,
|
|
9649
9248
|
placeholder: intl.formatMessage(messages$u.basicSelectInputPlaceholder),
|
|
@@ -9688,8 +9287,8 @@ StoresAsyncSelectInput.displayName = 'StoresAsyncSelectInput';
|
|
|
9688
9287
|
var StoresAsyncSelectInput$1 = StoresAsyncSelectInput;
|
|
9689
9288
|
|
|
9690
9289
|
const _excluded$5 = ["shouldFetchProductSelections"];
|
|
9691
|
-
function ownKeys$
|
|
9692
|
-
function _objectSpread$
|
|
9290
|
+
function ownKeys$F(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; }
|
|
9291
|
+
function _objectSpread$F(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$F(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$F(Object(t))).call(_context4, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
9693
9292
|
const hasErrors$1 = errors => {
|
|
9694
9293
|
var _context;
|
|
9695
9294
|
return errors && _someInstanceProperty__default["default"](_context = _Object$values__default["default"](errors)).call(_context, Boolean);
|
|
@@ -9748,7 +9347,7 @@ const StoresBasicSelectInput = _ref => {
|
|
|
9748
9347
|
};
|
|
9749
9348
|
if (storesListFetcher.isLoading) return jsxRuntime.jsx(CenteredLoadingSpinner$1, {});
|
|
9750
9349
|
return jsxRuntime.jsxs(jsxRuntime.Fragment, {
|
|
9751
|
-
children: [jsxRuntime.jsx(uiKit.SelectInput, _objectSpread$
|
|
9350
|
+
children: [jsxRuntime.jsx(uiKit.SelectInput, _objectSpread$F(_objectSpread$F(_objectSpread$F({
|
|
9752
9351
|
id: props.id,
|
|
9753
9352
|
name: props.name,
|
|
9754
9353
|
placeholder: props.placeholder || intl.formatMessage(messages$u.basicSelectInputPlaceholder),
|
|
@@ -9831,8 +9430,8 @@ const useStoresByFieldFetcher = function (stores, predicateField, projectKey) {
|
|
|
9831
9430
|
var useStoresByFieldFetcher$1 = useStoresByFieldFetcher;
|
|
9832
9431
|
|
|
9833
9432
|
const _excluded$4 = ["shouldFetchProductSelections"];
|
|
9834
|
-
function ownKeys$
|
|
9835
|
-
function _objectSpread$
|
|
9433
|
+
function ownKeys$E(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; }
|
|
9434
|
+
function _objectSpread$E(e) { for (var r = 1; r < arguments.length; r++) { var _context9, _context0; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context9 = ownKeys$E(Object(t), !0)).call(_context9, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context0 = ownKeys$E(Object(t))).call(_context0, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
9836
9435
|
var FetchStoresByWherePredicate = { kind: "Document", definitions: [{ kind: "OperationDefinition", operation: "query", name: { kind: "Name", value: "FetchStoresByWherePredicate" }, variableDefinitions: [{ kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "where" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "String" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "skipFetchingStores" } }, 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", alias: { kind: "Name", value: "storesByWherePredicate" }, 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: "skipFetchingStores" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "results" }, arguments: [], 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: [] }] } }, { 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: "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: 525, source: { body: "query FetchStoresByWherePredicate(\n $where: String!\n $skipFetchingStores: Boolean!\n $excludeProductSelections: Boolean!\n) {\n storesByWherePredicate: stores(where: $where) @skip(if: $skipFetchingStores) {\n results {\n id\n key\n nameAllLocales {\n locale\n value\n }\n productSelections @skip(if: $excludeProductSelections) {\n active\n productSelection {\n id\n nameAllLocales {\n locale\n value\n }\n }\n }\n }\n }\n}\n", name: "GraphQL request", locationOffset: { line: 1, column: 1 } } } }; // check wether there are any errors
|
|
9837
9436
|
const hasErrors = errors => {
|
|
9838
9437
|
var _context;
|
|
@@ -9898,7 +9497,7 @@ const getValueFromOptions = _ref3 => {
|
|
|
9898
9497
|
return selectedOptions[0];
|
|
9899
9498
|
}
|
|
9900
9499
|
};
|
|
9901
|
-
var _ref$
|
|
9500
|
+
var _ref$7 = {
|
|
9902
9501
|
name: "axl87t",
|
|
9903
9502
|
styles: "display:flex;flex-direction:column;justify-content:space-between;&>div:nth-of-type(2){margin-top:25px;}&>div:nth-of-type(1){margin-top:-4px;}"
|
|
9904
9503
|
} ;
|
|
@@ -9950,7 +9549,7 @@ const StoresSearchSelectInput = _ref4 => {
|
|
|
9950
9549
|
return extractMatchedStores;
|
|
9951
9550
|
};
|
|
9952
9551
|
const loadOptionsDebounced = debounce__default["default"](handleLoadOptions, 500);
|
|
9953
|
-
const renderLabelContainerStyles = _ref$
|
|
9552
|
+
const renderLabelContainerStyles = _ref$7;
|
|
9954
9553
|
const customLabelStyles = /*#__PURE__*/react$1.css("&>div{border-bottom:1px solid ", uiKit.designTokens.colorNeutral90, "!important;padding-bottom:4px;}" + ("" ), "" );
|
|
9955
9554
|
const renderNoOptions = _ref6 => {
|
|
9956
9555
|
let inputValue = _ref6.inputValue;
|
|
@@ -9966,7 +9565,7 @@ const StoresSearchSelectInput = _ref4 => {
|
|
|
9966
9565
|
};
|
|
9967
9566
|
if (storesByFieldFetcher.isLoading) return jsxRuntime.jsx(CenteredLoadingSpinner$1, {});
|
|
9968
9567
|
return jsxRuntime.jsxs(jsxRuntime.Fragment, {
|
|
9969
|
-
children: [jsxRuntime.jsx(uiKit.SearchSelectInput, _objectSpread$
|
|
9568
|
+
children: [jsxRuntime.jsx(uiKit.SearchSelectInput, _objectSpread$E(_objectSpread$E({
|
|
9970
9569
|
id: props.id,
|
|
9971
9570
|
name: props.name,
|
|
9972
9571
|
placeholder: intl.formatMessage(messages$u.searchSelectInputPlaceholder),
|
|
@@ -10013,9 +9612,9 @@ StoresSearchSelectInput.displayName = 'StoresSearchSelectInput';
|
|
|
10013
9612
|
var StoresSearchSelectInput$1 = StoresSearchSelectInput;
|
|
10014
9613
|
|
|
10015
9614
|
const _excluded$3 = ["lowerStoresLimit", "upperStoresLimit", "renderSelectInputOptionValuesByField", "optionType", "shouldFetchProductSelections"];
|
|
10016
|
-
function ownKeys$
|
|
10017
|
-
function _objectSpread$
|
|
10018
|
-
var _ref$
|
|
9615
|
+
function ownKeys$D(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; }
|
|
9616
|
+
function _objectSpread$D(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$D(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$D(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
9617
|
+
var _ref$6 = {
|
|
10019
9618
|
name: "1r0yqr6",
|
|
10020
9619
|
styles: "margin-top:10px"
|
|
10021
9620
|
} ;
|
|
@@ -10037,11 +9636,11 @@ const StoreSelectInput = _ref2 => {
|
|
|
10037
9636
|
// eslint-disable-next-line react/display-name
|
|
10038
9637
|
Option: optionInnerProps => {
|
|
10039
9638
|
if (optionInnerProps.isDisabled) {
|
|
10040
|
-
return jsxRuntime.jsx(uiKit.SelectInput.Option, _objectSpread$
|
|
9639
|
+
return jsxRuntime.jsx(uiKit.SelectInput.Option, _objectSpread$D({}, optionInnerProps));
|
|
10041
9640
|
}
|
|
10042
9641
|
const isSearchSelectInput = totalNumberOfStoresFetcher.total > upperStoresLimit;
|
|
10043
9642
|
return jsxRuntime.jsx("div", {
|
|
10044
|
-
css: isSearchSelectInput ? _ref$
|
|
9643
|
+
css: isSearchSelectInput ? _ref$6 : '',
|
|
10045
9644
|
children: jsxRuntime.jsx(selectUtils.CustomSelectInputOption, {
|
|
10046
9645
|
optionType: optionType,
|
|
10047
9646
|
optionInnerProps: optionInnerProps
|
|
@@ -10068,7 +9667,7 @@ const StoreSelectInput = _ref2 => {
|
|
|
10068
9667
|
else {
|
|
10069
9668
|
CustomStoreSelectInput = StoresSearchSelectInput$1;
|
|
10070
9669
|
}
|
|
10071
|
-
return jsxRuntime.jsx(CustomStoreSelectInput, _objectSpread$
|
|
9670
|
+
return jsxRuntime.jsx(CustomStoreSelectInput, _objectSpread$D(_objectSpread$D({
|
|
10072
9671
|
menuIsOpen: props.menuIsOpen,
|
|
10073
9672
|
placeholder: props.placeholder,
|
|
10074
9673
|
iconLeft: props.iconLeft,
|
|
@@ -10108,8 +9707,8 @@ StoreSelectInput.displayName = 'StoreSelectInput';
|
|
|
10108
9707
|
var StoreSelectInput$1 = StoreSelectInput;
|
|
10109
9708
|
|
|
10110
9709
|
const _excluded$2 = ["lowerStoresLimit", "upperStoresLimit", "mappedValueField"];
|
|
10111
|
-
function ownKeys$
|
|
10112
|
-
function _objectSpread$
|
|
9710
|
+
function ownKeys$C(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; }
|
|
9711
|
+
function _objectSpread$C(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$C(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$C(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
10113
9712
|
const StoreSelectField = _ref => {
|
|
10114
9713
|
let _ref$lowerStoresLimit = _ref.lowerStoresLimit,
|
|
10115
9714
|
lowerStoresLimit = _ref$lowerStoresLimit === void 0 ? LOWER_STORES_LIMIT : _ref$lowerStoresLimit,
|
|
@@ -10129,7 +9728,7 @@ const StoreSelectField = _ref => {
|
|
|
10129
9728
|
htmlFor: props.id,
|
|
10130
9729
|
hasRequiredIndicator: props.isRequired,
|
|
10131
9730
|
isBold: true
|
|
10132
|
-
}), jsxRuntime.jsx(StoreSelectInput$1, _objectSpread$
|
|
9731
|
+
}), jsxRuntime.jsx(StoreSelectInput$1, _objectSpread$C(_objectSpread$C({
|
|
10133
9732
|
projectKey: props.projectKey,
|
|
10134
9733
|
id: props.id,
|
|
10135
9734
|
name: props.name,
|
|
@@ -10164,10 +9763,10 @@ const StoreSelectField = _ref => {
|
|
|
10164
9763
|
StoreSelectField.displayName = 'StoreSelectField';
|
|
10165
9764
|
var StoreSelectField$1 = StoreSelectField;
|
|
10166
9765
|
|
|
10167
|
-
function ownKeys$
|
|
10168
|
-
function _objectSpread$
|
|
10169
|
-
function _callSuper$
|
|
10170
|
-
function _isNativeReflectConstruct$
|
|
9766
|
+
function ownKeys$B(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; }
|
|
9767
|
+
function _objectSpread$B(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$B(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$B(Object(t))).call(_context6, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
9768
|
+
function _callSuper$6(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct$6() ? _Reflect$construct__default["default"](o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
|
|
9769
|
+
function _isNativeReflectConstruct$6() { try { var t = !Boolean.prototype.valueOf.call(_Reflect$construct__default["default"](Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct$6 = function () { return !!t; })(); }
|
|
10171
9770
|
const EMAIL_REGEX = /^[-!#$%&'*+/0-9=?A-Z^_a-z`{|}~](\.?[-!#$%&'*+/0-9=?A-Z^_a-z`{|}~])*@[a-zA-Z0-9](-*\.?[a-zA-Z0-9])*\.[a-zA-Z](-?[a-zA-Z0-9])+$/i;
|
|
10172
9771
|
const getIsEvent = event => typeof event === 'object' && !isNil__default["default"](event.target);
|
|
10173
9772
|
const validateRequired = value => {
|
|
@@ -10249,7 +9848,7 @@ ToolTipWrapperComponent.displayName = 'ToolTipWrapperComponent';
|
|
|
10249
9848
|
ToolTipWrapperComponent.propTypes = {
|
|
10250
9849
|
children: PropTypes__default["default"].element
|
|
10251
9850
|
};
|
|
10252
|
-
var _ref$
|
|
9851
|
+
var _ref$5 = {
|
|
10253
9852
|
name: "1u4hpl4",
|
|
10254
9853
|
styles: "display:inline"
|
|
10255
9854
|
} ;
|
|
@@ -10277,7 +9876,7 @@ function validatedInput(InnerComponent, validators) {
|
|
|
10277
9876
|
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
10278
9877
|
args[_key] = arguments[_key];
|
|
10279
9878
|
}
|
|
10280
|
-
_this = _callSuper$
|
|
9879
|
+
_this = _callSuper$6(this, ValidatedInput, [...args]);
|
|
10281
9880
|
_this.state = {
|
|
10282
9881
|
validStatus: _initialValidState
|
|
10283
9882
|
};
|
|
@@ -10309,7 +9908,7 @@ function validatedInput(InnerComponent, validators) {
|
|
|
10309
9908
|
* so it must be an invalid numeric value
|
|
10310
9909
|
*/
|
|
10311
9910
|
_this.handleInvalid = () => {
|
|
10312
|
-
const nextValidStatus = _objectSpread$
|
|
9911
|
+
const nextValidStatus = _objectSpread$B({}, _this.state.validStatus);
|
|
10313
9912
|
if (has__default["default"](nextValidStatus, 'numeric')) {
|
|
10314
9913
|
nextValidStatus.numeric = false;
|
|
10315
9914
|
_this.conditionalSetValidStatus(nextValidStatus);
|
|
@@ -10360,7 +9959,7 @@ function validatedInput(InnerComponent, validators) {
|
|
|
10360
9959
|
if (prev) return this.state.validStatus[v.name];
|
|
10361
9960
|
return prev;
|
|
10362
9961
|
}, true);
|
|
10363
|
-
const componentProps = _objectSpread$
|
|
9962
|
+
const componentProps = _objectSpread$B(_objectSpread$B({}, this.props), {}, {
|
|
10364
9963
|
[blurHandler || 'onBlurValue']: this.handleBlur,
|
|
10365
9964
|
[changeHandler || 'onChange']: this.handleChange,
|
|
10366
9965
|
onInvalidValue: this.handleInvalid,
|
|
@@ -10370,7 +9969,7 @@ function validatedInput(InnerComponent, validators) {
|
|
|
10370
9969
|
const firstFailedValidator = _findInstanceProperty__default["default"](_validators).call(_validators, v => !this.state.validStatus[v.name]);
|
|
10371
9970
|
return jsxRuntime.jsx("div", {
|
|
10372
9971
|
className: classnames__default["default"](containerClassName),
|
|
10373
|
-
css: _ref$
|
|
9972
|
+
css: _ref$5,
|
|
10374
9973
|
children: jsxRuntime.jsx(uiKit.Tooltip, {
|
|
10375
9974
|
placement: "top",
|
|
10376
9975
|
title: firstFailedValidator && this.props.intl.formatMessage(firstFailedValidator.message) || '',
|
|
@@ -10378,7 +9977,7 @@ function validatedInput(InnerComponent, validators) {
|
|
|
10378
9977
|
components: {
|
|
10379
9978
|
WrapperComponent: ToolTipWrapperComponent
|
|
10380
9979
|
},
|
|
10381
|
-
children: jsxRuntime.jsx(_InnerComponent, _objectSpread$
|
|
9980
|
+
children: jsxRuntime.jsx(_InnerComponent, _objectSpread$B({}, componentProps))
|
|
10382
9981
|
})
|
|
10383
9982
|
});
|
|
10384
9983
|
}
|
|
@@ -10400,7 +9999,7 @@ function simpleInput(type) {
|
|
|
10400
9999
|
for (var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
|
|
10401
10000
|
args[_key2] = arguments[_key2];
|
|
10402
10001
|
}
|
|
10403
|
-
_this2 = _callSuper$
|
|
10002
|
+
_this2 = _callSuper$6(this, _Class, [...args]);
|
|
10404
10003
|
_this2.handleBlur = event => {
|
|
10405
10004
|
if (_this2.props.onBlurValue) _this2.props.onBlurValue(event.target.value);
|
|
10406
10005
|
};
|
|
@@ -10429,10 +10028,10 @@ function simpleInput(type) {
|
|
|
10429
10028
|
}, _Class;
|
|
10430
10029
|
}
|
|
10431
10030
|
|
|
10432
|
-
function ownKeys$
|
|
10433
|
-
function _objectSpread$
|
|
10434
|
-
function _callSuper$
|
|
10435
|
-
function _isNativeReflectConstruct$
|
|
10031
|
+
function ownKeys$A(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; }
|
|
10032
|
+
function _objectSpread$A(e) { for (var r = 1; r < arguments.length; r++) { var _context4, _context5; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context4 = ownKeys$A(Object(t), !0)).call(_context4, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context5 = ownKeys$A(Object(t))).call(_context5, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
10033
|
+
function _callSuper$5(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct$5() ? _Reflect$construct__default["default"](o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
|
|
10034
|
+
function _isNativeReflectConstruct$5() { try { var t = !Boolean.prototype.valueOf.call(_Reflect$construct__default["default"](Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct$5 = function () { return !!t; })(); }
|
|
10436
10035
|
var FetchTypeDefinitionsQuery = { kind: "Document", definitions: [{ kind: "OperationDefinition", operation: "query", name: { kind: "Name", value: "FetchTypeDefinitionsQuery" }, 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: "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: [] }], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "typeDefinitions" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "where" }, value: { kind: "Variable", name: { kind: "Name", value: "where" } } }, { 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" } } }], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "results" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "fieldDefinitions" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "type" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "name" }, arguments: [], directives: [] }, { kind: "InlineFragment", typeCondition: { kind: "NamedType", name: { kind: "Name", value: "SetType" } }, directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "elementType" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "name" }, arguments: [], directives: [] }, { kind: "InlineFragment", typeCondition: { kind: "NamedType", name: { kind: "Name", value: "EnumType" } }, directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "values" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "key" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "label" }, arguments: [], directives: [] }] } }] } }, { kind: "InlineFragment", typeCondition: { kind: "NamedType", name: { kind: "Name", value: "LocalizedEnumType" } }, directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "values" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "key" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "labelAllLocales" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "value" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "locale" }, arguments: [], directives: [] }] } }] } }] } }] } }] } }, { kind: "InlineFragment", typeCondition: { kind: "NamedType", name: { kind: "Name", value: "EnumType" } }, directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "values" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "key" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "label" }, arguments: [], directives: [] }] } }] } }, { kind: "InlineFragment", typeCondition: { kind: "NamedType", name: { kind: "Name", value: "LocalizedEnumType" } }, directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "values" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "key" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "labelAllLocales" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "value" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "locale" }, arguments: [], directives: [] }] } }] } }] } }, { kind: "InlineFragment", typeCondition: { kind: "NamedType", name: { kind: "Name", value: "ReferenceType" } }, directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "referenceTypeId" }, arguments: [], directives: [] }] } }] } }, { kind: "Field", name: { kind: "Name", value: "name" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "labelAllLocales" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "value" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "locale" }, arguments: [], directives: [] }] } }] } }] } }] } }] } }], loc: { start: 0, end: 1172, source: { body: "query FetchTypeDefinitionsQuery($where: String, $limit: Int, $offset: Int) {\n typeDefinitions(where: $where, limit: $limit, offset: $offset) {\n results {\n fieldDefinitions {\n type {\n name\n ... on SetType {\n elementType {\n name\n ... on EnumType {\n values {\n key\n label\n }\n }\n ... on LocalizedEnumType {\n values {\n key\n labelAllLocales {\n value\n locale\n }\n }\n }\n }\n }\n ... on EnumType {\n values {\n key\n label\n }\n }\n ... on LocalizedEnumType {\n values {\n key\n labelAllLocales {\n value\n locale\n }\n }\n }\n ... on ReferenceType {\n referenceTypeId\n }\n }\n name\n labelAllLocales {\n value\n locale\n }\n }\n }\n }\n}\n", name: "GraphQL request", locationOffset: { line: 1, column: 1 } } } };
|
|
10437
10036
|
const customizableResources$1 = ['asset', 'category', 'channel', 'customer', 'order', 'discount-code', 'cart-discount', 'inventory-entry', 'line-item', 'custom-line-item', 'product-price', 'payment', 'payment-interface-interaction', 'transaction',
|
|
10438
10037
|
// transactions on payment entity
|
|
@@ -10440,7 +10039,7 @@ const customizableResources$1 = ['asset', 'category', 'channel', 'customer', 'or
|
|
|
10440
10039
|
let CustomFieldDefinitionsConnector = /*#__PURE__*/function (_Component) {
|
|
10441
10040
|
function CustomFieldDefinitionsConnector() {
|
|
10442
10041
|
_classCallCheck(this, CustomFieldDefinitionsConnector);
|
|
10443
|
-
return _callSuper$
|
|
10042
|
+
return _callSuper$5(this, CustomFieldDefinitionsConnector, arguments);
|
|
10444
10043
|
}
|
|
10445
10044
|
_inherits(CustomFieldDefinitionsConnector, _Component);
|
|
10446
10045
|
return _createClass(CustomFieldDefinitionsConnector, [{
|
|
@@ -10490,7 +10089,7 @@ const mapDataToProps = _ref => {
|
|
|
10490
10089
|
return {
|
|
10491
10090
|
fetchTypeDefinitionsQuery: {
|
|
10492
10091
|
loading: fetchTypeDefinitionsQuery.loading,
|
|
10493
|
-
customFieldDefinitions: uniqBy__default["default"](_mapInstanceProperty__default["default"](fieldDefinitionsToOptionsMap).call(fieldDefinitionsToOptionsMap, fieldDefinition => _objectSpread$
|
|
10092
|
+
customFieldDefinitions: uniqBy__default["default"](_mapInstanceProperty__default["default"](fieldDefinitionsToOptionsMap).call(fieldDefinitionsToOptionsMap, fieldDefinition => _objectSpread$A({}, l10n.applyTransformedLocalizedFields(omitDeep(fieldDefinition, ['__typename'], {
|
|
10494
10093
|
isImmutable: true
|
|
10495
10094
|
}), [{
|
|
10496
10095
|
from: 'labelAllLocales',
|
|
@@ -10510,12 +10109,12 @@ var customFieldDefinitionsConnector = flowRight__default["default"](hoc.graphql(
|
|
|
10510
10109
|
props: mapDataToProps
|
|
10511
10110
|
}))(CustomFieldDefinitionsConnector);
|
|
10512
10111
|
|
|
10513
|
-
function ownKeys$
|
|
10514
|
-
function _objectSpread$
|
|
10112
|
+
function ownKeys$z(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; }
|
|
10113
|
+
function _objectSpread$z(e) { for (var r = 1; r < arguments.length; r++) { var _context4, _context5; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context4 = ownKeys$z(Object(t), !0)).call(_context4, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context5 = ownKeys$z(Object(t))).call(_context5, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
10515
10114
|
const restDocToForm = customFieldsFromRestResponse => {
|
|
10516
10115
|
return {
|
|
10517
10116
|
fields: customFieldsFromRestResponse.fields,
|
|
10518
|
-
type: _objectSpread$
|
|
10117
|
+
type: _objectSpread$z({
|
|
10519
10118
|
id: customFieldsFromRestResponse.type.id
|
|
10520
10119
|
}, customFieldsFromRestResponse.type.obj)
|
|
10521
10120
|
};
|
|
@@ -10534,14 +10133,14 @@ const graphQlDocToForm = typeDefinition => {
|
|
|
10534
10133
|
name: fieldDefinition.name,
|
|
10535
10134
|
required: fieldDefinition.required,
|
|
10536
10135
|
inputHint: fieldDefinition.inputHint,
|
|
10537
|
-
type: fieldDefinition.type?.elementType?.name === 'LocalizedEnum' ? _objectSpread$
|
|
10538
|
-
elementType: _objectSpread$
|
|
10136
|
+
type: fieldDefinition.type?.elementType?.name === 'LocalizedEnum' ? _objectSpread$z(_objectSpread$z({}, fieldDefinition.type), {}, {
|
|
10137
|
+
elementType: _objectSpread$z(_objectSpread$z({}, fieldDefinition.type.elementType), {}, {
|
|
10539
10138
|
values: _mapInstanceProperty__default["default"](_context2 = _valuesInstanceProperty__default["default"](fieldDefinition.type.elementType)).call(_context2, value => ({
|
|
10540
10139
|
key: value.key,
|
|
10541
10140
|
label: l10n.transformLocalizedFieldToLocalizedString(value.labelAllLocales)
|
|
10542
10141
|
}))
|
|
10543
10142
|
})
|
|
10544
|
-
}) : fieldDefinition.type?.name === 'LocalizedEnum' ? _objectSpread$
|
|
10143
|
+
}) : fieldDefinition.type?.name === 'LocalizedEnum' ? _objectSpread$z(_objectSpread$z({}, fieldDefinition.type), {}, {
|
|
10545
10144
|
values: _mapInstanceProperty__default["default"](_context3 = _valuesInstanceProperty__default["default"](fieldDefinition.type)).call(_context3, value => ({
|
|
10546
10145
|
key: value.key,
|
|
10547
10146
|
label: l10n.transformLocalizedFieldToLocalizedString(value.labelAllLocales)
|
|
@@ -10557,7 +10156,7 @@ const formToRestDoc = formCustomFields => ({
|
|
|
10557
10156
|
type: {
|
|
10558
10157
|
id: formCustomFields.type.id,
|
|
10559
10158
|
typeId: 'type',
|
|
10560
|
-
obj: _objectSpread$
|
|
10159
|
+
obj: _objectSpread$z({}, formCustomFields.type)
|
|
10561
10160
|
},
|
|
10562
10161
|
fields: formCustomFields.fields
|
|
10563
10162
|
});
|
|
@@ -10565,7 +10164,7 @@ const formToGraphQlDoc = formCustomFields => ({
|
|
|
10565
10164
|
type: {
|
|
10566
10165
|
id: formCustomFields.type.id,
|
|
10567
10166
|
typeId: 'type',
|
|
10568
|
-
obj: _objectSpread$
|
|
10167
|
+
obj: _objectSpread$z({}, omit__default["default"](formCustomFields.type, ['id']))
|
|
10569
10168
|
},
|
|
10570
10169
|
fields: omitBy__default["default"](formCustomFields.fields || {}, isNil__default["default"])
|
|
10571
10170
|
});
|
|
@@ -10578,8 +10177,8 @@ const createEmptyCustomFields = typeDefinition => ({
|
|
|
10578
10177
|
}
|
|
10579
10178
|
});
|
|
10580
10179
|
|
|
10581
|
-
function _callSuper$
|
|
10582
|
-
function _isNativeReflectConstruct$
|
|
10180
|
+
function _callSuper$4(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct$4() ? _Reflect$construct__default["default"](o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
|
|
10181
|
+
function _isNativeReflectConstruct$4() { try { var t = !Boolean.prototype.valueOf.call(_Reflect$construct__default["default"](Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct$4 = function () { return !!t; })(); }
|
|
10583
10182
|
var FetchTypeDefinitionsWithNamesQuery = { kind: "Document", definitions: [{ kind: "OperationDefinition", operation: "query", name: { kind: "Name", value: "FetchTypeDefinitionsWithNamesQuery" }, 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: "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: [] }], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "typeDefinitions" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "where" }, value: { kind: "Variable", name: { kind: "Name", value: "where" } } }, { 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" } } }], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "results" }, arguments: [], 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: "value" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "locale" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "fieldDefinitions" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "required" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "type" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "name" }, arguments: [], directives: [] }, { kind: "InlineFragment", typeCondition: { kind: "NamedType", name: { kind: "Name", value: "ReferenceType" } }, directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "referenceTypeId" }, arguments: [], directives: [] }] } }, { kind: "InlineFragment", typeCondition: { kind: "NamedType", name: { kind: "Name", value: "SetType" } }, directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "elementType" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "name" }, arguments: [], directives: [] }, { kind: "InlineFragment", typeCondition: { kind: "NamedType", name: { kind: "Name", value: "ReferenceType" } }, directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "referenceTypeId" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "name" }, arguments: [], directives: [] }] } }, { kind: "InlineFragment", typeCondition: { kind: "NamedType", name: { kind: "Name", value: "EnumType" } }, directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "values" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "key" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "label" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "name" }, arguments: [], directives: [] }] } }, { kind: "InlineFragment", typeCondition: { kind: "NamedType", name: { kind: "Name", value: "LocalizedEnumType" } }, directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "values" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "key" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "labelAllLocales" }, 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: "InlineFragment", typeCondition: { kind: "NamedType", name: { kind: "Name", value: "LocalizedEnumType" } }, directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "values" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "key" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "labelAllLocales" }, 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: "InlineFragment", typeCondition: { kind: "NamedType", name: { kind: "Name", value: "EnumType" } }, directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "values" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "key" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "label" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "name" }, arguments: [], directives: [] }] } }] } }, { kind: "Field", name: { kind: "Name", value: "name" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "labelAllLocales" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "value" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "locale" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "inputHint" }, arguments: [], directives: [] }] } }] } }] } }] } }], loc: { start: 0, end: 1445, source: { body: "query FetchTypeDefinitionsWithNamesQuery(\n $where: String\n $limit: Int\n $offset: Int\n) {\n typeDefinitions(where: $where, limit: $limit, offset: $offset) {\n results {\n id\n key\n nameAllLocales {\n value\n locale\n }\n fieldDefinitions {\n required\n type {\n name\n ... on ReferenceType {\n referenceTypeId\n }\n ... on SetType {\n elementType {\n name\n ... on ReferenceType {\n referenceTypeId\n name\n }\n ... on EnumType {\n values {\n key\n label\n }\n name\n }\n ... on LocalizedEnumType {\n values {\n key\n labelAllLocales {\n locale\n value\n }\n }\n }\n }\n }\n ... on LocalizedEnumType {\n values {\n key\n labelAllLocales {\n locale\n value\n }\n }\n }\n ... on EnumType {\n values {\n key\n label\n }\n name\n }\n }\n name\n labelAllLocales {\n value\n locale\n }\n inputHint\n }\n }\n }\n}\n", name: "GraphQL request", locationOffset: { line: 1, column: 1 } } } };
|
|
10584
10183
|
const customizableResources = ['asset', 'address', 'associate-role', 'business-unit', 'category', 'channel', 'customer', 'customer-group', 'order', 'quote', 'order-delivery', 'store', 'discount-code', 'inventory-entry', 'line-item', 'custom-line-item', 'product-price', 'payment', 'payment-interface-interaction', 'shipping-method', 'shopping-list', 'shopping-list-text-line-item', 'standalone-price', 'review', 'cart-discount', 'product-selection', 'order-return-item', 'order-parcel', 'transaction', 'recurring-order'];
|
|
10585
10184
|
const emptyTypeDefinitions = {
|
|
@@ -10590,7 +10189,7 @@ const emptyTypeDefinitions = {
|
|
|
10590
10189
|
let CustomFieldTypeDefinitionsConnector = /*#__PURE__*/function (_Component) {
|
|
10591
10190
|
function CustomFieldTypeDefinitionsConnector() {
|
|
10592
10191
|
_classCallCheck(this, CustomFieldTypeDefinitionsConnector);
|
|
10593
|
-
return _callSuper$
|
|
10192
|
+
return _callSuper$4(this, CustomFieldTypeDefinitionsConnector, arguments);
|
|
10594
10193
|
}
|
|
10595
10194
|
_inherits(CustomFieldTypeDefinitionsConnector, _Component);
|
|
10596
10195
|
return _createClass(CustomFieldTypeDefinitionsConnector, [{
|
|
@@ -10668,8 +10267,8 @@ const CustomFields = props => {
|
|
|
10668
10267
|
CustomFields.displayName = 'CustomFields';
|
|
10669
10268
|
var CustomFields$1 = CustomFields;
|
|
10670
10269
|
|
|
10671
|
-
function ownKeys$
|
|
10672
|
-
function _objectSpread$
|
|
10270
|
+
function ownKeys$y(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; }
|
|
10271
|
+
function _objectSpread$y(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$y(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$y(Object(t))).call(_context4, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
10673
10272
|
const extractDuplicatedValues = (values, type, language, languages) => {
|
|
10674
10273
|
let validatedValues = [];
|
|
10675
10274
|
if (type.name.toLowerCase() === 'money') {
|
|
@@ -10736,8 +10335,8 @@ function validations (formValues, language, languages) {
|
|
|
10736
10335
|
var _context2;
|
|
10737
10336
|
// Collect all required and set type fields
|
|
10738
10337
|
const fieldDefinitionsToValidate = _filterInstanceProperty__default["default"](_context2 = formValues.custom.type.fieldDefinitions).call(_context2, fieldDefinition => fieldDefinition.required || fieldDefinition.type.name.toLowerCase() === 'set');
|
|
10739
|
-
const errors = _reduceInstanceProperty__default["default"](fieldDefinitionsToValidate).call(fieldDefinitionsToValidate, (acc, fieldDefinition) => _objectSpread$
|
|
10740
|
-
[fieldDefinition.name]: _objectSpread$
|
|
10338
|
+
const errors = _reduceInstanceProperty__default["default"](fieldDefinitionsToValidate).call(fieldDefinitionsToValidate, (acc, fieldDefinition) => _objectSpread$y(_objectSpread$y({}, acc), {}, {
|
|
10339
|
+
[fieldDefinition.name]: _objectSpread$y(_objectSpread$y({}, setMissingIfRequired(formValues, fieldDefinition)), setDuplicatedIfSet(formValues, fieldDefinition, language, languages))
|
|
10741
10340
|
}), {});
|
|
10742
10341
|
return withoutEmptyErrorsByField$1(errors);
|
|
10743
10342
|
}
|
|
@@ -10752,14 +10351,14 @@ var messages$t = reactIntl.defineMessages({
|
|
|
10752
10351
|
}
|
|
10753
10352
|
});
|
|
10754
10353
|
|
|
10755
|
-
function ownKeys$
|
|
10756
|
-
function _objectSpread$
|
|
10354
|
+
function ownKeys$x(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; }
|
|
10355
|
+
function _objectSpread$x(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$x(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$x(Object(t))).call(_context3, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
10757
10356
|
const CustomFieldsErrorTextNotification = props => {
|
|
10758
10357
|
var _context;
|
|
10759
10358
|
return jsxRuntime.jsxs(uiKit.Spacings.Stack, {
|
|
10760
10359
|
scale: "s",
|
|
10761
10360
|
children: [jsxRuntime.jsx(uiKit.Text.Wrap, {
|
|
10762
|
-
intlMessage: _objectSpread$
|
|
10361
|
+
intlMessage: _objectSpread$x({}, messages$t.customFieldsError)
|
|
10763
10362
|
}), jsxRuntime.jsx(uiKit.Spacings.Stack, {
|
|
10764
10363
|
scale: "xs",
|
|
10765
10364
|
children: _mapInstanceProperty__default["default"](_context = props.formErrors).call(_context, formError => jsxRuntime.jsx(uiKit.Text.Detail, {
|
|
@@ -10812,13 +10411,13 @@ var messages$s = reactIntl.defineMessages({
|
|
|
10812
10411
|
|
|
10813
10412
|
const FIELD_NAME = 'custom';
|
|
10814
10413
|
|
|
10815
|
-
function ownKeys$
|
|
10816
|
-
function _objectSpread$
|
|
10414
|
+
function ownKeys$w(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; }
|
|
10415
|
+
function _objectSpread$w(e) { for (var r = 1; r < arguments.length; r++) { var _context6, _context7; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context6 = ownKeys$w(Object(t), !0)).call(_context6, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context7 = ownKeys$w(Object(t))).call(_context7, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
10817
10416
|
const transformFieldType = fieldDefinition => {
|
|
10818
10417
|
if (fieldDefinition.type?.elementType?.name === 'LocalizedEnum') {
|
|
10819
10418
|
var _context;
|
|
10820
|
-
return _objectSpread$
|
|
10821
|
-
elementType: _objectSpread$
|
|
10419
|
+
return _objectSpread$w(_objectSpread$w({}, fieldDefinition.type), {}, {
|
|
10420
|
+
elementType: _objectSpread$w(_objectSpread$w({}, fieldDefinition.type.elementType), {}, {
|
|
10822
10421
|
values: _mapInstanceProperty__default["default"](_context = _valuesInstanceProperty__default["default"](fieldDefinition.type.elementType)).call(_context, value => ({
|
|
10823
10422
|
key: value.key,
|
|
10824
10423
|
label: l10n.transformLocalizedFieldToLocalizedString(value.labelAllLocales)
|
|
@@ -10827,7 +10426,7 @@ const transformFieldType = fieldDefinition => {
|
|
|
10827
10426
|
});
|
|
10828
10427
|
} else if (fieldDefinition.type?.name === 'LocalizedEnum') {
|
|
10829
10428
|
var _context2;
|
|
10830
|
-
return _objectSpread$
|
|
10429
|
+
return _objectSpread$w(_objectSpread$w({}, fieldDefinition.type), {}, {
|
|
10831
10430
|
values: _mapInstanceProperty__default["default"](_context2 = _valuesInstanceProperty__default["default"](fieldDefinition.type)).call(_context2, value => ({
|
|
10832
10431
|
key: value.key,
|
|
10833
10432
|
label: l10n.transformLocalizedFieldToLocalizedString(value.labelAllLocales)
|
|
@@ -10855,7 +10454,7 @@ const convertCustomField = resource => {
|
|
|
10855
10454
|
}))
|
|
10856
10455
|
}
|
|
10857
10456
|
},
|
|
10858
|
-
fields: _reduceInstanceProperty__default["default"](_context4 = resource.custom.customFieldsRaw).call(_context4, (fields, customField) => _objectSpread$
|
|
10457
|
+
fields: _reduceInstanceProperty__default["default"](_context4 = resource.custom.customFieldsRaw).call(_context4, (fields, customField) => _objectSpread$w(_objectSpread$w({}, fields), {}, {
|
|
10859
10458
|
[customField.name]: customField.value
|
|
10860
10459
|
}), {})
|
|
10861
10460
|
};
|
|
@@ -10903,8 +10502,8 @@ const createRootFieldName = rootFieldName => {
|
|
|
10903
10502
|
return rootFieldName ? `${rootFieldName}.${FIELD_NAME}` : FIELD_NAME;
|
|
10904
10503
|
};
|
|
10905
10504
|
|
|
10906
|
-
function ownKeys$
|
|
10907
|
-
function _objectSpread$
|
|
10505
|
+
function ownKeys$v(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; }
|
|
10506
|
+
function _objectSpread$v(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$v(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$v(Object(t))).call(_context3, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
10908
10507
|
const typeDefinitionsExist = typeDefinitions => {
|
|
10909
10508
|
return typeDefinitions.length > 0;
|
|
10910
10509
|
};
|
|
@@ -10931,19 +10530,19 @@ const CustomFieldsInputWrapper = _ref2 => {
|
|
|
10931
10530
|
formValues = _valuesInstanceProperty__default["default"](_useFormikContext);
|
|
10932
10531
|
const rootFieldName = createRootFieldName(rootFormStateFieldName);
|
|
10933
10532
|
if (!typeDefinitionsExist(typeDefinitions)) {
|
|
10934
|
-
return jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$
|
|
10533
|
+
return jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$v({}, messages$s.noTypes));
|
|
10935
10534
|
}
|
|
10936
10535
|
if (!typeDefinitionSelected(formValues, rootFieldName) && isReadOnly) {
|
|
10937
|
-
return jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$
|
|
10536
|
+
return jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$v({}, messages$s.noCustomTypeReadOnly));
|
|
10938
10537
|
}
|
|
10939
10538
|
if (!typeDefinitionSelected(formValues, rootFieldName)) {
|
|
10940
|
-
return jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$
|
|
10539
|
+
return jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$v({}, messages$s.noCustomType));
|
|
10941
10540
|
}
|
|
10942
10541
|
if (!typeDefinitionContainsFieldDefinitions(formValues, rootFieldName)) {
|
|
10943
|
-
return jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$
|
|
10542
|
+
return jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$v({}, messages$s.noCustomFields));
|
|
10944
10543
|
}
|
|
10945
10544
|
if (fieldDefinitionsWithValues(formValues, rootFieldName).length === 0 && isReadOnly && hideEmptyFields) {
|
|
10946
|
-
return jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$
|
|
10545
|
+
return jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$v({}, messages$s.noInputValues));
|
|
10947
10546
|
}
|
|
10948
10547
|
return jsxRuntime.jsx(uiKit.Constraints.Horizontal, {
|
|
10949
10548
|
max: "scale",
|
|
@@ -10957,8 +10556,8 @@ const CustomFieldsInputWrapper = _ref2 => {
|
|
|
10957
10556
|
CustomFieldsInputWrapper.displayName = 'CustomFieldsInputWrapper';
|
|
10958
10557
|
var CustomFieldsInputWrapper$1 = CustomFieldsInputWrapper;
|
|
10959
10558
|
|
|
10960
|
-
function ownKeys$
|
|
10961
|
-
function _objectSpread$
|
|
10559
|
+
function ownKeys$u(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; }
|
|
10560
|
+
function _objectSpread$u(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$u(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$u(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
10962
10561
|
const mapTypeDefinitionsToOptions = (typeDefinitions, language, languages, selectedTypeDefinitionId) => {
|
|
10963
10562
|
return _mapInstanceProperty__default["default"](typeDefinitions).call(typeDefinitions, typeDefinition => ({
|
|
10964
10563
|
isDisabled: selectedTypeDefinitionId && selectedTypeDefinitionId === typeDefinition.type.id,
|
|
@@ -10992,7 +10591,9 @@ const CustomTypeSubform = _ref => {
|
|
|
10992
10591
|
isCondensed = _ref.isCondensed,
|
|
10993
10592
|
hideEmptyFields = _ref.hideEmptyFields,
|
|
10994
10593
|
rootFormStateFieldName = _ref.rootFormStateFieldName,
|
|
10995
|
-
panelTitle = _ref.panelTitle
|
|
10594
|
+
panelTitle = _ref.panelTitle,
|
|
10595
|
+
_ref$leftAlignDropdow = _ref.leftAlignDropdown,
|
|
10596
|
+
leftAlignDropdown = _ref$leftAlignDropdow === void 0 ? false : _ref$leftAlignDropdow;
|
|
10996
10597
|
const _useFormikContext = formik.useFormikContext(),
|
|
10997
10598
|
formValues = _valuesInstanceProperty__default["default"](_useFormikContext),
|
|
10998
10599
|
setFieldValue = _useFormikContext.setFieldValue,
|
|
@@ -11045,7 +10646,7 @@ const CustomTypeSubform = _ref => {
|
|
|
11045
10646
|
return jsxRuntime.jsx(uiKit.CollapsiblePanel, {
|
|
11046
10647
|
header: jsxRuntime.jsx(uiKit.CollapsiblePanel.Header, {
|
|
11047
10648
|
isCondensed: isCondensed,
|
|
11048
|
-
children: panelTitle || jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$
|
|
10649
|
+
children: panelTitle || jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$u({}, messages$s.title))
|
|
11049
10650
|
}),
|
|
11050
10651
|
headerControls: typeDefinitions.length > 0 && jsxRuntime.jsx("div", {
|
|
11051
10652
|
css: /*#__PURE__*/react$1.css("min-width:", uiKit.designTokens.constraint11, ";" + ("" ), "" ),
|
|
@@ -11060,7 +10661,7 @@ const CustomTypeSubform = _ref => {
|
|
|
11060
10661
|
isReadOnly: isReadOnly
|
|
11061
10662
|
})
|
|
11062
10663
|
}),
|
|
11063
|
-
headerControlsAlignment:
|
|
10664
|
+
headerControlsAlignment: leftAlignDropdown ? 'left' : 'right',
|
|
11064
10665
|
children: jsxRuntime.jsx(CustomFieldsInputWrapper$1, {
|
|
11065
10666
|
typeDefinitions: typeDefinitions,
|
|
11066
10667
|
isReadOnly: isReadOnly,
|
|
@@ -11078,7 +10679,8 @@ const CustomFieldsFormField = _ref => {
|
|
|
11078
10679
|
isCondensed = _ref.isCondensed,
|
|
11079
10680
|
hideEmptyFields = _ref.hideEmptyFields,
|
|
11080
10681
|
rootFormStateFieldName = _ref.rootFormStateFieldName,
|
|
11081
|
-
panelTitle = _ref.panelTitle
|
|
10682
|
+
panelTitle = _ref.panelTitle,
|
|
10683
|
+
leftAlignDropdown = _ref.leftAlignDropdown;
|
|
11082
10684
|
const projectKey = applicationShellConnectors.useApplicationContext(applicationContext => applicationContext.project.key);
|
|
11083
10685
|
return jsxRuntime.jsx(CustomFieldTypeDefinitionsConnector$1, {
|
|
11084
10686
|
resources: resources,
|
|
@@ -11098,7 +10700,8 @@ const CustomFieldsFormField = _ref => {
|
|
|
11098
10700
|
isCondensed: isCondensed,
|
|
11099
10701
|
hideEmptyFields: hideEmptyFields,
|
|
11100
10702
|
rootFormStateFieldName: rootFormStateFieldName,
|
|
11101
|
-
panelTitle: panelTitle
|
|
10703
|
+
panelTitle: panelTitle,
|
|
10704
|
+
leftAlignDropdown: leftAlignDropdown
|
|
11102
10705
|
});
|
|
11103
10706
|
}
|
|
11104
10707
|
});
|
|
@@ -11193,10 +10796,10 @@ var messages$r = reactIntl.defineMessages({
|
|
|
11193
10796
|
}
|
|
11194
10797
|
});
|
|
11195
10798
|
|
|
11196
|
-
function ownKeys$
|
|
11197
|
-
function _objectSpread$
|
|
11198
|
-
function _callSuper$
|
|
11199
|
-
function _isNativeReflectConstruct$
|
|
10799
|
+
function ownKeys$t(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; }
|
|
10800
|
+
function _objectSpread$t(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$t(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$t(Object(t))).call(_context3, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
10801
|
+
function _callSuper$3(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct$3() ? _Reflect$construct__default["default"](o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
|
|
10802
|
+
function _isNativeReflectConstruct$3() { try { var t = !Boolean.prototype.valueOf.call(_Reflect$construct__default["default"](Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct$3 = function () { return !!t; })(); }
|
|
11200
10803
|
var RefreshProductIndices = { kind: "Document", definitions: [{ kind: "OperationDefinition", operation: "mutation", name: { kind: "Name", value: "RefreshProductIndices" }, variableDefinitions: [{ kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "ids" } }, type: { kind: "NonNullType", type: { kind: "ListType", type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "String" } } } } }, directives: [] }], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "refreshProducts" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "ids" }, value: { kind: "Variable", name: { kind: "Name", value: "ids" } } }], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "updatedDocuments" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "id" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "version" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "deletedDocuments" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "id" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "notFoundDocuments" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "id" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "unchangedDocuments" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "id" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "version" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "failedRefreshedDocuments" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "id" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "reason" }, arguments: [], directives: [] }] } }] } }] } }], loc: { start: 0, end: 1549, source: { body: "mutation RefreshProductIndices($ids: [String!]!) {\n refreshProducts(ids: $ids) {\n updatedDocuments {\n id\n version\n }\n deletedDocuments {\n id\n }\n notFoundDocuments {\n id\n }\n unchangedDocuments {\n id\n version\n }\n failedRefreshedDocuments {\n id\n reason\n }\n }\n}\n\nmutation IndexProject(\n $shouldIndexProducts: Boolean!\n $shouldIndexProductTypes: Boolean!\n $shouldIndexProductSelections: Boolean!\n) {\n products: reIndexAllProducts @include(if: $shouldIndexProducts) {\n indexingJobId\n existingIndexingJobId\n }\n productTypes: reIndexAllProductTypes @include(if: $shouldIndexProductTypes) {\n indexingJobId\n existingIndexingJobId\n }\n productSelections: reIndexAllProductSelections\n @include(if: $shouldIndexProductSelections) {\n indexingJobId\n existingIndexingJobId\n }\n}\n\nquery GetIndexingProgress(\n $productsJobId: String!\n $productTypesJobId: String!\n $productSelectionsJobId: String!\n $shouldIncludeProducts: Boolean!\n $shouldIncludeProductTypes: Boolean!\n $shouldIncludeProductSelections: Boolean!\n) {\n products: getReindexingStatus(id: $productsJobId)\n @include(if: $shouldIncludeProducts) {\n percentCompleted\n completed\n }\n\n productTypes: getReindexingStatus(id: $productTypesJobId)\n @include(if: $shouldIncludeProductTypes) {\n percentCompleted\n completed\n }\n\n productSelections: getReindexingStatus(id: $productSelectionsJobId)\n @include(if: $shouldIncludeProductSelections) {\n percentCompleted\n completed\n }\n}\n", name: "GraphQL request", locationOffset: { line: 1, column: 1 } } } };
|
|
11201
10804
|
var IndexProject = { kind: "Document", definitions: [{ kind: "OperationDefinition", operation: "mutation", name: { kind: "Name", value: "IndexProject" }, variableDefinitions: [{ kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "shouldIndexProducts" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "shouldIndexProductTypes" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "shouldIndexProductSelections" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", alias: { kind: "Name", value: "products" }, name: { kind: "Name", value: "reIndexAllProducts" }, arguments: [], directives: [{ kind: "Directive", name: { kind: "Name", value: "include" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "shouldIndexProducts" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "indexingJobId" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "existingIndexingJobId" }, arguments: [], directives: [] }] } }, { kind: "Field", alias: { kind: "Name", value: "productTypes" }, name: { kind: "Name", value: "reIndexAllProductTypes" }, arguments: [], directives: [{ kind: "Directive", name: { kind: "Name", value: "include" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "shouldIndexProductTypes" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "indexingJobId" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "existingIndexingJobId" }, arguments: [], directives: [] }] } }, { kind: "Field", alias: { kind: "Name", value: "productSelections" }, name: { kind: "Name", value: "reIndexAllProductSelections" }, arguments: [], directives: [{ kind: "Directive", name: { kind: "Name", value: "include" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "shouldIndexProductSelections" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "indexingJobId" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "existingIndexingJobId" }, arguments: [], directives: [] }] } }] } }], loc: { start: 0, end: 1549, source: { body: "mutation RefreshProductIndices($ids: [String!]!) {\n refreshProducts(ids: $ids) {\n updatedDocuments {\n id\n version\n }\n deletedDocuments {\n id\n }\n notFoundDocuments {\n id\n }\n unchangedDocuments {\n id\n version\n }\n failedRefreshedDocuments {\n id\n reason\n }\n }\n}\n\nmutation IndexProject(\n $shouldIndexProducts: Boolean!\n $shouldIndexProductTypes: Boolean!\n $shouldIndexProductSelections: Boolean!\n) {\n products: reIndexAllProducts @include(if: $shouldIndexProducts) {\n indexingJobId\n existingIndexingJobId\n }\n productTypes: reIndexAllProductTypes @include(if: $shouldIndexProductTypes) {\n indexingJobId\n existingIndexingJobId\n }\n productSelections: reIndexAllProductSelections\n @include(if: $shouldIndexProductSelections) {\n indexingJobId\n existingIndexingJobId\n }\n}\n\nquery GetIndexingProgress(\n $productsJobId: String!\n $productTypesJobId: String!\n $productSelectionsJobId: String!\n $shouldIncludeProducts: Boolean!\n $shouldIncludeProductTypes: Boolean!\n $shouldIncludeProductSelections: Boolean!\n) {\n products: getReindexingStatus(id: $productsJobId)\n @include(if: $shouldIncludeProducts) {\n percentCompleted\n completed\n }\n\n productTypes: getReindexingStatus(id: $productTypesJobId)\n @include(if: $shouldIncludeProductTypes) {\n percentCompleted\n completed\n }\n\n productSelections: getReindexingStatus(id: $productSelectionsJobId)\n @include(if: $shouldIncludeProductSelections) {\n percentCompleted\n completed\n }\n}\n", name: "GraphQL request", locationOffset: { line: 1, column: 1 } } } };
|
|
11202
10805
|
var GetIndexingProgress = { kind: "Document", definitions: [{ kind: "OperationDefinition", operation: "query", name: { kind: "Name", value: "GetIndexingProgress" }, variableDefinitions: [{ kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "productsJobId" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "String" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "productTypesJobId" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "String" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "productSelectionsJobId" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "String" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "shouldIncludeProducts" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "shouldIncludeProductTypes" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }, { kind: "VariableDefinition", variable: { kind: "Variable", name: { kind: "Name", value: "shouldIncludeProductSelections" } }, type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "Boolean" } } }, directives: [] }], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", alias: { kind: "Name", value: "products" }, name: { kind: "Name", value: "getReindexingStatus" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "id" }, value: { kind: "Variable", name: { kind: "Name", value: "productsJobId" } } }], directives: [{ kind: "Directive", name: { kind: "Name", value: "include" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "shouldIncludeProducts" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "percentCompleted" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "completed" }, arguments: [], directives: [] }] } }, { kind: "Field", alias: { kind: "Name", value: "productTypes" }, name: { kind: "Name", value: "getReindexingStatus" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "id" }, value: { kind: "Variable", name: { kind: "Name", value: "productTypesJobId" } } }], directives: [{ kind: "Directive", name: { kind: "Name", value: "include" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "shouldIncludeProductTypes" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "percentCompleted" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "completed" }, arguments: [], directives: [] }] } }, { kind: "Field", alias: { kind: "Name", value: "productSelections" }, name: { kind: "Name", value: "getReindexingStatus" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "id" }, value: { kind: "Variable", name: { kind: "Name", value: "productSelectionsJobId" } } }], directives: [{ kind: "Directive", name: { kind: "Name", value: "include" }, arguments: [{ kind: "Argument", name: { kind: "Name", value: "if" }, value: { kind: "Variable", name: { kind: "Name", value: "shouldIncludeProductSelections" } } }] }], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "percentCompleted" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "completed" }, arguments: [], directives: [] }] } }] } }], loc: { start: 0, end: 1549, source: { body: "mutation RefreshProductIndices($ids: [String!]!) {\n refreshProducts(ids: $ids) {\n updatedDocuments {\n id\n version\n }\n deletedDocuments {\n id\n }\n notFoundDocuments {\n id\n }\n unchangedDocuments {\n id\n version\n }\n failedRefreshedDocuments {\n id\n reason\n }\n }\n}\n\nmutation IndexProject(\n $shouldIndexProducts: Boolean!\n $shouldIndexProductTypes: Boolean!\n $shouldIndexProductSelections: Boolean!\n) {\n products: reIndexAllProducts @include(if: $shouldIndexProducts) {\n indexingJobId\n existingIndexingJobId\n }\n productTypes: reIndexAllProductTypes @include(if: $shouldIndexProductTypes) {\n indexingJobId\n existingIndexingJobId\n }\n productSelections: reIndexAllProductSelections\n @include(if: $shouldIndexProductSelections) {\n indexingJobId\n existingIndexingJobId\n }\n}\n\nquery GetIndexingProgress(\n $productsJobId: String!\n $productTypesJobId: String!\n $productSelectionsJobId: String!\n $shouldIncludeProducts: Boolean!\n $shouldIncludeProductTypes: Boolean!\n $shouldIncludeProductSelections: Boolean!\n) {\n products: getReindexingStatus(id: $productsJobId)\n @include(if: $shouldIncludeProducts) {\n percentCompleted\n completed\n }\n\n productTypes: getReindexingStatus(id: $productTypesJobId)\n @include(if: $shouldIncludeProductTypes) {\n percentCompleted\n completed\n }\n\n productSelections: getReindexingStatus(id: $productSelectionsJobId)\n @include(if: $shouldIncludeProductSelections) {\n percentCompleted\n completed\n }\n}\n", name: "GraphQL request", locationOffset: { line: 1, column: 1 } } } };
|
|
@@ -11223,7 +10826,7 @@ let PimIndexerProvider = /*#__PURE__*/function (_PureComponent) {
|
|
|
11223
10826
|
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
11224
10827
|
args[_key] = arguments[_key];
|
|
11225
10828
|
}
|
|
11226
|
-
_this = _callSuper$
|
|
10829
|
+
_this = _callSuper$3(this, PimIndexerProvider, [...args]);
|
|
11227
10830
|
_this.state = {
|
|
11228
10831
|
isLoading: true,
|
|
11229
10832
|
isPimIndexerUnreachable: false,
|
|
@@ -11392,7 +10995,7 @@ let PimIndexerProvider = /*#__PURE__*/function (_PureComponent) {
|
|
|
11392
10995
|
shouldIndexProductSelections: isIndexingProductSelections
|
|
11393
10996
|
}
|
|
11394
10997
|
});
|
|
11395
|
-
_this.setState(_objectSpread$
|
|
10998
|
+
_this.setState(_objectSpread$t(_objectSpread$t({
|
|
11396
10999
|
isLoading: false,
|
|
11397
11000
|
isProjectBeingIndexedByPim: true
|
|
11398
11001
|
}, getIndexingJobIds(indexMutationResult)), {}, {
|
|
@@ -11419,7 +11022,7 @@ let PimIndexerProvider = /*#__PURE__*/function (_PureComponent) {
|
|
|
11419
11022
|
key: "render",
|
|
11420
11023
|
value: function render() {
|
|
11421
11024
|
return jsxRuntime.jsx(PimIndexerContext$1.Provider, {
|
|
11422
|
-
value: _objectSpread$
|
|
11025
|
+
value: _objectSpread$t(_objectSpread$t({}, this.state), {}, {
|
|
11423
11026
|
attemptToRefreshProducts: this.attemptToRefreshProducts,
|
|
11424
11027
|
indexProject: this.indexProject
|
|
11425
11028
|
}),
|
|
@@ -11439,12 +11042,12 @@ var pimIndexerProvider = flowRight__default["default"](applicationShellConnector
|
|
|
11439
11042
|
name: 'indexProject'
|
|
11440
11043
|
}), hoc.withApollo, reactIntl.injectIntl, injectNotifications$1())(PimIndexerProvider);
|
|
11441
11044
|
|
|
11442
|
-
function _callSuper$
|
|
11443
|
-
function _isNativeReflectConstruct$
|
|
11045
|
+
function _callSuper$2(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct$2() ? _Reflect$construct__default["default"](o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
|
|
11046
|
+
function _isNativeReflectConstruct$2() { try { var t = !Boolean.prototype.valueOf.call(_Reflect$construct__default["default"](Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct$2 = function () { return !!t; })(); }
|
|
11444
11047
|
let WithPimIndexer = /*#__PURE__*/function (_PureComponent) {
|
|
11445
11048
|
function WithPimIndexer() {
|
|
11446
11049
|
_classCallCheck(this, WithPimIndexer);
|
|
11447
|
-
return _callSuper$
|
|
11050
|
+
return _callSuper$2(this, WithPimIndexer, arguments);
|
|
11448
11051
|
}
|
|
11449
11052
|
_inherits(WithPimIndexer, _PureComponent);
|
|
11450
11053
|
return _createClass(WithPimIndexer, [{
|
|
@@ -11459,13 +11062,13 @@ let WithPimIndexer = /*#__PURE__*/function (_PureComponent) {
|
|
|
11459
11062
|
WithPimIndexer.displayName = 'WithPimIndexer';
|
|
11460
11063
|
var WithPimIndexer$1 = WithPimIndexer;
|
|
11461
11064
|
|
|
11462
|
-
function ownKeys$
|
|
11463
|
-
function _objectSpread$
|
|
11065
|
+
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; }
|
|
11066
|
+
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; }
|
|
11464
11067
|
var injectPimIndexer = (function () {
|
|
11465
11068
|
let propName = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'pimIndexer';
|
|
11466
11069
|
return Component => {
|
|
11467
11070
|
const WrappedComponent = props => jsxRuntime.jsx(WithPimIndexer$1, {
|
|
11468
|
-
children: pimIndexerProps => jsxRuntime.jsx(Component, _objectSpread$
|
|
11071
|
+
children: pimIndexerProps => jsxRuntime.jsx(Component, _objectSpread$s(_objectSpread$s({}, props), {}, {
|
|
11469
11072
|
[propName]: pimIndexerProps
|
|
11470
11073
|
}))
|
|
11471
11074
|
});
|
|
@@ -11493,10 +11096,10 @@ const RESOURCES_WITH_PLATFORM_LIMITS = {
|
|
|
11493
11096
|
carts: 'carts'
|
|
11494
11097
|
};
|
|
11495
11098
|
|
|
11496
|
-
function ownKeys$
|
|
11497
|
-
function _objectSpread$
|
|
11099
|
+
function ownKeys$r(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; }
|
|
11100
|
+
function _objectSpread$r(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$r(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$r(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
11498
11101
|
const resourcesWithPlatformLimits = _Object$keys__default["default"](RESOURCES_WITH_PLATFORM_LIMITS);
|
|
11499
|
-
const createQueryVariables = platformLimit => _reduceInstanceProperty__default["default"](resourcesWithPlatformLimits).call(resourcesWithPlatformLimits, (previousIncludedLimits, nextNameOfLimit) => _objectSpread$
|
|
11102
|
+
const createQueryVariables = platformLimit => _reduceInstanceProperty__default["default"](resourcesWithPlatformLimits).call(resourcesWithPlatformLimits, (previousIncludedLimits, nextNameOfLimit) => _objectSpread$r({
|
|
11500
11103
|
[camelCase__default["default"](`should include ${nextNameOfLimit}`)]: platformLimit ? nextNameOfLimit === platformLimit : true
|
|
11501
11104
|
}, previousIncludedLimits), {});
|
|
11502
11105
|
var createPlatformLimitsQueryVariables = createQueryVariables;
|
|
@@ -11592,8 +11195,8 @@ var messages$q = reactIntl.defineMessages({
|
|
|
11592
11195
|
}
|
|
11593
11196
|
});
|
|
11594
11197
|
|
|
11595
|
-
function ownKeys$
|
|
11596
|
-
function _objectSpread$
|
|
11198
|
+
function ownKeys$q(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; }
|
|
11199
|
+
function _objectSpread$q(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$q(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$q(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
11597
11200
|
const getCustomerSupportLink$1 = msg => jsxRuntime.jsx(uiKit.Link, {
|
|
11598
11201
|
isExternal: true,
|
|
11599
11202
|
to: constants.SUPPORT_PORTAL_URL,
|
|
@@ -11604,7 +11207,7 @@ const PlatformLimitErrorNotification = _ref => {
|
|
|
11604
11207
|
limit = _ref.limit;
|
|
11605
11208
|
return jsxRuntime.jsx(uiKit.ContentNotification, {
|
|
11606
11209
|
type: "error",
|
|
11607
|
-
children: jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$
|
|
11210
|
+
children: jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$q(_objectSpread$q({}, messages$q[resource]), {}, {
|
|
11608
11211
|
values: {
|
|
11609
11212
|
limit,
|
|
11610
11213
|
customersupport: getCustomerSupportLink$1
|
|
@@ -11646,8 +11249,8 @@ var messages$p = reactIntl.defineMessages({
|
|
|
11646
11249
|
}
|
|
11647
11250
|
});
|
|
11648
11251
|
|
|
11649
|
-
function ownKeys$
|
|
11650
|
-
function _objectSpread$
|
|
11252
|
+
function ownKeys$p(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; }
|
|
11253
|
+
function _objectSpread$p(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$p(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$p(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
11651
11254
|
const getCustomerSupportLink = msg => jsxRuntime.jsx(uiKit.Link, {
|
|
11652
11255
|
isExternal: true,
|
|
11653
11256
|
to: constants.SUPPORT_PORTAL_URL,
|
|
@@ -11658,7 +11261,7 @@ const PlatformLimitWarningNotification = _ref => {
|
|
|
11658
11261
|
limit = _ref.limit;
|
|
11659
11262
|
return jsxRuntime.jsx(uiKit.ContentNotification, {
|
|
11660
11263
|
type: "warning",
|
|
11661
|
-
children: jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$
|
|
11264
|
+
children: jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$p(_objectSpread$p({}, messages$p[resource]), {}, {
|
|
11662
11265
|
values: {
|
|
11663
11266
|
limit,
|
|
11664
11267
|
customersupport: getCustomerSupportLink
|
|
@@ -11678,8 +11281,8 @@ const Notifications = {
|
|
|
11678
11281
|
};
|
|
11679
11282
|
var Notifications$1 = Notifications;
|
|
11680
11283
|
|
|
11681
|
-
function ownKeys$
|
|
11682
|
-
function _objectSpread$
|
|
11284
|
+
function ownKeys$o(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; }
|
|
11285
|
+
function _objectSpread$o(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$o(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$o(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
11683
11286
|
const PlatformLimitsStatusText = _ref => {
|
|
11684
11287
|
let intlMessage = _ref.intlMessage,
|
|
11685
11288
|
children = _ref.children;
|
|
@@ -11688,7 +11291,7 @@ const PlatformLimitsStatusText = _ref => {
|
|
|
11688
11291
|
children: jsxRuntime.jsxs(uiKit.Spacings.Inline, {
|
|
11689
11292
|
size: "xs",
|
|
11690
11293
|
children: [jsxRuntime.jsx("span", {
|
|
11691
|
-
children: intlMessage && jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$
|
|
11294
|
+
children: intlMessage && jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$o({}, intlMessage))
|
|
11692
11295
|
}), jsxRuntime.jsx("span", {
|
|
11693
11296
|
children: children
|
|
11694
11297
|
})]
|
|
@@ -11798,11 +11401,11 @@ var messages$o = reactIntl.defineMessages({
|
|
|
11798
11401
|
}
|
|
11799
11402
|
});
|
|
11800
11403
|
|
|
11801
|
-
function ownKeys$
|
|
11802
|
-
function _objectSpread$
|
|
11404
|
+
function ownKeys$n(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; }
|
|
11405
|
+
function _objectSpread$n(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$n(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$n(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
11803
11406
|
const PlatformLimitsShippingMethodsTooltip = props => {
|
|
11804
11407
|
const intl = reactIntl.useIntl();
|
|
11805
|
-
return jsxRuntime.jsx(uiKit.Tooltip, _objectSpread$
|
|
11408
|
+
return jsxRuntime.jsx(uiKit.Tooltip, _objectSpread$n(_objectSpread$n({}, props), {}, {
|
|
11806
11409
|
title: intl.formatMessage(messages$o.shippingMethodsPlatformLimitReached)
|
|
11807
11410
|
}));
|
|
11808
11411
|
};
|
|
@@ -11864,15 +11467,15 @@ const useShippingMethodsLimits = () => {
|
|
|
11864
11467
|
};
|
|
11865
11468
|
var useShippingMethodsPlatformLimits = useShippingMethodsLimits;
|
|
11866
11469
|
|
|
11867
|
-
function ownKeys$
|
|
11868
|
-
function _objectSpread$
|
|
11470
|
+
function ownKeys$m(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; }
|
|
11471
|
+
function _objectSpread$m(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$m(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$m(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
11869
11472
|
const injectShippingMethodsPlatformLimits = () => WrappedComponent => {
|
|
11870
11473
|
const WithShippingMethodsPlatformLimits = props => {
|
|
11871
11474
|
const shippingMethodsPlatformLimits = useShippingMethodsPlatformLimits();
|
|
11872
11475
|
const shippingMethodsProps = {
|
|
11873
11476
|
platformLimits: shippingMethodsPlatformLimits
|
|
11874
11477
|
};
|
|
11875
|
-
return jsxRuntime.jsx(WrappedComponent, _objectSpread$
|
|
11478
|
+
return jsxRuntime.jsx(WrappedComponent, _objectSpread$m(_objectSpread$m({}, props), shippingMethodsProps));
|
|
11876
11479
|
};
|
|
11877
11480
|
WithShippingMethodsPlatformLimits.displayName = wrapDisplayName$1(WrappedComponent, 'WithShippingMethodsPlatformLimits');
|
|
11878
11481
|
return WithShippingMethodsPlatformLimits;
|
|
@@ -11955,11 +11558,11 @@ var messages$m = reactIntl.defineMessages({
|
|
|
11955
11558
|
}
|
|
11956
11559
|
});
|
|
11957
11560
|
|
|
11958
|
-
function ownKeys$
|
|
11959
|
-
function _objectSpread$
|
|
11561
|
+
function ownKeys$l(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; }
|
|
11562
|
+
function _objectSpread$l(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$l(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$l(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
11960
11563
|
const PlatformLimitsTaxCategoriesTooltip = props => {
|
|
11961
11564
|
const intl = reactIntl.useIntl();
|
|
11962
|
-
return jsxRuntime.jsx(uiKit.Tooltip, _objectSpread$
|
|
11565
|
+
return jsxRuntime.jsx(uiKit.Tooltip, _objectSpread$l(_objectSpread$l({}, props), {}, {
|
|
11963
11566
|
title: intl.formatMessage(messages$m.taxCategoriesPlatformLimitReached)
|
|
11964
11567
|
}));
|
|
11965
11568
|
};
|
|
@@ -12015,15 +11618,15 @@ const useTaxCategoriesLimits = () => {
|
|
|
12015
11618
|
};
|
|
12016
11619
|
var useTaxCategoriesPlatformLimits = useTaxCategoriesLimits;
|
|
12017
11620
|
|
|
12018
|
-
function ownKeys$
|
|
12019
|
-
function _objectSpread$
|
|
11621
|
+
function ownKeys$k(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; }
|
|
11622
|
+
function _objectSpread$k(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$k(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$k(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
12020
11623
|
const injectTaxCategoriesPlatformLimits = WrappedComponent => {
|
|
12021
11624
|
const WithTaxCategoriesPlatformLimits = props => {
|
|
12022
11625
|
const taxCategoriesPlatformLimits = useTaxCategoriesPlatformLimits();
|
|
12023
11626
|
const taxCategoriesProps = {
|
|
12024
11627
|
platformLimits: taxCategoriesPlatformLimits
|
|
12025
11628
|
};
|
|
12026
|
-
return jsxRuntime.jsx(WrappedComponent, _objectSpread$
|
|
11629
|
+
return jsxRuntime.jsx(WrappedComponent, _objectSpread$k(_objectSpread$k({}, props), taxCategoriesProps));
|
|
12027
11630
|
};
|
|
12028
11631
|
WithTaxCategoriesPlatformLimits.displayName = wrapDisplayName$1(WrappedComponent, 'WithTaxCategoriesPlatformLimits');
|
|
12029
11632
|
return WithTaxCategoriesPlatformLimits;
|
|
@@ -12106,11 +11709,11 @@ var messages$k = reactIntl.defineMessages({
|
|
|
12106
11709
|
}
|
|
12107
11710
|
});
|
|
12108
11711
|
|
|
12109
|
-
function ownKeys$
|
|
12110
|
-
function _objectSpread$
|
|
11712
|
+
function ownKeys$j(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; }
|
|
11713
|
+
function _objectSpread$j(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$j(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$j(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
12111
11714
|
const PlatformLimitsZonesTooltip = props => {
|
|
12112
11715
|
const intl = reactIntl.useIntl();
|
|
12113
|
-
return jsxRuntime.jsx(uiKit.Tooltip, _objectSpread$
|
|
11716
|
+
return jsxRuntime.jsx(uiKit.Tooltip, _objectSpread$j(_objectSpread$j({}, props), {}, {
|
|
12114
11717
|
title: intl.formatMessage(messages$k.zonesPlatformLimitReached)
|
|
12115
11718
|
}));
|
|
12116
11719
|
};
|
|
@@ -12166,15 +11769,15 @@ const useZonesLimits = () => {
|
|
|
12166
11769
|
};
|
|
12167
11770
|
var useZonesPlatformLimits = useZonesLimits;
|
|
12168
11771
|
|
|
12169
|
-
function ownKeys$
|
|
12170
|
-
function _objectSpread$
|
|
11772
|
+
function ownKeys$i(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; }
|
|
11773
|
+
function _objectSpread$i(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$i(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$i(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
12171
11774
|
const injectZonesPlatformLimits = () => WrappedComponent => {
|
|
12172
11775
|
const WithZonesPlatformLimits = props => {
|
|
12173
11776
|
const zonesPlatformLimits = useZonesPlatformLimits();
|
|
12174
11777
|
const zonesProps = {
|
|
12175
11778
|
platformLimits: zonesPlatformLimits
|
|
12176
11779
|
};
|
|
12177
|
-
return jsxRuntime.jsx(WrappedComponent, _objectSpread$
|
|
11780
|
+
return jsxRuntime.jsx(WrappedComponent, _objectSpread$i(_objectSpread$i({}, props), zonesProps));
|
|
12178
11781
|
};
|
|
12179
11782
|
WithZonesPlatformLimits.displayName = wrapDisplayName$1(WrappedComponent, 'WithZonesPlatformLimits');
|
|
12180
11783
|
return WithZonesPlatformLimits;
|
|
@@ -12271,11 +11874,11 @@ var messages$i = reactIntl.defineMessages({
|
|
|
12271
11874
|
}
|
|
12272
11875
|
});
|
|
12273
11876
|
|
|
12274
|
-
function ownKeys$
|
|
12275
|
-
function _objectSpread$
|
|
11877
|
+
function ownKeys$h(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; }
|
|
11878
|
+
function _objectSpread$h(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$h(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$h(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
12276
11879
|
const PlatformLimitsCustomersTooltip = props => {
|
|
12277
11880
|
const intl = reactIntl.useIntl();
|
|
12278
|
-
return jsxRuntime.jsx(uiKit.Tooltip, _objectSpread$
|
|
11881
|
+
return jsxRuntime.jsx(uiKit.Tooltip, _objectSpread$h(_objectSpread$h({}, props), {}, {
|
|
12279
11882
|
title: intl.formatMessage(messages$i.customersPlatformLimitReached)
|
|
12280
11883
|
}));
|
|
12281
11884
|
};
|
|
@@ -12290,9 +11893,9 @@ var messages$h = reactIntl.defineMessages({
|
|
|
12290
11893
|
}
|
|
12291
11894
|
});
|
|
12292
11895
|
|
|
12293
|
-
function ownKeys$
|
|
12294
|
-
function _objectSpread$
|
|
12295
|
-
var _ref$
|
|
11896
|
+
function ownKeys$g(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; }
|
|
11897
|
+
function _objectSpread$g(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$g(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$g(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
11898
|
+
var _ref$4 = {
|
|
12296
11899
|
name: "1670krd",
|
|
12297
11900
|
styles: "min-width:max-content"
|
|
12298
11901
|
} ;
|
|
@@ -12307,11 +11910,11 @@ const PlatformLimitsCustomersStatus = () => {
|
|
|
12307
11910
|
current = _platformLimits$custo.current,
|
|
12308
11911
|
limit = _platformLimits$custo.limit;
|
|
12309
11912
|
return jsxRuntime.jsx("div", {
|
|
12310
|
-
css: _ref$
|
|
11913
|
+
css: _ref$4,
|
|
12311
11914
|
children: jsxRuntime.jsx(uiKit.Text.Detail, {
|
|
12312
11915
|
tone: "secondary",
|
|
12313
11916
|
isInline: true,
|
|
12314
|
-
intlMessage: _objectSpread$
|
|
11917
|
+
intlMessage: _objectSpread$g(_objectSpread$g({}, messages$h.customersStatus), {}, {
|
|
12315
11918
|
values: {
|
|
12316
11919
|
current: intl.formatNumber(current),
|
|
12317
11920
|
limit: intl.formatNumber(limit)
|
|
@@ -12336,10 +11939,10 @@ var messages$g = reactIntl.defineMessages({
|
|
|
12336
11939
|
}
|
|
12337
11940
|
});
|
|
12338
11941
|
|
|
12339
|
-
function ownKeys$
|
|
12340
|
-
function _objectSpread$
|
|
11942
|
+
function ownKeys$f(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; }
|
|
11943
|
+
function _objectSpread$f(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$f(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$f(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
12341
11944
|
var LimitsReachedErrorGraphic$1 = function LimitsReachedErrorGraphic(props) {
|
|
12342
|
-
return jsxRuntime.jsxs("svg", _objectSpread$
|
|
11945
|
+
return jsxRuntime.jsxs("svg", _objectSpread$f(_objectSpread$f({}, props), {}, {
|
|
12343
11946
|
children: [jsxRuntime.jsx("defs", {
|
|
12344
11947
|
children: jsxRuntime.jsx("path", {
|
|
12345
11948
|
id: "a",
|
|
@@ -12514,15 +12117,15 @@ const useCustomersPlatformLimits = () => {
|
|
|
12514
12117
|
};
|
|
12515
12118
|
var useCustomersPlatformLimits$1 = useCustomersPlatformLimits;
|
|
12516
12119
|
|
|
12517
|
-
function ownKeys$
|
|
12518
|
-
function _objectSpread$
|
|
12120
|
+
function ownKeys$e(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; }
|
|
12121
|
+
function _objectSpread$e(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$e(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$e(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
12519
12122
|
const injectCustomersPlatformLimits = () => WrappedComponent => {
|
|
12520
12123
|
const WithCustomersPlatformLimits = props => {
|
|
12521
12124
|
const CustomersPlatformLimits = useCustomersPlatformLimits$1();
|
|
12522
12125
|
const customersProps = {
|
|
12523
12126
|
platformLimits: CustomersPlatformLimits
|
|
12524
12127
|
};
|
|
12525
|
-
return jsxRuntime.jsx(WrappedComponent, _objectSpread$
|
|
12128
|
+
return jsxRuntime.jsx(WrappedComponent, _objectSpread$e(_objectSpread$e({}, props), customersProps));
|
|
12526
12129
|
};
|
|
12527
12130
|
WithCustomersPlatformLimits.displayName = wrapDisplayName$1(WrappedComponent, 'WithCustomersPlatformLimits');
|
|
12528
12131
|
return WithCustomersPlatformLimits;
|
|
@@ -12651,11 +12254,11 @@ var messages$f = reactIntl.defineMessages({
|
|
|
12651
12254
|
}
|
|
12652
12255
|
});
|
|
12653
12256
|
|
|
12654
|
-
function ownKeys$
|
|
12655
|
-
function _objectSpread$
|
|
12257
|
+
function ownKeys$d(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; }
|
|
12258
|
+
function _objectSpread$d(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$d(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$d(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
12656
12259
|
const PlatformLimitsCustomerGroupsTooltip = props => {
|
|
12657
12260
|
const intl = reactIntl.useIntl();
|
|
12658
|
-
return jsxRuntime.jsx(uiKit.Tooltip, _objectSpread$
|
|
12261
|
+
return jsxRuntime.jsx(uiKit.Tooltip, _objectSpread$d(_objectSpread$d({}, props), {}, {
|
|
12659
12262
|
title: intl.formatMessage(messages$f.customerGroupsPlatformLimitReached)
|
|
12660
12263
|
}));
|
|
12661
12264
|
};
|
|
@@ -12670,9 +12273,9 @@ var messages$e = reactIntl.defineMessages({
|
|
|
12670
12273
|
}
|
|
12671
12274
|
});
|
|
12672
12275
|
|
|
12673
|
-
function ownKeys$
|
|
12674
|
-
function _objectSpread$
|
|
12675
|
-
var _ref$
|
|
12276
|
+
function ownKeys$c(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; }
|
|
12277
|
+
function _objectSpread$c(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$c(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$c(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
12278
|
+
var _ref$3 = {
|
|
12676
12279
|
name: "1670krd",
|
|
12677
12280
|
styles: "min-width:max-content"
|
|
12678
12281
|
} ;
|
|
@@ -12687,11 +12290,11 @@ const PlatformLimitsCustomerGroupsStatus = () => {
|
|
|
12687
12290
|
current = _platformLimits$custo.current,
|
|
12688
12291
|
limit = _platformLimits$custo.limit;
|
|
12689
12292
|
return jsxRuntime.jsx("div", {
|
|
12690
|
-
css: _ref$
|
|
12293
|
+
css: _ref$3,
|
|
12691
12294
|
children: jsxRuntime.jsx(uiKit.Text.Detail, {
|
|
12692
12295
|
tone: "secondary",
|
|
12693
12296
|
isInline: true,
|
|
12694
|
-
intlMessage: _objectSpread$
|
|
12297
|
+
intlMessage: _objectSpread$c(_objectSpread$c({}, messages$e.customerGroupsStatus), {}, {
|
|
12695
12298
|
values: {
|
|
12696
12299
|
current: intl.formatNumber(current),
|
|
12697
12300
|
limit: intl.formatNumber(limit)
|
|
@@ -12716,10 +12319,10 @@ var messages$d = reactIntl.defineMessages({
|
|
|
12716
12319
|
}
|
|
12717
12320
|
});
|
|
12718
12321
|
|
|
12719
|
-
function ownKeys$
|
|
12720
|
-
function _objectSpread$
|
|
12322
|
+
function ownKeys$b(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; }
|
|
12323
|
+
function _objectSpread$b(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$b(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$b(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
12721
12324
|
var LimitsReachedErrorGraphic = function LimitsReachedErrorGraphic(props) {
|
|
12722
|
-
return jsxRuntime.jsxs("svg", _objectSpread$
|
|
12325
|
+
return jsxRuntime.jsxs("svg", _objectSpread$b(_objectSpread$b({}, props), {}, {
|
|
12723
12326
|
children: [jsxRuntime.jsx("defs", {
|
|
12724
12327
|
children: jsxRuntime.jsx("path", {
|
|
12725
12328
|
id: "a",
|
|
@@ -12891,15 +12494,15 @@ const useCustomerGroupsPlatformLimits = () => {
|
|
|
12891
12494
|
};
|
|
12892
12495
|
var useCustomerGroupsPlatformLimits$1 = useCustomerGroupsPlatformLimits;
|
|
12893
12496
|
|
|
12894
|
-
function ownKeys$
|
|
12895
|
-
function _objectSpread$
|
|
12497
|
+
function ownKeys$a(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; }
|
|
12498
|
+
function _objectSpread$a(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$a(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$a(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
12896
12499
|
const injectCustomerGroupsPlatformLimits = () => WrappedComponent => {
|
|
12897
12500
|
const WithCustomerGroupsPlatformLimits = props => {
|
|
12898
12501
|
const CustomerGroupsPlatformLimits = useCustomerGroupsPlatformLimits$1();
|
|
12899
12502
|
const customersProps = {
|
|
12900
12503
|
platformLimits: CustomerGroupsPlatformLimits
|
|
12901
12504
|
};
|
|
12902
|
-
return jsxRuntime.jsx(WrappedComponent, _objectSpread$
|
|
12505
|
+
return jsxRuntime.jsx(WrappedComponent, _objectSpread$a(_objectSpread$a({}, props), customersProps));
|
|
12903
12506
|
};
|
|
12904
12507
|
WithCustomerGroupsPlatformLimits.displayName = wrapDisplayName$1(WrappedComponent, 'WithCustomerGroupsPlatformLimits');
|
|
12905
12508
|
return WithCustomerGroupsPlatformLimits;
|
|
@@ -13048,17 +12651,17 @@ const messages$a = reactIntl.defineMessages({
|
|
|
13048
12651
|
});
|
|
13049
12652
|
var messages$b = messages$a;
|
|
13050
12653
|
|
|
13051
|
-
function ownKeys$
|
|
13052
|
-
function _objectSpread$
|
|
13053
|
-
var _ref$
|
|
12654
|
+
function ownKeys$9(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; }
|
|
12655
|
+
function _objectSpread$9(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$9(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$9(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
12656
|
+
var _ref$2 = {
|
|
13054
12657
|
name: "1rk22b8",
|
|
13055
12658
|
styles: "font-size:0.9rem;font-weight:bold"
|
|
13056
12659
|
} ;
|
|
13057
12660
|
const LabelRange = _ref2 => {
|
|
13058
12661
|
let type = _ref2.type;
|
|
13059
12662
|
return jsxRuntime.jsx("label", {
|
|
13060
|
-
css: _ref$
|
|
13061
|
-
children: jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$
|
|
12663
|
+
css: _ref$2,
|
|
12664
|
+
children: jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$9({}, messages$b[type]))
|
|
13062
12665
|
});
|
|
13063
12666
|
};
|
|
13064
12667
|
LabelRange.displayName = 'LabelRange';
|
|
@@ -13073,8 +12676,8 @@ var messages$9 = reactIntl.defineMessages({
|
|
|
13073
12676
|
});
|
|
13074
12677
|
|
|
13075
12678
|
const _excluded = ["isChecked"];
|
|
13076
|
-
function ownKeys$
|
|
13077
|
-
function _objectSpread$
|
|
12679
|
+
function ownKeys$8(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; }
|
|
12680
|
+
function _objectSpread$8(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$8(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$8(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
13078
12681
|
const MissingValueField = _ref => {
|
|
13079
12682
|
let _ref$isChecked = _ref.isChecked,
|
|
13080
12683
|
isChecked = _ref$isChecked === void 0 ? false : _ref$isChecked,
|
|
@@ -13083,7 +12686,7 @@ const MissingValueField = _ref => {
|
|
|
13083
12686
|
name: "missing-value",
|
|
13084
12687
|
isChecked: isChecked,
|
|
13085
12688
|
onChange: props.onChange,
|
|
13086
|
-
children: jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$
|
|
12689
|
+
children: jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$8({}, messages$9.label))
|
|
13087
12690
|
});
|
|
13088
12691
|
};
|
|
13089
12692
|
var MissingValueField$1 = MissingValueField;
|
|
@@ -13101,8 +12704,8 @@ var messages$8 = reactIntl.defineMessages({
|
|
|
13101
12704
|
}
|
|
13102
12705
|
});
|
|
13103
12706
|
|
|
13104
|
-
function ownKeys$
|
|
13105
|
-
function _objectSpread$
|
|
12707
|
+
function ownKeys$7(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; }
|
|
12708
|
+
function _objectSpread$7(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$7(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$7(Object(t))).call(_context3, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
13106
12709
|
const IS_MULTI_VALUE_FLAG = '?isMulti=true';
|
|
13107
12710
|
const MultiValueSelectorDropdown = props => {
|
|
13108
12711
|
if (!props.isOpen) return null;
|
|
@@ -13114,7 +12717,7 @@ const MultiValueSelectorDropdown = props => {
|
|
|
13114
12717
|
css: /*#__PURE__*/react$1.css("padding:", uiKit.designTokens.spacingS, ";&:hover{background-color:", uiKit.designTokens.colorNeutral95, ";border-radius:", uiKit.designTokens.borderRadiusForInput, ";}" + ("" ), "" ),
|
|
13115
12718
|
children: jsxRuntime.jsx(uiKit.Text.Body, {
|
|
13116
12719
|
truncate: true,
|
|
13117
|
-
intlMessage: _objectSpread$
|
|
12720
|
+
intlMessage: _objectSpread$7(_objectSpread$7({}, messages$8.filterWholeInput), {}, {
|
|
13118
12721
|
values: {
|
|
13119
12722
|
values: `"${props.value}"`
|
|
13120
12723
|
}
|
|
@@ -13125,7 +12728,7 @@ const MultiValueSelectorDropdown = props => {
|
|
|
13125
12728
|
css: /*#__PURE__*/react$1.css("padding:", uiKit.designTokens.spacingS, ";&:hover{background-color:", uiKit.designTokens.colorNeutral95, ";border-bottom-left-radius:", uiKit.designTokens.borderRadiusForInput, ";border-bottom-right-radius:", uiKit.designTokens.borderRadiusForInput, ";}" + ("" ), "" ),
|
|
13126
12729
|
children: jsxRuntime.jsx(uiKit.Text.Body, {
|
|
13127
12730
|
truncate: true,
|
|
13128
|
-
intlMessage: _objectSpread$
|
|
12731
|
+
intlMessage: _objectSpread$7(_objectSpread$7({}, messages$8.filterSeparateValues), {}, {
|
|
13129
12732
|
values: {
|
|
13130
12733
|
values: `"${props.multiValue.join('", "')}"` || props.value
|
|
13131
12734
|
}
|
|
@@ -13143,7 +12746,7 @@ const MultiValueSelectorDropdown = props => {
|
|
|
13143
12746
|
});
|
|
13144
12747
|
};
|
|
13145
12748
|
MultiValueSelectorDropdown.displayName = 'MultiValueSelectorDropdown';
|
|
13146
|
-
var _ref = {
|
|
12749
|
+
var _ref$1 = {
|
|
13147
12750
|
name: "bjn8wh",
|
|
13148
12751
|
styles: "position:relative"
|
|
13149
12752
|
} ;
|
|
@@ -13217,7 +12820,7 @@ const MultiValueSearchInput = props => {
|
|
|
13217
12820
|
clearRunningTooltipTimer();
|
|
13218
12821
|
});
|
|
13219
12822
|
return jsxRuntime.jsxs("div", {
|
|
13220
|
-
css: _ref,
|
|
12823
|
+
css: _ref$1,
|
|
13221
12824
|
children: [jsxRuntime.jsx(uiKit.Spacings.Stack, {
|
|
13222
12825
|
size: "s",
|
|
13223
12826
|
children: jsxRuntime.jsx(uiKit.SearchTextInput, {
|
|
@@ -13241,10 +12844,10 @@ const MultiValueSearchInput = props => {
|
|
|
13241
12844
|
MultiValueSearchInput.displayName = 'MultiValueSearchInput';
|
|
13242
12845
|
var MultiValueSearchInput$1 = MultiValueSearchInput;
|
|
13243
12846
|
|
|
13244
|
-
function ownKeys$
|
|
13245
|
-
function _objectSpread$
|
|
13246
|
-
function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? _Reflect$construct__default["default"](o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
|
|
13247
|
-
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(_Reflect$construct__default["default"](Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function () { return !!t; })(); }
|
|
12847
|
+
function ownKeys$6(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; }
|
|
12848
|
+
function _objectSpread$6(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$6(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$6(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
12849
|
+
function _callSuper$1(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct$1() ? _Reflect$construct__default["default"](o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
|
|
12850
|
+
function _isNativeReflectConstruct$1() { try { var t = !Boolean.prototype.valueOf.call(_Reflect$construct__default["default"](Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct$1 = function () { return !!t; })(); }
|
|
13248
12851
|
Cleave__default["default"].displayName = 'Cleave';
|
|
13249
12852
|
|
|
13250
12853
|
// only allow values of type Number or values that are nil (null or undefined)
|
|
@@ -13257,7 +12860,7 @@ let NumericFormatInput = /*#__PURE__*/function (_PureComponent) {
|
|
|
13257
12860
|
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
13258
12861
|
args[_key] = arguments[_key];
|
|
13259
12862
|
}
|
|
13260
|
-
_this = _callSuper(this, NumericFormatInput, [...args]);
|
|
12863
|
+
_this = _callSuper$1(this, NumericFormatInput, [...args]);
|
|
13261
12864
|
_this.state = {
|
|
13262
12865
|
parsedValue: _this.props.value
|
|
13263
12866
|
};
|
|
@@ -13302,7 +12905,7 @@ let NumericFormatInput = /*#__PURE__*/function (_PureComponent) {
|
|
|
13302
12905
|
value: function render() {
|
|
13303
12906
|
const separators = getSeparatorsForLocale(this.props.numberFormat);
|
|
13304
12907
|
const dataAttributes = filterDataAttributes(this.props);
|
|
13305
|
-
return jsxRuntime.jsx(Cleave__default["default"], _objectSpread$
|
|
12908
|
+
return jsxRuntime.jsx(Cleave__default["default"], _objectSpread$6({
|
|
13306
12909
|
placeholder: this.props.placeholder,
|
|
13307
12910
|
htmlRef: this.registerInputRef,
|
|
13308
12911
|
options: {
|
|
@@ -13375,6 +12978,152 @@ const withPropsForMoney = ownProps => ownProps.numberFormatType === 'money' ? {
|
|
|
13375
12978
|
} : {};
|
|
13376
12979
|
var numericFormatInput = withProps$1(withPropsForMoney)(NumericFormatInput);
|
|
13377
12980
|
|
|
12981
|
+
const getTextareaStyles = props => /*#__PURE__*/react$1.css("transition:0.2s ease;border-radius:", designSystem.designTokens.borderRadiusForInput, ";border-style:solid;border-width:1px;color:", designSystem.designTokens.colorSolid, ";font-weight:", designSystem.designTokens.fontWeight500, ";font-size:", designSystem.designTokens.fontSize10, ";font-family:", designSystem.designTokens.fontFamily, ";padding:", designSystem.designTokens.spacingS, " ", designSystem.designTokens.spacingM, ";outline:none;box-shadow:none;appearance:none;width:100%;min-height:", designSystem.designTokens.heightForInput, ";resize:vertical;", props.style === 'primary' && /*#__PURE__*/react$1.css("border-color:", designSystem.designTokens.colorNeutral, ";background-color:", designSystem.designTokens.colorSurface, ";" + ("" ), "" ), " ", props.style === 'secondary' && /*#__PURE__*/react$1.css("background-color:", designSystem.designTokens.colorNeutral95, ";border-color:", designSystem.designTokens.colorSurface, ";" + ("" ), "" ), " ", props.disabled && /*#__PURE__*/react$1.css("cursor:not-allowed;background-color:", designSystem.designTokens.colorAccent98, ";color:", designSystem.designTokens.colorSolid, ";opacity:1;" + ("" ), "" ), " ", !props.isValid && /*#__PURE__*/react$1.css("border-color:", designSystem.designTokens.colorError, ";border:1px solid;" + ("" ), "" ), ";" + ("" ), "" );
|
|
12982
|
+
var _ref = {
|
|
12983
|
+
name: "7g7czh",
|
|
12984
|
+
styles: "border-top-left-radius:0;border-bottom-left-radius:0;margin-left:0"
|
|
12985
|
+
} ;
|
|
12986
|
+
const getInputStyles = props => /*#__PURE__*/react$1.css("transition:0.2s ease;border-radius:", designSystem.designTokens.borderRadiusForInput, ";border-style:solid;border-width:1px;color:", designSystem.designTokens.colorSolid, ";font-weight:", designSystem.designTokens.fontWeight500, ";font-size:", designSystem.designTokens.fontSize10, ";font-family:", designSystem.designTokens.fontFamily, ";padding:", designSystem.designTokens.spacingS, " ", designSystem.designTokens.spacingM, ";outline:none;box-shadow:none;appearance:none;width:100%;min-height:", designSystem.designTokens.heightForInput, ";", props.style === 'primary' && /*#__PURE__*/react$1.css("border-color:", designSystem.designTokens.colorNeutral, ";background-color:", designSystem.designTokens.colorSurface, ";" + ("" ), "" ), " ", props.style === 'secondary' && /*#__PURE__*/react$1.css("background-color:", designSystem.designTokens.colorNeutral95, ";border-color:", designSystem.designTokens.colorSurface, ";" + ("" ), "" ), " ", props.disabled && /*#__PURE__*/react$1.css("cursor:not-allowed;background-color:", designSystem.designTokens.colorAccent98, ";color:", designSystem.designTokens.colorSolid, ";opacity:1;" + ("" ), "" ), " ", !props.isValid && /*#__PURE__*/react$1.css("border-color:", designSystem.designTokens.colorError, "!important;border:1px solid;" + ("" ), "" ), " ", props.isGranular && _ref, ";" + ("" ), "" );
|
|
12987
|
+
|
|
12988
|
+
function ownKeys$5(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; }
|
|
12989
|
+
function _objectSpread$5(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$5(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$5(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
12990
|
+
function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? _Reflect$construct__default["default"](o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
|
|
12991
|
+
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(_Reflect$construct__default["default"](Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function () { return !!t; })(); }
|
|
12992
|
+
let ThrottledField = /*#__PURE__*/function (_PureComponent) {
|
|
12993
|
+
function ThrottledField() {
|
|
12994
|
+
var _this;
|
|
12995
|
+
_classCallCheck(this, ThrottledField);
|
|
12996
|
+
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
12997
|
+
args[_key] = arguments[_key];
|
|
12998
|
+
}
|
|
12999
|
+
_this = _callSuper(this, ThrottledField, [...args]);
|
|
13000
|
+
_this.state = {
|
|
13001
|
+
draftValue: '',
|
|
13002
|
+
prevValue: ''
|
|
13003
|
+
};
|
|
13004
|
+
_this.clearPendingUpdates = () => {
|
|
13005
|
+
clearTimeout(_this.changeTimeout);
|
|
13006
|
+
clearTimeout(_this.blurTimeout);
|
|
13007
|
+
_this.changeTimeout = null;
|
|
13008
|
+
_this.blurTimeout = null;
|
|
13009
|
+
};
|
|
13010
|
+
_this.handleChange = event => {
|
|
13011
|
+
// The `SyntheticEvent` is pooled by default for perf reasons.
|
|
13012
|
+
// See https://facebook.github.io/react/docs/events.html#event-pooling
|
|
13013
|
+
// To access the event in an async way we need to persist it.
|
|
13014
|
+
event.persist();
|
|
13015
|
+
_this.setState({
|
|
13016
|
+
draftValue: event.target.value
|
|
13017
|
+
});
|
|
13018
|
+
_this.doDelayedUpdate(_this.props.onChange, event, 'change');
|
|
13019
|
+
};
|
|
13020
|
+
_this.handleEnter = event => {
|
|
13021
|
+
if (event.keyCode !== 13) return;
|
|
13022
|
+
if (_this.changeTimeout) {
|
|
13023
|
+
// Since there are still are some pending updates that are not sent to the
|
|
13024
|
+
// parent yet we need to call the update here explicitly and clear the
|
|
13025
|
+
// pending updates
|
|
13026
|
+
_this.props.onChange({
|
|
13027
|
+
target: {
|
|
13028
|
+
value: _this.state.draftValue
|
|
13029
|
+
}
|
|
13030
|
+
});
|
|
13031
|
+
// we can savely clear the timeout and thus abort all pending changes
|
|
13032
|
+
// because we just update the parent with the current state
|
|
13033
|
+
clearTimeout(_this.changeTimeout);
|
|
13034
|
+
_this.changeTimeout = null;
|
|
13035
|
+
}
|
|
13036
|
+
_this.props.onEnter(_this.state.draftValue);
|
|
13037
|
+
};
|
|
13038
|
+
_this.handleBlur = event => {
|
|
13039
|
+
// The `SyntheticEvent` is pooled by default for perf reasons.
|
|
13040
|
+
// See https://facebook.github.io/react/docs/events.html#event-pooling
|
|
13041
|
+
// To access the event in an async way we need to persist it.
|
|
13042
|
+
if (_this.props.onBlurValue) {
|
|
13043
|
+
event.persist();
|
|
13044
|
+
_this.doDelayedUpdate(e => _this.props.onBlurValue(e.target.value), event, 'blur');
|
|
13045
|
+
}
|
|
13046
|
+
};
|
|
13047
|
+
_this.doDelayedUpdate = (updateFunction, event, eventType) => {
|
|
13048
|
+
const self = _this;
|
|
13049
|
+
const timeoutKey = `${eventType}Timeout`;
|
|
13050
|
+
// TODO: can't we just use one variable?
|
|
13051
|
+
clearTimeout(_this[timeoutKey]);
|
|
13052
|
+
_this[timeoutKey] = _setTimeout__default["default"](() => {
|
|
13053
|
+
updateFunction.call(self, event);
|
|
13054
|
+
_this[timeoutKey] = null;
|
|
13055
|
+
}, _this.props.throttleMS);
|
|
13056
|
+
};
|
|
13057
|
+
return _this;
|
|
13058
|
+
}
|
|
13059
|
+
_inherits(ThrottledField, _PureComponent);
|
|
13060
|
+
return _createClass(ThrottledField, [{
|
|
13061
|
+
key: "componentWillUnmount",
|
|
13062
|
+
value: function componentWillUnmount() {
|
|
13063
|
+
this.clearPendingUpdates();
|
|
13064
|
+
}
|
|
13065
|
+
}, {
|
|
13066
|
+
key: "render",
|
|
13067
|
+
value: function render() {
|
|
13068
|
+
const commonProps = _objectSpread$5(_objectSpread$5({
|
|
13069
|
+
value: this.state.draftValue,
|
|
13070
|
+
autoComplete: this.props.autoComplete,
|
|
13071
|
+
onChange: this.handleChange,
|
|
13072
|
+
onBlur: this.handleBlur,
|
|
13073
|
+
disabled: this.props.disabled,
|
|
13074
|
+
name: this.props.name,
|
|
13075
|
+
placeholder: this.props.placeholder,
|
|
13076
|
+
autoFocus: this.props.autoFocus
|
|
13077
|
+
}, this.props.onEnter ? {
|
|
13078
|
+
onKeyDown: this.handleEnter
|
|
13079
|
+
} : {}), filterDataAttributes(this.props));
|
|
13080
|
+
const inputId = `throttled-field-${this.props.name}`;
|
|
13081
|
+
return jsxRuntime.jsxs(jsxRuntime.Fragment, {
|
|
13082
|
+
children: [jsxRuntime.jsx(uiKit.AccessibleHidden, {
|
|
13083
|
+
children: jsxRuntime.jsx("label", {
|
|
13084
|
+
htmlFor: inputId,
|
|
13085
|
+
children: this.props.label
|
|
13086
|
+
})
|
|
13087
|
+
}), this.props.as === 'textarea' ? jsxRuntime.jsx(Textarea__default["default"], _objectSpread$5(_objectSpread$5({}, commonProps), {}, {
|
|
13088
|
+
id: inputId,
|
|
13089
|
+
css: getTextareaStyles(this.props),
|
|
13090
|
+
rows: 1,
|
|
13091
|
+
maxRows: this.props.autoSize ? undefined : 1,
|
|
13092
|
+
cacheMeasurements: true
|
|
13093
|
+
})) : jsxRuntime.jsx("input", _objectSpread$5(_objectSpread$5({}, commonProps), {}, {
|
|
13094
|
+
id: inputId,
|
|
13095
|
+
ref: this.props.inputRef,
|
|
13096
|
+
type: this.props.as,
|
|
13097
|
+
css: getInputStyles(this.props)
|
|
13098
|
+
}))]
|
|
13099
|
+
});
|
|
13100
|
+
}
|
|
13101
|
+
}], [{
|
|
13102
|
+
key: "getDerivedStateFromProps",
|
|
13103
|
+
value: function getDerivedStateFromProps(nextProps, prevState) {
|
|
13104
|
+
if (nextProps.value !== prevState.prevValue) {
|
|
13105
|
+
return {
|
|
13106
|
+
draftValue: nextProps.value || nextProps.value === 0 ? nextProps.value : '',
|
|
13107
|
+
prevValue: nextProps.value
|
|
13108
|
+
};
|
|
13109
|
+
}
|
|
13110
|
+
return null;
|
|
13111
|
+
}
|
|
13112
|
+
}]);
|
|
13113
|
+
}(React.PureComponent);
|
|
13114
|
+
ThrottledField.displayName = 'ThrottledField';
|
|
13115
|
+
ThrottledField.defaultProps = {
|
|
13116
|
+
as: 'text',
|
|
13117
|
+
style: 'secondary',
|
|
13118
|
+
throttleMS: 300,
|
|
13119
|
+
isValid: true,
|
|
13120
|
+
disabled: false,
|
|
13121
|
+
autoSize: true,
|
|
13122
|
+
autoFocus: false,
|
|
13123
|
+
label: 'Throttled field'
|
|
13124
|
+
};
|
|
13125
|
+
var ThrottledField$1 = ThrottledField;
|
|
13126
|
+
|
|
13378
13127
|
/**
|
|
13379
13128
|
* @param mixed value
|
|
13380
13129
|
* @param String definitionName
|
|
@@ -14761,7 +14510,6 @@ function withPendingRequests() {
|
|
|
14761
14510
|
var CategorySearchPickerOptionFragment = { kind: "Document", definitions: [{ kind: "FragmentDefinition", name: { kind: "Name", value: "CategorySearchPickerOptionFragment" }, typeCondition: { kind: "NamedType", name: { kind: "Name", value: "CategorySearch" } }, directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "id" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "externalId" }, 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: "slugAllLocales" }, 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: "parent" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ 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: "ancestors" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ 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: 685, source: { body: "query SearchCategoryReference($locale: Locale!, $text: String!) {\n categories: categoryAutocomplete(locale: $locale, text: $text) {\n results {\n ...CategorySearchPickerOptionFragment\n }\n }\n}\n\nquery FetchCategoriesByIds($where: String!) {\n categories(where: $where) {\n results {\n id\n nameAllLocales {\n locale\n value\n }\n }\n }\n}\n\nfragment CategorySearchPickerOptionFragment on CategorySearch {\n id\n externalId\n nameAllLocales {\n locale\n value\n }\n slugAllLocales {\n locale\n value\n }\n parent {\n nameAllLocales {\n locale\n value\n }\n }\n ancestors {\n nameAllLocales {\n locale\n value\n }\n }\n}\n", name: "GraphQL request", locationOffset: { line: 1, column: 1 } } } };
|
|
14762
14511
|
|
|
14763
14512
|
exports.BooleanField = booleanField;
|
|
14764
|
-
exports.Button = Button$1;
|
|
14765
14513
|
exports.CUSTOM_FIELD_TYPES = CUSTOM_FIELD_TYPES;
|
|
14766
14514
|
exports.Carousel = Carousel$1;
|
|
14767
14515
|
exports.CartDiscountReferenceSearch = CartDiscountReferenceSearch;
|
|
@@ -14806,7 +14554,6 @@ exports.RecurrentIntervalPicker = RecurrentIntervalPicker$1;
|
|
|
14806
14554
|
exports.RequestCache = RequestCache$1;
|
|
14807
14555
|
exports.RequiredIndicator = RequiredIndicator$1;
|
|
14808
14556
|
exports.ScrollToFieldError = ScrollToFieldError$1;
|
|
14809
|
-
exports.SearchInput = searchInput;
|
|
14810
14557
|
exports.SelectableFieldSearchInput = SelectableFieldSearchInput$1;
|
|
14811
14558
|
exports.StoreSelectField = StoreSelectField$1;
|
|
14812
14559
|
exports.StoreSelectInput = StoreSelectInput$1;
|
|
@@ -14929,7 +14676,6 @@ exports.resolveStatusType = resolveStatusType;
|
|
|
14929
14676
|
exports.safelyAddFallback = safelyAddFallback;
|
|
14930
14677
|
exports.sanitize = sanitize;
|
|
14931
14678
|
exports.searchCategories = searchCategories;
|
|
14932
|
-
exports.searchInputMessages = messages$P;
|
|
14933
14679
|
exports.setDisplayName = setDisplayName$1;
|
|
14934
14680
|
exports.setToArray = setToArray;
|
|
14935
14681
|
exports.shallowEqual = shallowEqual;
|