mirror of
https://github.com/kilyabin/psysonic.git
synced 2026-07-22 06:25:41 +00:00
refactor(utils): group utils/ files into topic folders (Phase L, part 1) (#689)
111 of 122 top-level src/utils/ files move into 16 topic folders (audio, cache, cover, share, server, playback, playlist, deviceSync, waveform, mix, format, export, changelog, ui, perf, componentHelpers). True singletons with no cluster stay at the utils/ root. Pure file-move: a path-aware codemod rewrote 539 relative-import specifiers across 275 files; no logic touched. The hot-path coverage gate list (.github/frontend-hot-path-files.txt) is updated to the new paths for the 11 gated utils files — a mechanical consequence of the move, not a CI change. tsc is green.
This commit is contained in:
committed by
GitHub
parent
2409a1fec8
commit
7a7a9f5e6b
@@ -50,11 +50,11 @@ import { usePlayerStore } from '../store/playerStore';
|
||||
import { useThemeStore } from '../store/themeStore';
|
||||
import { useFontStore } from '../store/fontStore';
|
||||
import { useEqStore } from '../store/eqStore';
|
||||
import { usePerfProbeFlags } from '../utils/perfFlags';
|
||||
import { usePerfProbeFlags } from '../utils/perf/perfFlags';
|
||||
import {
|
||||
persistSidebarCollapsed,
|
||||
readInitialSidebarCollapsed,
|
||||
} from '../utils/appShellHelpers';
|
||||
} from '../utils/componentHelpers/appShellHelpers';
|
||||
|
||||
/**
|
||||
* The main webview's persistent layout: titlebar (Linux only) + sidebar +
|
||||
|
||||
+2
-2
@@ -2,7 +2,7 @@ import { initAudioListeners } from '../store/initAudioListeners';
|
||||
import { lazy, Suspense, useEffect, useState } from 'react';
|
||||
import { BrowserRouter, Route, Routes } from 'react-router-dom';
|
||||
import { invoke } from '@tauri-apps/api/core';
|
||||
import { showToast } from '../utils/toast';
|
||||
import { showToast } from '../utils/ui/toast';
|
||||
import { WindowVisibilityProvider } from '../hooks/useWindowVisibility';
|
||||
import { DragDropProvider } from '../contexts/DragDropContext';
|
||||
import PasteClipboardHandler from '../components/PasteClipboardHandler';
|
||||
@@ -69,7 +69,7 @@ export default function MainApp() {
|
||||
const handleExport = async (since: number) => {
|
||||
setExportPickerOpen(false);
|
||||
try {
|
||||
const { exportNewAlbumsImage } = await import('../utils/exportNewAlbums');
|
||||
const { exportNewAlbumsImage } = await import('../utils/export/exportNewAlbums');
|
||||
const result = await exportNewAlbumsImage(since);
|
||||
if (result) {
|
||||
const files = result.paths.length > 1 ? ` (${result.paths.length} Dateien)` : '';
|
||||
|
||||
@@ -22,7 +22,7 @@ vi.mock('../store/fontStore', () => ({
|
||||
vi.mock('../store/keybindingsStore', () => ({
|
||||
useKeybindingsStore: { persist: { rehydrate: keybindingsRehydrate } },
|
||||
}));
|
||||
vi.mock('../utils/perfFlags', () => ({
|
||||
vi.mock('../utils/perf/perfFlags', () => ({
|
||||
usePerfProbeFlags: () => ({ disableTooltipPortal: true }),
|
||||
}));
|
||||
vi.mock('../i18n', () => ({
|
||||
|
||||
@@ -7,7 +7,7 @@ import FpsOverlay from '../components/FpsOverlay';
|
||||
import { useThemeStore } from '../store/themeStore';
|
||||
import { useFontStore } from '../store/fontStore';
|
||||
import { useKeybindingsStore } from '../store/keybindingsStore';
|
||||
import { usePerfProbeFlags } from '../utils/perfFlags';
|
||||
import { usePerfProbeFlags } from '../utils/perf/perfFlags';
|
||||
import i18n from '../i18n';
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user