Skip to content

Commit

Permalink
[docs] Property !== attribute (mui#11694)
Browse files Browse the repository at this point in the history
* added inputRef example in text-field doc

* [core] Property !== attribute
  • Loading branch information
adeelibr authored and Joe Shelby committed Jul 14, 2018
1 parent 5ca1070 commit 03fa7c5
Show file tree
Hide file tree
Showing 16 changed files with 17 additions and 18 deletions.
2 changes: 1 addition & 1 deletion packages/material-ui/src/Avatar/Avatar.js
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ Avatar.propTypes = {
*/
component: PropTypes.oneOfType([PropTypes.string, PropTypes.func]),
/**
* Properties applied to the `img` element when the component
* Attributes applied to the `img` element when the component
* is used to display an image.
*/
imgProps: PropTypes.object,
Expand Down
2 changes: 1 addition & 1 deletion packages/material-ui/src/Input/Input.js
Original file line number Diff line number Diff line change
Expand Up @@ -535,7 +535,7 @@ Input.propTypes = {
*/
inputComponent: PropTypes.oneOfType([PropTypes.string, PropTypes.func]),
/**
* Properties applied to the `input` element.
* Attributes applied to the `input` element.
*/
inputProps: PropTypes.object,
/**
Expand Down
3 changes: 1 addition & 2 deletions packages/material-ui/src/NativeSelect/NativeSelect.js
Original file line number Diff line number Diff line change
Expand Up @@ -102,8 +102,7 @@ NativeSelect.propTypes = {
*/
input: PropTypes.element,
/**
* Properties applied to the `input` element.
* The properties are applied on the `select` element.
* Attributes applied to the `select` element.
*/
inputProps: PropTypes.object,
/**
Expand Down
2 changes: 1 addition & 1 deletion packages/material-ui/src/Radio/Radio.js
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ Radio.propTypes = {
*/
id: PropTypes.string,
/**
* Properties applied to the `input` element.
* Attributes applied to the `input` element.
*/
inputProps: PropTypes.object,
/**
Expand Down
4 changes: 2 additions & 2 deletions packages/material-ui/src/Select/Select.js
Original file line number Diff line number Diff line change
Expand Up @@ -97,8 +97,8 @@ Select.propTypes = {
*/
input: PropTypes.element,
/**
* Properties applied to the `input` element.
* When `native` is `true`, the properties are applied on the `select` element.
* Attributes applied to the `input` element.
* When `native` is `true`, the attributes are applied on the `select` element.
*/
inputProps: PropTypes.object,
/**
Expand Down
2 changes: 1 addition & 1 deletion packages/material-ui/src/Switch/Switch.js
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ Switch.propTypes = {
*/
id: PropTypes.string,
/**
* Properties applied to the `input` element.
* Attributes applied to the `input` element.
*/
inputProps: PropTypes.object,
/**
Expand Down
2 changes: 1 addition & 1 deletion packages/material-ui/src/TextField/TextField.js
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ TextField.propTypes = {
*/
InputProps: PropTypes.object,
/**
* Properties applied to the native `input` element.
* Attributes applied to the native `input` element.
*/
inputProps: PropTypes.object,
/**
Expand Down
2 changes: 1 addition & 1 deletion packages/material-ui/src/internal/SwitchBase.js
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ SwitchBase.propTypes = {
*/
indeterminateIcon: PropTypes.node,
/**
* Properties applied to the `input` element.
* Attributes applied to the `input` element.
*/
inputProps: PropTypes.object,
/**
Expand Down
2 changes: 1 addition & 1 deletion pages/api/avatar.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ filename: /packages/material-ui/src/Avatar/Avatar.js
| <span class="prop-name">children</span> | <span class="prop-type">node |   | Used to render icon or text elements inside the Avatar. `src` and `alt` props will not be used and no `img` will be rendered by default.<br>This can be an element, or just a string. |
| <span class="prop-name">classes</span> | <span class="prop-type">object |   | Override or extend the styles applied to the component. See [CSS API](#css-api) below for more details. |
| <span class="prop-name">component</span> | <span class="prop-type">union:&nbsp;string&nbsp;&#124;<br>&nbsp;func<br> | <span class="prop-default">'div'</span> | The component used for the root node. Either a string to use a DOM element or a component. |
| <span class="prop-name">imgProps</span> | <span class="prop-type">object |   | Properties applied to the `img` element when the component is used to display an image. |
| <span class="prop-name">imgProps</span> | <span class="prop-type">object |   | Attributes applied to the `img` element when the component is used to display an image. |
| <span class="prop-name">sizes</span> | <span class="prop-type">string |   | The `sizes` attribute for the `img` element. |
| <span class="prop-name">src</span> | <span class="prop-type">string |   | The `src` attribute for the `img` element. |
| <span class="prop-name">srcSet</span> | <span class="prop-type">string |   | The `srcSet` attribute for the `img` element. |
Expand Down
2 changes: 1 addition & 1 deletion pages/api/input.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ filename: /packages/material-ui/src/Input/Input.js
| <span class="prop-name">fullWidth</span> | <span class="prop-type">bool | <span class="prop-default">false</span> | If `true`, the input will take up the full width of its container. |
| <span class="prop-name">id</span> | <span class="prop-type">string |   | The id of the `input` element. |
| <span class="prop-name">inputComponent</span> | <span class="prop-type">union:&nbsp;string&nbsp;&#124;<br>&nbsp;func<br> |   | The component used for the native input. Either a string to use a DOM element or a component. |
| <span class="prop-name">inputProps</span> | <span class="prop-type">object |   | Properties applied to the `input` element. |
| <span class="prop-name">inputProps</span> | <span class="prop-type">object |   | Attributes applied to the `input` element. |
| <span class="prop-name">inputRef</span> | <span class="prop-type">func |   | Use that property to pass a ref callback to the native input component. |
| <span class="prop-name">margin</span> | <span class="prop-type">enum:&nbsp;'dense'&nbsp;&#124;<br>&nbsp;'none'<br> |   | If `dense`, will adjust vertical spacing. This is normally obtained via context from FormControl. |
| <span class="prop-name">multiline</span> | <span class="prop-type">bool | <span class="prop-default">false</span> | If `true`, a textarea element will be rendered. |
Expand Down
2 changes: 1 addition & 1 deletion pages/api/native-select.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ An alternative to `<Select native />` with a much smaller dependency graph.
| <span class="prop-name">classes</span> | <span class="prop-type">object |   | Override or extend the styles applied to the component. See [CSS API](#css-api) below for more details. |
| <span class="prop-name">IconComponent</span> | <span class="prop-type">union:&nbsp;string&nbsp;&#124;<br>&nbsp;func<br> | <span class="prop-default">ArrowDropDownIcon</span> | The icon that displays the arrow. |
| <span class="prop-name">input</span> | <span class="prop-type">element | <span class="prop-default">&lt;Input /></span> | An `Input` element; does not have to be a material-ui specific `Input`. |
| <span class="prop-name">inputProps</span> | <span class="prop-type">object |   | Properties applied to the `input` element. The properties are applied on the `select` element. |
| <span class="prop-name">inputProps</span> | <span class="prop-type">object |   | Attributes applied to the `select` element. |
| <span class="prop-name">onChange</span> | <span class="prop-type">func |   | Callback function fired when a menu item is selected.<br><br>**Signature:**<br>`function(event: object) => void`<br>*event:* The event source of the callback. You can pull out the new value by accessing `event.target.value`. |
| <span class="prop-name">value</span> | <span class="prop-type">union:&nbsp;string&nbsp;&#124;<br>&nbsp;number<br> |   | The input value. |

Expand Down
2 changes: 1 addition & 1 deletion pages/api/radio.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ filename: /packages/material-ui/src/Radio/Radio.js
| <span class="prop-name">disableRipple</span> | <span class="prop-type">bool |   | If `true`, the ripple effect will be disabled. |
| <span class="prop-name">icon</span> | <span class="prop-type">node |   | The icon to display when the component is unchecked. |
| <span class="prop-name">id</span> | <span class="prop-type">string |   | The id of the `input` element. |
| <span class="prop-name">inputProps</span> | <span class="prop-type">object |   | Properties applied to the `input` element. |
| <span class="prop-name">inputProps</span> | <span class="prop-type">object |   | Attributes applied to the `input` element. |
| <span class="prop-name">inputRef</span> | <span class="prop-type">func |   | Use that property to pass a ref callback to the native input component. |
| <span class="prop-name">onChange</span> | <span class="prop-type">func |   | Callback fired when the state is changed.<br><br>**Signature:**<br>`function(event: object, checked: boolean) => void`<br>*event:* The event source of the callback. You can pull out the new value by accessing `event.target.value`.<br>*checked:* The `checked` value of the switch |
| <span class="prop-name">type</span> | <span class="prop-type">string |   | The input component property `type`. |
Expand Down
2 changes: 1 addition & 1 deletion pages/api/select.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ filename: /packages/material-ui/src/Select/Select.js
| <span class="prop-name">displayEmpty</span> | <span class="prop-type">bool | <span class="prop-default">false</span> | If `true`, the selected item is displayed even if its value is empty. You can only use it when the `native` property is `false` (default). |
| <span class="prop-name">IconComponent</span> | <span class="prop-type">union:&nbsp;string&nbsp;&#124;<br>&nbsp;func<br> | <span class="prop-default">ArrowDropDownIcon</span> | The icon that displays the arrow. |
| <span class="prop-name">input</span> | <span class="prop-type">element | <span class="prop-default">&lt;Input /></span> | An `Input` element; does not have to be a material-ui specific `Input`. |
| <span class="prop-name">inputProps</span> | <span class="prop-type">object |   | Properties applied to the `input` element. When `native` is `true`, the properties are applied on the `select` element. |
| <span class="prop-name">inputProps</span> | <span class="prop-type">object |   | Attributes applied to the `input` element. When `native` is `true`, the attributes are applied on the `select` element. |
| <span class="prop-name">MenuProps</span> | <span class="prop-type">object |   | Properties applied to the `Menu` element. |
| <span class="prop-name">multiple</span> | <span class="prop-type">bool | <span class="prop-default">false</span> | If true, `value` must be an array and the menu will support multiple selections. You can only use it when the `native` property is `false` (default). |
| <span class="prop-name">native</span> | <span class="prop-type">bool | <span class="prop-default">false</span> | If `true`, the component will be using a native `select` element. |
Expand Down
2 changes: 1 addition & 1 deletion pages/api/switch-base.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ filename: /packages/material-ui/src/internal/SwitchBase.js
| <span class="prop-name">id</span> | <span class="prop-type">string |   | The id of the `input` element. |
| <span class="prop-name">indeterminate</span> | <span class="prop-type">bool |   | If `true`, the component appears indeterminate. |
| <span class="prop-name">indeterminateIcon</span> | <span class="prop-type">node |   | The icon to display when the component is indeterminate. |
| <span class="prop-name">inputProps</span> | <span class="prop-type">object |   | Properties applied to the `input` element. |
| <span class="prop-name">inputProps</span> | <span class="prop-type">object |   | Attributes applied to the `input` element. |
| <span class="prop-name">inputRef</span> | <span class="prop-type">func |   | Use that property to pass a ref callback to the native input component. |
| <span class="prop-name">name</span> | <span class="prop-type">string |   | |
| <span class="prop-name">onChange</span> | <span class="prop-type">func |   | Callback fired when the state is changed.<br><br>**Signature:**<br>`function(event: object, checked: boolean) => void`<br>*event:* The event source of the callback. You can pull out the new value by accessing `event.target.checked`.<br>*checked:* The `checked` value of the switch |
Expand Down
2 changes: 1 addition & 1 deletion pages/api/switch.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ filename: /packages/material-ui/src/Switch/Switch.js
| <span class="prop-name">disableRipple</span> | <span class="prop-type">bool |   | If `true`, the ripple effect will be disabled. |
| <span class="prop-name">icon</span> | <span class="prop-type">node |   | The icon to display when the component is unchecked. |
| <span class="prop-name">id</span> | <span class="prop-type">string |   | The id of the `input` element. |
| <span class="prop-name">inputProps</span> | <span class="prop-type">object |   | Properties applied to the `input` element. |
| <span class="prop-name">inputProps</span> | <span class="prop-type">object |   | Attributes applied to the `input` element. |
| <span class="prop-name">inputRef</span> | <span class="prop-type">func |   | Use that property to pass a ref callback to the native input component. |
| <span class="prop-name">onChange</span> | <span class="prop-type">func |   | Callback fired when the state is changed.<br><br>**Signature:**<br>`function(event: object, checked: boolean) => void`<br>*event:* The event source of the callback. You can pull out the new value by accessing `event.target.checked`.<br>*checked:* The `checked` value of the switch |
| <span class="prop-name">type</span> | <span class="prop-type">string |   | The input component property `type`. |
Expand Down
2 changes: 1 addition & 1 deletion pages/api/text-field.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ For advanced cases, please look at the source of TextField by clicking on the
| <span class="prop-name">id</span> | <span class="prop-type">string |   | The id of the `input` element. Use that property to make `label` and `helperText` accessible for screen readers. |
| <span class="prop-name">InputLabelProps</span> | <span class="prop-type">object |   | Properties applied to the `InputLabel` element. |
| <span class="prop-name">InputProps</span> | <span class="prop-type">object |   | Properties applied to the `Input` element. |
| <span class="prop-name">inputProps</span> | <span class="prop-type">object |   | Properties applied to the native `input` element. |
| <span class="prop-name">inputProps</span> | <span class="prop-type">object |   | Attributes applied to the native `input` element. |
| <span class="prop-name">inputRef</span> | <span class="prop-type">func |   | Use that property to pass a ref callback to the native input component. |
| <span class="prop-name">label</span> | <span class="prop-type">node |   | The label content. |
| <span class="prop-name">margin</span> | <span class="prop-type">enum:&nbsp;'none'&nbsp;&#124;<br>&nbsp;'dense'&nbsp;&#124;<br>&nbsp;'normal'<br> |   | If `dense` or `normal`, will adjust vertical spacing of this and contained components. |
Expand Down

0 comments on commit 03fa7c5

Please sign in to comment.