mirror of
https://github.com/clash-verge-rev/clash-verge-rev.git
synced 2026-01-29 08:45:41 +08:00
revert: use-app-data (#6088)
* Revert "refactor(app-data): split monolithic context into focused SWR hooks (#5576)"
This reverts commit 8e8182f707.
# Conflicts:
# src/components/home/clash-info-card.tsx
# src/components/home/clash-mode-card.tsx
# src/components/home/current-proxy-card.tsx
# src/components/home/home-profile-card.tsx
# src/components/proxy/provider-button.tsx
# src/components/proxy/proxy-chain.tsx
# src/components/proxy/proxy-groups.tsx
# src/components/proxy/use-render-list.ts
# src/components/rule/provider-button.tsx
# src/components/setting/mods/sysproxy-viewer.tsx
# src/hooks/use-clash-data.ts
# src/hooks/use-current-proxy.ts
# src/hooks/use-shared-swr-poller.ts
# src/hooks/use-system-proxy-state.ts
# src/pages/rules.tsx
* docs: Changelog.md
This commit is contained in:
@@ -34,14 +34,10 @@ import { useNavigate } from "react-router";
|
||||
import { delayGroup, healthcheckProxyProvider } from "tauri-plugin-mihomo-api";
|
||||
|
||||
import { EnhancedCard } from "@/components/home/enhanced-card";
|
||||
import {
|
||||
useClashConfig,
|
||||
useProxiesData,
|
||||
useRulesData,
|
||||
} from "@/hooks/use-clash-data";
|
||||
import { useProfiles } from "@/hooks/use-profiles";
|
||||
import { useProxySelection } from "@/hooks/use-proxy-selection";
|
||||
import { useVerge } from "@/hooks/use-verge";
|
||||
import { useAppData } from "@/providers/app-data-context";
|
||||
import delayManager from "@/services/delay";
|
||||
import { debugLog } from "@/utils/debug";
|
||||
|
||||
@@ -105,9 +101,7 @@ export const CurrentProxyCard = () => {
|
||||
const { t } = useTranslation();
|
||||
const navigate = useNavigate();
|
||||
const theme = useTheme();
|
||||
const { proxies, refreshProxy } = useProxiesData();
|
||||
const { clashConfig } = useClashConfig();
|
||||
const { rules } = useRulesData();
|
||||
const { proxies, clashConfig, refreshProxy, rules } = useAppData();
|
||||
const { verge } = useVerge();
|
||||
const { current: currentProfile } = useProfiles();
|
||||
const autoDelayEnabled = verge?.enable_auto_delay_detection ?? false;
|
||||
|
||||
Reference in New Issue
Block a user