Skip to content

Commit

Permalink
move tabs index file into tabs folder and remove _content on folder n…
Browse files Browse the repository at this point in the history
…ames
  • Loading branch information
michaelolo24 committed Apr 5, 2024
1 parent 6b5a343 commit ec3b959
Show file tree
Hide file tree
Showing 48 changed files with 16 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ import { useDiscoverInTimelineContext } from '../../common/components/discover_i
import { useShowTimeline } from '../../common/utils/timeline/use_show_timeline';
import { useIsExperimentalFeatureEnabled } from '../../common/hooks/use_experimental_features';
import { useSourcererDataView } from '../../common/containers/sourcerer';
import { useDiscoverState } from '../../timelines/components/timeline/tabs/esql_tab_content/use_discover_state';
import { useDiscoverState } from '../../timelines/components/timeline/tabs/esql/use_discover_state';

export interface SendToTimelineButtonProps {
asEmptyButton: boolean;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,14 @@ import type { SavedSearch } from '@kbn/saved-search-plugin/common';
import type { DiscoverAppState } from '@kbn/discover-plugin/public/application/main/services/discover_app_state_container';
import type { TimeRange } from '@kbn/es-query';
import { useMutation, useQueryClient } from '@tanstack/react-query';
import { useDiscoverState } from '../../../timelines/components/timeline/tabs/esql_tab_content/use_discover_state';
import { useDiscoverState } from '../../../timelines/components/timeline/tabs/esql/use_discover_state';
import { timelineDefaults } from '../../../timelines/store/defaults';
import { TimelineId } from '../../../../common/types';
import { timelineActions, timelineSelectors } from '../../../timelines/store';
import { useAppToasts } from '../../hooks/use_app_toasts';
import { useShallowEqualSelector } from '../../hooks/use_selector';
import { useKibana } from '../../lib/kibana';
import { savedSearchComparator } from '../../../timelines/components/timeline/tabs/esql_tab_content/utils';
import { savedSearchComparator } from '../../../timelines/components/timeline/tabs/esql/utils';
import {
DISCOVER_SEARCH_SAVE_ERROR_TITLE,
DISCOVER_SEARCH_SAVE_ERROR_UNKNOWN,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ import { useFieldBrowserOptions } from '../../../timelines/components/fields_bro
import {
useSessionViewNavigation,
useSessionView,
} from '../../../timelines/components/timeline/tabs/session_tab_content/use_session_view';
} from '../../../timelines/components/timeline/tabs/session/use_session_view';
import {
EventsContainerLoading,
FullScreenContainer,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ import { GraphOverlay } from '../../../timelines/components/graph_overlay';
import {
useSessionView,
useSessionViewNavigation,
} from '../../../timelines/components/timeline/tabs/session_tab_content/use_session_view';
} from '../../../timelines/components/timeline/tabs/session/use_session_view';
import { inputsSelectors } from '../../../common/store';
import { combineQueries } from '../../../common/lib/kuery';
import { useInvalidFilterQuery } from '../../../common/hooks/use_invalid_filter_query';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ import { useDeepEqualSelector } from '../../../../common/hooks/use_selector';
import { SourcererScopeName } from '../../../../common/store/sourcerer/model';
import { useSourcererDataView } from '../../../../common/containers/sourcerer';
import { useDeleteNote } from './hooks/use_delete_note';
import { getTimelineNoteSelector } from '../../timeline/tabs/notes_tab_content/selectors';
import { getTimelineNoteSelector } from '../../timeline/tabs/notes/selectors';

export const NotePreviewsContainer = styled.section`
padding-top: ${({ theme }) => `${theme.eui.euiSizeS}`};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ import { useDeepEqualSelector, useShallowEqualSelector } from '../../../common/h
import type { State } from '../../../common/store';
import { EVENTS_COUNT_BUTTON_CLASS_NAME, onTimelineTabKeyPressed } from './helpers';
import * as i18n from './translations';
import { TabsContent } from './tabs_content';
import { TabsContent } from './tabs';
import { HideShowContainer, TimelineContainer } from './styles';
import { useTimelineFullScreen } from '../../../common/containers/use_full_screen';
import { EXIT_FULL_SCREEN_CLASS_NAME } from '../../../common/components/exit_full_screen';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import { timelineSelectors } from '../../../../store';
import { useShallowEqualSelector } from '../../../../../common/hooks/use_selector';
import type { TimelineId } from '../../../../../../common/types/timeline';
import { GraphOverlay } from '../../../graph_overlay';
import { useSessionViewNavigation, useSessionView } from '../session_tab_content/use_session_view';
import { useSessionViewNavigation, useSessionView } from '../session/use_session_view';
import { ScrollableFlexItem, VerticalRule } from '../shared/layout';

interface GraphTabContentProps {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,13 +76,13 @@ const tabWithSuspense = <P extends {}, R = {}>(
return Comp;
};

const QueryTab = tabWithSuspense(lazy(() => import('../tabs/query_tab_content')));
const EqlTab = tabWithSuspense(lazy(() => import('../tabs/eql_tab_content')));
const GraphTab = tabWithSuspense(lazy(() => import('../tabs/graph_tab_content')));
const NotesTab = tabWithSuspense(lazy(() => import('../tabs/notes_tab_content')));
const PinnedTab = tabWithSuspense(lazy(() => import('../tabs/pinned_tab_content')));
const SessionTab = tabWithSuspense(lazy(() => import('../tabs/session_tab_content')));
const EsqlTab = tabWithSuspense(lazy(() => import('../tabs/esql_tab_content')));
const QueryTab = tabWithSuspense(lazy(() => import('./query')));
const EqlTab = tabWithSuspense(lazy(() => import('./eql')));
const GraphTab = tabWithSuspense(lazy(() => import('./graph')));
const NotesTab = tabWithSuspense(lazy(() => import('./notes')));
const PinnedTab = tabWithSuspense(lazy(() => import('./pinned')));
const SessionTab = tabWithSuspense(lazy(() => import('./session')));
const EsqlTab = tabWithSuspense(lazy(() => import('./esql')));
interface BasicTimelineTab {
renderCellValue: (props: CellValueElementProps) => React.ReactNode;
rowRenderers: RowRenderer[];
Expand Down Expand Up @@ -136,7 +136,7 @@ const ActiveTimelineTab = memo<ActiveTimelineTabProps>(

const getAssistantTab = useCallback(() => {
if (showTimeline) {
const AssistantTab = tabWithSuspense(lazy(() => import('../tabs/assistant_tab_content')));
const AssistantTab = tabWithSuspense(lazy(() => import('./assistant')));
return (
<HideShowContainer
$isVisible={activeTimelineTab === TimelineTabs.securityAssistant}
Expand Down

0 comments on commit ec3b959

Please sign in to comment.