Skip to content

Commit 41c7a9a

Browse files
committed
refactor: add startup scripts
1 parent 0290eae commit 41c7a9a

File tree

40 files changed

+62
-34
lines changed

40 files changed

+62
-34
lines changed

packages/platform/src/app/App.tsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import type { UserState } from '../core/state';
1+
import type { UserState } from './core/state';
22
import type { DRootProps } from '@react-devui/ui';
33
import type { DLang } from '@react-devui/ui/utils/types';
44

@@ -9,10 +9,10 @@ import { useNavigate } from 'react-router-dom';
99
import { useAsync, useMount, useStorage } from '@react-devui/hooks';
1010
import { DRoot } from '@react-devui/ui';
1111

12-
import { LOGIN_PATH } from '../config/other';
13-
import { STORAGE_KEY } from '../config/storage';
14-
import { useHttp, useInit } from '../core';
1512
import { AppRoutes } from './Routes';
13+
import { LOGIN_PATH } from './config/other';
14+
import { STORAGE_KEY } from './config/storage';
15+
import { useHttp, useInit } from './core';
1616

1717
export type AppTheme = 'light' | 'dark';
1818

packages/platform/src/app/Routes.guard.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ import type { CanActivateFn } from './Routes';
33
import { isNull, isObject } from 'lodash';
44
import { Navigate, useLocation } from 'react-router-dom';
55

6-
import { LOGIN_PATH, PREV_ROUTE_KEY } from '../config/other';
7-
import { TOKEN, useACL } from '../core';
6+
import { LOGIN_PATH, PREV_ROUTE_KEY } from './config/other';
7+
import { TOKEN, useACL } from './core';
88

99
export function useACLGuard(): CanActivateFn {
1010
const acl = useACL();

packages/platform/src/app/Routes.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
1-
import type { Control, ControlMode } from '../core/useACL';
1+
import type { Control, ControlMode } from './core/useACL';
22
import type { IndexRouteObject, NonIndexRouteObject, RouteMatch } from 'react-router-dom';
33

44
import { nth } from 'lodash';
55
import React from 'react';
66
import { useTranslation } from 'react-i18next';
77
import { matchRoutes, Navigate, renderMatches, useLocation } from 'react-router-dom';
88

9-
import { ROUTES_ACL } from '../config/acl';
10-
import { LOGIN_PATH } from '../config/other';
119
import { useACLGuard, useTokenGuard } from './Routes.guard';
1210
import { AppFCPLoader } from './components';
11+
import { ROUTES_ACL } from './config/acl';
12+
import { LOGIN_PATH } from './config/other';
1313
import { usePageTitle } from './hooks';
1414
import AppHomeRoute from './routes/Home';
1515
import AppExceptionRoute from './routes/exception/Exception';

packages/platform/src/app/components/chart/Chart.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import React, { useEffect, useImperativeHandle, useRef, useState } from 'react';
77
import { useAsync, useResize, useStorage } from '@react-devui/hooks';
88
import { getClassName } from '@react-devui/utils';
99

10-
import { STORAGE_KEY } from '../../../config/storage';
10+
import { STORAGE_KEY } from '../../config/storage';
1111
import chartTheme from './theme.json';
1212

1313
echarts.registerTheme('light', chartTheme.light);

packages/platform/src/app/components/language/Language.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import { useStorage } from '@react-devui/hooks';
88
import { DCustomIcon } from '@react-devui/icons';
99
import { DDropdown } from '@react-devui/ui';
1010

11-
import { STORAGE_KEY } from '../../../config/storage';
11+
import { STORAGE_KEY } from '../../config/storage';
1212

1313
export function AppLanguage(props: React.ButtonHTMLAttributes<HTMLButtonElement>): JSX.Element | null {
1414
const languageStorage = useStorage<DLang>(...STORAGE_KEY.language);

packages/platform/src/app/components/map/Map.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import { Subject } from 'rxjs';
77
import { useStorage } from '@react-devui/hooks';
88
import { getClassName } from '@react-devui/utils';
99

10-
import { STORAGE_KEY } from '../../../config/storage';
10+
import { STORAGE_KEY } from '../../config/storage';
1111
import { AppMapInfoWindow } from './MapInfoWindow';
1212
import { AppMapMarker } from './MapMarker';
1313
import { AppMapMarkerCluster } from './MapMarkerCluster';
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)