Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Preparation for upgrading EUI so that it includes date picker types #31801

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/legacy/ui/public/query_bar/components/query_bar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ interface Props {
isRefreshPaused?: boolean;
refreshInterval?: number;
showAutoRefreshOnly?: boolean;
onRefreshChange?: (isPaused: boolean, refreshInterval: number) => void;
onRefreshChange?: (options: { isPaused: boolean; refreshInterval: number }) => void;
}

interface State {
Expand Down
2 changes: 1 addition & 1 deletion src/legacy/ui/public/search_bar/components/search_bar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ interface Props {
isRefreshPaused?: boolean;
refreshInterval?: number;
showAutoRefreshOnly?: boolean;
onRefreshChange?: (isPaused: boolean, refreshInterval: number) => void;
onRefreshChange?: (options: { isPaused: boolean; refreshInterval: number }) => void;
}

interface State {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -274,7 +274,6 @@ export const RangeDatePicker = injectI18n(
<EuiDatePickerRange
className="euiDatePickerRange--inGroup"
iconType={false}
disabled={disabled}
fullWidth
startDateControl={
<EuiDatePicker
Expand Down
47 changes: 0 additions & 47 deletions x-pack/plugins/infra/types/eui.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -46,41 +46,6 @@ declare module '@elastic/eui' {
type EuiHeaderBreadcrumbsProps = EuiBreadcrumbsProps;
export const EuiHeaderBreadcrumbs: React.SFC<EuiHeaderBreadcrumbsProps>;

type EuiDatePickerProps = CommonProps &
Pick<
ReactDatePickerProps,
Exclude<
keyof ReactDatePickerProps,
| 'monthsShown'
| 'showWeekNumbers'
| 'fixedHeight'
| 'dropdownMode'
| 'useShortMonthInDropdown'
| 'todayButton'
| 'timeCaption'
| 'disabledKeyboardNavigation'
| 'isClearable'
| 'withPortal'
| 'ref'
| 'placeholderText'
| 'selected'
>
> & {
fullWidth?: boolean;
inputRef?: Ref<Element | ReactType>;
injectTimes?: moment.Moment[];
isInvalid?: boolean;
isLoading?: boolean;
selected?: moment.Moment | null | undefined;
placeholder?: string;
shadow?: boolean;
calendarContainer?: React.ReactNode;
onChange?: (date: moment.Moment | null) => void;
startDate?: moment.Moment | undefined;
endDate?: moment.Moment | undefined;
};
export const EuiDatePicker: React.SFC<EuiDatePickerProps>;

type EuiFilterGroupProps = CommonProps;
export const EuiFilterGroup: React.SFC<EuiFilterGroupProps>;

Expand Down Expand Up @@ -159,18 +124,6 @@ declare module '@elastic/eui' {

export const EuiShowFor: React.SFC<EuiResponsiveProps>;

type EuiDatePickerRangeProps = CommonProps & {
startDateControl: React.ReactNode;
endDateControl: React.ReactNode;
iconType?: IconType | boolean;
fullWidth?: boolean;
disabled?: boolean;
isLoading?: boolean;
dateFormat?: string;
};

export const EuiDatePickerRange: React.SFC<EuiDatePickerRangeProps>;

type EuiInMemoryTableProps = CommonProps & {
items?: any;
columns?: any;
Expand Down