Skip to content

Commit

Permalink
[docs] Remove controlled Tooltip example in Slider (#23625)
Browse files Browse the repository at this point in the history
  • Loading branch information
micsidoruk authored Nov 20, 2020
1 parent a54a7ce commit e28f1af
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
5 changes: 2 additions & 3 deletions docs/src/pages/components/slider/CustomizedSlider.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,18 +18,17 @@ const Separator = styled('div')(
);

function ValueLabelComponent(props) {
const { children, open, value } = props;
const { children, value } = props;

return (
<Tooltip open={open} enterTouchDelay={0} placement="top" title={value}>
<Tooltip enterTouchDelay={0} placement="top" title={value}>
{children}
</Tooltip>
);
}

ValueLabelComponent.propTypes = {
children: PropTypes.element.isRequired,
open: PropTypes.bool.isRequired,
value: PropTypes.number.isRequired,
};

Expand Down
5 changes: 2 additions & 3 deletions docs/src/pages/components/slider/CustomizedSlider.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,14 @@ const Separator = styled('div')(

interface Props {
children: React.ReactElement;
open: boolean;
value: number;
}

function ValueLabelComponent(props: Props) {
const { children, open, value } = props;
const { children, value } = props;

return (
<Tooltip open={open} enterTouchDelay={0} placement="top" title={value}>
<Tooltip enterTouchDelay={0} placement="top" title={value}>
{children}
</Tooltip>
);
Expand Down

0 comments on commit e28f1af

Please sign in to comment.