@commercetools-uikit/money-field 12.2.2 → 12.2.6
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/README.md
CHANGED
|
@@ -3,7 +3,15 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
var _Reflect$construct = require('@babel/runtime-corejs3/core-js-stable/reflect/construct');
|
|
6
|
-
var
|
|
6
|
+
var _Object$keys = require('@babel/runtime-corejs3/core-js-stable/object/keys');
|
|
7
|
+
var _Object$getOwnPropertySymbols = require('@babel/runtime-corejs3/core-js-stable/object/get-own-property-symbols');
|
|
8
|
+
var _filterInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/filter');
|
|
9
|
+
var _Object$getOwnPropertyDescriptor = require('@babel/runtime-corejs3/core-js-stable/object/get-own-property-descriptor');
|
|
10
|
+
var _forEachInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/for-each');
|
|
11
|
+
var _Object$getOwnPropertyDescriptors = require('@babel/runtime-corejs3/core-js-stable/object/get-own-property-descriptors');
|
|
12
|
+
var _Object$defineProperties = require('@babel/runtime-corejs3/core-js-stable/object/define-properties');
|
|
13
|
+
var _Object$defineProperty = require('@babel/runtime-corejs3/core-js-stable/object/define-property');
|
|
14
|
+
var _defineProperty = require('@babel/runtime-corejs3/helpers/defineProperty');
|
|
7
15
|
var _classCallCheck = require('@babel/runtime-corejs3/helpers/classCallCheck');
|
|
8
16
|
var _createClass = require('@babel/runtime-corejs3/helpers/createClass');
|
|
9
17
|
var _inherits = require('@babel/runtime-corejs3/helpers/inherits');
|
|
@@ -12,7 +20,7 @@ var _getPrototypeOf = require('@babel/runtime-corejs3/helpers/getPrototypeOf');
|
|
|
12
20
|
var _someInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/some');
|
|
13
21
|
var _Object$values = require('@babel/runtime-corejs3/core-js-stable/object/values');
|
|
14
22
|
var _concatInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/concat');
|
|
15
|
-
var
|
|
23
|
+
var react = require('react');
|
|
16
24
|
var PropTypes = require('prop-types');
|
|
17
25
|
var requiredIf = require('react-required-if');
|
|
18
26
|
var has = require('lodash/has');
|
|
@@ -22,15 +30,22 @@ var Spacings = require('@commercetools-uikit/spacings');
|
|
|
22
30
|
var FieldLabel = require('@commercetools-uikit/field-label');
|
|
23
31
|
var MoneyInput = require('@commercetools-uikit/money-input');
|
|
24
32
|
var FieldErrors = require('@commercetools-uikit/field-errors');
|
|
25
|
-
var
|
|
33
|
+
var jsxRuntime = require('@emotion/react/jsx-runtime');
|
|
26
34
|
|
|
27
35
|
function _interopDefault (e) { return e && e.__esModule ? e : { 'default': e }; }
|
|
28
36
|
|
|
29
37
|
var _Reflect$construct__default = /*#__PURE__*/_interopDefault(_Reflect$construct);
|
|
38
|
+
var _Object$keys__default = /*#__PURE__*/_interopDefault(_Object$keys);
|
|
39
|
+
var _Object$getOwnPropertySymbols__default = /*#__PURE__*/_interopDefault(_Object$getOwnPropertySymbols);
|
|
40
|
+
var _filterInstanceProperty__default = /*#__PURE__*/_interopDefault(_filterInstanceProperty);
|
|
41
|
+
var _Object$getOwnPropertyDescriptor__default = /*#__PURE__*/_interopDefault(_Object$getOwnPropertyDescriptor);
|
|
42
|
+
var _forEachInstanceProperty__default = /*#__PURE__*/_interopDefault(_forEachInstanceProperty);
|
|
43
|
+
var _Object$getOwnPropertyDescriptors__default = /*#__PURE__*/_interopDefault(_Object$getOwnPropertyDescriptors);
|
|
44
|
+
var _Object$defineProperties__default = /*#__PURE__*/_interopDefault(_Object$defineProperties);
|
|
45
|
+
var _Object$defineProperty__default = /*#__PURE__*/_interopDefault(_Object$defineProperty);
|
|
30
46
|
var _someInstanceProperty__default = /*#__PURE__*/_interopDefault(_someInstanceProperty);
|
|
31
47
|
var _Object$values__default = /*#__PURE__*/_interopDefault(_Object$values);
|
|
32
48
|
var _concatInstanceProperty__default = /*#__PURE__*/_interopDefault(_concatInstanceProperty);
|
|
33
|
-
var React__default = /*#__PURE__*/_interopDefault(React);
|
|
34
49
|
var PropTypes__default = /*#__PURE__*/_interopDefault(PropTypes);
|
|
35
50
|
var requiredIf__default = /*#__PURE__*/_interopDefault(requiredIf);
|
|
36
51
|
var has__default = /*#__PURE__*/_interopDefault(has);
|
|
@@ -40,19 +55,23 @@ var FieldLabel__default = /*#__PURE__*/_interopDefault(FieldLabel);
|
|
|
40
55
|
var MoneyInput__default = /*#__PURE__*/_interopDefault(MoneyInput);
|
|
41
56
|
var FieldErrors__default = /*#__PURE__*/_interopDefault(FieldErrors);
|
|
42
57
|
|
|
43
|
-
function
|
|
58
|
+
function ownKeys(object, enumerableOnly) { var keys = _Object$keys__default["default"](object); if (_Object$getOwnPropertySymbols__default["default"]) { var symbols = _Object$getOwnPropertySymbols__default["default"](object); if (enumerableOnly) { symbols = _filterInstanceProperty__default["default"](symbols).call(symbols, function (sym) { return _Object$getOwnPropertyDescriptor__default["default"](object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
|
|
44
59
|
|
|
45
|
-
function
|
|
60
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { var _context4; _forEachInstanceProperty__default["default"](_context4 = ownKeys(Object(source), true)).call(_context4, function (key) { _defineProperty(target, key, source[key]); }); } else if (_Object$getOwnPropertyDescriptors__default["default"]) { _Object$defineProperties__default["default"](target, _Object$getOwnPropertyDescriptors__default["default"](source)); } else { var _context5; _forEachInstanceProperty__default["default"](_context5 = ownKeys(Object(source))).call(_context5, function (key) { _Object$defineProperty__default["default"](target, key, _Object$getOwnPropertyDescriptor__default["default"](source, key)); }); } } return target; }
|
|
61
|
+
|
|
62
|
+
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = _Reflect$construct__default["default"](Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
63
|
+
|
|
64
|
+
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !_Reflect$construct__default["default"]) return false; if (_Reflect$construct__default["default"].sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(_Reflect$construct__default["default"](Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
46
65
|
var sequentialId = utils.createSequentialId('money-field-');
|
|
47
66
|
|
|
48
67
|
var hasErrors = function hasErrors(errors) {
|
|
49
68
|
var _context;
|
|
50
69
|
|
|
51
|
-
return errors && _someInstanceProperty__default[
|
|
70
|
+
return errors && _someInstanceProperty__default["default"](_context = _Object$values__default["default"](errors)).call(_context, Boolean);
|
|
52
71
|
};
|
|
53
72
|
|
|
54
|
-
var MoneyField = /*#__PURE__*/function (
|
|
55
|
-
_inherits(MoneyField,
|
|
73
|
+
var MoneyField = /*#__PURE__*/function (_Component) {
|
|
74
|
+
_inherits(MoneyField, _Component);
|
|
56
75
|
|
|
57
76
|
var _super = _createSuper(MoneyField);
|
|
58
77
|
|
|
@@ -67,7 +86,7 @@ var MoneyField = /*#__PURE__*/function (_React$Component) {
|
|
|
67
86
|
args[_key] = arguments[_key];
|
|
68
87
|
}
|
|
69
88
|
|
|
70
|
-
_this = _super.call.apply(_super, _concatInstanceProperty__default[
|
|
89
|
+
_this = _super.call.apply(_super, _concatInstanceProperty__default["default"](_context2 = [this]).call(_context2, args));
|
|
71
90
|
_this.state = {
|
|
72
91
|
// We generate an id in case no id is provided by the parent to attach the
|
|
73
92
|
// label to the input component.
|
|
@@ -82,47 +101,49 @@ var MoneyField = /*#__PURE__*/function (_React$Component) {
|
|
|
82
101
|
// MoneyInput.isTouched() ensures both fields have been touched.
|
|
83
102
|
// This avoids showing an error when the user just selected a language but
|
|
84
103
|
// didn't add an amount yet.
|
|
85
|
-
var hasError = MoneyInput__default[
|
|
86
|
-
return
|
|
87
|
-
max: this.props.horizontalConstraint
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
104
|
+
var hasError = MoneyInput__default["default"].isTouched(this.props.touched) && hasErrors(this.props.errors);
|
|
105
|
+
return jsxRuntime.jsx(Constraints__default["default"].Horizontal, {
|
|
106
|
+
max: this.props.horizontalConstraint,
|
|
107
|
+
children: jsxRuntime.jsxs(Spacings__default["default"].Stack, {
|
|
108
|
+
scale: "xs",
|
|
109
|
+
children: [jsxRuntime.jsx(FieldLabel__default["default"], {
|
|
110
|
+
title: this.props.title,
|
|
111
|
+
hint: this.props.hint,
|
|
112
|
+
description: this.props.description,
|
|
113
|
+
onInfoButtonClick: this.props.onInfoButtonClick,
|
|
114
|
+
hintIcon: this.props.hintIcon,
|
|
115
|
+
hasRequiredIndicator: this.props.isRequired,
|
|
116
|
+
htmlFor: this.state.id
|
|
117
|
+
}), jsxRuntime.jsx(MoneyInput__default["default"], _objectSpread({
|
|
118
|
+
id: this.state.id,
|
|
119
|
+
name: this.props.name,
|
|
120
|
+
autoComplete: this.props.autoComplete,
|
|
121
|
+
value: this.props.value,
|
|
122
|
+
currencies: this.props.currencies,
|
|
123
|
+
placeholder: this.props.placeholder,
|
|
124
|
+
onFocus: this.props.onFocus,
|
|
125
|
+
onBlur: this.props.onBlur,
|
|
126
|
+
isDisabled: this.props.isDisabled,
|
|
127
|
+
isAutofocussed: this.props.isAutofocussed,
|
|
128
|
+
isReadOnly: this.props.isReadOnly,
|
|
129
|
+
onChange: this.props.onChange,
|
|
130
|
+
hasError: hasError,
|
|
131
|
+
hasHighPrecisionBadge: this.props.hasHighPrecisionBadge,
|
|
132
|
+
menuPortalTarget: this.props.menuPortalTarget,
|
|
133
|
+
menuPortalZIndex: this.props.menuPortalZIndex,
|
|
134
|
+
menuShouldBlockScroll: this.props.menuShouldBlockScroll
|
|
135
|
+
}, utils.filterDataAttributes(this.props))), jsxRuntime.jsx(FieldErrors__default["default"], {
|
|
136
|
+
errors: this.props.errors,
|
|
137
|
+
isVisible: hasError,
|
|
138
|
+
renderError: this.props.renderError
|
|
139
|
+
})]
|
|
140
|
+
})
|
|
141
|
+
});
|
|
121
142
|
}
|
|
122
143
|
}]);
|
|
123
144
|
|
|
124
145
|
return MoneyField;
|
|
125
|
-
}(
|
|
146
|
+
}(react.Component);
|
|
126
147
|
|
|
127
148
|
MoneyField.displayName = 'MoneyField';
|
|
128
149
|
MoneyField.defaultProps = {
|
|
@@ -141,20 +162,20 @@ MoneyField.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
|
141
162
|
/**
|
|
142
163
|
* Used as HTML id property. An id is auto-generated when it is not specified.
|
|
143
164
|
*/
|
|
144
|
-
id: PropTypes__default[
|
|
165
|
+
id: PropTypes__default["default"].string,
|
|
145
166
|
|
|
146
167
|
/**
|
|
147
168
|
* Horizontal size limit of the input fields.
|
|
148
169
|
*/
|
|
149
|
-
horizontalConstraint: PropTypes__default[
|
|
170
|
+
horizontalConstraint: PropTypes__default["default"].oneOf([3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 'scale', 'auto']),
|
|
150
171
|
|
|
151
172
|
/**
|
|
152
173
|
* A map of errors. Error messages for known errors are rendered automatically.
|
|
153
174
|
* <br />
|
|
154
175
|
* Unknown errors will be forwarded to `renderError`
|
|
155
176
|
*/
|
|
156
|
-
errors: PropTypes__default[
|
|
157
|
-
missing: PropTypes__default[
|
|
177
|
+
errors: PropTypes__default["default"].shape({
|
|
178
|
+
missing: PropTypes__default["default"].bool
|
|
158
179
|
}),
|
|
159
180
|
|
|
160
181
|
/**
|
|
@@ -162,31 +183,31 @@ MoneyField.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
|
162
183
|
* <br />
|
|
163
184
|
* Signature: `(key, error) => React.node`
|
|
164
185
|
*/
|
|
165
|
-
renderError: PropTypes__default[
|
|
186
|
+
renderError: PropTypes__default["default"].func,
|
|
166
187
|
|
|
167
188
|
/**
|
|
168
189
|
* Indicates if the value is required. Shows an the "required asterisk" if so.
|
|
169
190
|
*/
|
|
170
|
-
isRequired: PropTypes__default[
|
|
191
|
+
isRequired: PropTypes__default["default"].bool,
|
|
171
192
|
|
|
172
193
|
/**
|
|
173
194
|
* Indicates whether the `currencyCode` or `amount` fields were touched.
|
|
174
195
|
* <br />
|
|
175
196
|
* Errors will only be shown when the field was touched.
|
|
176
197
|
*/
|
|
177
|
-
touched: PropTypes__default[
|
|
178
|
-
amount: PropTypes__default[
|
|
179
|
-
currencyCode: PropTypes__default[
|
|
198
|
+
touched: PropTypes__default["default"].shape({
|
|
199
|
+
amount: PropTypes__default["default"].bool,
|
|
200
|
+
currencyCode: PropTypes__default["default"].bool
|
|
180
201
|
}),
|
|
181
202
|
// Some other fields use isTouched, but the check isn't as simple here.
|
|
182
203
|
// isTouched accepts a boolean, whereas touched takes an object.
|
|
183
204
|
// Maybe we should upgrade them all to just be "touched"?
|
|
184
205
|
// eslint-disable-next-line react/no-unused-prop-types
|
|
185
206
|
isTouched: function isTouched(props, propName, componentName) {
|
|
186
|
-
if (has__default[
|
|
207
|
+
if (has__default["default"](props, propName)) {
|
|
187
208
|
var _context3;
|
|
188
209
|
|
|
189
|
-
return new Error(_concatInstanceProperty__default[
|
|
210
|
+
return new Error(_concatInstanceProperty__default["default"](_context3 = "Invalid prop `".concat(propName, "` supplied to `")).call(_context3, componentName, "`. Use `touched` instead."));
|
|
190
211
|
}
|
|
191
212
|
|
|
192
213
|
return undefined;
|
|
@@ -196,95 +217,95 @@ MoneyField.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
|
196
217
|
/**
|
|
197
218
|
* Used as HTML `autocomplete` property
|
|
198
219
|
*/
|
|
199
|
-
autoComplete: PropTypes__default[
|
|
220
|
+
autoComplete: PropTypes__default["default"].string,
|
|
200
221
|
|
|
201
222
|
/**
|
|
202
223
|
* The prefix used to create a HTML `name` property for the amount input field (`${name}.amount`) and the currency dropdown (`${name}.currencyCode`).
|
|
203
224
|
*/
|
|
204
|
-
name: PropTypes__default[
|
|
225
|
+
name: PropTypes__default["default"].string,
|
|
205
226
|
|
|
206
227
|
/**
|
|
207
228
|
* Value of the input. Consists of the currency code and an amount. `amount` is a string representing the amount. A dot has to be used as the decimal separator.
|
|
208
229
|
*/
|
|
209
|
-
value: PropTypes__default[
|
|
210
|
-
amount: PropTypes__default[
|
|
211
|
-
currencyCode: PropTypes__default[
|
|
230
|
+
value: PropTypes__default["default"].shape({
|
|
231
|
+
amount: PropTypes__default["default"].string.isRequired,
|
|
232
|
+
currencyCode: PropTypes__default["default"].string.isRequired
|
|
212
233
|
}).isRequired,
|
|
213
234
|
|
|
214
235
|
/**
|
|
215
236
|
* List of possible currencies. When not provided or empty, the component renders a label with the value's currency instead of a dropdown.
|
|
216
237
|
*/
|
|
217
|
-
currencies: PropTypes__default[
|
|
238
|
+
currencies: PropTypes__default["default"].arrayOf(PropTypes__default["default"].string),
|
|
218
239
|
|
|
219
240
|
/**
|
|
220
241
|
* Placeholder text for the amount input
|
|
221
242
|
*/
|
|
222
|
-
placeholder: PropTypes__default[
|
|
243
|
+
placeholder: PropTypes__default["default"].string,
|
|
223
244
|
|
|
224
245
|
/**
|
|
225
246
|
* Called when input is blurred
|
|
226
247
|
*/
|
|
227
|
-
onBlur: PropTypes__default[
|
|
248
|
+
onBlur: PropTypes__default["default"].func,
|
|
228
249
|
|
|
229
250
|
/**
|
|
230
251
|
* Called when input is focused
|
|
231
252
|
*/
|
|
232
|
-
onFocus: PropTypes__default[
|
|
253
|
+
onFocus: PropTypes__default["default"].func,
|
|
233
254
|
|
|
234
255
|
/**
|
|
235
256
|
* Indicates that the input cannot be modified (e.g not authorized, or changes currently saving).
|
|
236
257
|
*/
|
|
237
|
-
isDisabled: PropTypes__default[
|
|
258
|
+
isDisabled: PropTypes__default["default"].bool,
|
|
238
259
|
|
|
239
260
|
/**
|
|
240
261
|
* Indicates that the field is displaying read-only content
|
|
241
262
|
*/
|
|
242
|
-
isReadOnly: PropTypes__default[
|
|
263
|
+
isReadOnly: PropTypes__default["default"].bool,
|
|
243
264
|
|
|
244
265
|
/**
|
|
245
266
|
* Focus the input on initial render
|
|
246
267
|
*/
|
|
247
|
-
isAutofocussed: PropTypes__default[
|
|
268
|
+
isAutofocussed: PropTypes__default["default"].bool,
|
|
248
269
|
|
|
249
270
|
/**
|
|
250
271
|
* Called with the event of the input or dropdown when either the currency or the amount have changed.
|
|
251
272
|
* <br />
|
|
252
273
|
* Signature: `(event) => void`
|
|
253
274
|
*/
|
|
254
|
-
onChange: PropTypes__default[
|
|
275
|
+
onChange: PropTypes__default["default"].func.isRequired,
|
|
255
276
|
|
|
256
277
|
/**
|
|
257
278
|
* Dom element to portal the currency select menu to
|
|
258
279
|
*/
|
|
259
|
-
menuPortalTarget: PropTypes__default[
|
|
280
|
+
menuPortalTarget: PropTypes__default["default"].instanceOf(utils.SafeHTMLElement),
|
|
260
281
|
|
|
261
282
|
/**
|
|
262
283
|
* z-index value for the currency select menu portal
|
|
263
284
|
*/
|
|
264
|
-
menuPortalZIndex: PropTypes__default[
|
|
285
|
+
menuPortalZIndex: PropTypes__default["default"].number,
|
|
265
286
|
|
|
266
287
|
/**
|
|
267
288
|
* whether the menu should block scroll while open
|
|
268
289
|
*/
|
|
269
|
-
menuShouldBlockScroll: PropTypes__default[
|
|
290
|
+
menuShouldBlockScroll: PropTypes__default["default"].bool,
|
|
270
291
|
// LabelField
|
|
271
292
|
|
|
272
293
|
/**
|
|
273
294
|
* Title of the label
|
|
274
295
|
*/
|
|
275
|
-
title: PropTypes__default[
|
|
296
|
+
title: PropTypes__default["default"].oneOfType([PropTypes__default["default"].string, PropTypes__default["default"].node]).isRequired,
|
|
276
297
|
|
|
277
298
|
/**
|
|
278
299
|
* Hint for the label. Provides a supplementary but important information regarding the behaviour of the input (e.g warn about uniqueness of a field, when it can only be set once), whereas `description` can describe it in more depth. Can also receive a `hintIcon`.
|
|
279
300
|
*/
|
|
280
|
-
hint: requiredIf__default[
|
|
301
|
+
hint: requiredIf__default["default"](PropTypes__default["default"].oneOfType([PropTypes__default["default"].string, PropTypes__default["default"].node]), function (props) {
|
|
281
302
|
return props.hintIcon;
|
|
282
303
|
}),
|
|
283
304
|
|
|
284
305
|
/**
|
|
285
306
|
* Provides a description for the title.
|
|
286
307
|
*/
|
|
287
|
-
description: PropTypes__default[
|
|
308
|
+
description: PropTypes__default["default"].oneOfType([PropTypes__default["default"].string, PropTypes__default["default"].node]),
|
|
288
309
|
|
|
289
310
|
/**
|
|
290
311
|
* Function called when info button is pressed.
|
|
@@ -293,24 +314,24 @@ MoneyField.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
|
293
314
|
* <br />
|
|
294
315
|
* Signature: `(event) => void`
|
|
295
316
|
*/
|
|
296
|
-
onInfoButtonClick: PropTypes__default[
|
|
317
|
+
onInfoButtonClick: PropTypes__default["default"].func,
|
|
297
318
|
|
|
298
319
|
/**
|
|
299
320
|
* Icon to be displayed beside the hint text.
|
|
300
321
|
* <br />
|
|
301
322
|
* Will only get rendered when `hint` is passed as well.
|
|
302
323
|
*/
|
|
303
|
-
hintIcon: PropTypes__default[
|
|
324
|
+
hintIcon: PropTypes__default["default"].node,
|
|
304
325
|
|
|
305
326
|
/**
|
|
306
327
|
* Shows high precision badge in case current value uses high precision.
|
|
307
328
|
*/
|
|
308
|
-
hasHighPrecisionBadge: PropTypes__default[
|
|
329
|
+
hasHighPrecisionBadge: PropTypes__default["default"].bool
|
|
309
330
|
} : {};
|
|
310
331
|
var MoneyField$1 = MoneyField;
|
|
311
332
|
|
|
312
|
-
// NOTE: This string will be replaced
|
|
313
|
-
var version =
|
|
333
|
+
// NOTE: This string will be replaced on build time with the package version.
|
|
334
|
+
var version = "12.2.6";
|
|
314
335
|
|
|
315
|
-
exports[
|
|
336
|
+
exports["default"] = MoneyField$1;
|
|
316
337
|
exports.version = version;
|
|
@@ -3,7 +3,15 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
var _Reflect$construct = require('@babel/runtime-corejs3/core-js-stable/reflect/construct');
|
|
6
|
-
var
|
|
6
|
+
var _Object$keys = require('@babel/runtime-corejs3/core-js-stable/object/keys');
|
|
7
|
+
var _Object$getOwnPropertySymbols = require('@babel/runtime-corejs3/core-js-stable/object/get-own-property-symbols');
|
|
8
|
+
var _filterInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/filter');
|
|
9
|
+
var _Object$getOwnPropertyDescriptor = require('@babel/runtime-corejs3/core-js-stable/object/get-own-property-descriptor');
|
|
10
|
+
var _forEachInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/for-each');
|
|
11
|
+
var _Object$getOwnPropertyDescriptors = require('@babel/runtime-corejs3/core-js-stable/object/get-own-property-descriptors');
|
|
12
|
+
var _Object$defineProperties = require('@babel/runtime-corejs3/core-js-stable/object/define-properties');
|
|
13
|
+
var _Object$defineProperty = require('@babel/runtime-corejs3/core-js-stable/object/define-property');
|
|
14
|
+
var _defineProperty = require('@babel/runtime-corejs3/helpers/defineProperty');
|
|
7
15
|
var _classCallCheck = require('@babel/runtime-corejs3/helpers/classCallCheck');
|
|
8
16
|
var _createClass = require('@babel/runtime-corejs3/helpers/createClass');
|
|
9
17
|
var _inherits = require('@babel/runtime-corejs3/helpers/inherits');
|
|
@@ -12,7 +20,7 @@ var _getPrototypeOf = require('@babel/runtime-corejs3/helpers/getPrototypeOf');
|
|
|
12
20
|
var _someInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/some');
|
|
13
21
|
var _Object$values = require('@babel/runtime-corejs3/core-js-stable/object/values');
|
|
14
22
|
var _concatInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/concat');
|
|
15
|
-
var
|
|
23
|
+
var react = require('react');
|
|
16
24
|
require('prop-types');
|
|
17
25
|
require('react-required-if');
|
|
18
26
|
require('lodash/has');
|
|
@@ -22,34 +30,45 @@ var Spacings = require('@commercetools-uikit/spacings');
|
|
|
22
30
|
var FieldLabel = require('@commercetools-uikit/field-label');
|
|
23
31
|
var MoneyInput = require('@commercetools-uikit/money-input');
|
|
24
32
|
var FieldErrors = require('@commercetools-uikit/field-errors');
|
|
25
|
-
var
|
|
33
|
+
var jsxRuntime = require('@emotion/react/jsx-runtime');
|
|
26
34
|
|
|
27
35
|
function _interopDefault (e) { return e && e.__esModule ? e : { 'default': e }; }
|
|
28
36
|
|
|
29
37
|
var _Reflect$construct__default = /*#__PURE__*/_interopDefault(_Reflect$construct);
|
|
38
|
+
var _Object$keys__default = /*#__PURE__*/_interopDefault(_Object$keys);
|
|
39
|
+
var _Object$getOwnPropertySymbols__default = /*#__PURE__*/_interopDefault(_Object$getOwnPropertySymbols);
|
|
40
|
+
var _filterInstanceProperty__default = /*#__PURE__*/_interopDefault(_filterInstanceProperty);
|
|
41
|
+
var _Object$getOwnPropertyDescriptor__default = /*#__PURE__*/_interopDefault(_Object$getOwnPropertyDescriptor);
|
|
42
|
+
var _forEachInstanceProperty__default = /*#__PURE__*/_interopDefault(_forEachInstanceProperty);
|
|
43
|
+
var _Object$getOwnPropertyDescriptors__default = /*#__PURE__*/_interopDefault(_Object$getOwnPropertyDescriptors);
|
|
44
|
+
var _Object$defineProperties__default = /*#__PURE__*/_interopDefault(_Object$defineProperties);
|
|
45
|
+
var _Object$defineProperty__default = /*#__PURE__*/_interopDefault(_Object$defineProperty);
|
|
30
46
|
var _someInstanceProperty__default = /*#__PURE__*/_interopDefault(_someInstanceProperty);
|
|
31
47
|
var _Object$values__default = /*#__PURE__*/_interopDefault(_Object$values);
|
|
32
48
|
var _concatInstanceProperty__default = /*#__PURE__*/_interopDefault(_concatInstanceProperty);
|
|
33
|
-
var React__default = /*#__PURE__*/_interopDefault(React);
|
|
34
49
|
var Constraints__default = /*#__PURE__*/_interopDefault(Constraints);
|
|
35
50
|
var Spacings__default = /*#__PURE__*/_interopDefault(Spacings);
|
|
36
51
|
var FieldLabel__default = /*#__PURE__*/_interopDefault(FieldLabel);
|
|
37
52
|
var MoneyInput__default = /*#__PURE__*/_interopDefault(MoneyInput);
|
|
38
53
|
var FieldErrors__default = /*#__PURE__*/_interopDefault(FieldErrors);
|
|
39
54
|
|
|
40
|
-
function
|
|
55
|
+
function ownKeys(object, enumerableOnly) { var keys = _Object$keys__default["default"](object); if (_Object$getOwnPropertySymbols__default["default"]) { var symbols = _Object$getOwnPropertySymbols__default["default"](object); if (enumerableOnly) { symbols = _filterInstanceProperty__default["default"](symbols).call(symbols, function (sym) { return _Object$getOwnPropertyDescriptor__default["default"](object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
|
|
41
56
|
|
|
42
|
-
function
|
|
57
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { var _context4; _forEachInstanceProperty__default["default"](_context4 = ownKeys(Object(source), true)).call(_context4, function (key) { _defineProperty(target, key, source[key]); }); } else if (_Object$getOwnPropertyDescriptors__default["default"]) { _Object$defineProperties__default["default"](target, _Object$getOwnPropertyDescriptors__default["default"](source)); } else { var _context5; _forEachInstanceProperty__default["default"](_context5 = ownKeys(Object(source))).call(_context5, function (key) { _Object$defineProperty__default["default"](target, key, _Object$getOwnPropertyDescriptor__default["default"](source, key)); }); } } return target; }
|
|
58
|
+
|
|
59
|
+
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = _Reflect$construct__default["default"](Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
60
|
+
|
|
61
|
+
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !_Reflect$construct__default["default"]) return false; if (_Reflect$construct__default["default"].sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(_Reflect$construct__default["default"](Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
43
62
|
var sequentialId = utils.createSequentialId('money-field-');
|
|
44
63
|
|
|
45
64
|
var hasErrors = function hasErrors(errors) {
|
|
46
65
|
var _context;
|
|
47
66
|
|
|
48
|
-
return errors && _someInstanceProperty__default[
|
|
67
|
+
return errors && _someInstanceProperty__default["default"](_context = _Object$values__default["default"](errors)).call(_context, Boolean);
|
|
49
68
|
};
|
|
50
69
|
|
|
51
|
-
var MoneyField = /*#__PURE__*/function (
|
|
52
|
-
_inherits(MoneyField,
|
|
70
|
+
var MoneyField = /*#__PURE__*/function (_Component) {
|
|
71
|
+
_inherits(MoneyField, _Component);
|
|
53
72
|
|
|
54
73
|
var _super = _createSuper(MoneyField);
|
|
55
74
|
|
|
@@ -64,7 +83,7 @@ var MoneyField = /*#__PURE__*/function (_React$Component) {
|
|
|
64
83
|
args[_key] = arguments[_key];
|
|
65
84
|
}
|
|
66
85
|
|
|
67
|
-
_this = _super.call.apply(_super, _concatInstanceProperty__default[
|
|
86
|
+
_this = _super.call.apply(_super, _concatInstanceProperty__default["default"](_context2 = [this]).call(_context2, args));
|
|
68
87
|
_this.state = {
|
|
69
88
|
// We generate an id in case no id is provided by the parent to attach the
|
|
70
89
|
// label to the input component.
|
|
@@ -79,47 +98,49 @@ var MoneyField = /*#__PURE__*/function (_React$Component) {
|
|
|
79
98
|
// MoneyInput.isTouched() ensures both fields have been touched.
|
|
80
99
|
// This avoids showing an error when the user just selected a language but
|
|
81
100
|
// didn't add an amount yet.
|
|
82
|
-
var hasError = MoneyInput__default[
|
|
83
|
-
return
|
|
84
|
-
max: this.props.horizontalConstraint
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
101
|
+
var hasError = MoneyInput__default["default"].isTouched(this.props.touched) && hasErrors(this.props.errors);
|
|
102
|
+
return jsxRuntime.jsx(Constraints__default["default"].Horizontal, {
|
|
103
|
+
max: this.props.horizontalConstraint,
|
|
104
|
+
children: jsxRuntime.jsxs(Spacings__default["default"].Stack, {
|
|
105
|
+
scale: "xs",
|
|
106
|
+
children: [jsxRuntime.jsx(FieldLabel__default["default"], {
|
|
107
|
+
title: this.props.title,
|
|
108
|
+
hint: this.props.hint,
|
|
109
|
+
description: this.props.description,
|
|
110
|
+
onInfoButtonClick: this.props.onInfoButtonClick,
|
|
111
|
+
hintIcon: this.props.hintIcon,
|
|
112
|
+
hasRequiredIndicator: this.props.isRequired,
|
|
113
|
+
htmlFor: this.state.id
|
|
114
|
+
}), jsxRuntime.jsx(MoneyInput__default["default"], _objectSpread({
|
|
115
|
+
id: this.state.id,
|
|
116
|
+
name: this.props.name,
|
|
117
|
+
autoComplete: this.props.autoComplete,
|
|
118
|
+
value: this.props.value,
|
|
119
|
+
currencies: this.props.currencies,
|
|
120
|
+
placeholder: this.props.placeholder,
|
|
121
|
+
onFocus: this.props.onFocus,
|
|
122
|
+
onBlur: this.props.onBlur,
|
|
123
|
+
isDisabled: this.props.isDisabled,
|
|
124
|
+
isAutofocussed: this.props.isAutofocussed,
|
|
125
|
+
isReadOnly: this.props.isReadOnly,
|
|
126
|
+
onChange: this.props.onChange,
|
|
127
|
+
hasError: hasError,
|
|
128
|
+
hasHighPrecisionBadge: this.props.hasHighPrecisionBadge,
|
|
129
|
+
menuPortalTarget: this.props.menuPortalTarget,
|
|
130
|
+
menuPortalZIndex: this.props.menuPortalZIndex,
|
|
131
|
+
menuShouldBlockScroll: this.props.menuShouldBlockScroll
|
|
132
|
+
}, utils.filterDataAttributes(this.props))), jsxRuntime.jsx(FieldErrors__default["default"], {
|
|
133
|
+
errors: this.props.errors,
|
|
134
|
+
isVisible: hasError,
|
|
135
|
+
renderError: this.props.renderError
|
|
136
|
+
})]
|
|
137
|
+
})
|
|
138
|
+
});
|
|
118
139
|
}
|
|
119
140
|
}]);
|
|
120
141
|
|
|
121
142
|
return MoneyField;
|
|
122
|
-
}(
|
|
143
|
+
}(react.Component);
|
|
123
144
|
|
|
124
145
|
MoneyField.displayName = 'MoneyField';
|
|
125
146
|
MoneyField.defaultProps = {
|
|
@@ -135,8 +156,8 @@ MoneyField.getDerivedStateFromProps = function (props, state) {
|
|
|
135
156
|
MoneyField.propTypes = {};
|
|
136
157
|
var MoneyField$1 = MoneyField;
|
|
137
158
|
|
|
138
|
-
// NOTE: This string will be replaced
|
|
139
|
-
var version =
|
|
159
|
+
// NOTE: This string will be replaced on build time with the package version.
|
|
160
|
+
var version = "12.2.6";
|
|
140
161
|
|
|
141
|
-
exports[
|
|
162
|
+
exports["default"] = MoneyField$1;
|
|
142
163
|
exports.version = version;
|
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
import _Reflect$construct from '@babel/runtime-corejs3/core-js-stable/reflect/construct';
|
|
2
|
-
import
|
|
2
|
+
import _Object$keys from '@babel/runtime-corejs3/core-js-stable/object/keys';
|
|
3
|
+
import _Object$getOwnPropertySymbols from '@babel/runtime-corejs3/core-js-stable/object/get-own-property-symbols';
|
|
4
|
+
import _filterInstanceProperty from '@babel/runtime-corejs3/core-js-stable/instance/filter';
|
|
5
|
+
import _Object$getOwnPropertyDescriptor from '@babel/runtime-corejs3/core-js-stable/object/get-own-property-descriptor';
|
|
6
|
+
import _forEachInstanceProperty from '@babel/runtime-corejs3/core-js-stable/instance/for-each';
|
|
7
|
+
import _Object$getOwnPropertyDescriptors from '@babel/runtime-corejs3/core-js-stable/object/get-own-property-descriptors';
|
|
8
|
+
import _Object$defineProperties from '@babel/runtime-corejs3/core-js-stable/object/define-properties';
|
|
9
|
+
import _Object$defineProperty from '@babel/runtime-corejs3/core-js-stable/object/define-property';
|
|
10
|
+
import _defineProperty from '@babel/runtime-corejs3/helpers/esm/defineProperty';
|
|
3
11
|
import _classCallCheck from '@babel/runtime-corejs3/helpers/esm/classCallCheck';
|
|
4
12
|
import _createClass from '@babel/runtime-corejs3/helpers/esm/createClass';
|
|
5
13
|
import _inherits from '@babel/runtime-corejs3/helpers/esm/inherits';
|
|
@@ -8,7 +16,7 @@ import _getPrototypeOf from '@babel/runtime-corejs3/helpers/esm/getPrototypeOf';
|
|
|
8
16
|
import _someInstanceProperty from '@babel/runtime-corejs3/core-js-stable/instance/some';
|
|
9
17
|
import _Object$values from '@babel/runtime-corejs3/core-js-stable/object/values';
|
|
10
18
|
import _concatInstanceProperty from '@babel/runtime-corejs3/core-js-stable/instance/concat';
|
|
11
|
-
import
|
|
19
|
+
import { Component } from 'react';
|
|
12
20
|
import PropTypes from 'prop-types';
|
|
13
21
|
import requiredIf from 'react-required-if';
|
|
14
22
|
import has from 'lodash/has';
|
|
@@ -18,7 +26,11 @@ import Spacings from '@commercetools-uikit/spacings';
|
|
|
18
26
|
import FieldLabel from '@commercetools-uikit/field-label';
|
|
19
27
|
import MoneyInput from '@commercetools-uikit/money-input';
|
|
20
28
|
import FieldErrors from '@commercetools-uikit/field-errors';
|
|
21
|
-
import { jsx } from '@emotion/react';
|
|
29
|
+
import { jsx, jsxs } from '@emotion/react/jsx-runtime';
|
|
30
|
+
|
|
31
|
+
function ownKeys(object, enumerableOnly) { var keys = _Object$keys(object); if (_Object$getOwnPropertySymbols) { var symbols = _Object$getOwnPropertySymbols(object); if (enumerableOnly) { symbols = _filterInstanceProperty(symbols).call(symbols, function (sym) { return _Object$getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
|
|
32
|
+
|
|
33
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { var _context4; _forEachInstanceProperty(_context4 = ownKeys(Object(source), true)).call(_context4, function (key) { _defineProperty(target, key, source[key]); }); } else if (_Object$getOwnPropertyDescriptors) { _Object$defineProperties(target, _Object$getOwnPropertyDescriptors(source)); } else { var _context5; _forEachInstanceProperty(_context5 = ownKeys(Object(source))).call(_context5, function (key) { _Object$defineProperty(target, key, _Object$getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
|
22
34
|
|
|
23
35
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = _Reflect$construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
24
36
|
|
|
@@ -31,8 +43,8 @@ var hasErrors = function hasErrors(errors) {
|
|
|
31
43
|
return errors && _someInstanceProperty(_context = _Object$values(errors)).call(_context, Boolean);
|
|
32
44
|
};
|
|
33
45
|
|
|
34
|
-
var MoneyField = /*#__PURE__*/function (
|
|
35
|
-
_inherits(MoneyField,
|
|
46
|
+
var MoneyField = /*#__PURE__*/function (_Component) {
|
|
47
|
+
_inherits(MoneyField, _Component);
|
|
36
48
|
|
|
37
49
|
var _super = _createSuper(MoneyField);
|
|
38
50
|
|
|
@@ -64,45 +76,47 @@ var MoneyField = /*#__PURE__*/function (_React$Component) {
|
|
|
64
76
|
// didn't add an amount yet.
|
|
65
77
|
var hasError = MoneyInput.isTouched(this.props.touched) && hasErrors(this.props.errors);
|
|
66
78
|
return jsx(Constraints.Horizontal, {
|
|
67
|
-
max: this.props.horizontalConstraint
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
79
|
+
max: this.props.horizontalConstraint,
|
|
80
|
+
children: jsxs(Spacings.Stack, {
|
|
81
|
+
scale: "xs",
|
|
82
|
+
children: [jsx(FieldLabel, {
|
|
83
|
+
title: this.props.title,
|
|
84
|
+
hint: this.props.hint,
|
|
85
|
+
description: this.props.description,
|
|
86
|
+
onInfoButtonClick: this.props.onInfoButtonClick,
|
|
87
|
+
hintIcon: this.props.hintIcon,
|
|
88
|
+
hasRequiredIndicator: this.props.isRequired,
|
|
89
|
+
htmlFor: this.state.id
|
|
90
|
+
}), jsx(MoneyInput, _objectSpread({
|
|
91
|
+
id: this.state.id,
|
|
92
|
+
name: this.props.name,
|
|
93
|
+
autoComplete: this.props.autoComplete,
|
|
94
|
+
value: this.props.value,
|
|
95
|
+
currencies: this.props.currencies,
|
|
96
|
+
placeholder: this.props.placeholder,
|
|
97
|
+
onFocus: this.props.onFocus,
|
|
98
|
+
onBlur: this.props.onBlur,
|
|
99
|
+
isDisabled: this.props.isDisabled,
|
|
100
|
+
isAutofocussed: this.props.isAutofocussed,
|
|
101
|
+
isReadOnly: this.props.isReadOnly,
|
|
102
|
+
onChange: this.props.onChange,
|
|
103
|
+
hasError: hasError,
|
|
104
|
+
hasHighPrecisionBadge: this.props.hasHighPrecisionBadge,
|
|
105
|
+
menuPortalTarget: this.props.menuPortalTarget,
|
|
106
|
+
menuPortalZIndex: this.props.menuPortalZIndex,
|
|
107
|
+
menuShouldBlockScroll: this.props.menuShouldBlockScroll
|
|
108
|
+
}, filterDataAttributes(this.props))), jsx(FieldErrors, {
|
|
109
|
+
errors: this.props.errors,
|
|
110
|
+
isVisible: hasError,
|
|
111
|
+
renderError: this.props.renderError
|
|
112
|
+
})]
|
|
113
|
+
})
|
|
114
|
+
});
|
|
101
115
|
}
|
|
102
116
|
}]);
|
|
103
117
|
|
|
104
118
|
return MoneyField;
|
|
105
|
-
}(
|
|
119
|
+
}(Component);
|
|
106
120
|
|
|
107
121
|
MoneyField.displayName = 'MoneyField';
|
|
108
122
|
MoneyField.defaultProps = {
|
|
@@ -289,7 +303,7 @@ MoneyField.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
|
289
303
|
} : {};
|
|
290
304
|
var MoneyField$1 = MoneyField;
|
|
291
305
|
|
|
292
|
-
// NOTE: This string will be replaced
|
|
293
|
-
var version =
|
|
306
|
+
// NOTE: This string will be replaced on build time with the package version.
|
|
307
|
+
var version = "12.2.6";
|
|
294
308
|
|
|
295
309
|
export { MoneyField$1 as default, version };
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@commercetools-uikit/money-field",
|
|
3
3
|
"description": "A controlled input component for money values with validation states and a label.",
|
|
4
|
-
"version": "12.2.
|
|
4
|
+
"version": "12.2.6",
|
|
5
5
|
"bugs": "https://github.com/commercetools/ui-kit/issues",
|
|
6
6
|
"repository": {
|
|
7
7
|
"type": "git",
|
|
@@ -11,7 +11,6 @@
|
|
|
11
11
|
"homepage": "https://uikit.commercetools.com",
|
|
12
12
|
"keywords": ["javascript", "design system", "react", "uikit"],
|
|
13
13
|
"license": "MIT",
|
|
14
|
-
"private": false,
|
|
15
14
|
"publishConfig": {
|
|
16
15
|
"access": "public"
|
|
17
16
|
},
|
|
@@ -19,19 +18,16 @@
|
|
|
19
18
|
"main": "dist/commercetools-uikit-money-field.cjs.js",
|
|
20
19
|
"module": "dist/commercetools-uikit-money-field.esm.js",
|
|
21
20
|
"files": ["dist"],
|
|
22
|
-
"scripts": {
|
|
23
|
-
"prepare": "../../../../scripts/version.js replace"
|
|
24
|
-
},
|
|
25
21
|
"dependencies": {
|
|
26
|
-
"@babel/runtime": "7.
|
|
27
|
-
"@babel/runtime-corejs3": "7.
|
|
28
|
-
"@commercetools-uikit/constraints": "12.2.
|
|
29
|
-
"@commercetools-uikit/design-system": "12.2.
|
|
30
|
-
"@commercetools-uikit/field-errors": "12.2.
|
|
31
|
-
"@commercetools-uikit/field-label": "12.2.
|
|
32
|
-
"@commercetools-uikit/money-input": "12.2.
|
|
33
|
-
"@commercetools-uikit/spacings": "12.2.
|
|
34
|
-
"@commercetools-uikit/utils": "12.2.
|
|
22
|
+
"@babel/runtime": "7.16.3",
|
|
23
|
+
"@babel/runtime-corejs3": "7.16.3",
|
|
24
|
+
"@commercetools-uikit/constraints": "12.2.5",
|
|
25
|
+
"@commercetools-uikit/design-system": "12.2.5",
|
|
26
|
+
"@commercetools-uikit/field-errors": "12.2.5",
|
|
27
|
+
"@commercetools-uikit/field-label": "12.2.6",
|
|
28
|
+
"@commercetools-uikit/money-input": "12.2.6",
|
|
29
|
+
"@commercetools-uikit/spacings": "12.2.5",
|
|
30
|
+
"@commercetools-uikit/utils": "12.2.5",
|
|
35
31
|
"@emotion/react": "^11.4.0",
|
|
36
32
|
"@emotion/styled": "^11.3.0",
|
|
37
33
|
"lodash": "4.17.21",
|