Skip to content

Commit

Permalink
[docs] Update TextField multiline description (#31291)
Browse files Browse the repository at this point in the history
  • Loading branch information
jontewks committed Mar 9, 2022
1 parent 62c9b03 commit 3fa0a45
Show file tree
Hide file tree
Showing 10 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion docs/data/material/components/text-fields/text-fields.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ The `helperText` prop can then be used to provide feedback to the user about the

## Multiline

The `multiline` prop transforms the text field into a [`<textarea>`](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/textarea) element.
The `multiline` prop transforms the text field into a [TextareaAutosize](/components/textarea-autosize/) element.
Unless the `rows` prop is set, the height of the text field dynamically matches its content (using [TextareaAutosize](/components/textarea-autosize/)).
You can use the `minRows` and `maxRows` props to bound it.

Expand Down
2 changes: 1 addition & 1 deletion docs/translations/api-docs/filled-input/filled-input.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
"margin": "If <code>dense</code>, will adjust vertical spacing. This is normally obtained via context from FormControl. The prop defaults to the value (<code>&#39;none&#39;</code>) inherited from the parent FormControl component.",
"maxRows": "Maximum number of rows to display when multiline option is set to true.",
"minRows": "Minimum number of rows to display when multiline option is set to true.",
"multiline": "If <code>true</code>, a <code>textarea</code> element is rendered.",
"multiline": "If <code>true</code>, a <a href=\"/components/textarea-autosize/\">TextareaAutosize</a> element is rendered.",
"name": "Name attribute of the <code>input</code> element.",
"onChange": "Callback fired when the value is changed.<br><br><strong>Signature:</strong><br><code>function(event: React.ChangeEvent&lt;HTMLTextAreaElement | HTMLInputElement&gt;) =&gt; void</code><br><em>event:</em> The event source of the callback. You can pull out the new value by accessing <code>event.target.value</code> (string).",
"placeholder": "The short hint displayed in the <code>input</code> before the user enters a value.",
Expand Down
2 changes: 1 addition & 1 deletion docs/translations/api-docs/input-base/input-base.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
"margin": "If <code>dense</code>, will adjust vertical spacing. This is normally obtained via context from FormControl. The prop defaults to the value (<code>&#39;none&#39;</code>) inherited from the parent FormControl component.",
"maxRows": "Maximum number of rows to display when multiline option is set to true.",
"minRows": "Minimum number of rows to display when multiline option is set to true.",
"multiline": "If <code>true</code>, a <code>textarea</code> element is rendered.",
"multiline": "If <code>true</code>, a <a href=\"/components/textarea-autosize/\">TextareaAutosize</a> element is rendered.",
"name": "Name attribute of the <code>input</code> element.",
"onBlur": "Callback fired when the <code>input</code> is blurred.<br>Notice that the first argument (event) might be undefined.",
"onChange": "Callback fired when the value is changed.<br><br><strong>Signature:</strong><br><code>function(event: React.ChangeEvent&lt;HTMLTextAreaElement | HTMLInputElement&gt;) =&gt; void</code><br><em>event:</em> The event source of the callback. You can pull out the new value by accessing <code>event.target.value</code> (string).",
Expand Down
2 changes: 1 addition & 1 deletion docs/translations/api-docs/input/input.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
"margin": "If <code>dense</code>, will adjust vertical spacing. This is normally obtained via context from FormControl. The prop defaults to the value (<code>&#39;none&#39;</code>) inherited from the parent FormControl component.",
"maxRows": "Maximum number of rows to display when multiline option is set to true.",
"minRows": "Minimum number of rows to display when multiline option is set to true.",
"multiline": "If <code>true</code>, a <code>textarea</code> element is rendered.",
"multiline": "If <code>true</code>, a <a href=\"/components/textarea-autosize/\">TextareaAutosize</a> element is rendered.",
"name": "Name attribute of the <code>input</code> element.",
"onChange": "Callback fired when the value is changed.<br><br><strong>Signature:</strong><br><code>function(event: React.ChangeEvent&lt;HTMLTextAreaElement | HTMLInputElement&gt;) =&gt; void</code><br><em>event:</em> The event source of the callback. You can pull out the new value by accessing <code>event.target.value</code> (string).",
"placeholder": "The short hint displayed in the <code>input</code> before the user enters a value.",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"margin": "If <code>dense</code>, will adjust vertical spacing. This is normally obtained via context from FormControl. The prop defaults to the value (<code>&#39;none&#39;</code>) inherited from the parent FormControl component.",
"maxRows": "Maximum number of rows to display when multiline option is set to true.",
"minRows": "Minimum number of rows to display when multiline option is set to true.",
"multiline": "If <code>true</code>, a <code>textarea</code> element is rendered.",
"multiline": "If <code>true</code>, a <a href=\"/components/textarea-autosize/\">TextareaAutosize</a> element is rendered.",
"name": "Name attribute of the <code>input</code> element.",
"notched": "If <code>true</code>, the outline is notched to accommodate the label.",
"onChange": "Callback fired when the value is changed.<br><br><strong>Signature:</strong><br><code>function(event: React.ChangeEvent&lt;HTMLTextAreaElement | HTMLInputElement&gt;) =&gt; void</code><br><em>event:</em> The event source of the callback. You can pull out the new value by accessing <code>event.target.value</code> (string).",
Expand Down
2 changes: 1 addition & 1 deletion packages/mui-material/src/FilledInput/FilledInput.js
Original file line number Diff line number Diff line change
Expand Up @@ -329,7 +329,7 @@ FilledInput.propTypes /* remove-proptypes */ = {
*/
minRows: PropTypes.oneOfType([PropTypes.number, PropTypes.string]),
/**
* If `true`, a `textarea` element is rendered.
* If `true`, a [TextareaAutosize](/components/textarea-autosize/) element is rendered.
* @default false
*/
multiline: PropTypes.bool,
Expand Down
2 changes: 1 addition & 1 deletion packages/mui-material/src/Input/Input.js
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,7 @@ Input.propTypes /* remove-proptypes */ = {
*/
minRows: PropTypes.oneOfType([PropTypes.number, PropTypes.string]),
/**
* If `true`, a `textarea` element is rendered.
* If `true`, a [TextareaAutosize](/components/textarea-autosize/) element is rendered.
* @default false
*/
multiline: PropTypes.bool,
Expand Down
2 changes: 1 addition & 1 deletion packages/mui-material/src/InputBase/InputBase.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ export interface InputBaseProps
*/
margin?: 'dense' | 'none';
/**
* If `true`, a `textarea` element is rendered.
* If `true`, a [TextareaAutosize](/components/textarea-autosize/) element is rendered.
* @default false
*/
multiline?: boolean;
Expand Down
2 changes: 1 addition & 1 deletion packages/mui-material/src/InputBase/InputBase.js
Original file line number Diff line number Diff line change
Expand Up @@ -663,7 +663,7 @@ InputBase.propTypes /* remove-proptypes */ = {
*/
minRows: PropTypes.oneOfType([PropTypes.number, PropTypes.string]),
/**
* If `true`, a `textarea` element is rendered.
* If `true`, a [TextareaAutosize](/components/textarea-autosize/) element is rendered.
* @default false
*/
multiline: PropTypes.bool,
Expand Down
2 changes: 1 addition & 1 deletion packages/mui-material/src/OutlinedInput/OutlinedInput.js
Original file line number Diff line number Diff line change
Expand Up @@ -268,7 +268,7 @@ OutlinedInput.propTypes /* remove-proptypes */ = {
*/
minRows: PropTypes.oneOfType([PropTypes.number, PropTypes.string]),
/**
* If `true`, a `textarea` element is rendered.
* If `true`, a [TextareaAutosize](/components/textarea-autosize/) element is rendered.
* @default false
*/
multiline: PropTypes.bool,
Expand Down

0 comments on commit 3fa0a45

Please sign in to comment.