From e028d13a1b743a74df8b162edc15080768e95eda Mon Sep 17 00:00:00 2001 From: Sean Perkins Date: Thu, 2 Feb 2023 11:40:51 -0500 Subject: [PATCH] chore(many): import types from source path (#26718) --- core/src/components/datetime-button/datetime-button.tsx | 3 ++- core/src/components/popover/utils.ts | 3 ++- core/src/components/select/select.tsx | 4 ++-- core/src/utils/theme.ts | 3 ++- 4 files changed, 8 insertions(+), 5 deletions(-) diff --git a/core/src/components/datetime-button/datetime-button.tsx b/core/src/components/datetime-button/datetime-button.tsx index 532dd01481..c42fa0edd0 100644 --- a/core/src/components/datetime-button/datetime-button.tsx +++ b/core/src/components/datetime-button/datetime-button.tsx @@ -2,10 +2,11 @@ import type { ComponentInterface } from '@stencil/core'; import { Component, Element, Host, Prop, State, h } from '@stencil/core'; import { getIonMode } from '../../global/ionic-global'; -import type { Color, DatetimePresentation } from '../../interface'; +import type { Color } from '../../interface'; import { componentOnReady, addEventListener } from '../../utils/helpers'; import { printIonError } from '../../utils/logging'; import { createColorClasses } from '../../utils/theme'; +import type { DatetimePresentation } from '../datetime/datetime-interface'; import { getToday } from '../datetime/utils/data'; import { getMonthAndYear, getMonthDayAndYear, getLocalizedDateTime, getLocalizedTime } from '../datetime/utils/format'; import { is24Hour } from '../datetime/utils/helpers'; diff --git a/core/src/components/popover/utils.ts b/core/src/components/popover/utils.ts index 9c6af58640..23182610d4 100644 --- a/core/src/components/popover/utils.ts +++ b/core/src/components/popover/utils.ts @@ -1,6 +1,7 @@ -import type { PopoverSize, PositionAlign, PositionReference, PositionSide, TriggerAction } from '../../interface'; import { getElementRoot, raf } from '../../utils/helpers'; +import type { PopoverSize, PositionAlign, PositionReference, PositionSide, TriggerAction } from './popover-interface'; + interface InteractionCallback { eventName: string; callback: (ev: any) => void; // TODO(FW-2832): type diff --git a/core/src/components/select/select.tsx b/core/src/components/select/select.tsx index dd165aae4f..709e6ec9db 100644 --- a/core/src/components/select/select.tsx +++ b/core/src/components/select/select.tsx @@ -8,9 +8,7 @@ import { caretDownSharp } from 'ionicons/icons'; import { getIonMode } from '../../global/ionic-global'; import type { - ActionSheetButton, ActionSheetOptions, - AlertInput, AlertOptions, Color, CssClassMap, @@ -23,6 +21,8 @@ import { actionSheetController, alertController, popoverController } from '../.. import type { OverlaySelect } from '../../utils/overlays-interface'; import { createColorClasses, hostContext } from '../../utils/theme'; import { watchForOptions } from '../../utils/watch-options'; +import type { ActionSheetButton } from '../action-sheet/action-sheet-interface'; +import type { AlertInput } from '../alert/alert-interface'; import type { SelectPopoverOption } from '../select-popover/select-popover-interface'; import type { SelectChangeEventDetail, SelectInterface, SelectCompareFn } from './select-interface'; diff --git a/core/src/utils/theme.ts b/core/src/utils/theme.ts index 31c6b3c60d..df2d49a1b5 100644 --- a/core/src/utils/theme.ts +++ b/core/src/utils/theme.ts @@ -1,4 +1,5 @@ -import type { AnimationBuilder, Color, CssClassMap, RouterDirection } from '../interface'; +import type { RouterDirection } from '../components/router/utils/interface'; +import type { AnimationBuilder, Color, CssClassMap } from '../interface'; export const hostContext = (selector: string, el: HTMLElement): boolean => { return el.closest(selector) !== null;