refactor(162): introduced forwardRefDivider (#218)

This commit is contained in:
Priscila Oliveira 2019-10-26 12:19:14 +02:00 committed by Juan Picado @jotadeveloper
parent 52ed8ad67b
commit a38b93e127
3 changed files with 12 additions and 1 deletions

View File

@ -1,10 +1,10 @@
import * as React from 'react';
import Divider from '@material-ui/core/Divider';
import Package from '../Package';
import Help from '../Help';
import { formatLicense } from '../../utils/package';
import { PackageInterface } from '../Package/Package';
import Divider from '../../muiComponents/Divider';
import * as classes from './styles';

View File

@ -0,0 +1,10 @@
import React, { forwardRef } from 'react';
import { default as MaterialUIDivider, DividerProps } from '@material-ui/core/Divider';
type DividerRef = keyof HTMLElementTagNameMap;
const Divider = forwardRef<DividerRef, DividerProps>(function Divider(props, ref) {
return <MaterialUIDivider {...props} innerRef={ref} />;
});
export default Divider;

View File

@ -0,0 +1 @@
export { default } from './Divider';