Skip to content

Commit

Permalink
[docs] Fix inputRef date picker customization demo (mui#2028)
Browse files Browse the repository at this point in the history
* Update `ref` to `inputRef` on the broken demo

Fixes Issue mui#2027

* yarn prettier

Co-authored-by: Dmitriy Kovalenko <[email protected]>
  • Loading branch information
Chee7ah and dmtrKovalenko authored Jul 27, 2020
1 parent b3f94f4 commit b101c47
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions docs/pages/demo/daterangepicker/CustomRangeInputs.example.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,11 @@ export default function CustomRangeInputs() {
onChange={(date) => handleDateChange(date)}
renderInput={(startProps, endProps) => (
<React.Fragment>
<input ref={startProps.ref as React.Ref<HTMLInputElement>} {...startProps.inputProps} />
<input ref={endProps.ref as React.Ref<HTMLInputElement>} {...endProps.inputProps} />
<input
ref={startProps.inputRef as React.Ref<HTMLInputElement>}
{...startProps.inputProps}
/>
<input ref={endProps.inputRef as React.Ref<HTMLInputElement>} {...endProps.inputProps} />
</React.Fragment>
)}
/>
Expand Down

0 comments on commit b101c47

Please sign in to comment.