@commercetools-uikit/field-label 19.9.0 → 19.10.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.
@@ -129,7 +129,7 @@ FieldLabel.defaultProps = {
129
129
  var FieldLabel$1 = FieldLabel;
130
130
 
131
131
  // NOTE: This string will be replaced on build time with the package version.
132
- var version = "19.9.0";
132
+ var version = "19.10.0";
133
133
 
134
134
  exports["default"] = FieldLabel$1;
135
135
  exports.version = version;
@@ -104,7 +104,7 @@ FieldLabel.defaultProps = {
104
104
  var FieldLabel$1 = FieldLabel;
105
105
 
106
106
  // NOTE: This string will be replaced on build time with the package version.
107
- var version = "19.9.0";
107
+ var version = "19.10.0";
108
108
 
109
109
  exports["default"] = FieldLabel$1;
110
110
  exports.version = version;
@@ -115,6 +115,6 @@ FieldLabel.defaultProps = {
115
115
  var FieldLabel$1 = FieldLabel;
116
116
 
117
117
  // NOTE: This string will be replaced on build time with the package version.
118
- var version = "19.9.0";
118
+ var version = "19.10.0";
119
119
 
120
120
  export { FieldLabel$1 as default, version };
@@ -1,15 +1,48 @@
1
1
  import { MouseEvent, KeyboardEvent, ReactElement, ReactNode } from 'react';
2
2
  export type TFieldLabelProps = {
3
+ /**
4
+ * Title of the label
5
+ */
3
6
  title: string | ReactNode;
7
+ /**
8
+ * 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.
9
+ */
4
10
  hint?: string | ReactNode;
11
+ /**
12
+ * Provides a description for the title.
13
+ */
5
14
  description?: string | ReactNode;
15
+ /**
16
+ * Function called when info button is pressed. Info button will only be visible when this prop is passed.
17
+ */
6
18
  onInfoButtonClick?: (event: MouseEvent<HTMLButtonElement> | KeyboardEvent<HTMLButtonElement>) => void;
19
+ /**
20
+ * Indicates the tone to be applied to the label
21
+ */
7
22
  tone?: 'primary' | 'inverted';
23
+ /**
24
+ * Icon to be displayed beside the hint text. Will only get rendered when hint is passed as well.
25
+ */
8
26
  hintIcon?: ReactElement;
27
+ /**
28
+ * Badge to be displayed beside the label. Might be used to display additional information about the content of the field (E.g verified email)
29
+ */
9
30
  badge?: ReactNode;
31
+ /**
32
+ * Indicates if the labeled field is required in a form
33
+ */
10
34
  hasRequiredIndicator?: boolean;
35
+ /**
36
+ * The for HTML attribute, used to reference form elements with the related attribute id or aria-labelledby.
37
+ */
11
38
  htmlFor?: string;
39
+ /**
40
+ * The id HTML attribute, used to reference non-form elements with the related attribute aria-labelledby.
41
+ */
12
42
  id?: string;
43
+ /**
44
+ * Horizontal size limit of the label.
45
+ */
13
46
  horizontalConstraint?: 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 'scale' | 'auto';
14
47
  };
15
48
  declare const FieldLabel: {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@commercetools-uikit/field-label",
3
3
  "description": "The FieldLabel component represents the label for a field in a form.",
4
- "version": "19.9.0",
4
+ "version": "19.10.0",
5
5
  "bugs": "https://github.com/commercetools/ui-kit/issues",
6
6
  "repository": {
7
7
  "type": "git",
@@ -21,16 +21,16 @@
21
21
  "dependencies": {
22
22
  "@babel/runtime": "^7.20.13",
23
23
  "@babel/runtime-corejs3": "^7.20.13",
24
- "@commercetools-uikit/constraints": "19.9.0",
25
- "@commercetools-uikit/design-system": "19.9.0",
26
- "@commercetools-uikit/icon-button": "19.9.0",
27
- "@commercetools-uikit/icons": "19.9.0",
28
- "@commercetools-uikit/label": "19.9.0",
29
- "@commercetools-uikit/secondary-icon-button": "19.9.0",
30
- "@commercetools-uikit/spacings-inline": "19.9.0",
31
- "@commercetools-uikit/spacings-stack": "19.9.0",
32
- "@commercetools-uikit/text": "19.9.0",
33
- "@commercetools-uikit/utils": "19.9.0",
24
+ "@commercetools-uikit/constraints": "19.10.0",
25
+ "@commercetools-uikit/design-system": "19.10.0",
26
+ "@commercetools-uikit/icon-button": "19.10.0",
27
+ "@commercetools-uikit/icons": "19.10.0",
28
+ "@commercetools-uikit/label": "19.10.0",
29
+ "@commercetools-uikit/secondary-icon-button": "19.10.0",
30
+ "@commercetools-uikit/spacings-inline": "19.10.0",
31
+ "@commercetools-uikit/spacings-stack": "19.10.0",
32
+ "@commercetools-uikit/text": "19.10.0",
33
+ "@commercetools-uikit/utils": "19.10.0",
34
34
  "@emotion/react": "^11.10.5",
35
35
  "@emotion/styled": "^11.10.5",
36
36
  "prop-types": "15.8.1",