Convert all store files from JavaScript to TypeScript

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-03-06 14:47:57 +08:00
parent 90048d0505
commit a619be7881
65 changed files with 2031 additions and 5066 deletions

View File

@@ -2,16 +2,16 @@ import { describe, it, expect, beforeEach, vi } from 'vitest';
import { setActivePinia, createPinia } from 'pinia';
// Mock all heavy imports that MainContainer.vue pulls in
vi.mock('@/stores/loading.js', () => ({
vi.mock('@/stores/loading', () => ({
useLoadingStore: () => ({ isLoading: false }),
}));
vi.mock('@/stores/allMapData.js', () => ({
vi.mock('@/stores/allMapData', () => ({
useAllMapDataStore: () => ({}),
}));
vi.mock('@/stores/conformance.js', () => ({
vi.mock('@/stores/conformance', () => ({
useConformanceStore: () => ({}),
}));
vi.mock('@/stores/pageAdmin.js', () => ({
vi.mock('@/stores/pageAdmin', () => ({
usePageAdminStore: () => ({}),
}));
vi.mock('@/module/alertModal.js', () => ({
@@ -26,7 +26,7 @@ vi.mock('@/router/index.ts', () => ({
}));
vi.mock('@/module/cytoscapeMap.js', () => ({}));
import { useLoginStore } from '@/stores/login.ts';
import { useLoginStore } from '@/stores/login';
import * as cookieUtil from '@/utils/cookieUtil.js';
// Import the component definition to access beforeRouteEnter