@instructure/ui-form-field 7.7.1 → 7.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.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,22 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # [7.11.0](https://github.com/instructure/instructure-ui/compare/v7.10.0...v7.11.0) (2021-09-17)
7
+
8
+ **Note:** Version bump only for package @instructure/ui-form-field
9
+
10
+ # [7.10.0](https://github.com/instructure/instructure-ui/compare/v7.9.0...v7.10.0) (2021-08-27)
11
+
12
+ **Note:** Version bump only for package @instructure/ui-form-field
13
+
14
+ # [7.9.0](https://github.com/instructure/instructure-ui/compare/v7.8.0...v7.9.0) (2021-07-16)
15
+
16
+ **Note:** Version bump only for package @instructure/ui-form-field
17
+
18
+ # [7.8.0](https://github.com/instructure/instructure-ui/compare/v7.7.1...v7.8.0) (2021-06-18)
19
+
20
+ **Note:** Version bump only for package @instructure/ui-form-field
21
+
6
22
  ## [7.7.1](https://github.com/instructure/instructure-ui/compare/v7.7.0...v7.7.1) (2021-06-09)
7
23
 
8
24
  **Note:** Version bump only for package @instructure/ui-form-field
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@instructure/ui-form-field",
3
- "version": "7.7.1",
3
+ "version": "7.11.0",
4
4
  "description": "Form layout components.",
5
5
  "author": "Instructure, Inc. Engineering and Product Design",
6
6
  "type": "commonjs",
@@ -23,20 +23,20 @@
23
23
  },
24
24
  "license": "MIT",
25
25
  "devDependencies": {
26
- "@instructure/ui-babel-preset": "^7.7.1",
27
- "@instructure/ui-test-utils": "^7.7.1"
26
+ "@instructure/ui-babel-preset": "^7.11.0",
27
+ "@instructure/ui-test-utils": "^7.11.0"
28
28
  },
29
29
  "dependencies": {
30
30
  "@babel/runtime": "^7.9.2",
31
- "@instructure/console": "^7.7.1",
32
- "@instructure/ui-a11y-content": "^7.7.1",
33
- "@instructure/ui-a11y-utils": "^7.7.1",
34
- "@instructure/ui-grid": "^7.7.1",
35
- "@instructure/ui-icons": "^7.7.1",
36
- "@instructure/ui-react-utils": "^7.7.1",
37
- "@instructure/ui-themeable": "^7.7.1",
38
- "@instructure/ui-utils": "^7.7.1",
39
- "@instructure/uid": "^7.7.1",
31
+ "@instructure/console": "^7.11.0",
32
+ "@instructure/ui-a11y-content": "^7.11.0",
33
+ "@instructure/ui-a11y-utils": "^7.11.0",
34
+ "@instructure/ui-grid": "^7.11.0",
35
+ "@instructure/ui-icons": "^7.11.0",
36
+ "@instructure/ui-react-utils": "^7.11.0",
37
+ "@instructure/ui-themeable": "^7.11.0",
38
+ "@instructure/ui-utils": "^7.11.0",
39
+ "@instructure/uid": "^7.11.0",
40
40
  "classnames": "^2",
41
41
  "prop-types": "^15"
42
42
  },
package/types/index.d.ts CHANGED
@@ -1,17 +1,21 @@
1
1
  import * as React from 'react';
2
2
 
3
- export type FormFieldLayout = "stacked" | "inline";
3
+ export type FormFieldGroupLayout = "stacked" | "columns" | "inline";
4
4
 
5
- export type FormFieldLabelAlign = "start" | "end";
5
+ export type FormFieldGroupRowSpacing = "none" | "small" | "medium" | "large";
6
6
 
7
- export type FormFieldVAlign = "top" | "middle" | "bottom";
7
+ export type FormFieldGroupColSpacing = "none" | "small" | "medium" | "large";
8
8
 
9
- export interface FormFieldProps {
10
- label: React.ReactNode;
9
+ export type FormFieldGroupVAlign = "top" | "middle" | "bottom";
10
+
11
+ export type FormFieldGroupStartAt = "small" | "medium" | "large" | "x-large" | any;
12
+
13
+ export interface FormFieldGroupProps {
14
+ description: React.ReactNode;
11
15
  /**
12
- * the id of the input (to link it to its label for a11y)
16
+ * the element type to render as
13
17
  */
14
- id: string;
18
+ as?: any;
15
19
  /**
16
20
  * object with shape: `{
17
21
  * text: PropTypes.string,
@@ -19,17 +23,20 @@ export interface FormFieldProps {
19
23
  * }`
20
24
  */
21
25
  messages?: any[];
26
+ /**
27
+ * id for the form field messages
28
+ */
22
29
  messagesId?: string;
30
+ disabled?: boolean;
23
31
  children?: React.ReactNode;
24
- inline?: boolean;
25
- layout?: FormFieldLayout;
26
- labelAlign?: FormFieldLabelAlign;
27
- vAlign?: FormFieldVAlign;
28
- width?: string;
29
- inputContainerRef?: (...args: any[])=>any;
32
+ layout?: FormFieldGroupLayout;
33
+ rowSpacing?: FormFieldGroupRowSpacing;
34
+ colSpacing?: FormFieldGroupColSpacing;
35
+ vAlign?: FormFieldGroupVAlign;
36
+ startAt?: FormFieldGroupStartAt;
30
37
  }
31
38
 
32
- export class FormField extends React.Component<FormFieldProps, any> {
39
+ export class FormFieldGroup extends React.Component<FormFieldGroupProps, any> {
33
40
  render(): JSX.Element;
34
41
 
35
42
  }
@@ -37,22 +44,18 @@ export class FormField extends React.Component<FormFieldProps, any> {
37
44
 
38
45
 
39
46
 
40
- export type FormFieldGroupLayout = "stacked" | "columns" | "inline";
41
-
42
- export type FormFieldGroupRowSpacing = "none" | "small" | "medium" | "large";
43
-
44
- export type FormFieldGroupColSpacing = "none" | "small" | "medium" | "large";
47
+ export type FormFieldLayout = "stacked" | "inline";
45
48
 
46
- export type FormFieldGroupVAlign = "top" | "middle" | "bottom";
49
+ export type FormFieldLabelAlign = "start" | "end";
47
50
 
48
- export type FormFieldGroupStartAt = "small" | "medium" | "large" | "x-large" | any;
51
+ export type FormFieldVAlign = "top" | "middle" | "bottom";
49
52
 
50
- export interface FormFieldGroupProps {
51
- description: React.ReactNode;
53
+ export interface FormFieldProps {
54
+ label: React.ReactNode;
52
55
  /**
53
- * the element type to render as
56
+ * the id of the input (to link it to its label for a11y)
54
57
  */
55
- as?: any;
58
+ id: string;
56
59
  /**
57
60
  * object with shape: `{
58
61
  * text: PropTypes.string,
@@ -60,20 +63,17 @@ export interface FormFieldGroupProps {
60
63
  * }`
61
64
  */
62
65
  messages?: any[];
63
- /**
64
- * id for the form field messages
65
- */
66
66
  messagesId?: string;
67
- disabled?: boolean;
68
67
  children?: React.ReactNode;
69
- layout?: FormFieldGroupLayout;
70
- rowSpacing?: FormFieldGroupRowSpacing;
71
- colSpacing?: FormFieldGroupColSpacing;
72
- vAlign?: FormFieldGroupVAlign;
73
- startAt?: FormFieldGroupStartAt;
68
+ inline?: boolean;
69
+ layout?: FormFieldLayout;
70
+ labelAlign?: FormFieldLabelAlign;
71
+ vAlign?: FormFieldVAlign;
72
+ width?: string;
73
+ inputContainerRef?: (...args: any[])=>any;
74
74
  }
75
75
 
76
- export class FormFieldGroup extends React.Component<FormFieldGroupProps, any> {
76
+ export class FormField extends React.Component<FormFieldProps, any> {
77
77
  render(): JSX.Element;
78
78
 
79
79
  }