From e3b5dd8891be8a022501cf135a6d9aba8907e408 Mon Sep 17 00:00:00 2001 From: Ashley Harrison Date: Wed, 22 Oct 2025 15:20:33 +0100 Subject: [PATCH] remove barrel export in useStateSync --- eslint-suppressions.json | 10 ---------- public/app/features/explore/Logs/Logs.tsx | 2 +- .../app/features/explore/hooks/useStateSync/index.ts | 2 -- .../explore/hooks/useStateSync/synchronizer/fromURL.ts | 2 +- .../explore/hooks/useStateSync/synchronizer/init.ts | 2 +- .../explore/hooks/useStateSync/synchronizer/toURL.ts | 2 +- public/app/features/explore/utils/links.ts | 2 +- 7 files changed, 5 insertions(+), 17 deletions(-) diff --git a/eslint-suppressions.json b/eslint-suppressions.json index f36865c5c86..ed127499b02 100644 --- a/eslint-suppressions.json +++ b/eslint-suppressions.json @@ -3055,11 +3055,6 @@ "count": 1 } }, - "public/app/features/explore/TraceView/components/utils/DraggableManager/demo/index.tsx": { - "no-barrel-files/no-barrel-files": { - "count": 1 - } - }, "public/app/features/explore/TraceView/components/utils/sort.ts": { "no-restricted-syntax": { "count": 1 @@ -3070,11 +3065,6 @@ "count": 2 } }, - "public/app/features/explore/hooks/useStateSync/index.ts": { - "no-barrel-files/no-barrel-files": { - "count": 1 - } - }, "public/app/features/explore/spec/helper/setup.tsx": { "@typescript-eslint/no-explicit-any": { "count": 1 diff --git a/public/app/features/explore/Logs/Logs.tsx b/public/app/features/explore/Logs/Logs.tsx index 1049a09567a..237a53ea420 100644 --- a/public/app/features/explore/Logs/Logs.tsx +++ b/public/app/features/explore/Logs/Logs.tsx @@ -73,7 +73,7 @@ import { contentOutlineTrackUnpinClicked, } from '../ContentOutline/ContentOutlineAnalyticEvents'; import { useContentOutlineContext } from '../ContentOutline/ContentOutlineContext'; -import { getUrlStateFromPaneState } from '../hooks/useStateSync'; +import { getUrlStateFromPaneState } from '../hooks/useStateSync/external.utils'; import { changePanelState } from '../state/explorePane'; import { changeQueries, runQueries } from '../state/query'; diff --git a/public/app/features/explore/hooks/useStateSync/index.ts b/public/app/features/explore/hooks/useStateSync/index.ts index 44462fa0d35..264b19e3d56 100644 --- a/public/app/features/explore/hooks/useStateSync/index.ts +++ b/public/app/features/explore/hooks/useStateSync/index.ts @@ -12,8 +12,6 @@ import { syncFromURL } from './synchronizer/fromURL'; import { initializeFromURL } from './synchronizer/init'; import { syncToURL, syncToURLPredicate } from './synchronizer/toURL'; -export { getUrlStateFromPaneState } from './external.utils'; - /** * Bi-directionally syncs URL changes with Explore's state. */ diff --git a/public/app/features/explore/hooks/useStateSync/synchronizer/fromURL.ts b/public/app/features/explore/hooks/useStateSync/synchronizer/fromURL.ts index a7856edc9af..5cc17e4a172 100644 --- a/public/app/features/explore/hooks/useStateSync/synchronizer/fromURL.ts +++ b/public/app/features/explore/hooks/useStateSync/synchronizer/fromURL.ts @@ -11,7 +11,7 @@ import { withUniqueRefIds } from 'app/features/explore/utils/queries'; import { ExploreItemState } from 'app/types/explore'; import { ThunkDispatch } from 'app/types/store'; -import { getUrlStateFromPaneState } from '../index'; +import { getUrlStateFromPaneState } from '../external.utils'; import { urlDiff } from '../internal.utils'; import { ExploreURLV1 } from '../migrators/v1'; diff --git a/public/app/features/explore/hooks/useStateSync/synchronizer/init.ts b/public/app/features/explore/hooks/useStateSync/synchronizer/init.ts index 201355d32b3..097e5549f01 100644 --- a/public/app/features/explore/hooks/useStateSync/synchronizer/init.ts +++ b/public/app/features/explore/hooks/useStateSync/synchronizer/init.ts @@ -11,7 +11,7 @@ import { withUniqueRefIds } from 'app/features/explore/utils/queries'; import { getDatasourceSrv } from 'app/features/plugins/datasource_srv'; import { ThunkDispatch } from 'app/types/store'; -import { getUrlStateFromPaneState } from '../index'; +import { getUrlStateFromPaneState } from '../external.utils'; import { getDefaultQuery, getPaneDatasource, diff --git a/public/app/features/explore/hooks/useStateSync/synchronizer/toURL.ts b/public/app/features/explore/hooks/useStateSync/synchronizer/toURL.ts index c746d767048..d665592d80d 100644 --- a/public/app/features/explore/hooks/useStateSync/synchronizer/toURL.ts +++ b/public/app/features/explore/hooks/useStateSync/synchronizer/toURL.ts @@ -11,7 +11,7 @@ import { runQueries } from 'app/features/explore/state/query'; import { changeRangeAction } from 'app/features/explore/state/time'; import { ExploreState } from 'app/types/explore'; -import { getUrlStateFromPaneState } from '../index'; +import { getUrlStateFromPaneState } from '../external.utils'; import { InitState } from '../internal.utils'; /* diff --git a/public/app/features/explore/utils/links.ts b/public/app/features/explore/utils/links.ts index 10b2acb3d54..c4644e1a709 100644 --- a/public/app/features/explore/utils/links.ts +++ b/public/app/features/explore/utils/links.ts @@ -30,7 +30,7 @@ import { parseDataplaneLogsFrame } from 'app/features/logs/logsFrame'; import { ExploreItemState } from 'app/types/explore'; import { getLinkSrv } from '../../panel/panellinks/link_srv'; -import { getUrlStateFromPaneState } from '../hooks/useStateSync'; +import { getUrlStateFromPaneState } from '../hooks/useStateSync/external.utils'; type DataLinkFilter = (link: DataLink, scopedVars: ScopedVars) => boolean;