@commercetools-uikit/label 19.9.0 → 19.11.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.
@@ -88,7 +88,7 @@ Label.displayName = 'Label';
88
88
  var Label$1 = Label;
89
89
 
90
90
  // NOTE: This string will be replaced on build time with the package version.
91
- var version = "19.9.0";
91
+ var version = "19.11.0";
92
92
 
93
93
  exports["default"] = Label$1;
94
94
  exports.version = version;
@@ -68,7 +68,7 @@ Label.displayName = 'Label';
68
68
  var Label$1 = Label;
69
69
 
70
70
  // NOTE: This string will be replaced on build time with the package version.
71
- var version = "19.9.0";
71
+ var version = "19.11.0";
72
72
 
73
73
  exports["default"] = Label$1;
74
74
  exports.version = version;
@@ -71,6 +71,6 @@ Label.displayName = 'Label';
71
71
  var Label$1 = Label;
72
72
 
73
73
  // NOTE: This string will be replaced on build time with the package version.
74
- var version = "19.9.0";
74
+ var version = "19.11.0";
75
75
 
76
76
  export { Label$1 as default, version };
@@ -1,15 +1,55 @@
1
1
  import type { MessageDescriptor } from 'react-intl';
2
2
  import { type ReactNode } from 'react';
3
3
  export type TLabelProps = {
4
+ /**
5
+ * The `id` HTML attribute, used to reference non-form elements with the related attribute `aria-labelledby`.
6
+ * <br/>
7
+ * Use this to set the relationships between the label and a non-form element.
8
+ * <br />
9
+ * For example:
10
+ * ````
11
+ * <label id="foo">
12
+ * <div aria-labelledby="foo">
13
+ * ````
14
+ */
4
15
  id?: string;
16
+ /**
17
+ * The `for` HTML attribute, used to reference form elements with the related attribute `id` or `aria-labelledby`.
18
+ * <br />
19
+ * Use this to set the relationships between the label and a form element.
20
+ * <br />
21
+ * For example:
22
+ * ````
23
+ * <label for="foo">
24
+ * <input id="foo">
25
+ *
26
+ * <label id="foo">
27
+ * <input aria-labelledby="foo">
28
+ * ````
29
+ */
5
30
  htmlFor?: string;
6
31
  fontWeight?: 'medium' | 'bold';
32
+ /**
33
+ * @deprecated: Use the new `fontWeight` prop.
34
+ */
7
35
  isBold?: boolean;
8
36
  isRequiredIndicatorVisible?: boolean;
9
37
  tone?: 'primary' | 'inverted';
38
+ /**
39
+ * A `MessageDescriptor` rendered `children` to `Label`.
40
+ * <br />
41
+ * When a value is provided, `intlMessage` will be rendered instead of `children`
42
+ * <br />
43
+ * This is required when `children` is `undefined` and vice versa
44
+ */
10
45
  intlMessage?: MessageDescriptor & {
11
46
  values?: Record<string, ReactNode>;
12
47
  };
48
+ /**
49
+ * Rendered as `children` to `Label`.
50
+ * <br />
51
+ * This is required when `intlMessage` is `undefined` and vice versa
52
+ */
13
53
  children?: ReactNode;
14
54
  };
15
55
  declare const Label: {
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": "19.9.0",
4
+ "version": "19.11.0",
5
5
  "bugs": "https://github.com/commercetools/ui-kit/issues",
6
6
  "repository": {
7
7
  "type": "git",
@@ -21,9 +21,9 @@
21
21
  "dependencies": {
22
22
  "@babel/runtime": "^7.20.13",
23
23
  "@babel/runtime-corejs3": "^7.20.13",
24
- "@commercetools-uikit/design-system": "19.9.0",
25
- "@commercetools-uikit/text": "19.9.0",
26
- "@commercetools-uikit/utils": "19.9.0",
24
+ "@commercetools-uikit/design-system": "19.11.0",
25
+ "@commercetools-uikit/text": "19.11.0",
26
+ "@commercetools-uikit/utils": "19.11.0",
27
27
  "@emotion/react": "^11.10.5",
28
28
  "@emotion/styled": "^11.10.5",
29
29
  "prop-types": "15.8.1"