Skip to content

Commit

Permalink
[docs] Miscellaneous fixes in MUI Base docs (#33091)
Browse files Browse the repository at this point in the history
* docs: should be badge slot

* fix code comment
  • Loading branch information
ZeeshanTamboli committed Jun 10, 2022
1 parent 66f7a9d commit 1a30806
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion docs/data/base/components/input/UseInput.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ const CustomInput = React.forwardRef(function CustomInput(props, ref) {

const inputProps = getInputProps();

// Make sure that both the forwarded ref and the ref returned from the are applied on the input element
// Make sure that both the forwarded ref and the ref returned from the getInputProps are applied on the input element
inputProps.ref = useForkRef(inputProps.ref, ref);

return (
Expand Down
2 changes: 1 addition & 1 deletion docs/data/base/components/input/UseInput.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ const CustomInput = React.forwardRef(function CustomInput(

const inputProps = getInputProps();

// Make sure that both the forwarded ref and the ref returned from the are applied on the input element
// Make sure that both the forwarded ref and the ref returned from the getInputProps are applied on the input element
inputProps.ref = useForkRef(inputProps.ref, ref);

return (
Expand Down
4 changes: 2 additions & 2 deletions docs/data/base/getting-started/usage/usage.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,10 +68,10 @@ The code snippet below shows how to override the `Root` element of the [`BadgeUn
The `componentsProps` prop is an object that contains the props for all slots within a component.
You can use it to define additional custom props for a component's interior elements.

For example, the code snippet below shows how to add a custom CSS class to the `input` slot of the `BadgeUnstyled` component:
For example, the code snippet below shows how to add a custom CSS class to the `badge` slot of the `BadgeUnstyled` component:

```jsx
<BadgeUnstyled componentsProps={{ input: { className: 'my-badge' } }} />
<BadgeUnstyled componentsProps={{ badge: { className: 'my-badge' } }} />
```

All additional props placed on the primary component are also propagated into the `Root` slot (just as if they were placed in `componentsProps.root`).
Expand Down

0 comments on commit 1a30806

Please sign in to comment.