Skip to content

Commit

Permalink
Remove direct @material-ui/core imports. (mui#1252)
Browse files Browse the repository at this point in the history
After mui#1236, a few imports were remaining, remove those imports.
Also use type `Omit` from typescript utility types. This will ensure
zero direct references to `@material-ui/core`.
  • Loading branch information
sudeshyadav-pws authored and dmtrKovalenko committed Aug 13, 2019
1 parent ea4c299 commit b49b34a
Show file tree
Hide file tree
Showing 7 changed files with 3 additions and 7 deletions.
2 changes: 1 addition & 1 deletion lib/src/DateTimePicker/DateTimePickerToolbar.tsx
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import * as React from 'react';
import Grid from '@material-ui/core/Grid';
import ToolbarText from '../_shared/ToolbarText';
import PickerToolbar from '../_shared/PickerToolbar';
import ToolbarButton from '../_shared/ToolbarButton';
import DateTimePickerTabs from './DateTimePickerTabs';
import { Grid } from '@material-ui/core';
import { useUtils } from '../_shared/hooks/useUtils';
import { DateTimePickerView } from './DateTimePicker';
import { ToolbarComponentProps } from '../Picker/Picker';
Expand Down
1 change: 0 additions & 1 deletion lib/src/_helpers/text-field-helper.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { DatePickerProps } from '..';
import { Omit } from '@material-ui/core';
import { IUtils } from '@date-io/core/IUtils';
import { ParsableDate } from '../constants/prop-types';
import { BasePickerProps } from '../typings/BasePicker';
Expand Down
1 change: 0 additions & 1 deletion lib/src/_shared/WithUtils.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import * as React from 'react';
import { Omit } from '@material-ui/core';
import { useUtils } from './hooks/useUtils';
import { IUtils } from '@date-io/core/IUtils';
import { MaterialUiPickersDate } from '../typings/date';
Expand Down
1 change: 0 additions & 1 deletion lib/src/_shared/hooks/useKeyboardPickerState.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { useUtils } from './useUtils';
import { Omit } from '@material-ui/core';
import { IUtils } from '@date-io/core/IUtils';
import { BasePickerProps } from '../../typings/BasePicker';
import { MaterialUiPickersDate } from '../../typings/date';
Expand Down
1 change: 0 additions & 1 deletion lib/src/typings/extendMui.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import { Omit } from '@material-ui/core';
/**
* All standard components exposed by `material-ui` are `StyledComponents` with
* certain `classes`, on which one can also set a top-level `className` and inline
Expand Down
2 changes: 1 addition & 1 deletion lib/src/views/Calendar/Calendar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import DayWrapper from './DayWrapper';
import CalendarHeader from './CalendarHeader';
import CircularProgress from '@material-ui/core/CircularProgress';
import SlideTransition, { SlideDirection } from './SlideTransition';
import { Theme } from '@material-ui/core';
import { Theme } from '@material-ui/core/styles';
import { MaterialUiPickersDate } from '../../typings/date';
import { runKeyHandler } from '../../_shared/hooks/useKeyDown';
import { IconButtonProps } from '@material-ui/core/IconButton';
Expand Down
2 changes: 1 addition & 1 deletion lib/src/views/Clock/ClockPointer.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import * as React from 'react';
import clsx from 'clsx';
import ClockType, { ClockViewType } from '../../constants/ClockType';
import { Theme } from '@material-ui/core';
import { Theme } from '@material-ui/core/styles';
import { withStyles, createStyles, WithStyles } from '@material-ui/core/styles';

export interface ClockPointerProps extends WithStyles<typeof styles> {
Expand Down

0 comments on commit b49b34a

Please sign in to comment.