@commercetools-uikit/label 12.2.3 → 13.0.0
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-uikit-label.cjs.dev.js +13 -13
- package/dist/commercetools-uikit-label.cjs.prod.js +6 -6
- package/dist/commercetools-uikit-label.esm.js +4 -4
- package/dist/declarations/src/index.d.ts +2 -2
- package/dist/declarations/src/label.d.ts +16 -16
- package/dist/declarations/src/required-indicator.d.ts +5 -5
- package/dist/declarations/src/version.d.ts +2 -2
- package/package.json +8 -12
|
@@ -43,9 +43,9 @@ var RequiredIndicator = function RequiredIndicator() {
|
|
|
43
43
|
RequiredIndicator.displayName = 'RequiredIndicator';
|
|
44
44
|
var RequiredIndicator$1 = RequiredIndicator;
|
|
45
45
|
|
|
46
|
-
function ownKeys(object, enumerableOnly) { var keys = _Object$keys__default[
|
|
46
|
+
function ownKeys(object, enumerableOnly) { var keys = _Object$keys__default["default"](object); if (_Object$getOwnPropertySymbols__default["default"]) { var symbols = _Object$getOwnPropertySymbols__default["default"](object); 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; }
|
|
47
47
|
|
|
48
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]
|
|
48
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var _context, _context2; var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys(Object(source), !0)).call(_context, function (key) { _defineProperty(target, key, source[key]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](target, _Object$getOwnPropertyDescriptors__default["default"](source)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys(Object(source))).call(_context2, function (key) { _Object$defineProperty__default["default"](target, key, _Object$getOwnPropertyDescriptor__default["default"](source, key)); }); } return target; }
|
|
49
49
|
|
|
50
50
|
var Label = function Label(props) {
|
|
51
51
|
process.env.NODE_ENV !== "production" ? utils.warning(!(Boolean(props.id) && Boolean(props.htmlFor)), "ui-kit/Label: provide only the \"id\" or the \"htmlFor\" properties, not both.") : void 0;
|
|
@@ -54,7 +54,7 @@ var Label = function Label(props) {
|
|
|
54
54
|
return jsxRuntime.jsx("label", {
|
|
55
55
|
id: props.id,
|
|
56
56
|
htmlFor: props.htmlFor,
|
|
57
|
-
children: jsxRuntime.jsxs(Text__default[
|
|
57
|
+
children: jsxRuntime.jsxs(Text__default["default"].Body, {
|
|
58
58
|
tone: props.tone,
|
|
59
59
|
isBold: props.isBold,
|
|
60
60
|
children: [props.intlMessage ? jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread({}, props.intlMessage)) : props.children, props.isRequiredIndicatorVisible && jsxRuntime.jsx(RequiredIndicator$1, {})]
|
|
@@ -63,19 +63,19 @@ var Label = function Label(props) {
|
|
|
63
63
|
};
|
|
64
64
|
|
|
65
65
|
Label.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
66
|
-
id: _pt__default[
|
|
67
|
-
htmlFor: _pt__default[
|
|
68
|
-
isBold: _pt__default[
|
|
69
|
-
isRequiredIndicatorVisible: _pt__default[
|
|
70
|
-
tone: _pt__default[
|
|
71
|
-
intlMessage: _pt__default[
|
|
72
|
-
children: _pt__default[
|
|
66
|
+
id: _pt__default["default"].string,
|
|
67
|
+
htmlFor: _pt__default["default"].string,
|
|
68
|
+
isBold: _pt__default["default"].bool,
|
|
69
|
+
isRequiredIndicatorVisible: _pt__default["default"].bool,
|
|
70
|
+
tone: _pt__default["default"].oneOf(['primary', 'inverted']),
|
|
71
|
+
intlMessage: _pt__default["default"].any,
|
|
72
|
+
children: _pt__default["default"].node
|
|
73
73
|
} : {};
|
|
74
74
|
Label.displayName = 'Label';
|
|
75
75
|
var Label$1 = Label;
|
|
76
76
|
|
|
77
|
-
// NOTE: This string will be replaced
|
|
78
|
-
var version =
|
|
77
|
+
// NOTE: This string will be replaced on build time with the package version.
|
|
78
|
+
var version = "13.0.0";
|
|
79
79
|
|
|
80
|
-
exports[
|
|
80
|
+
exports["default"] = Label$1;
|
|
81
81
|
exports.version = version;
|
|
@@ -42,16 +42,16 @@ var RequiredIndicator = function RequiredIndicator() {
|
|
|
42
42
|
RequiredIndicator.displayName = 'RequiredIndicator';
|
|
43
43
|
var RequiredIndicator$1 = RequiredIndicator;
|
|
44
44
|
|
|
45
|
-
function ownKeys(object, enumerableOnly) { var keys = _Object$keys__default[
|
|
45
|
+
function ownKeys(object, enumerableOnly) { var keys = _Object$keys__default["default"](object); if (_Object$getOwnPropertySymbols__default["default"]) { var symbols = _Object$getOwnPropertySymbols__default["default"](object); 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; }
|
|
46
46
|
|
|
47
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]
|
|
47
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var _context, _context2; var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys(Object(source), !0)).call(_context, function (key) { _defineProperty(target, key, source[key]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](target, _Object$getOwnPropertyDescriptors__default["default"](source)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys(Object(source))).call(_context2, function (key) { _Object$defineProperty__default["default"](target, key, _Object$getOwnPropertyDescriptor__default["default"](source, key)); }); } return target; }
|
|
48
48
|
|
|
49
49
|
var Label = function Label(props) {
|
|
50
50
|
props.intlMessage || Boolean(react$1.Children.count(props.children));
|
|
51
51
|
return jsxRuntime.jsx("label", {
|
|
52
52
|
id: props.id,
|
|
53
53
|
htmlFor: props.htmlFor,
|
|
54
|
-
children: jsxRuntime.jsxs(Text__default[
|
|
54
|
+
children: jsxRuntime.jsxs(Text__default["default"].Body, {
|
|
55
55
|
tone: props.tone,
|
|
56
56
|
isBold: props.isBold,
|
|
57
57
|
children: [props.intlMessage ? jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread({}, props.intlMessage)) : props.children, props.isRequiredIndicatorVisible && jsxRuntime.jsx(RequiredIndicator$1, {})]
|
|
@@ -63,8 +63,8 @@ Label.propTypes = {};
|
|
|
63
63
|
Label.displayName = 'Label';
|
|
64
64
|
var Label$1 = Label;
|
|
65
65
|
|
|
66
|
-
// NOTE: This string will be replaced
|
|
67
|
-
var version =
|
|
66
|
+
// NOTE: This string will be replaced on build time with the package version.
|
|
67
|
+
var version = "13.0.0";
|
|
68
68
|
|
|
69
|
-
exports[
|
|
69
|
+
exports["default"] = Label$1;
|
|
70
70
|
exports.version = version;
|
|
@@ -26,9 +26,9 @@ var RequiredIndicator = function RequiredIndicator() {
|
|
|
26
26
|
RequiredIndicator.displayName = 'RequiredIndicator';
|
|
27
27
|
var RequiredIndicator$1 = RequiredIndicator;
|
|
28
28
|
|
|
29
|
-
function ownKeys(object, enumerableOnly) { var keys = _Object$keys(object); if (_Object$getOwnPropertySymbols) { var symbols = _Object$getOwnPropertySymbols(object);
|
|
29
|
+
function ownKeys(object, enumerableOnly) { var keys = _Object$keys(object); if (_Object$getOwnPropertySymbols) { var symbols = _Object$getOwnPropertySymbols(object); enumerableOnly && (symbols = _filterInstanceProperty(symbols).call(symbols, function (sym) { return _Object$getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
30
30
|
|
|
31
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]
|
|
31
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var _context, _context2; var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? _forEachInstanceProperty(_context = ownKeys(Object(source), !0)).call(_context, function (key) { _defineProperty(target, key, source[key]); }) : _Object$getOwnPropertyDescriptors ? _Object$defineProperties(target, _Object$getOwnPropertyDescriptors(source)) : _forEachInstanceProperty(_context2 = ownKeys(Object(source))).call(_context2, function (key) { _Object$defineProperty(target, key, _Object$getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
32
32
|
|
|
33
33
|
var Label = function Label(props) {
|
|
34
34
|
process.env.NODE_ENV !== "production" ? warning(!(Boolean(props.id) && Boolean(props.htmlFor)), "ui-kit/Label: provide only the \"id\" or the \"htmlFor\" properties, not both.") : void 0;
|
|
@@ -57,7 +57,7 @@ Label.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
|
57
57
|
Label.displayName = 'Label';
|
|
58
58
|
var Label$1 = Label;
|
|
59
59
|
|
|
60
|
-
// NOTE: This string will be replaced
|
|
61
|
-
var version =
|
|
60
|
+
// NOTE: This string will be replaced on build time with the package version.
|
|
61
|
+
var version = "13.0.0";
|
|
62
62
|
|
|
63
63
|
export { Label$1 as default, version };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { default } from './label';
|
|
2
|
-
export { default as version } from './version';
|
|
1
|
+
export { default } from './label';
|
|
2
|
+
export { default as version } from './version';
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import type { MessageDescriptor } from 'react-intl';
|
|
2
|
-
import { ReactNode } from 'react';
|
|
3
|
-
declare type TLabelProps = {
|
|
4
|
-
id?: string;
|
|
5
|
-
htmlFor?: string;
|
|
6
|
-
isBold?: boolean;
|
|
7
|
-
isRequiredIndicatorVisible?: boolean;
|
|
8
|
-
tone?: 'primary' | 'inverted';
|
|
9
|
-
intlMessage?: MessageDescriptor;
|
|
10
|
-
children?: ReactNode;
|
|
11
|
-
};
|
|
12
|
-
declare const Label: {
|
|
13
|
-
(props: TLabelProps): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
14
|
-
displayName: string;
|
|
15
|
-
};
|
|
16
|
-
export default Label;
|
|
1
|
+
import type { MessageDescriptor } from 'react-intl';
|
|
2
|
+
import { ReactNode } from 'react';
|
|
3
|
+
declare type TLabelProps = {
|
|
4
|
+
id?: string;
|
|
5
|
+
htmlFor?: string;
|
|
6
|
+
isBold?: boolean;
|
|
7
|
+
isRequiredIndicatorVisible?: boolean;
|
|
8
|
+
tone?: 'primary' | 'inverted';
|
|
9
|
+
intlMessage?: MessageDescriptor;
|
|
10
|
+
children?: ReactNode;
|
|
11
|
+
};
|
|
12
|
+
declare const Label: {
|
|
13
|
+
(props: TLabelProps): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
14
|
+
displayName: string;
|
|
15
|
+
};
|
|
16
|
+
export default Label;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
declare const RequiredIndicator: {
|
|
2
|
-
(): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
3
|
-
displayName: string;
|
|
4
|
-
};
|
|
5
|
-
export default RequiredIndicator;
|
|
1
|
+
declare const RequiredIndicator: {
|
|
2
|
+
(): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
3
|
+
displayName: string;
|
|
4
|
+
};
|
|
5
|
+
export default RequiredIndicator;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
declare const _default: "
|
|
2
|
-
export default _default;
|
|
1
|
+
declare const _default: "__@UI_KIT_PACKAGE/VERSION_OF_RELEASE__";
|
|
2
|
+
export default _default;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@commercetools-uikit/label",
|
|
3
3
|
"description": "The Label component represents the primitive label for a form field component.",
|
|
4
|
-
"version": "
|
|
4
|
+
"version": "13.0.0",
|
|
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,22 +18,19 @@
|
|
|
19
18
|
"main": "dist/commercetools-uikit-label.cjs.js",
|
|
20
19
|
"module": "dist/commercetools-uikit-label.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/design-system": "
|
|
29
|
-
"@commercetools-uikit/text": "
|
|
30
|
-
"@commercetools-uikit/utils": "12.2.
|
|
22
|
+
"@babel/runtime": "7.17.2",
|
|
23
|
+
"@babel/runtime-corejs3": "7.17.2",
|
|
24
|
+
"@commercetools-uikit/design-system": "13.0.0",
|
|
25
|
+
"@commercetools-uikit/text": "13.0.0",
|
|
26
|
+
"@commercetools-uikit/utils": "12.2.9",
|
|
31
27
|
"@emotion/react": "^11.4.0",
|
|
32
28
|
"@emotion/styled": "^11.3.0",
|
|
33
|
-
"prop-types": "15.
|
|
29
|
+
"prop-types": "15.8.1"
|
|
34
30
|
},
|
|
35
31
|
"devDependencies": {
|
|
36
32
|
"react": "17.0.2",
|
|
37
|
-
"react-intl": "5.
|
|
33
|
+
"react-intl": "5.24.6"
|
|
38
34
|
},
|
|
39
35
|
"peerDependencies": {
|
|
40
36
|
"react": "17.x",
|