Skip to content

Build your own AI office with Univer Office SDK. Bring editing, calculation, collaboration, and file processing into your product for people and AI agents. Built on an extensible open-source core.

refactor(core)!: make `redi` a built-in feature of the `@univerjs/core` (#2801)

白熱ea9219283344
diff --git a/common/shared/vite/auto-externalize-dependency-plugin.js b/common/shared/vite/auto-externalize-dependency-plugin.js
index 7f8c704d84..f5385b9785 100644
--- a/common/shared/vite/auto-externalize-dependency-plugin.js
+++ b/common/shared/vite/auto-externalize-dependency-plugin.js
@@ -24,16 +24,6 @@ exports.autoExternalizeDependency = function autoExternalizeDependency() {
let hasCss = false;
const externalMap = {
- '@wendellhu/redi': {
- global: '@wendellhu/redi',
- name: '@wendellhu/redi',
- version: '0.16.0',
- },
- '@wendellhu/redi/react-bindings': {
- global: '@wendellhu/redi/react-bindings',
- name: '@wendellhu/redi',
- version: '@wendellhu/redi',
- },
clsx: {
global: 'clsx',
name: 'clsx',
diff --git a/common/storybook/.storybook/preview.tsx b/common/storybook/.storybook/preview.tsx
index 951b40f7c2..ff50f01a1e 100644
--- a/common/storybook/.storybook/preview.tsx
+++ b/common/storybook/.storybook/preview.tsx
@@ -16,7 +16,9 @@
import React from 'react';
import type { Preview } from '@storybook/react';
-import { ConfigProvider, defaultTheme, enUS, greenTheme, themeInstance, zhCN } from '@univerjs/design';
+import { ConfigProvider, defaultTheme, greenTheme, themeInstance } from '@univerjs/design';
+import zhCN from '@univerjs/design/locale/zh-CN';
+import enUS from '@univerjs/design/locale/en-US';
import {
CommandService,
ConfigService,
@@ -28,6 +30,7 @@ import {
IContextService,
ILocalStorageService,
ILogService,
+ Injector,
IPermissionService,
IResourceManagerService,
IUndoRedoService,
@@ -38,12 +41,11 @@ import {
LocaleType,
LocalUndoRedoService,
PermissionService,
+ RediContext,
ResourceManagerService,
ThemeService,
UniverInstanceService,
} from '@univerjs/core';
-import { Injector } from '@wendellhu/redi';
-import { RediContext } from '@wendellhu/redi/react-bindings';
import { DesktopLocalStorageService } from '@univerjs/ui';
export const themes: Record<string, Record<string, string>> = {
@@ -107,7 +109,7 @@ const preview: Preview = {
injector.get(LocaleService).setLocale(context.globals.i18n);
themeInstance.setTheme(document.body, themes[context.globals.theme]);
- const designLocale = context.globals.i18n === LocaleType.ZH_CN ? zhCN : enUS;
+ const designLocale = context.globals.i18n === LocaleType.ZH_CN ? zhCN.design : enUS.design;
return (
<RediContext.Provider value={{ injector }}>
diff --git a/common/storybook/package.json b/common/storybook/package.json
index 6680718a05..45a409ae81 100644
--- a/common/storybook/package.json
+++ b/common/storybook/package.json
@@ -30,7 +30,6 @@
"@univerjs/core": "workspace:*",
"@univerjs/design": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"css-loader": "^6.10.0",
"less-loader": "^12.2.0",
"storybook": "8.1.11",
diff --git a/examples/package.json b/examples/package.json
index e4bcbeec33..ee111dc16d 100644
--- a/examples/package.json
+++ b/examples/package.json
@@ -59,7 +59,6 @@
"@univerjs/uni-formula": "workspace:*",
"@univerjs/uniscript": "workspace:*",
"@univerjs/uniui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": "^2.1.1",
"monaco-editor": "0.50.0",
"react": "18.3.1",
diff --git a/packages-experimental/uni-formula-ui/package.json b/packages-experimental/uni-formula-ui/package.json
index cfb11cce58..2f41a48316 100644
--- a/packages-experimental/uni-formula-ui/package.json
+++ b/packages-experimental/uni-formula-ui/package.json
@@ -58,14 +58,12 @@
},
"peerDependencies": {
"@univerjs/core": "workspace:*",
- "@univerjs/uni-formula": "workspace:*",
- "@wendellhu/redi": "0.16.0"
+ "@univerjs/uni-formula": "workspace:*"
},
"devDependencies": {
"@univerjs/core": "workspace:*",
"@univerjs/shared": "workspace:*",
"@univerjs/uni-formula": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": "^7.8.1",
"typescript": "^5.5.3",
"vite": "^5.3.4",
diff --git a/packages-experimental/uni-formula-ui/src/uni-formula-ui.plugin.ts b/packages-experimental/uni-formula-ui/src/uni-formula-ui.plugin.ts
index a71a108153..9e48dcbe26 100644
--- a/packages-experimental/uni-formula-ui/src/uni-formula-ui.plugin.ts
+++ b/packages-experimental/uni-formula-ui/src/uni-formula-ui.plugin.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { DependentOn, Plugin, UniverInstanceType } from '@univerjs/core';
-import { Inject, Injector } from '@wendellhu/redi';
+import { DependentOn, Inject, Injector, Plugin, UniverInstanceType } from '@univerjs/core';
import { UniverDocUniFormulaPlugin } from '@univerjs/uni-formula';
import { DOC_FORMULA_UI_PLUGIN_NAME } from './const';
diff --git a/packages-experimental/uni-formula/package.json b/packages-experimental/uni-formula/package.json
index 09ab8d02b8..4456442da4 100644
--- a/packages-experimental/uni-formula/package.json
+++ b/packages-experimental/uni-formula/package.json
@@ -63,8 +63,7 @@
"@univerjs/core": "workspace:*",
"@univerjs/engine-formula": "workspace:*",
"@univerjs/rpc": "workspace:*",
- "@univerjs/sheets-formula": "workspace:*",
- "@wendellhu/redi": "0.16.0"
+ "@univerjs/sheets-formula": "workspace:*"
},
"dependencies": {
"@univerjs/icons": "^0.1.65"
@@ -78,7 +77,6 @@
"@univerjs/shared": "workspace:*",
"@univerjs/sheets-formula": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": "^2.1.1",
"rxjs": "^7.8.1",
"typescript": "^5.5.3",
diff --git a/packages-experimental/uni-formula/src/services/uni-formula.service.ts b/packages-experimental/uni-formula/src/services/uni-formula.service.ts
index e7a8348760..01d899f13c 100644
--- a/packages-experimental/uni-formula/src/services/uni-formula.service.ts
+++ b/packages-experimental/uni-formula/src/services/uni-formula.service.ts
@@ -14,12 +14,10 @@
* limitations under the License.
*/
-import type { ICellData, IMutation, Nullable } from '@univerjs/core';
-import { CommandType, Disposable, ICommandService, IUniverInstanceService, LifecycleService, LifecycleStages, OnLifecycle, RCDisposable, ResourceManagerService, toDisposable, UniverInstanceType } from '@univerjs/core';
+import type { ICellData, IDisposable, IMutation, Nullable } from '@univerjs/core';
+import { CommandType, Disposable, ICommandService, Inject, IUniverInstanceService, LifecycleService, LifecycleStages, OnLifecycle, Optional, RCDisposable, ResourceManagerService, toDisposable, UniverInstanceType } from '@univerjs/core';
import { DataSyncPrimaryController } from '@univerjs/rpc';
import { RegisterOtherFormulaService } from '@univerjs/sheets-formula';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject, Optional } from '@wendellhu/redi';
import { type IDocFormulaCache, type IDocFormulaData, type IDocFormulaReference, toJson } from '../models/doc-formula';
import { DOC_FORMULA_PLUGIN_NAME } from '../const';
diff --git a/packages-experimental/uni-formula/src/uni-formula.plugin.ts b/packages-experimental/uni-formula/src/uni-formula.plugin.ts
index 3840076b99..d3aa83722c 100644
--- a/packages-experimental/uni-formula/src/uni-formula.plugin.ts
+++ b/packages-experimental/uni-formula/src/uni-formula.plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { DependentOn, Plugin, UniverInstanceType } from '@univerjs/core';
+import { DependentOn, Inject, Injector, Plugin, UniverInstanceType } from '@univerjs/core';
import { UniverFormulaEnginePlugin } from '@univerjs/engine-formula';
-import { Inject, Injector } from '@wendellhu/redi';
import { UniFormulaService } from './services/uni-formula.service';
import { DOC_FORMULA_PLUGIN_NAME } from './const';
diff --git a/packages-experimental/uniui/package.json b/packages-experimental/uniui/package.json
index 3b645a3daa..76118edf5c 100644
--- a/packages-experimental/uniui/package.json
+++ b/packages-experimental/uniui/package.json
@@ -64,7 +64,6 @@
"@univerjs/design": "workspace:*",
"@univerjs/engine-render": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": ">=2.0.0",
"react": "^16.9.0 || ^17.0.0 || ^18.0.0",
"react-dom": "^16.9.0 || ^17.0.0 || ^18.0.0",
@@ -82,7 +81,6 @@
"@univerjs/engine-render": "workspace:*",
"@univerjs/shared": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": "^2.1.1",
"less": "^4.2.0",
"react": "18.3.1",
diff --git a/packages-experimental/uniui/src/controllers/uniui-desktop.controller.tsx b/packages-experimental/uniui/src/controllers/uniui-desktop.controller.tsx
index d75e6d720f..337aed4bb4 100644
--- a/packages-experimental/uniui/src/controllers/uniui-desktop.controller.tsx
+++ b/packages-experimental/uniui/src/controllers/uniui-desktop.controller.tsx
@@ -14,12 +14,10 @@
* limitations under the License.
*/
-import { Disposable, LifecycleService, LifecycleStages, toDisposable } from '@univerjs/core';
+import { connectInjector, Disposable, Inject, Injector, LifecycleService, LifecycleStages, toDisposable } from '@univerjs/core';
import type { IUniverUIConfig, IWorkbenchOptions } from '@univerjs/ui';
import { BuiltInUIPart, CanvasPopup, FloatDom, IUIPartsService } from '@univerjs/ui';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
-import { connectInjector } from '@wendellhu/redi/react-bindings';
+import type { IDisposable } from '@univerjs/core';
import React from 'react';
import { delay, filter, take } from 'rxjs';
import { render as createRoot, unmount } from 'rc-util/lib/React/render';
diff --git a/packages-experimental/uniui/src/plugin.ts b/packages-experimental/uniui/src/plugin.ts
index afda4382d8..de5e80b676 100644
--- a/packages-experimental/uniui/src/plugin.ts
+++ b/packages-experimental/uniui/src/plugin.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { DependentOn, IContextService, ILocalStorageService, mergeOverrideWithDependencies, Plugin, Tools } from '@univerjs/core';
+import { DependentOn, IContextService, ILocalStorageService, Inject, Injector, mergeOverrideWithDependencies, Plugin, Tools } from '@univerjs/core';
import { UniverRenderEnginePlugin } from '@univerjs/engine-render';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import type { Dependency } from '@univerjs/core';
import type { IUniverUIConfig } from '@univerjs/ui';
import {
BrowserClipboardService,
diff --git a/packages-experimental/uniui/src/views/workbench/UniWorkbench.tsx b/packages-experimental/uniui/src/views/workbench/UniWorkbench.tsx
index e2b1eddcb9..5f3fd598d3 100644
--- a/packages-experimental/uniui/src/views/workbench/UniWorkbench.tsx
+++ b/packages-experimental/uniui/src/views/workbench/UniWorkbench.tsx
@@ -16,7 +16,7 @@
// Refer to packages/ui/src/views/App.tsx
-import { IContextService, IUniverInstanceService, LocaleService, ThemeService } from '@univerjs/core';
+import { IContextService, IUniverInstanceService, LocaleService, ThemeService, useDependency } from '@univerjs/core';
import { ConfigContext, ConfigProvider, defaultTheme, themeInstance } from '@univerjs/design';
import type { ILocale } from '@univerjs/design';
import {
@@ -33,7 +33,6 @@ import {
useObservable,
ZenZone,
} from '@univerjs/ui';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import React, { useCallback, useContext, useEffect, useMemo, useRef, useState } from 'react';
import { createPortal } from 'react-dom';
import clsx from 'clsx';
diff --git a/packages/core/package.json b/packages/core/package.json
index 90d22d799d..33526947d2 100644
--- a/packages/core/package.json
+++ b/packages/core/package.json
@@ -60,11 +60,12 @@
"sync:cnpm": "cnpm sync"
},
"peerDependencies": {
- "@wendellhu/redi": "0.16.0",
+ "react": "^16.9.0 || ^17.0.0 || ^18.0.0",
"rxjs": ">=7.0.0"
},
"dependencies": {
"@univerjs/protocol": "0.1.38-alpha.23",
+ "@wendellhu/redi": "0.16.0",
"nanoid": "5.0.7",
"numeral": "^2.0.6",
"ot-json1": "^1.0.2"
@@ -72,7 +73,6 @@
"devDependencies": {
"@types/numeral": "^2.0.5",
"@univerjs/shared": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": "^7.8.1",
"typescript": "^5.5.3",
"vite": "^5.3.4",
diff --git a/packages/core/src/common/di.ts b/packages/core/src/common/di.ts
new file mode 100644
index 0000000000..e4731f015c
--- /dev/null
+++ b/packages/core/src/common/di.ts
@@ -0,0 +1,18 @@
+/**
+ * Copyright 2023-present DreamNum Inc.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+export * from '@wendellhu/redi';
+export * from '@wendellhu/redi/react-bindings';
diff --git a/packages/core/src/index.ts b/packages/core/src/index.ts
index c341db66d8..414ac555a5 100644
--- a/packages/core/src/index.ts
+++ b/packages/core/src/index.ts
@@ -16,6 +16,8 @@
import { installShims } from './common/shims';
+installShims();
+
export { DEFAULT_DOCUMENT_SUB_COMPONENT_ID } from './docs/data-model/subdocument';
export { type UnitType, UnitModel, UniverInstanceType } from './common/unit';
export { Registry, RegistryAsMap } from './common/registry';
@@ -187,4 +189,5 @@ export { normalizeBody, getCustomRangeSlice, getCustomDecorationSlice } from './
export { updateAttributeByDelete } from './docs/data-model/text-x/apply-utils/delete-apply';
export { updateAttributeByInsert } from './docs/data-model/text-x/apply-utils/insert-apply';
export { nameCharacterCheck } from './shared/name';
-installShims();
+
+export * from './common/di';
diff --git a/packages/core/src/services/__tests__/index.ts b/packages/core/src/services/__tests__/index.ts
index ff9c9d4871..a8de206540 100644
--- a/packages/core/src/services/__tests__/index.ts
+++ b/packages/core/src/services/__tests__/index.ts
@@ -17,8 +17,8 @@
import type { IWorkbookData } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, LocaleType, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import type { Dependency } from '../../common/di';
+import { Inject, Injector } from '../../common/di';
const TEST_WORKBOOK_DATA_DEMO: () => IWorkbookData = () => ({
id: 'test',
diff --git a/packages/core/src/services/authz-io/authz-io-local.service.ts b/packages/core/src/services/authz-io/authz-io-local.service.ts
index 8fa5575279..b0a55062d6 100644
--- a/packages/core/src/services/authz-io/authz-io-local.service.ts
+++ b/packages/core/src/services/authz-io/authz-io-local.service.ts
@@ -16,7 +16,7 @@
import type { IActionInfo, IAllowedRequest, IBatchAllowedResponse, ICollaborator, ICreateRequest, ICreateRequest_SelectRangeObject, ICreateRequest_WorksheetObject, IListPermPointRequest, IPermissionPoint, IPutCollaboratorsRequest, IUnitRoleKV, IUpdatePermPointRequest, UnitAction } from '@univerjs/protocol';
import { CreateRequest_WorkSheetObjectScope, UnitObject, UnitRole, UniverType } from '@univerjs/protocol';
-import { Inject } from '@wendellhu/redi';
+import { Inject } from '../../common/di';
import { Tools } from '../../shared/tools';
import { IResourceManagerService } from '../resource-manager/type';
import { UserManagerService } from '../user-manager/user-manager.service';
diff --git a/packages/core/src/services/authz-io/type.ts b/packages/core/src/services/authz-io/type.ts
index c9c454110b..debbecf9fa 100644
--- a/packages/core/src/services/authz-io/type.ts
+++ b/packages/core/src/services/authz-io/type.ts
@@ -15,8 +15,8 @@
*/
import type { ILogContext } from '@univerjs/core';
-import { createIdentifier } from '@wendellhu/redi';
import type { IAllowedRequest, IAllowedResponse, IBatchAllowedResponse, ICreateCollaboratorRequest, ICreateRequest, ICreateResponse, IDeleteCollaboratorRequest, IListCollaboratorRequest, IListCollaboratorResponse, IListPermPointRequest, IListPermPointResponse, IListRolesRequest, IListRolesResponse, IPutCollaboratorsRequest, IUpdateCollaboratorRequest, IUpdatePermPointRequest } from '@univerjs/protocol';
+import { createIdentifier } from '../../common/di';
export interface IAuthzIoService {
create(config: ICreateRequest, context?: ILogContext): Promise<ICreateResponse['objectID']>;
diff --git a/packages/core/src/services/command/__tests__/command.service.spec.ts b/packages/core/src/services/command/__tests__/command.service.spec.ts
index da13648549..3db36124dd 100644
--- a/packages/core/src/services/command/__tests__/command.service.spec.ts
+++ b/packages/core/src/services/command/__tests__/command.service.spec.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-import { Injector } from '@wendellhu/redi';
import { beforeEach, describe, expect, it, vi } from 'vitest';
+import { Injector } from '../../../common/di';
import { ContextService, IContextService } from '../../context/context.service';
import { DesktopLogService, ILogService } from '../../log/log.service';
diff --git a/packages/core/src/services/command/command.service.ts b/packages/core/src/services/command/command.service.ts
index 8e6d512f6b..4774ca57cb 100644
--- a/packages/core/src/services/command/command.service.ts
+++ b/packages/core/src/services/command/command.service.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-import type { IAccessor, IDisposable } from '@wendellhu/redi';
-import { createIdentifier, Inject, Injector } from '@wendellhu/redi';
+import type { IAccessor, IDisposable } from '../../common/di';
+import { createIdentifier, Inject, Injector } from '../../common/di';
import { findLast, remove } from '../../common/array';
import { sequence, sequenceAsync } from '../../common/sequence';
diff --git a/packages/core/src/services/config/config.service.ts b/packages/core/src/services/config/config.service.ts
index 474d6c1386..d96f8089ff 100644
--- a/packages/core/src/services/config/config.service.ts
+++ b/packages/core/src/services/config/config.service.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier } from '../../common/di';
import type { Nullable } from '../../shared/types';
diff --git a/packages/core/src/services/context/context.service.ts b/packages/core/src/services/context/context.service.ts
index b00e8f0d9e..e7cc50cfa8 100644
--- a/packages/core/src/services/context/context.service.ts
+++ b/packages/core/src/services/context/context.service.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-import { createIdentifier } from '@wendellhu/redi';
import { filter, Observable, Subject } from 'rxjs';
+import { createIdentifier } from '../../common/di';
import { Disposable } from '../../shared/lifecycle';
diff --git a/packages/core/src/services/instance/instance.service.ts b/packages/core/src/services/instance/instance.service.ts
index b1486ac5d2..ea33e920b5 100644
--- a/packages/core/src/services/instance/instance.service.ts
+++ b/packages/core/src/services/instance/instance.service.ts
@@ -14,10 +14,10 @@
* limitations under the License.
*/
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier, Inject, Injector } from '@wendellhu/redi';
import type { Observable } from 'rxjs';
import { BehaviorSubject, distinctUntilChanged, filter, map, Subject } from 'rxjs';
+import type { IDisposable } from '../../common/di';
+import { createIdentifier, Inject, Injector } from '../../common/di';
import { DocumentDataModel } from '../../docs/data-model/document-data-model';
import type { Nullable } from '../../shared';
diff --git a/packages/core/src/services/lifecycle/__tests__/lifecycle.service.spec.ts b/packages/core/src/services/lifecycle/__tests__/lifecycle.service.spec.ts
index 34eb21a170..65c76118c7 100644
--- a/packages/core/src/services/lifecycle/__tests__/lifecycle.service.spec.ts
+++ b/packages/core/src/services/lifecycle/__tests__/lifecycle.service.spec.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-import { Injector } from '@wendellhu/redi';
import { afterEach, describe, expect, it } from 'vitest';
+import { Injector } from '../../../common/di';
import { DesktopLogService, ILogService } from '../../log/log.service';
import { LifecycleStages } from '../lifecycle';
diff --git a/packages/core/src/services/lifecycle/lifecycle.service.ts b/packages/core/src/services/lifecycle/lifecycle.service.ts
index b233c52a3e..7594295c6f 100644
--- a/packages/core/src/services/lifecycle/lifecycle.service.ts
+++ b/packages/core/src/services/lifecycle/lifecycle.service.ts
@@ -14,10 +14,10 @@
* limitations under the License.
*/
-import type { DependencyIdentifier } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
import type { Observable } from 'rxjs';
import { BehaviorSubject, merge, of, skip } from 'rxjs';
+import type { DependencyIdentifier } from '../../common/di';
+import { Inject, Injector } from '../../common/di';
import { Disposable } from '../../shared/lifecycle';
import { ILogService } from '../log/log.service';
diff --git a/packages/core/src/services/lifecycle/lifecycle.ts b/packages/core/src/services/lifecycle/lifecycle.ts
index d0e06f395d..bfb47955a9 100644
--- a/packages/core/src/services/lifecycle/lifecycle.ts
+++ b/packages/core/src/services/lifecycle/lifecycle.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { Ctor, DependencyIdentifier } from '@wendellhu/redi';
+import type { Ctor, DependencyIdentifier } from '../../common/di';
/**
* This enum defines multiple lifecycle stages in Univer SDK.
diff --git a/packages/core/src/services/local-storage/local-storage.service.ts b/packages/core/src/services/local-storage/local-storage.service.ts
index 15eee8741b..e148880e70 100644
--- a/packages/core/src/services/local-storage/local-storage.service.ts
+++ b/packages/core/src/services/local-storage/local-storage.service.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier } from '../../common/di';
export const ILocalStorageService = createIdentifier<ILocalStorageService>('ILocalStorageService');
diff --git a/packages/core/src/services/log/log.service.ts b/packages/core/src/services/log/log.service.ts
index 2aea0637fb..3ca9388dc6 100644
--- a/packages/core/src/services/log/log.service.ts
+++ b/packages/core/src/services/log/log.service.ts
@@ -16,7 +16,7 @@
/* eslint-disable no-console */
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier } from '../../common/di';
import { Disposable } from '../../shared/lifecycle';
diff --git a/packages/core/src/services/permission/type.ts b/packages/core/src/services/permission/type.ts
index fbd3c55d2e..21cf0d5ed2 100644
--- a/packages/core/src/services/permission/type.ts
+++ b/packages/core/src/services/permission/type.ts
@@ -15,8 +15,8 @@
*/
import type { BehaviorSubject, Observable } from 'rxjs';
-import { createIdentifier } from '@wendellhu/redi';
import type { UnitAction, UnitObject } from '@univerjs/protocol';
+import { createIdentifier } from '../../common/di';
import type { Nullable } from '../../common/type-utils';
import { LifecycleStages, runOnLifecycle } from '../lifecycle/lifecycle';
import type { IRange } from '../../types/interfaces';
diff --git a/packages/core/src/services/plugin/__tests__/plugin-override.spec.ts b/packages/core/src/services/plugin/__tests__/plugin-override.spec.ts
index 1b3f57945b..1a5e76d349 100644
--- a/packages/core/src/services/plugin/__tests__/plugin-override.spec.ts
+++ b/packages/core/src/services/plugin/__tests__/plugin-override.spec.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-import { createIdentifier } from '@wendellhu/redi';
import { describe, expect, it } from 'vitest';
+import { createIdentifier } from '../../../common/di';
import { mergeOverrideWithDependencies } from '../plugin-override';
describe('test dependency override', () => {
diff --git a/packages/core/src/services/plugin/plugin-override.ts b/packages/core/src/services/plugin/plugin-override.ts
index 7c6306a934..d327c2d4bc 100644
--- a/packages/core/src/services/plugin/plugin-override.ts
+++ b/packages/core/src/services/plugin/plugin-override.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { Dependency, DependencyIdentifier, DependencyItem } from '@wendellhu/redi';
+import type { Dependency, DependencyIdentifier, DependencyItem } from '../../common/di';
export type NullableDependencyPair<T> = [DependencyIdentifier<T>, DependencyItem<T> | null];
diff --git a/packages/core/src/services/plugin/plugin.service.ts b/packages/core/src/services/plugin/plugin.service.ts
index 7bac5ea5a7..f4e65a6665 100644
--- a/packages/core/src/services/plugin/plugin.service.ts
+++ b/packages/core/src/services/plugin/plugin.service.ts
@@ -14,9 +14,9 @@
* limitations under the License.
*/
-import type { Ctor, IDisposable } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
import { skip } from 'rxjs';
+import type { Ctor, IDisposable } from '../../common/di';
+import { Inject, Injector } from '../../common/di';
import { Disposable } from '../../shared/lifecycle';
import { type UnitType, UniverInstanceType } from '../../common/unit';
diff --git a/packages/core/src/services/plugin/plugin.ts b/packages/core/src/services/plugin/plugin.ts
index e568324f6c..adc6383f39 100644
--- a/packages/core/src/services/plugin/plugin.ts
+++ b/packages/core/src/services/plugin/plugin.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { Ctor, Injector } from '@wendellhu/redi';
+import type { Ctor, Injector } from '../../common/di';
import { Disposable } from '../../shared';
import { UniverInstanceType } from '../../common/unit';
diff --git a/packages/core/src/services/resource-loader/resource-loader.service.ts b/packages/core/src/services/resource-loader/resource-loader.service.ts
index 3dd9f642f3..dd9174ddc9 100644
--- a/packages/core/src/services/resource-loader/resource-loader.service.ts
+++ b/packages/core/src/services/resource-loader/resource-loader.service.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import { Inject } from '@wendellhu/redi';
+import { Inject } from '../../common/di';
import type { Workbook } from '../../sheets/workbook';
import type { IWorkbookData } from '../../types/interfaces';
import type { IResourceHook } from '../resource-manager/type';
diff --git a/packages/core/src/services/resource-loader/type.ts b/packages/core/src/services/resource-loader/type.ts
index 5e0e547786..eeba166919 100644
--- a/packages/core/src/services/resource-loader/type.ts
+++ b/packages/core/src/services/resource-loader/type.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier } from '../../common/di';
import type { Workbook } from '../../sheets/workbook';
import type { IWorkbookData } from '../../types/interfaces/i-workbook-data';
import { LifecycleStages, runOnLifecycle } from '../lifecycle/lifecycle';
diff --git a/packages/core/src/services/resource-manager/type.ts b/packages/core/src/services/resource-manager/type.ts
index d9d65d1496..3f71085322 100644
--- a/packages/core/src/services/resource-manager/type.ts
+++ b/packages/core/src/services/resource-manager/type.ts
@@ -14,10 +14,10 @@
* limitations under the License.
*/
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier } from '@wendellhu/redi';
import type { Observable } from 'rxjs';
import type { UniverInstanceType } from '@univerjs/core';
+import type { IDisposable } from '../../common/di';
+import { createIdentifier } from '../../common/di';
import type { IWorkbookData } from '../../types/interfaces/i-workbook-data';
type IBusinessName = 'SHEET' | 'DOC';
diff --git a/packages/core/src/services/snapshot/snapshot-server.service.ts b/packages/core/src/services/snapshot/snapshot-server.service.ts
index a959b0bb37..3878eec130 100644
--- a/packages/core/src/services/snapshot/snapshot-server.service.ts
+++ b/packages/core/src/services/snapshot/snapshot-server.service.ts
@@ -35,7 +35,7 @@ import type {
ISaveSnapshotResponse,
ISheetBlock,
} from '@univerjs/protocol';
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier } from '../../common/di';
import type { ILogContext } from '../log/context';
diff --git a/packages/core/src/services/undoredo/undoredo.service.ts b/packages/core/src/services/undoredo/undoredo.service.ts
index 6fd9391890..3c1fcc50b4 100644
--- a/packages/core/src/services/undoredo/undoredo.service.ts
+++ b/packages/core/src/services/undoredo/undoredo.service.ts
@@ -14,10 +14,10 @@
* limitations under the License.
*/
-import type { IAccessor, IDisposable } from '@wendellhu/redi';
-import { createIdentifier } from '@wendellhu/redi';
import type { Observable } from 'rxjs';
import { BehaviorSubject } from 'rxjs';
+import type { IAccessor, IDisposable } from '../../common/di';
+import { createIdentifier } from '../../common/di';
import { DOCS_FORMULA_BAR_EDITOR_UNIT_ID_KEY, DOCS_NORMAL_EDITOR_UNIT_ID_KEY } from '../../common/const';
import { Disposable, toDisposable } from '../../shared/lifecycle';
diff --git a/packages/core/src/shared/lifecycle.ts b/packages/core/src/shared/lifecycle.ts
index db7b723891..ac337d1f74 100644
--- a/packages/core/src/shared/lifecycle.ts
+++ b/packages/core/src/shared/lifecycle.ts
@@ -14,10 +14,10 @@
* limitations under the License.
*/
-import type { IDisposable } from '@wendellhu/redi';
import type { Subscription, SubscriptionLike } from 'rxjs';
import { Subject } from 'rxjs';
import { isSubscription } from 'rxjs/internal/Subscription';
+import type { IDisposable } from '../common/di';
type DisposableLike = IDisposable | SubscriptionLike | (() => void);
diff --git a/packages/core/src/shared/lru/lru-map.ts b/packages/core/src/shared/lru/lru-map.ts
index f8e76570b6..89c9e1baed 100644
--- a/packages/core/src/shared/lru/lru-map.ts
+++ b/packages/core/src/shared/lru/lru-map.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { IDisposable } from '@wendellhu/redi';
+import type { IDisposable } from '../../common/di';
import { remove } from '../../common/array';
import { toDisposable } from '../lifecycle';
diff --git a/packages/core/src/shared/rxjs.ts b/packages/core/src/shared/rxjs.ts
index a7e326ac96..33e6a5ffb1 100644
--- a/packages/core/src/shared/rxjs.ts
+++ b/packages/core/src/shared/rxjs.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-import type { IDisposable } from '@wendellhu/redi';
import { Observable } from 'rxjs';
+import type { IDisposable } from '../common/di';
type CallbackFn<T extends readonly unknown[]> = (cb: (...args: T) => void) => IDisposable;
diff --git a/packages/core/src/sheets/view-model.ts b/packages/core/src/sheets/view-model.ts
index a84cdca60f..143f2ddd8a 100644
--- a/packages/core/src/sheets/view-model.ts
+++ b/packages/core/src/sheets/view-model.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { IDisposable } from '@wendellhu/redi';
+import type { IDisposable } from '../common/di';
import type { Nullable } from '../common/type-util';
import { Disposable, toDisposable } from '../shared/lifecycle';
diff --git a/packages/core/src/univer.ts b/packages/core/src/univer.ts
index 9b85455cb2..6a748d3e9d 100644
--- a/packages/core/src/univer.ts
+++ b/packages/core/src/univer.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-import type { Dependency } from '@wendellhu/redi';
-import { Injector } from '@wendellhu/redi';
+import type { Dependency } from './common/di';
+import { Injector } from './common/di';
import { DocumentDataModel } from './docs/data-model/document-data-model';
import { CommandService, ICommandService } from './services/command/command.service';
diff --git a/packages/data-validation/package.json b/packages/data-validation/package.json
index 045386c1b4..4bdf4e6b06 100644
--- a/packages/data-validation/package.json
+++ b/packages/data-validation/package.json
@@ -65,7 +65,6 @@
"peerDependencies": {
"@univerjs/core": "workspace:*",
"@univerjs/sheets": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": ">=7.0.0"
},
"dependencies": {
@@ -75,7 +74,6 @@
"@univerjs/core": "workspace:*",
"@univerjs/shared": "workspace:*",
"@univerjs/sheets": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": "^7.8.1",
"typescript": "^5.5.3",
"vite": "^5.3.4",
diff --git a/packages/data-validation/src/commands/commands/data-validation.command.ts b/packages/data-validation/src/commands/commands/data-validation.command.ts
index ac477593a9..8dcf864494 100644
--- a/packages/data-validation/src/commands/commands/data-validation.command.ts
+++ b/packages/data-validation/src/commands/commands/data-validation.command.ts
@@ -15,8 +15,7 @@
*/
import { CommandType, ICommandService, ILogService, IUndoRedoService } from '@univerjs/core';
-import type { ICommand, IDataValidationRule, IDataValidationRuleBase, IDataValidationRuleOptions, IMutationInfo, IRange, ISheetDataValidationRule } from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
+import type { ICommand, IDataValidationRule, IDataValidationRuleBase, IDataValidationRuleOptions, IMutationInfo, Injector, IRange, ISheetDataValidationRule } from '@univerjs/core';
import type { ISheetCommandSharedParams } from '@univerjs/sheets';
import type { IAddDataValidationMutationParams, IRemoveDataValidationMutationParams, IUpdateDataValidationMutationParams } from '../mutations/data-validation.mutation';
import { AddDataValidationMutation, RemoveDataValidationMutation, UpdateDataValidationMutation } from '../mutations/data-validation.mutation';
diff --git a/packages/data-validation/src/common/util.ts b/packages/data-validation/src/common/util.ts
index b1bb4dc3c0..4c1fedeabe 100644
--- a/packages/data-validation/src/common/util.ts
+++ b/packages/data-validation/src/common/util.ts
@@ -14,9 +14,9 @@
* limitations under the License.
*/
-import { DataValidationOperator, DataValidationType, type IDataValidationRuleBase, type IDataValidationRuleOptions, Tools } from '@univerjs/core';
+import type { IAccessor, IDataValidationRuleBase, IDataValidationRuleOptions } from '@univerjs/core';
+import { DataValidationOperator, DataValidationType, Tools } from '@univerjs/core';
import { SheetsSelectionsService } from '@univerjs/sheets';
-import type { IAccessor } from '@wendellhu/redi';
export function getRuleSetting(rule: IDataValidationRuleBase): IDataValidationRuleBase {
return {
diff --git a/packages/data-validation/src/controllers/dv-resource.controller.ts b/packages/data-validation/src/controllers/dv-resource.controller.ts
index 625d32e3ca..c96231cfdc 100644
--- a/packages/data-validation/src/controllers/dv-resource.controller.ts
+++ b/packages/data-validation/src/controllers/dv-resource.controller.ts
@@ -15,8 +15,7 @@
*/
import type { ISheetDataValidationRule } from '@univerjs/core';
-import { Disposable, IResourceManagerService, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { Disposable, Inject, IResourceManagerService, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import { DataValidationModel } from '../models/data-validation-model';
type DataValidationJSON = Record<string, ISheetDataValidationRule[]>;
diff --git a/packages/data-validation/src/controllers/dv-sheet.controller.ts b/packages/data-validation/src/controllers/dv-sheet.controller.ts
index 4056c4065a..0e0bc22ee4 100644
--- a/packages/data-validation/src/controllers/dv-sheet.controller.ts
+++ b/packages/data-validation/src/controllers/dv-sheet.controller.ts
@@ -15,10 +15,9 @@
*/
import type { Workbook } from '@univerjs/core';
-import { Disposable, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
+import { Disposable, Inject, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import type { IRemoveSheetCommandParams } from '@univerjs/sheets';
import { RemoveSheetCommand, SheetInterceptorService } from '@univerjs/sheets';
-import { Inject } from '@wendellhu/redi';
import type { IAddDataValidationMutationParams, IRemoveDataValidationMutationParams } from '../commands/mutations/data-validation.mutation';
import { AddDataValidationMutation, RemoveDataValidationMutation } from '../commands/mutations/data-validation.mutation';
import { DataValidationModel } from '../models/data-validation-model';
diff --git a/packages/data-validation/src/plugin.ts b/packages/data-validation/src/plugin.ts
index d9af8e6c77..cda4f0ae37 100644
--- a/packages/data-validation/src/plugin.ts
+++ b/packages/data-validation/src/plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { ICommandService, Plugin, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { ICommandService, Inject, Injector, Plugin, UniverInstanceType } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
import { DataValidatorRegistryService } from './services/data-validator-registry.service';
import { DataValidationModel } from './models/data-validation-model';
import { AddDataValidationCommand, RemoveAllDataValidationCommand, RemoveDataValidationCommand, UpdateDataValidationOptionsCommand, UpdateDataValidationSettingCommand } from './commands/commands/data-validation.command';
diff --git a/packages/data-validation/src/validators/base-data-validator.ts b/packages/data-validation/src/validators/base-data-validator.ts
index 01c3e3fae1..94cee0fe07 100644
--- a/packages/data-validation/src/validators/base-data-validator.ts
+++ b/packages/data-validation/src/validators/base-data-validator.ts
@@ -15,8 +15,7 @@
*/
import type { CellValue, IDataValidationRule, IDataValidationRuleBase, Nullable } from '@univerjs/core';
-import { DataValidationOperator, LocaleService, Tools } from '@univerjs/core';
-import { Inject, Injector } from '@wendellhu/redi';
+import { DataValidationOperator, Inject, Injector, LocaleService, Tools } from '@univerjs/core';
import { OperatorErrorTitleMap, OperatorTitleMap } from '../types/const/operator-text-map';
import type { IBaseDataValidationWidget } from './base-widget';
diff --git a/packages/debugger/package.json b/packages/debugger/package.json
index 6bbc2286af..5198427a7a 100644
--- a/packages/debugger/package.json
+++ b/packages/debugger/package.json
@@ -61,7 +61,6 @@
"@univerjs/sheets": "workspace:*",
"@univerjs/sheets-drawing-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"react": "^16.9.0 || ^17.0.0 || ^18.0.0",
"rxjs": ">=7.0.0"
},
@@ -77,7 +76,6 @@
"@univerjs/sheets-drawing-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
"@vitejs/plugin-vue": "^5.0.4",
- "@wendellhu/redi": "0.16.0",
"rxjs": "^7.8.1",
"typescript": "^5.5.3",
"vite": "^5.3.4",
diff --git a/packages/debugger/src/commands/operations/change-user.operation.ts b/packages/debugger/src/commands/operations/change-user.operation.ts
index 30e401abc4..75fff119dd 100644
--- a/packages/debugger/src/commands/operations/change-user.operation.ts
+++ b/packages/debugger/src/commands/operations/change-user.operation.ts
@@ -14,12 +14,10 @@
* limitations under the License.
*/
-import type { ICommand, Workbook } from '@univerjs/core';
+import type { IAccessor, ICommand, Workbook } from '@univerjs/core';
import { CommandType, createDefaultUser, IPermissionService, IUniverInstanceService, UniverInstanceType, UserManagerService } from '@univerjs/core';
import { WorkbookManageCollaboratorPermission } from '@univerjs/sheets';
-import type { IAccessor } from '@wendellhu/redi';
-
export enum UnitRole {
Reader = 0,
Editor = 1,
diff --git a/packages/debugger/src/commands/operations/confirm.operation.ts b/packages/debugger/src/commands/operations/confirm.operation.ts
index dd475bd5f6..8708a8d8ab 100644
--- a/packages/debugger/src/commands/operations/confirm.operation.ts
+++ b/packages/debugger/src/commands/operations/confirm.operation.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType } from '@univerjs/core';
import { IConfirmService } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
export interface IUIComponentCommandParams {
value: string;
diff --git a/packages/debugger/src/commands/operations/dialog.operation.ts b/packages/debugger/src/commands/operations/dialog.operation.ts
index 4ed82a4f9e..c6ccf5b469 100644
--- a/packages/debugger/src/commands/operations/dialog.operation.ts
+++ b/packages/debugger/src/commands/operations/dialog.operation.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType } from '@univerjs/core';
import { IDialogService } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
export interface IUIComponentCommandParams {
value: string;
diff --git a/packages/debugger/src/commands/operations/locale.operation.ts b/packages/debugger/src/commands/operations/locale.operation.ts
index 446fce60bc..1ae9b0d2d2 100644
--- a/packages/debugger/src/commands/operations/locale.operation.ts
+++ b/packages/debugger/src/commands/operations/locale.operation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICommand, LocaleType } from '@univerjs/core';
+import type { IAccessor, ICommand, LocaleType } from '@univerjs/core';
import { CommandType, LocaleService } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
export interface ILocaleCommandParams {
value: LocaleType;
diff --git a/packages/debugger/src/commands/operations/message.operation.ts b/packages/debugger/src/commands/operations/message.operation.ts
index a418f8a222..5e18104189 100644
--- a/packages/debugger/src/commands/operations/message.operation.ts
+++ b/packages/debugger/src/commands/operations/message.operation.ts
@@ -14,11 +14,10 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType } from '@univerjs/core';
import { MessageType } from '@univerjs/design';
import { IMessageService } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
export const MessageOperation: ICommand = {
id: 'debugger.operation.message',
diff --git a/packages/debugger/src/commands/operations/notification.operation.ts b/packages/debugger/src/commands/operations/notification.operation.ts
index 159eed6ac6..9eeebbcdb1 100644
--- a/packages/debugger/src/commands/operations/notification.operation.ts
+++ b/packages/debugger/src/commands/operations/notification.operation.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType } from '@univerjs/core';
import { INotificationService } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
export interface IUIComponentCommandParams {
value: string;
diff --git a/packages/debugger/src/commands/operations/numfmt.operations.ts b/packages/debugger/src/commands/operations/numfmt.operations.ts
index da0c5264b0..fd128f3c32 100644
--- a/packages/debugger/src/commands/operations/numfmt.operations.ts
+++ b/packages/debugger/src/commands/operations/numfmt.operations.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType, ICommandService } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
export interface INumfmtOperationCommandParams {
value: 'close' | 'open';
diff --git a/packages/debugger/src/commands/operations/save-snapshot.operations.ts b/packages/debugger/src/commands/operations/save-snapshot.operations.ts
index d3f4aecaf3..7d7d68e487 100644
--- a/packages/debugger/src/commands/operations/save-snapshot.operations.ts
+++ b/packages/debugger/src/commands/operations/save-snapshot.operations.ts
@@ -15,9 +15,8 @@
*/
/* eslint-disable node/prefer-global/process */
-import type { DocumentDataModel, ICommand, IStyleData, IWorkbookData, Workbook } from '@univerjs/core';
+import type { DocumentDataModel, IAccessor, ICommand, IStyleData, IWorkbookData, Workbook } from '@univerjs/core';
import { CommandType, IResourceLoaderService, IUniverInstanceService, ObjectMatrix, UniverInstanceType } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { RecordController } from '../../controllers/local-save/record.controller';
import { ExportController } from '../../controllers/local-save/export.controller';
diff --git a/packages/debugger/src/commands/operations/set.editable.operation.ts b/packages/debugger/src/commands/operations/set.editable.operation.ts
index fd49bfd28c..5a8379453a 100644
--- a/packages/debugger/src/commands/operations/set.editable.operation.ts
+++ b/packages/debugger/src/commands/operations/set.editable.operation.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType, IPermissionService, IUniverInstanceService } from '@univerjs/core';
import { getSheetCommandTarget, WorkbookEditablePermission, WorksheetEditPermission } from '@univerjs/sheets';
-import type { IAccessor } from '@wendellhu/redi';
export interface ISetEditableCommandParams {
value: 'sheet' | 'univer';
diff --git a/packages/debugger/src/commands/operations/sidebar.operation.ts b/packages/debugger/src/commands/operations/sidebar.operation.ts
index 273d17a12c..e835c2c6cb 100644
--- a/packages/debugger/src/commands/operations/sidebar.operation.ts
+++ b/packages/debugger/src/commands/operations/sidebar.operation.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { ICommand, Workbook } from '@univerjs/core';
+import type { IAccessor, ICommand, Workbook } from '@univerjs/core';
import { CommandType, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
import { IEditorService, ISidebarService } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
import { TEST_EDITOR_CONTAINER_COMPONENT } from '../../views/test-editor/component-name';
export interface IUIComponentCommandParams {
diff --git a/packages/debugger/src/commands/operations/theme.operation.ts b/packages/debugger/src/commands/operations/theme.operation.ts
index 3f01f301f2..8e80116bff 100644
--- a/packages/debugger/src/commands/operations/theme.operation.ts
+++ b/packages/debugger/src/commands/operations/theme.operation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICommand, IStyleSheet } from '@univerjs/core';
+import type { IAccessor, ICommand, IStyleSheet } from '@univerjs/core';
import { CommandType, ThemeService } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
export interface IThemeCommandParams {
value?: IStyleSheet;
diff --git a/packages/debugger/src/controllers/debugger.controller.ts b/packages/debugger/src/controllers/debugger.controller.ts
index 2765d7c35a..c79d1a5605 100644
--- a/packages/debugger/src/controllers/debugger.controller.ts
+++ b/packages/debugger/src/controllers/debugger.controller.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { Disposable, ICommandService } from '@univerjs/core';
+import { Disposable, ICommandService, Inject, Injector } from '@univerjs/core';
import type { IMenuItemFactory, MenuConfig } from '@univerjs/ui';
import { ComponentManager, IMenuService } from '@univerjs/ui';
-import { Inject, Injector } from '@wendellhu/redi';
import { ConfirmOperation } from '../commands/operations/confirm.operation';
import { DialogOperation } from '../commands/operations/dialog.operation';
diff --git a/packages/debugger/src/controllers/local-save/record.controller.ts b/packages/debugger/src/controllers/local-save/record.controller.ts
index e8e6a3f8b1..4d659faa13 100644
--- a/packages/debugger/src/controllers/local-save/record.controller.ts
+++ b/packages/debugger/src/controllers/local-save/record.controller.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { CommandType, ICommandService } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { CommandType, ICommandService, Inject } from '@univerjs/core';
import { Observable } from 'rxjs';
export class RecordController {
diff --git a/packages/debugger/src/controllers/menu.ts b/packages/debugger/src/controllers/menu.ts
index 7f5fd603bb..ee8ce5e0f8 100644
--- a/packages/debugger/src/controllers/menu.ts
+++ b/packages/debugger/src/controllers/menu.ts
@@ -18,7 +18,7 @@ import { LocaleType } from '@univerjs/core';
import { defaultTheme, greenTheme } from '@univerjs/design';
import type { IMenuButtonItem, IMenuSelectorItem } from '@univerjs/ui';
import { MenuItemType, MenuPosition } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor } from '@univerjs/core';
import { ConfirmOperation } from '../commands/operations/confirm.operation';
import { DialogOperation } from '../commands/operations/dialog.operation';
diff --git a/packages/debugger/src/controllers/performance-monitor.controller.ts b/packages/debugger/src/controllers/performance-monitor.controller.ts
index e37f2abe29..1373b5c0f6 100644
--- a/packages/debugger/src/controllers/performance-monitor.controller.ts
+++ b/packages/debugger/src/controllers/performance-monitor.controller.ts
@@ -15,9 +15,8 @@
*/
import type { Nullable } from '@univerjs/core';
-import { IUniverInstanceService, LifecycleService, LifecycleStages, OnLifecycle, RxDisposable } from '@univerjs/core';
+import { Inject, IUniverInstanceService, LifecycleService, LifecycleStages, OnLifecycle, RxDisposable } from '@univerjs/core';
import { IRenderManagerService } from '@univerjs/engine-render';
-import { Inject } from '@wendellhu/redi';
import type { Subscription } from 'rxjs';
import { distinctUntilChanged, filter, take, takeUntil } from 'rxjs';
diff --git a/packages/debugger/src/debugger-plugin.ts b/packages/debugger/src/debugger-plugin.ts
index d0eaf1a3db..f7d15a3334 100644
--- a/packages/debugger/src/debugger-plugin.ts
+++ b/packages/debugger/src/debugger-plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { Plugin, Tools } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { Inject, Injector, Plugin, Tools } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
import type { IUniverDebuggerConfig } from './controllers/debugger.controller';
import { DebuggerController, DefaultDebuggerConfig } from './controllers/debugger.controller';
diff --git a/packages/debugger/src/views/test-editor/TestTextEditor.tsx b/packages/debugger/src/views/test-editor/TestTextEditor.tsx
index 90f09bf448..3d52aab369 100644
--- a/packages/debugger/src/views/test-editor/TestTextEditor.tsx
+++ b/packages/debugger/src/views/test-editor/TestTextEditor.tsx
@@ -18,8 +18,7 @@ import React, { useState } from 'react';
import { RangeSelector, TextEditor } from '@univerjs/ui';
import type { Workbook } from '@univerjs/core';
-import { createInternalEditorID, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { createInternalEditorID, IUniverInstanceService, UniverInstanceType, useDependency } from '@univerjs/core';
import { Input } from '@univerjs/design';
const editorStyle: React.CSSProperties = {
diff --git a/packages/docs-drawing-ui/package.json b/packages/docs-drawing-ui/package.json
index 7152ac675c..0712c909d1 100644
--- a/packages/docs-drawing-ui/package.json
+++ b/packages/docs-drawing-ui/package.json
@@ -72,7 +72,6 @@
"@univerjs/drawing-ui": "workspace:*",
"@univerjs/engine-render": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": ">=2.0.0",
"react": "^16.9.0 || ^17.0.0 || ^18.0.0",
"rxjs": ">=7.0.0"
@@ -91,7 +90,6 @@
"@univerjs/engine-render": "workspace:*",
"@univerjs/shared": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": "^2.1.1",
"less": "^4.2.0",
"ot-json1": "^1.0.2",
diff --git a/packages/docs-drawing-ui/src/commands/commands/delete-doc-drawing.command.ts b/packages/docs-drawing-ui/src/commands/commands/delete-doc-drawing.command.ts
index 0486d2d2ee..eef6834704 100644
--- a/packages/docs-drawing-ui/src/commands/commands/delete-doc-drawing.command.ts
+++ b/packages/docs-drawing-ui/src/commands/commands/delete-doc-drawing.command.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-import { CommandType, type ICommand, ICommandService } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor, ICommand } from '@univerjs/core';
+import { CommandType, ICommandService } from '@univerjs/core';
import type { IDocDrawing } from '@univerjs/docs-drawing';
import { IDocDrawingService } from '@univerjs/docs-drawing';
import { RemoveDocDrawingCommand } from './remove-doc-drawing.command';
diff --git a/packages/docs-drawing-ui/src/commands/commands/group-doc-drawing.command.ts b/packages/docs-drawing-ui/src/commands/commands/group-doc-drawing.command.ts
index c72422a6aa..c04a6b251f 100644
--- a/packages/docs-drawing-ui/src/commands/commands/group-doc-drawing.command.ts
+++ b/packages/docs-drawing-ui/src/commands/commands/group-doc-drawing.command.ts
@@ -14,13 +14,12 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import {
CommandType,
ICommandService,
IUndoRedoService,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { IDrawingGroupUpdateParam, IDrawingJsonUndo1 } from '@univerjs/drawing';
import { IDocDrawingService } from '@univerjs/docs-drawing';
diff --git a/packages/docs-drawing-ui/src/commands/commands/insert-doc-drawing.command.ts b/packages/docs-drawing-ui/src/commands/commands/insert-doc-drawing.command.ts
index 82a804626e..f50e1507e8 100644
--- a/packages/docs-drawing-ui/src/commands/commands/insert-doc-drawing.command.ts
+++ b/packages/docs-drawing-ui/src/commands/commands/insert-doc-drawing.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICommand, IMutationInfo, JSONXActions } from '@univerjs/core';
+import type { IAccessor, ICommand, IMutationInfo, JSONXActions } from '@univerjs/core';
import {
CommandType,
ICommandService,
@@ -23,7 +23,6 @@ import {
TextX,
TextXActionType,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { IRichTextEditingMutationParams } from '@univerjs/docs';
import { getRetainAndDeleteFromReplace, getRichTextEditPath, RichTextEditingMutation, TextSelectionManagerService } from '@univerjs/docs';
import type { IInsertDrawingCommandParams } from './interfaces';
diff --git a/packages/docs-drawing-ui/src/commands/commands/move-drawings.command.ts b/packages/docs-drawing-ui/src/commands/commands/move-drawings.command.ts
index 39021c3f94..d790118821 100644
--- a/packages/docs-drawing-ui/src/commands/commands/move-drawings.command.ts
+++ b/packages/docs-drawing-ui/src/commands/commands/move-drawings.command.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType, Direction, ICommandService, IUniverInstanceService, PositionedObjectLayoutType } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { IDocDrawing } from '@univerjs/docs-drawing';
import { IDocDrawingService } from '@univerjs/docs-drawing';
import { IRenderManagerService } from '@univerjs/engine-render';
diff --git a/packages/docs-drawing-ui/src/commands/commands/remove-doc-drawing.command.ts b/packages/docs-drawing-ui/src/commands/commands/remove-doc-drawing.command.ts
index 4da24e57bc..2366002406 100644
--- a/packages/docs-drawing-ui/src/commands/commands/remove-doc-drawing.command.ts
+++ b/packages/docs-drawing-ui/src/commands/commands/remove-doc-drawing.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICommand, IMutationInfo, JSONXActions } from '@univerjs/core';
+import type { IAccessor, ICommand, IMutationInfo, JSONXActions } from '@univerjs/core';
import {
CommandType,
ICommandService,
@@ -24,7 +24,6 @@ import {
TextX,
TextXActionType,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { IRichTextEditingMutationParams } from '@univerjs/docs';
import { getRichTextEditPath, RichTextEditingMutation } from '@univerjs/docs';
import { type ITextRangeWithStyle, ITextSelectionRenderManager } from '@univerjs/engine-render';
diff --git a/packages/docs-drawing-ui/src/commands/commands/set-drawing-arrange.command.ts b/packages/docs-drawing-ui/src/commands/commands/set-drawing-arrange.command.ts
index 4c210631d7..af0be412ad 100644
--- a/packages/docs-drawing-ui/src/commands/commands/set-drawing-arrange.command.ts
+++ b/packages/docs-drawing-ui/src/commands/commands/set-drawing-arrange.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICommand, IMutationInfo, JSONXActions, Nullable } from '@univerjs/core';
+import type { IAccessor, ICommand, IMutationInfo, JSONXActions, Nullable } from '@univerjs/core';
import {
CommandType,
ICommandService,
@@ -26,7 +26,6 @@ import { RichTextEditingMutation } from '@univerjs/docs';
import { IDocDrawingService } from '@univerjs/docs-drawing';
import type { IDrawingJsonUndo1, IDrawingOrderMapParam } from '@univerjs/drawing';
import { ArrangeTypeEnum } from '@univerjs/drawing';
-import type { IAccessor } from '@wendellhu/redi';
export interface ISetDrawingArrangeCommandParams extends IDrawingOrderMapParam {
arrangeType: ArrangeTypeEnum;
diff --git a/packages/docs-drawing-ui/src/commands/commands/ungroup-doc-drawing.command.ts b/packages/docs-drawing-ui/src/commands/commands/ungroup-doc-drawing.command.ts
index 5b2bfdec48..7a915bcf80 100644
--- a/packages/docs-drawing-ui/src/commands/commands/ungroup-doc-drawing.command.ts
+++ b/packages/docs-drawing-ui/src/commands/commands/ungroup-doc-drawing.command.ts
@@ -14,14 +14,13 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import {
CommandType,
ICommandService,
IUndoRedoService,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { IDrawingGroupUpdateParam, IDrawingJsonUndo1 } from '@univerjs/drawing';
import { IDocDrawingService } from '@univerjs/docs-drawing';
diff --git a/packages/docs-drawing-ui/src/commands/commands/update-doc-drawing.command.ts b/packages/docs-drawing-ui/src/commands/commands/update-doc-drawing.command.ts
index ffe7fd541a..f88eda27b8 100644
--- a/packages/docs-drawing-ui/src/commands/commands/update-doc-drawing.command.ts
+++ b/packages/docs-drawing-ui/src/commands/commands/update-doc-drawing.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { DocumentDataModel, ICommand, IDocDrawingBase, IDocDrawingPosition, IMutationInfo, IObjectPositionH, IObjectPositionV, ISize, JSONXActions, WrapTextType } from '@univerjs/core';
+import type { DocumentDataModel, IAccessor, ICommand, IDocDrawingBase, IDocDrawingPosition, IMutationInfo, IObjectPositionH, IObjectPositionV, ISize, JSONXActions, WrapTextType } from '@univerjs/core';
import {
BooleanNumber,
CommandType,
@@ -28,7 +28,6 @@ import {
TextXActionType,
Tools,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { IRichTextEditingMutationParams } from '@univerjs/docs';
import { DocSkeletonManagerService, getRichTextEditPath, RichTextEditingMutation } from '@univerjs/docs';
import type { IDocDrawing } from '@univerjs/docs-drawing';
diff --git a/packages/docs-drawing-ui/src/commands/operations/edit-doc-drawing.operation.ts b/packages/docs-drawing-ui/src/commands/operations/edit-doc-drawing.operation.ts
index bb05c80b1a..f3c62c03ea 100644
--- a/packages/docs-drawing-ui/src/commands/operations/edit-doc-drawing.operation.ts
+++ b/packages/docs-drawing-ui/src/commands/operations/edit-doc-drawing.operation.ts
@@ -14,13 +14,12 @@
* limitations under the License.
*/
-import type { IOperation } from '@univerjs/core';
+import type { IAccessor, IOperation } from '@univerjs/core';
import {
CommandType,
ICommandService,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { IDrawingSearch } from '@univerjs/drawing';
import { IDrawingManagerService } from '@univerjs/drawing';
import { SidebarDocDrawingOperation } from './open-drawing-panel.operation';
diff --git a/packages/docs-drawing-ui/src/commands/operations/open-drawing-panel.operation.ts b/packages/docs-drawing-ui/src/commands/operations/open-drawing-panel.operation.ts
index c2ce2a8fb1..8cd1d123fb 100644
--- a/packages/docs-drawing-ui/src/commands/operations/open-drawing-panel.operation.ts
+++ b/packages/docs-drawing-ui/src/commands/operations/open-drawing-panel.operation.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType, LocaleService } from '@univerjs/core';
import { ISidebarService } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
import { IDrawingManagerService } from '@univerjs/drawing';
import { COMPONENT_DOC_DRAWING_PANEL } from '../../views/doc-image-panel/component-name';
diff --git a/packages/docs-drawing-ui/src/controllers/doc-drawing.controller.ts b/packages/docs-drawing-ui/src/controllers/doc-drawing.controller.ts
index 239f5dbb63..b212f46f85 100644
--- a/packages/docs-drawing-ui/src/controllers/doc-drawing.controller.ts
+++ b/packages/docs-drawing-ui/src/controllers/doc-drawing.controller.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { Disposable, ICommandService, LifecycleStages, OnLifecycle } from '@univerjs/core';
+import { Disposable, ICommandService, Inject, Injector, LifecycleStages, OnLifecycle } from '@univerjs/core';
import type { IMenuItemFactory } from '@univerjs/ui';
import { ComponentManager, IMenuService, IShortcutService } from '@univerjs/ui';
-import { Inject, Injector } from '@wendellhu/redi';
import { AddImageSingle } from '@univerjs/icons';
import { UploadFileMenu } from '../views/upload-component/UploadFile';
diff --git a/packages/docs-drawing-ui/src/controllers/drawing-popup-menu.controller.ts b/packages/docs-drawing-ui/src/controllers/drawing-popup-menu.controller.ts
index 78d62efbe7..fd6b72305f 100644
--- a/packages/docs-drawing-ui/src/controllers/drawing-popup-menu.controller.ts
+++ b/packages/docs-drawing-ui/src/controllers/drawing-popup-menu.controller.ts
@@ -14,10 +14,8 @@
* limitations under the License.
*/
-import type { DocumentDataModel, Nullable } from '@univerjs/core';
-import { FOCUSING_COMMON_DRAWINGS, IContextService, IUniverInstanceService, LifecycleStages, OnLifecycle, RxDisposable, toDisposable, UniverInstanceType } from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject } from '@wendellhu/redi';
+import type { DocumentDataModel, IDisposable, Nullable } from '@univerjs/core';
+import { FOCUSING_COMMON_DRAWINGS, IContextService, Inject, IUniverInstanceService, LifecycleStages, OnLifecycle, RxDisposable, toDisposable, UniverInstanceType } from '@univerjs/core';
import type { BaseObject, Scene } from '@univerjs/engine-render';
import { IRenderManagerService } from '@univerjs/engine-render';
import { COMPONENT_IMAGE_POPUP_MENU, ImageCropperObject, ImageResetSizeOperation, OpenImageCropOperation } from '@univerjs/drawing-ui';
diff --git a/packages/docs-drawing-ui/src/controllers/render-controllers/doc-drawing-transform-update.controller.ts b/packages/docs-drawing-ui/src/controllers/render-controllers/doc-drawing-transform-update.controller.ts
index 7ec92520bb..b3b4a0003f 100644
--- a/packages/docs-drawing-ui/src/controllers/render-controllers/doc-drawing-transform-update.controller.ts
+++ b/packages/docs-drawing-ui/src/controllers/render-controllers/doc-drawing-transform-update.controller.ts
@@ -19,6 +19,7 @@ import {
BooleanNumber,
Disposable,
ICommandService,
+ Inject,
PositionedObjectLayoutType,
} from '@univerjs/core';
import type { IRichTextEditingMutationParams } from '@univerjs/docs';
@@ -27,7 +28,6 @@ import { IDrawingManagerService } from '@univerjs/drawing';
import type { Documents, DocumentSkeleton, IDocumentSkeletonHeaderFooter, IDocumentSkeletonPage, Image, IRenderContext, IRenderModule } from '@univerjs/engine-render';
import { Liquid } from '@univerjs/engine-render';
import { IEditorService } from '@univerjs/ui';
-import { Inject } from '@wendellhu/redi';
import { DocRefreshDrawingsService } from '../../services/doc-refresh-drawings.service';
interface IDrawingParamsWithBehindText {
diff --git a/packages/docs-drawing-ui/src/controllers/render-controllers/doc-drawing-update.render-controller.ts b/packages/docs-drawing-ui/src/controllers/render-controllers/doc-drawing-update.render-controller.ts
index f403a9f4c9..61def40f04 100644
--- a/packages/docs-drawing-ui/src/controllers/render-controllers/doc-drawing-update.render-controller.ts
+++ b/packages/docs-drawing-ui/src/controllers/render-controllers/doc-drawing-update.render-controller.ts
@@ -15,8 +15,7 @@
*/
import type { DocumentDataModel, ICommandInfo, IDocDrawingPosition, Nullable } from '@univerjs/core';
-import { BooleanNumber, Disposable, FOCUSING_COMMON_DRAWINGS, ICommandService, IContextService, LocaleService, ObjectRelativeFromH, ObjectRelativeFromV, PositionedObjectLayoutType, WrapTextType } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { BooleanNumber, Disposable, FOCUSING_COMMON_DRAWINGS, ICommandService, IContextService, Inject, LocaleService, ObjectRelativeFromH, ObjectRelativeFromV, PositionedObjectLayoutType, WrapTextType } from '@univerjs/core';
import type { IImageIoServiceParam } from '@univerjs/drawing';
import { DRAWING_IMAGE_ALLOW_SIZE, DRAWING_IMAGE_COUNT_LIMIT, DRAWING_IMAGE_HEIGHT_LIMIT, DRAWING_IMAGE_WIDTH_LIMIT, DrawingTypeEnum, getDrawingShapeKeyByDrawingSearch, getImageSize, IDrawingManagerService, IImageIoService, ImageUploadStatusType } from '@univerjs/drawing';
import { IMessageService } from '@univerjs/ui';
diff --git a/packages/docs-drawing-ui/src/plugin.ts b/packages/docs-drawing-ui/src/plugin.ts
index a5c825166d..7d9f8320e6 100644
--- a/packages/docs-drawing-ui/src/plugin.ts
+++ b/packages/docs-drawing-ui/src/plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { DependentOn, Plugin, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { DependentOn, Inject, Injector, Plugin, UniverInstanceType } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
import { UniverDrawingUIPlugin } from '@univerjs/drawing-ui';
import { UniverDrawingPlugin } from '@univerjs/drawing';
import { UniverDocsDrawingPlugin } from '@univerjs/docs-drawing';
diff --git a/packages/docs-drawing-ui/src/views/doc-image-panel/DocDrawingPanel.tsx b/packages/docs-drawing-ui/src/views/doc-image-panel/DocDrawingPanel.tsx
index 541e5eef15..c5a814ffbb 100644
--- a/packages/docs-drawing-ui/src/views/doc-image-panel/DocDrawingPanel.tsx
+++ b/packages/docs-drawing-ui/src/views/doc-image-panel/DocDrawingPanel.tsx
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { useDependency } from '@univerjs/core';
import React, { useEffect, useState } from 'react';
import { DrawingCommonPanel } from '@univerjs/drawing-ui';
import type { IDrawingParam } from '@univerjs/drawing';
diff --git a/packages/docs-drawing-ui/src/views/doc-image-panel/DocDrawingPosition.tsx b/packages/docs-drawing-ui/src/views/doc-image-panel/DocDrawingPosition.tsx
index 9da7165514..7c286e67db 100644
--- a/packages/docs-drawing-ui/src/views/doc-image-panel/DocDrawingPosition.tsx
+++ b/packages/docs-drawing-ui/src/views/doc-image-panel/DocDrawingPosition.tsx
@@ -15,8 +15,7 @@
*/
import type { ICommandInfo, IObjectPositionH, IObjectPositionV, Nullable } from '@univerjs/core';
-import { ICommandService, IUniverInstanceService, LocaleService, ObjectRelativeFromH, ObjectRelativeFromV, PositionedObjectLayoutType } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { ICommandService, IUniverInstanceService, LocaleService, ObjectRelativeFromH, ObjectRelativeFromV, PositionedObjectLayoutType, useDependency } from '@univerjs/core';
import React, { useEffect, useState } from 'react';
import clsx from 'clsx';
import type { IDocumentSkeletonDrawing } from '@univerjs/engine-render';
diff --git a/packages/docs-drawing-ui/src/views/doc-image-panel/DocDrawingTextWrap.tsx b/packages/docs-drawing-ui/src/views/doc-image-panel/DocDrawingTextWrap.tsx
index 74f075e2e5..6cf812d287 100644
--- a/packages/docs-drawing-ui/src/views/doc-image-panel/DocDrawingTextWrap.tsx
+++ b/packages/docs-drawing-ui/src/views/doc-image-panel/DocDrawingTextWrap.tsx
@@ -15,8 +15,7 @@
*/
import type { ICommandInfo, Nullable } from '@univerjs/core';
-import { BooleanNumber, ICommandService, IUniverInstanceService, LocaleService, PositionedObjectLayoutType, WrapTextType } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { BooleanNumber, ICommandService, IUniverInstanceService, LocaleService, PositionedObjectLayoutType, useDependency, WrapTextType } from '@univerjs/core';
import React, { useEffect, useState } from 'react';
import clsx from 'clsx';
import { IRenderManagerService } from '@univerjs/engine-render';
diff --git a/packages/docs-drawing-ui/src/views/menu/image.menu.ts b/packages/docs-drawing-ui/src/views/menu/image.menu.ts
index 001c345e52..2a37be0d57 100644
--- a/packages/docs-drawing-ui/src/views/menu/image.menu.ts
+++ b/packages/docs-drawing-ui/src/views/menu/image.menu.ts
@@ -15,8 +15,8 @@
*/
import { getMenuHiddenObservable, type IMenuItem, MenuGroup, MenuItemType, MenuPosition } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
import { UniverInstanceType } from '@univerjs/core';
+import type { IAccessor } from '@univerjs/core';
import { COMPONENT_DOC_UPLOAD_FILE_MENU } from '../upload-component/component-name';
diff --git a/packages/docs-drawing-ui/src/views/upload-component/UploadFile.tsx b/packages/docs-drawing-ui/src/views/upload-component/UploadFile.tsx
index 710464d268..dab53188b5 100644
--- a/packages/docs-drawing-ui/src/views/upload-component/UploadFile.tsx
+++ b/packages/docs-drawing-ui/src/views/upload-component/UploadFile.tsx
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { ICommandService } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { ICommandService, useDependency } from '@univerjs/core';
import React, { useRef } from 'react';
import { DRAWING_IMAGE_ALLOW_IMAGE_LIST } from '@univerjs/drawing';
import { InsertDocImageOperation } from '../../commands/operations/insert-image.operation';
diff --git a/packages/docs-drawing/package.json b/packages/docs-drawing/package.json
index f0bf881775..98dfecc8ed 100644
--- a/packages/docs-drawing/package.json
+++ b/packages/docs-drawing/package.json
@@ -60,7 +60,6 @@
"peerDependencies": {
"@univerjs/core": "workspace:*",
"@univerjs/drawing": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": ">=7.0.0"
},
"devDependencies": {
@@ -69,7 +68,6 @@
"@univerjs/drawing": "workspace:*",
"@univerjs/engine-render": "workspace:*",
"@univerjs/shared": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"typescript": "^5.5.3",
"vite": "^5.3.4",
"vitest": "^2.0.3"
diff --git a/packages/docs-drawing/src/controllers/doc-drawing.controller.ts b/packages/docs-drawing/src/controllers/doc-drawing.controller.ts
index 095ce443f1..daaf95b527 100644
--- a/packages/docs-drawing/src/controllers/doc-drawing.controller.ts
+++ b/packages/docs-drawing/src/controllers/doc-drawing.controller.ts
@@ -15,10 +15,9 @@
*/
import type { DocumentDataModel, IDocumentData } from '@univerjs/core';
-import { Disposable, ICommandService, IResourceManagerService, IUniverInstanceService, LifecycleService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
+import { Disposable, ICommandService, Inject, IResourceManagerService, IUniverInstanceService, LifecycleService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import type { IDrawingMapItem, IDrawingMapItemData } from '@univerjs/drawing';
import { IDrawingManagerService } from '@univerjs/drawing';
-import { Inject } from '@wendellhu/redi';
import { filter, first } from 'rxjs/operators';
import { type IDocDrawing, IDocDrawingService } from '../services/doc-drawing.service';
diff --git a/packages/docs-drawing/src/plugin.ts b/packages/docs-drawing/src/plugin.ts
index 8729a24822..3dd1d4dc57 100644
--- a/packages/docs-drawing/src/plugin.ts
+++ b/packages/docs-drawing/src/plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { Plugin, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { Inject, Injector, Plugin, UniverInstanceType } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
import { DocDrawingController, DocDrawingLoadController, DOCS_DRAWING_PLUGIN } from './controllers/doc-drawing.controller';
import { DocDrawingService, IDocDrawingService } from './services/doc-drawing.service';
diff --git a/packages/docs-drawing/src/services/doc-drawing.service.ts b/packages/docs-drawing/src/services/doc-drawing.service.ts
index 3f6ab1b291..358fbb39cf 100644
--- a/packages/docs-drawing/src/services/doc-drawing.service.ts
+++ b/packages/docs-drawing/src/services/doc-drawing.service.ts
@@ -15,7 +15,7 @@
*/
import type { IDocDrawingBase } from '@univerjs/core';
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier } from '@univerjs/core';
import { type IImageData, type IUnitDrawingService, UnitDrawingService } from '@univerjs/drawing';
export interface IDocImage extends IImageData, IDocDrawingBase {}
diff --git a/packages/docs-hyper-link-ui/package.json b/packages/docs-hyper-link-ui/package.json
index 3d4bf60570..2aa7ea9657 100644
--- a/packages/docs-hyper-link-ui/package.json
+++ b/packages/docs-hyper-link-ui/package.json
@@ -66,7 +66,6 @@
"@univerjs/docs-ui": "workspace:*",
"@univerjs/engine-render": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": ">=2.0.0",
"react": "^16.9.0 || ^17.0.0 || ^18.0.0",
"rxjs": ">=7.0.0"
@@ -82,7 +81,6 @@
"@univerjs/engine-render": "workspace:*",
"@univerjs/shared": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": "^2.1.1",
"react": "18.3.1",
"rxjs": "^7.8.1",
diff --git a/packages/docs-hyper-link-ui/src/commands/operations/popup.operation.ts b/packages/docs-hyper-link-ui/src/commands/operations/popup.operation.ts
index ea5a7af831..7023c18ce4 100644
--- a/packages/docs-hyper-link-ui/src/commands/operations/popup.operation.ts
+++ b/packages/docs-hyper-link-ui/src/commands/operations/popup.operation.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { DocumentDataModel, ICommand } from '@univerjs/core';
+import type { DocumentDataModel, IAccessor, ICommand } from '@univerjs/core';
import { CommandType, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
import { DocSkeletonManagerService, TextSelectionManagerService } from '@univerjs/docs';
-import type { IAccessor } from '@wendellhu/redi';
import { DocumentEditArea, IRenderManagerService } from '@univerjs/engine-render';
import { DocHyperLinkPopupService } from '../../services/hyper-link-popup.service';
diff --git a/packages/docs-hyper-link-ui/src/controllers/doc-hyper-link-clipboard.controller.ts b/packages/docs-hyper-link-ui/src/controllers/doc-hyper-link-clipboard.controller.ts
index 2bfaa2bde0..697355f89e 100644
--- a/packages/docs-hyper-link-ui/src/controllers/doc-hyper-link-clipboard.controller.ts
+++ b/packages/docs-hyper-link-ui/src/controllers/doc-hyper-link-clipboard.controller.ts
@@ -15,11 +15,10 @@
*/
import type { DocumentDataModel } from '@univerjs/core';
-import { CustomRangeType, Disposable, IUniverInstanceService, LifecycleStages, OnLifecycle, Tools, UniverInstanceType, updateAttributeByDelete } from '@univerjs/core';
+import { CustomRangeType, Disposable, Inject, IUniverInstanceService, LifecycleStages, OnLifecycle, Tools, UniverInstanceType, updateAttributeByDelete } from '@univerjs/core';
import { TextSelectionManagerService } from '@univerjs/docs';
import { DocHyperLinkModel } from '@univerjs/docs-hyper-link';
import { IDocClipboardService } from '@univerjs/docs-ui';
-import { Inject } from '@wendellhu/redi';
@OnLifecycle(LifecycleStages.Ready, DocHyperLinkClipboardController)
export class DocHyperLinkClipboardController extends Disposable {
diff --git a/packages/docs-hyper-link-ui/src/controllers/doc-hyper-link-selection.controller.ts b/packages/docs-hyper-link-ui/src/controllers/doc-hyper-link-selection.controller.ts
index 8669d31e3a..680ea1999a 100644
--- a/packages/docs-hyper-link-ui/src/controllers/doc-hyper-link-selection.controller.ts
+++ b/packages/docs-hyper-link-ui/src/controllers/doc-hyper-link-selection.controller.ts
@@ -15,10 +15,9 @@
*/
import type { DocumentDataModel } from '@univerjs/core';
-import { Disposable, ICommandService, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
+import { Disposable, ICommandService, Inject, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import type { ISetTextSelectionsOperationParams } from '@univerjs/docs';
import { DocSkeletonManagerService, SetTextSelectionsOperation } from '@univerjs/docs';
-import { Inject } from '@wendellhu/redi';
import { DocumentEditArea, IRenderManagerService } from '@univerjs/engine-render';
import { DocHyperLinkPopupService } from '../services/hyper-link-popup.service';
diff --git a/packages/docs-hyper-link-ui/src/controllers/menu.ts b/packages/docs-hyper-link-ui/src/controllers/menu.ts
index a928a6efee..3991455e5b 100644
--- a/packages/docs-hyper-link-ui/src/controllers/menu.ts
+++ b/packages/docs-hyper-link-ui/src/controllers/menu.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor } from '@univerjs/core';
import { UniverInstanceType } from '@univerjs/core';
import type { IMenuButtonItem, IShortcutItem } from '@univerjs/ui';
import { getMenuHiddenObservable, KeyCode, MenuGroup, MenuItemType, MenuPosition, MetaKeys } from '@univerjs/ui';
diff --git a/packages/docs-hyper-link-ui/src/controllers/render-controllers/render.controller.ts b/packages/docs-hyper-link-ui/src/controllers/render-controllers/render.controller.ts
index d0821e5bca..5840b999eb 100644
--- a/packages/docs-hyper-link-ui/src/controllers/render-controllers/render.controller.ts
+++ b/packages/docs-hyper-link-ui/src/controllers/render-controllers/render.controller.ts
@@ -15,10 +15,9 @@
*/
import type { DocumentDataModel } from '@univerjs/core';
-import { Disposable } from '@univerjs/core';
+import { Disposable, Inject } from '@univerjs/core';
import type { IRenderContext, IRenderModule } from '@univerjs/engine-render';
import { DOC_INTERCEPTOR_POINT, DocInterceptorService } from '@univerjs/docs';
-import { Inject } from '@wendellhu/redi';
import { DocHyperLinkPopupService } from '../../services/hyper-link-popup.service';
export class DocHyperLinkRenderController extends Disposable implements IRenderModule {
diff --git a/packages/docs-hyper-link-ui/src/controllers/ui.controller.ts b/packages/docs-hyper-link-ui/src/controllers/ui.controller.ts
index 9be86e868e..b8558560dd 100644
--- a/packages/docs-hyper-link-ui/src/controllers/ui.controller.ts
+++ b/packages/docs-hyper-link-ui/src/controllers/ui.controller.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { Disposable, ICommandService, LifecycleStages, OnLifecycle } from '@univerjs/core';
+import { Disposable, ICommandService, Inject, Injector, LifecycleStages, OnLifecycle } from '@univerjs/core';
import type { MenuConfig } from '@univerjs/ui';
import { ComponentManager, IMenuService, IShortcutService } from '@univerjs/ui';
-import { Inject, Injector } from '@wendellhu/redi';
import { LinkSingle } from '@univerjs/icons';
import { DocHyperLinkEdit } from '../views/hyper-link-edit';
import { AddDocHyperLinkCommand } from '../commands/commands/add-link.command';
diff --git a/packages/docs-hyper-link-ui/src/plugin.ts b/packages/docs-hyper-link-ui/src/plugin.ts
index b52258034e..d8f96754de 100644
--- a/packages/docs-hyper-link-ui/src/plugin.ts
+++ b/packages/docs-hyper-link-ui/src/plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { DependentOn, Plugin, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { DependentOn, Inject, Injector, Plugin, UniverInstanceType } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
import { UniverDocsHyperLinkPlugin } from '@univerjs/docs-hyper-link';
import { IRenderManagerService } from '@univerjs/engine-render';
import { DOC_HYPER_LINK_UI_PLUGIN } from './types/const';
diff --git a/packages/docs-hyper-link-ui/src/services/hyper-link-popup.service.ts b/packages/docs-hyper-link-ui/src/services/hyper-link-popup.service.ts
index 2fab383b58..ec9840ddf9 100644
--- a/packages/docs-hyper-link-ui/src/services/hyper-link-popup.service.ts
+++ b/packages/docs-hyper-link-ui/src/services/hyper-link-popup.service.ts
@@ -14,12 +14,10 @@
* limitations under the License.
*/
-import type { DocumentDataModel, ITextRange, Nullable } from '@univerjs/core';
-import { Disposable, ICommandService, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
+import type { DocumentDataModel, IDisposable, ITextRange, Nullable } from '@univerjs/core';
+import { Disposable, ICommandService, Inject, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
import { TextSelectionManagerService } from '@univerjs/docs';
import { DocCanvasPopManagerService } from '@univerjs/docs-ui';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject } from '@wendellhu/redi';
import { BehaviorSubject } from 'rxjs';
import { DocHyperLinkModel } from '@univerjs/docs-hyper-link';
import { DocHyperLinkEdit } from '../views/hyper-link-edit';
diff --git a/packages/docs-hyper-link-ui/src/views/hyper-link-edit/index.tsx b/packages/docs-hyper-link-ui/src/views/hyper-link-edit/index.tsx
index e92d82eff5..1885189220 100644
--- a/packages/docs-hyper-link-ui/src/views/hyper-link-edit/index.tsx
+++ b/packages/docs-hyper-link-ui/src/views/hyper-link-edit/index.tsx
@@ -17,10 +17,9 @@
import { Button, FormLayout, Input } from '@univerjs/design';
import React, { useEffect, useState } from 'react';
import { CloseSingle } from '@univerjs/icons';
-import { useDependency, useObservable } from '@wendellhu/redi/react-bindings';
+import { ICommandService, IUniverInstanceService, LocaleService, Tools, UniverInstanceType, useDependency, useObservable } from '@univerjs/core';
import { DocHyperLinkModel } from '@univerjs/docs-hyper-link';
import type { DocumentDataModel } from '@univerjs/core';
-import { ICommandService, IUniverInstanceService, LocaleService, Tools, UniverInstanceType } from '@univerjs/core';
import { ITextSelectionRenderManager } from '@univerjs/engine-render';
import { TextSelectionManagerService } from '@univerjs/docs';
import { DocHyperLinkPopupService } from '../../services/hyper-link-popup.service';
diff --git a/packages/docs-hyper-link-ui/src/views/hyper-link-popup/index.tsx b/packages/docs-hyper-link-ui/src/views/hyper-link-popup/index.tsx
index 73270395ba..9e5cd22ce2 100644
--- a/packages/docs-hyper-link-ui/src/views/hyper-link-popup/index.tsx
+++ b/packages/docs-hyper-link-ui/src/views/hyper-link-popup/index.tsx
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { ICommandService, LocaleService, useDependency } from '@univerjs/core';
import React from 'react';
import { CopySingle, LinkSingle, UnlinkSingle, WriteSingle } from '@univerjs/icons';
-import { ICommandService, LocaleService } from '@univerjs/core';
import cs from 'clsx';
import { MessageType, Tooltip } from '@univerjs/design';
import { IMessageService, useObservable } from '@univerjs/ui';
diff --git a/packages/docs-hyper-link/package.json b/packages/docs-hyper-link/package.json
index 8f374d3bf8..a3ff8a1741 100644
--- a/packages/docs-hyper-link/package.json
+++ b/packages/docs-hyper-link/package.json
@@ -59,7 +59,6 @@
"peerDependencies": {
"@univerjs/core": "workspace:*",
"@univerjs/docs": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": ">=7.0.0"
},
"devDependencies": {
@@ -67,7 +66,6 @@
"@univerjs/design": "workspace:*",
"@univerjs/docs": "workspace:*",
"@univerjs/shared": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": "^7.8.1",
"typescript": "^5.5.3",
"vite": "^5.3.4",
diff --git a/packages/docs-hyper-link/src/controllers/doc-hyper-link-custom-range.controller.ts b/packages/docs-hyper-link/src/controllers/doc-hyper-link-custom-range.controller.ts
index d8249334c0..f4c154ee21 100644
--- a/packages/docs-hyper-link/src/controllers/doc-hyper-link-custom-range.controller.ts
+++ b/packages/docs-hyper-link/src/controllers/doc-hyper-link-custom-range.controller.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { CustomRangeType, Disposable, LifecycleStages, OnLifecycle, Tools } from '@univerjs/core';
+import { CustomRangeType, Disposable, Inject, LifecycleStages, OnLifecycle, Tools } from '@univerjs/core';
import { DocCustomRangeService } from '@univerjs/docs';
-import { Inject } from '@wendellhu/redi';
import { DocHyperLinkModel } from '../models/hyper-link.model';
@OnLifecycle(LifecycleStages.Ready, DocHyperLinkCustomRangeController)
diff --git a/packages/docs-hyper-link/src/controllers/resource.controller.ts b/packages/docs-hyper-link/src/controllers/resource.controller.ts
index 0896b5cc14..f8f4850b55 100644
--- a/packages/docs-hyper-link/src/controllers/resource.controller.ts
+++ b/packages/docs-hyper-link/src/controllers/resource.controller.ts
@@ -15,8 +15,7 @@
*/
import type { DocumentDataModel } from '@univerjs/core';
-import { CustomRangeType, Disposable, IResourceManagerService, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { CustomRangeType, Disposable, Inject, IResourceManagerService, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import { DOC_HYPER_LINK_PLUGIN } from '../types/const';
import { DocHyperLinkModel } from '../models/hyper-link.model';
import type { IDocHyperLink } from '../types/interfaces/i-doc-hyper-link';
diff --git a/packages/docs-hyper-link/src/plugin.ts b/packages/docs-hyper-link/src/plugin.ts
index 364a77416b..9b763590f7 100644
--- a/packages/docs-hyper-link/src/plugin.ts
+++ b/packages/docs-hyper-link/src/plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { DependentOn, Plugin, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { DependentOn, Inject, Injector, Plugin, UniverInstanceType } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
import { UniverDocsPlugin } from '@univerjs/docs';
import { DOC_HYPER_LINK_PLUGIN } from './types/const';
import { DocHyperLinkModel } from './models/hyper-link.model';
diff --git a/packages/docs-mention-ui/package.json b/packages/docs-mention-ui/package.json
index aabc798c44..6672e387b1 100644
--- a/packages/docs-mention-ui/package.json
+++ b/packages/docs-mention-ui/package.json
@@ -69,7 +69,6 @@
"@univerjs/docs-ui": "workspace:*",
"@univerjs/engine-render": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": ">=2.0.0",
"react": "^16.9.0 || ^17.0.0 || ^18.0.0",
"rxjs": ">=7.0.0"
@@ -84,7 +83,6 @@
"@univerjs/engine-render": "workspace:*",
"@univerjs/shared": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": "^2.1.1",
"less": "^4.2.0",
"react": "18.3.1",
diff --git a/packages/docs-mention-ui/src/controllers/doc-mention-trigger.controller.ts b/packages/docs-mention-ui/src/controllers/doc-mention-trigger.controller.ts
index 4ddd366e37..6c2c035273 100644
--- a/packages/docs-mention-ui/src/controllers/doc-mention-trigger.controller.ts
+++ b/packages/docs-mention-ui/src/controllers/doc-mention-trigger.controller.ts
@@ -14,11 +14,10 @@
* limitations under the License.
*/
-import { Disposable, ICommandService, LifecycleStages, OnLifecycle, Tools } from '@univerjs/core';
+import { Disposable, ICommandService, Inject, LifecycleStages, OnLifecycle, Tools } from '@univerjs/core';
import type { IInsertCommandParams } from '@univerjs/docs';
import { DeleteLeftCommand, InsertCommand, MoveCursorOperation, TextSelectionManagerService } from '@univerjs/docs';
import { DocMentionService } from '@univerjs/docs-mention';
-import { Inject } from '@wendellhu/redi';
import { DocMentionPopupService } from '../services/doc-mention-popup.service';
import { CloseMentionEditPopupOperation, ShowMentionEditPopupOperation } from '../commands/operations/mention-popup.operation';
diff --git a/packages/docs-mention-ui/src/controllers/doc-mention-ui.controller.ts b/packages/docs-mention-ui/src/controllers/doc-mention-ui.controller.ts
index 1dbfd2a60d..19add98d42 100644
--- a/packages/docs-mention-ui/src/controllers/doc-mention-ui.controller.ts
+++ b/packages/docs-mention-ui/src/controllers/doc-mention-ui.controller.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { Disposable, ICommandService, LifecycleStages, OnLifecycle } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { Disposable, ICommandService, Inject, LifecycleStages, OnLifecycle } from '@univerjs/core';
import { ComponentManager } from '@univerjs/ui';
import { CloseMentionEditPopupOperation, CloseMentionInfoPopupOperation, ShowMentionEditPopupOperation, ShowMentionInfoPopupOperation } from '../commands/operations/mention-popup.operation';
import { MentionEditPopup } from '../views/mention-edit-popup';
diff --git a/packages/docs-mention-ui/src/plugin.ts b/packages/docs-mention-ui/src/plugin.ts
index 7e86676c70..fd86bbdef8 100644
--- a/packages/docs-mention-ui/src/plugin.ts
+++ b/packages/docs-mention-ui/src/plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { DependentOn, Plugin, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { DependentOn, Inject, Injector, Plugin, UniverInstanceType } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
import { UniverDocsMentionPlugin } from '@univerjs/docs-mention';
import { DOC_MENTION_UI_PLUGIN } from './types/const/const';
import { DocMentionPopupService } from './services/doc-mention-popup.service';
diff --git a/packages/docs-mention-ui/src/services/doc-mention-popup.service.ts b/packages/docs-mention-ui/src/services/doc-mention-popup.service.ts
index 9378c67620..a4839d1deb 100644
--- a/packages/docs-mention-ui/src/services/doc-mention-popup.service.ts
+++ b/packages/docs-mention-ui/src/services/doc-mention-popup.service.ts
@@ -14,11 +14,9 @@
* limitations under the License.
*/
-import type { Nullable } from '@univerjs/core';
-import { Disposable, LifecycleStages, OnLifecycle } from '@univerjs/core';
+import type { IDisposable, Nullable } from '@univerjs/core';
+import { Disposable, Inject, LifecycleStages, OnLifecycle } from '@univerjs/core';
import { DocCanvasPopManagerService } from '@univerjs/docs-ui';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject } from '@wendellhu/redi';
import { BehaviorSubject } from 'rxjs';
import { DocMentionService } from '@univerjs/docs-mention';
import { MentionEditPopup } from '../views/mention-edit-popup';
diff --git a/packages/docs-mention-ui/src/views/mention-edit-popup/index.tsx b/packages/docs-mention-ui/src/views/mention-edit-popup/index.tsx
index d2297903f5..f379e9f3ef 100644
--- a/packages/docs-mention-ui/src/views/mention-edit-popup/index.tsx
+++ b/packages/docs-mention-ui/src/views/mention-edit-popup/index.tsx
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { useDependency, useObservable } from '@wendellhu/redi/react-bindings';
+import { ICommandService, IUniverInstanceService, Tools, UniverInstanceType, useDependency, useObservable, UserManagerService } from '@univerjs/core';
import { AddDocMentionCommand, type IMention, MentionType } from '@univerjs/docs-mention';
import React, { useEffect } from 'react';
-import { ICommandService, IUniverInstanceService, Tools, UniverInstanceType, UserManagerService } from '@univerjs/core';
import { ITextSelectionRenderManager } from '@univerjs/engine-render';
import { DocMentionPopupService } from '../../services/doc-mention-popup.service';
import { MentionList } from '../mention-list';
diff --git a/packages/docs-mention/package.json b/packages/docs-mention/package.json
index 9b0d601ae1..882135f962 100644
--- a/packages/docs-mention/package.json
+++ b/packages/docs-mention/package.json
@@ -65,7 +65,6 @@
"peerDependencies": {
"@univerjs/core": "workspace:*",
"@univerjs/docs": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": ">=7.0.0"
},
"devDependencies": {
@@ -74,7 +73,6 @@
"@univerjs/docs": "workspace:*",
"@univerjs/engine-render": "workspace:*",
"@univerjs/shared": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": "^7.8.1",
"typescript": "^5.5.3",
"vite": "^5.3.4",
diff --git a/packages/docs-mention/src/controllers/doc-mention-custom-range.controller.ts b/packages/docs-mention/src/controllers/doc-mention-custom-range.controller.ts
index 2d1088e3cf..4ca28f183d 100644
--- a/packages/docs-mention/src/controllers/doc-mention-custom-range.controller.ts
+++ b/packages/docs-mention/src/controllers/doc-mention-custom-range.controller.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { CustomRangeType, Disposable, LifecycleStages, OnLifecycle, Tools } from '@univerjs/core';
+import { CustomRangeType, Disposable, Inject, LifecycleStages, OnLifecycle, Tools } from '@univerjs/core';
import { DocCustomRangeService } from '@univerjs/docs';
-import { Inject } from '@wendellhu/redi';
import { DocMentionModel } from '../models/doc-mention.model';
@OnLifecycle(LifecycleStages.Ready, DocMentionCustomRangeController)
diff --git a/packages/docs-mention/src/controllers/doc-mention-resource.controller.ts b/packages/docs-mention/src/controllers/doc-mention-resource.controller.ts
index 3f3c3eda35..ecfd8473ff 100644
--- a/packages/docs-mention/src/controllers/doc-mention-resource.controller.ts
+++ b/packages/docs-mention/src/controllers/doc-mention-resource.controller.ts
@@ -15,8 +15,7 @@
*/
import type { DocumentDataModel } from '@univerjs/core';
-import { CustomRangeType, Disposable, IResourceManagerService, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { CustomRangeType, Disposable, Inject, IResourceManagerService, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import { DOC_MENTION_PLUGIN } from '../types/const/const';
import type { IDocMention } from '../types/interfaces/i-mention';
import { DocMentionModel } from '../models/doc-mention.model';
diff --git a/packages/docs-mention/src/plugin.ts b/packages/docs-mention/src/plugin.ts
index ddb256cf34..1427676e52 100644
--- a/packages/docs-mention/src/plugin.ts
+++ b/packages/docs-mention/src/plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { DependentOn, Plugin, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { DependentOn, Inject, Injector, Plugin, UniverInstanceType } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
import { UniverDocsPlugin } from '@univerjs/docs';
import { DOC_MENTION_PLUGIN } from './types/const/const';
import { DocMentionModel } from './models/doc-mention.model';
diff --git a/packages/docs-thread-comment-ui/package.json b/packages/docs-thread-comment-ui/package.json
index 8c3a89a644..e006a48660 100644
--- a/packages/docs-thread-comment-ui/package.json
+++ b/packages/docs-thread-comment-ui/package.json
@@ -64,7 +64,6 @@
"@univerjs/thread-comment": "workspace:*",
"@univerjs/thread-comment-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"react": "^16.9.0 || ^17.0.0 || ^18.0.0",
"rxjs": ">=7.0.0"
},
@@ -79,7 +78,6 @@
"@univerjs/thread-comment": "workspace:*",
"@univerjs/thread-comment-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": "^2.1.1",
"react": "18.3.1",
"rxjs": "^7.8.1",
diff --git a/packages/docs-thread-comment-ui/src/controllers/doc-thread-comment-selection.controller.ts b/packages/docs-thread-comment-ui/src/controllers/doc-thread-comment-selection.controller.ts
index 6b224e22a7..ccb87f4001 100644
--- a/packages/docs-thread-comment-ui/src/controllers/doc-thread-comment-selection.controller.ts
+++ b/packages/docs-thread-comment-ui/src/controllers/doc-thread-comment-selection.controller.ts
@@ -15,11 +15,10 @@
*/
import type { DocumentDataModel } from '@univerjs/core';
-import { Disposable, ICommandService, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
+import { Disposable, ICommandService, Inject, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import type { ISetTextSelectionsOperationParams } from '@univerjs/docs';
import { SetTextSelectionsOperation } from '@univerjs/docs';
import { SetActiveCommentOperation, ThreadCommentPanelService } from '@univerjs/thread-comment-ui';
-import { Inject } from '@wendellhu/redi';
import { DocBackScrollRenderController } from '@univerjs/docs-ui';
import { IRenderManagerService } from '@univerjs/engine-render';
import { ThreadCommentModel } from '@univerjs/thread-comment';
diff --git a/packages/docs-thread-comment-ui/src/controllers/doc-thread-comment-ui.controller.ts b/packages/docs-thread-comment-ui/src/controllers/doc-thread-comment-ui.controller.ts
index ecafbf5b9c..884594e5b7 100644
--- a/packages/docs-thread-comment-ui/src/controllers/doc-thread-comment-ui.controller.ts
+++ b/packages/docs-thread-comment-ui/src/controllers/doc-thread-comment-ui.controller.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { Disposable, ICommandService, LifecycleStages, OnLifecycle } from '@univerjs/core';
+import { Disposable, ICommandService, Inject, Injector, LifecycleStages, OnLifecycle } from '@univerjs/core';
import type { MenuConfig } from '@univerjs/ui';
import { ComponentManager, IMenuService } from '@univerjs/ui';
-import { Inject, Injector } from '@wendellhu/redi';
import { CommentSingle } from '@univerjs/icons';
import { AddDocCommentComment } from '../commands/commands/add-doc-comment.command';
import { DocThreadCommentPanel } from '../views/doc-thread-comment-panel';
diff --git a/packages/docs-thread-comment-ui/src/controllers/menu.ts b/packages/docs-thread-comment-ui/src/controllers/menu.ts
index ecb33aac7c..1a3d3897b3 100644
--- a/packages/docs-thread-comment-ui/src/controllers/menu.ts
+++ b/packages/docs-thread-comment-ui/src/controllers/menu.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor } from '@univerjs/core';
import { UniverInstanceType } from '@univerjs/core';
import type { IMenuButtonItem } from '@univerjs/ui';
import { getMenuHiddenObservable, MenuGroup, MenuItemType, MenuPosition } from '@univerjs/ui';
diff --git a/packages/docs-thread-comment-ui/src/controllers/render-controllers/render.controller.ts b/packages/docs-thread-comment-ui/src/controllers/render-controllers/render.controller.ts
index f0fb38ecb8..39f0e6cc09 100644
--- a/packages/docs-thread-comment-ui/src/controllers/render-controllers/render.controller.ts
+++ b/packages/docs-thread-comment-ui/src/controllers/render-controllers/render.controller.ts
@@ -15,13 +15,12 @@
*/
import type { DocumentDataModel } from '@univerjs/core';
-import { Disposable, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
+import { Disposable, Inject, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import { DOC_INTERCEPTOR_POINT, DocInterceptorService } from '@univerjs/docs';
import { DocRenderController } from '@univerjs/docs-ui';
import type { IRenderContext, IRenderModule } from '@univerjs/engine-render';
import { ThreadCommentModel } from '@univerjs/thread-comment';
import { ThreadCommentPanelService } from '@univerjs/thread-comment-ui';
-import { Inject } from '@wendellhu/redi';
import { DEFAULT_DOC_SUBUNIT_ID } from '../../common/const';
@OnLifecycle(LifecycleStages.Starting, DocThreadCommentRenderController)
diff --git a/packages/docs-thread-comment-ui/src/plugin.ts b/packages/docs-thread-comment-ui/src/plugin.ts
index 05bf08bbac..22cd6e86ce 100644
--- a/packages/docs-thread-comment-ui/src/plugin.ts
+++ b/packages/docs-thread-comment-ui/src/plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { DependentOn, Plugin, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { DependentOn, Inject, Injector, Plugin, UniverInstanceType } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
import { UniverThreadCommentUIPlugin } from '@univerjs/thread-comment-ui';
import { IRenderManagerService } from '@univerjs/engine-render';
import { PLUGIN_NAME } from './common/const';
diff --git a/packages/docs-thread-comment-ui/src/services/doc-thread-comment.service.ts b/packages/docs-thread-comment-ui/src/services/doc-thread-comment.service.ts
index d0384e4106..2c655f6489 100644
--- a/packages/docs-thread-comment-ui/src/services/doc-thread-comment.service.ts
+++ b/packages/docs-thread-comment-ui/src/services/doc-thread-comment.service.ts
@@ -18,7 +18,7 @@ import { Disposable, type ITextRange, type Nullable } from '@univerjs/core';
import type { IThreadComment } from '@univerjs/thread-comment';
import { ThreadCommentPanelService } from '@univerjs/thread-comment-ui';
import { ISidebarService } from '@univerjs/ui';
-import { Inject } from '@wendellhu/redi';
+import { Inject } from '@univerjs/core';
import { BehaviorSubject } from 'rxjs';
export class DocThreadCommentService extends Disposable {
diff --git a/packages/docs-thread-comment-ui/src/views/doc-thread-comment-panel/index.tsx b/packages/docs-thread-comment-ui/src/views/doc-thread-comment-panel/index.tsx
index 520c02af1e..683fef637e 100644
--- a/packages/docs-thread-comment-ui/src/views/doc-thread-comment-panel/index.tsx
+++ b/packages/docs-thread-comment-ui/src/views/doc-thread-comment-panel/index.tsx
@@ -15,9 +15,8 @@
*/
import type { DocumentDataModel } from '@univerjs/core';
-import { ICommandService, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
+import { ICommandService, IUniverInstanceService, UniverInstanceType, useDependency, useObservable } from '@univerjs/core';
import { ThreadCommentPanel } from '@univerjs/thread-comment-ui';
-import { useDependency, useObservable } from '@wendellhu/redi/react-bindings';
import React, { useEffect, useMemo, useState } from 'react';
import { Observable } from 'rxjs';
import { RichTextEditingMutation, TextSelectionManagerService } from '@univerjs/docs';
diff --git a/packages/docs-ui/package.json b/packages/docs-ui/package.json
index 059982a40d..4b9569b6ff 100644
--- a/packages/docs-ui/package.json
+++ b/packages/docs-ui/package.json
@@ -70,7 +70,6 @@
"@univerjs/docs": "workspace:*",
"@univerjs/engine-render": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": ">=2.0.0",
"react": "^16.9.0 || ^17.0.0 || ^18.0.0",
"rxjs": ">=7.0.0"
@@ -83,7 +82,6 @@
"@univerjs/engine-render": "workspace:*",
"@univerjs/shared": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": "^2.1.1",
"less": "^4.2.0",
"react": "18.3.1",
diff --git a/packages/docs-ui/src/commands/commands/clipboard.command.ts b/packages/docs-ui/src/commands/commands/clipboard.command.ts
index 5f8affbb73..5cd5121b70 100644
--- a/packages/docs-ui/src/commands/commands/clipboard.command.ts
+++ b/packages/docs-ui/src/commands/commands/clipboard.command.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { IContextService, IMultiCommand } from '@univerjs/core';
+import type { IAccessor, IContextService, IMultiCommand } from '@univerjs/core';
import { CommandType, EDITOR_ACTIVATED, FOCUSING_DOC } from '@univerjs/core';
import { CopyCommand, CutCommand, IClipboardInterfaceService, PasteCommand } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
import { IDocClipboardService } from '../../services/clipboard/clipboard.service';
export function whenDocOrEditor(contextService: IContextService): boolean {
diff --git a/packages/docs-ui/src/commands/operations/doc-header-footer-panel.operation.ts b/packages/docs-ui/src/commands/operations/doc-header-footer-panel.operation.ts
index f13110f15a..9eb8708149 100644
--- a/packages/docs-ui/src/commands/operations/doc-header-footer-panel.operation.ts
+++ b/packages/docs-ui/src/commands/operations/doc-header-footer-panel.operation.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType, LocaleService } from '@univerjs/core';
import { ISidebarService } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
import { COMPONENT_DOC_HEADER_FOOTER_PANEL } from '../../views/header-footer/panel/component-name';
export interface IUIComponentCommandParams {
diff --git a/packages/docs-ui/src/controllers/app-ui-controller.ts b/packages/docs-ui/src/controllers/app-ui-controller.ts
index d0a1192d9f..5a4b7c89df 100644
--- a/packages/docs-ui/src/controllers/app-ui-controller.ts
+++ b/packages/docs-ui/src/controllers/app-ui-controller.ts
@@ -15,8 +15,7 @@
*/
import type { LocaleType } from '@univerjs/core';
-import { LocaleService, RxDisposable } from '@univerjs/core';
-import { Inject, Injector, Optional } from '@wendellhu/redi';
+import { Inject, Injector, LocaleService, Optional, RxDisposable } from '@univerjs/core';
import { ILayoutService } from '@univerjs/ui';
import { ITextSelectionRenderManager } from '@univerjs/engine-render';
diff --git a/packages/docs-ui/src/controllers/doc-container-ui-controller.ts b/packages/docs-ui/src/controllers/doc-container-ui-controller.ts
index 81312203db..33c84429de 100644
--- a/packages/docs-ui/src/controllers/doc-container-ui-controller.ts
+++ b/packages/docs-ui/src/controllers/doc-container-ui-controller.ts
@@ -15,8 +15,7 @@
*/
import type { LocaleType } from '@univerjs/core';
-import { LocaleService } from '@univerjs/core';
-import { Inject, Injector } from '@wendellhu/redi';
+import { Inject, Injector, LocaleService } from '@univerjs/core';
import type { IUniverDocsUIConfig } from '../basics';
import type { DocContainer } from '../views/doc-container/DocContainer';
diff --git a/packages/docs-ui/src/controllers/doc-header-footer.controller.ts b/packages/docs-ui/src/controllers/doc-header-footer.controller.ts
index 4dae1ab284..0b052927fa 100644
--- a/packages/docs-ui/src/controllers/doc-header-footer.controller.ts
+++ b/packages/docs-ui/src/controllers/doc-header-footer.controller.ts
@@ -15,10 +15,9 @@
*/
import type { DocumentDataModel } from '@univerjs/core';
-import { BooleanNumber, Disposable, DocumentFlavor, ICommandService, IUniverInstanceService, LocaleService, toDisposable, Tools } from '@univerjs/core';
+import { BooleanNumber, Disposable, DocumentFlavor, ICommandService, Inject, IUniverInstanceService, LocaleService, toDisposable, Tools } from '@univerjs/core';
import type { Documents, DocumentViewModel, IMouseEvent, IPageRenderConfig, IPathProps, IPointerEvent, IRenderContext, IRenderModule, RenderComponentType } from '@univerjs/engine-render';
import { DocumentEditArea, IRenderManagerService, ITextSelectionRenderManager, PageLayoutType, Path, Rect, Vector2 } from '@univerjs/engine-render';
-import { Inject } from '@wendellhu/redi';
import { ComponentManager, IEditorService } from '@univerjs/ui';
import { DocSkeletonManagerService, neoGetDocObject } from '@univerjs/docs';
diff --git a/packages/docs-ui/src/controllers/doc-ui.controller.ts b/packages/docs-ui/src/controllers/doc-ui.controller.ts
index 99501db49b..ff7b53e5b0 100644
--- a/packages/docs-ui/src/controllers/doc-ui.controller.ts
+++ b/packages/docs-ui/src/controllers/doc-ui.controller.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { Disposable, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
+import { Disposable, Inject, Injector, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import type { IMenuItemFactory } from '@univerjs/ui';
import { ComponentManager, ILayoutService, IMenuService } from '@univerjs/ui';
-import { Inject, Injector } from '@wendellhu/redi';
import { ITextSelectionRenderManager } from '@univerjs/engine-render';
import { COLOR_PICKER_COMPONENT, ColorPicker } from '../components/color-picker';
diff --git a/packages/docs-ui/src/controllers/menu/menu.ts b/packages/docs-ui/src/controllers/menu/menu.ts
index 0a56a472e8..3bd71e93a6 100644
--- a/packages/docs-ui/src/controllers/menu/menu.ts
+++ b/packages/docs-ui/src/controllers/menu/menu.ts
@@ -56,7 +56,7 @@ import {
MenuItemType,
MenuPosition,
} from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor } from '@univerjs/core';
import { combineLatest, Observable } from 'rxjs';
import { COLOR_PICKER_COMPONENT } from '../../components/color-picker';
diff --git a/packages/docs-ui/src/controllers/render-controllers/back-scroll.render-controller.ts b/packages/docs-ui/src/controllers/render-controllers/back-scroll.render-controller.ts
index c48c14607b..783e501d5e 100644
--- a/packages/docs-ui/src/controllers/render-controllers/back-scroll.render-controller.ts
+++ b/packages/docs-ui/src/controllers/render-controllers/back-scroll.render-controller.ts
@@ -15,12 +15,11 @@
*/
import type { DocumentDataModel, ITextRange, Nullable } from '@univerjs/core';
-import { IUniverInstanceService, RxDisposable } from '@univerjs/core';
+import { Inject, IUniverInstanceService, RxDisposable } from '@univerjs/core';
import { DocSkeletonManagerService, getDocObject, TextSelectionManagerService, VIEWPORT_KEY } from '@univerjs/docs';
import type { INodePosition, IRenderContext, IRenderModule } from '@univerjs/engine-render';
import { getAnchorBounding, IRenderManagerService, NodePositionConvertToCursor } from '@univerjs/engine-render';
import { IEditorService } from '@univerjs/ui';
-import { Inject } from '@wendellhu/redi';
import { takeUntil } from 'rxjs';
const ANCHOR_WIDTH = 1.5;
diff --git a/packages/docs-ui/src/controllers/render-controllers/doc.render-controller.ts b/packages/docs-ui/src/controllers/render-controllers/doc.render-controller.ts
index a4972da02b..521b06d306 100644
--- a/packages/docs-ui/src/controllers/render-controllers/doc.render-controller.ts
+++ b/packages/docs-ui/src/controllers/render-controllers/doc.render-controller.ts
@@ -15,13 +15,12 @@
*/
import type { DocumentDataModel, EventState, ICommandInfo, Nullable } from '@univerjs/core';
-import { ICommandService, IConfigService, RxDisposable } from '@univerjs/core';
+import { ICommandService, IConfigService, Inject, RxDisposable } from '@univerjs/core';
import type { IRichTextEditingMutationParams } from '@univerjs/docs';
import { DOCS_COMPONENT_BACKGROUND_LAYER_INDEX, DOCS_COMPONENT_DEFAULT_Z_INDEX, DOCS_COMPONENT_HEADER_LAYER_INDEX, DOCS_COMPONENT_MAIN_LAYER_INDEX, DOCS_VIEW_KEY, DocSkeletonManagerService, RichTextEditingMutation, VIEWPORT_KEY } from '@univerjs/docs';
import type { DocumentSkeleton, IRenderContext, IRenderModule, IWheelEvent } from '@univerjs/engine-render';
import { DocBackground, Documents, IRenderManagerService, Layer, PageLayoutType, ScrollBar, Viewport } from '@univerjs/engine-render';
import { IEditorService } from '@univerjs/ui';
-import { Inject } from '@wendellhu/redi';
import { takeUntil } from 'rxjs';
export class DocRenderController extends RxDisposable implements IRenderModule {
diff --git a/packages/docs-ui/src/controllers/render-controllers/text-selection.render-controller.ts b/packages/docs-ui/src/controllers/render-controllers/text-selection.render-controller.ts
index f9fd4620da..cdb3c194d8 100644
--- a/packages/docs-ui/src/controllers/render-controllers/text-selection.render-controller.ts
+++ b/packages/docs-ui/src/controllers/render-controllers/text-selection.render-controller.ts
@@ -15,10 +15,9 @@
*/
import type { DocumentDataModel, ICommandInfo } from '@univerjs/core';
-import { Disposable, ICommandService, isInternalEditorID, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
+import { Disposable, ICommandService, Inject, isInternalEditorID, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
import type { Documents, IMouseEvent, IPointerEvent, IRenderContext, IRenderModule, RenderComponentType } from '@univerjs/engine-render';
import { CURSOR_TYPE, DocumentEditArea, ITextSelectionRenderManager, PageLayoutType, Vector2 } from '@univerjs/engine-render';
-import { Inject } from '@wendellhu/redi';
import { IEditorService } from '@univerjs/ui';
import type { ISetDocZoomRatioOperationParams } from '@univerjs/docs';
diff --git a/packages/docs-ui/src/controllers/render-controllers/zoom.render-controller.ts b/packages/docs-ui/src/controllers/render-controllers/zoom.render-controller.ts
index 0016bb9801..515141c1fc 100644
--- a/packages/docs-ui/src/controllers/render-controllers/zoom.render-controller.ts
+++ b/packages/docs-ui/src/controllers/render-controllers/zoom.render-controller.ts
@@ -18,13 +18,13 @@ import type { DocumentDataModel, ICommandInfo } from '@univerjs/core';
import {
Disposable,
ICommandService,
+ Inject,
IUniverInstanceService,
} from '@univerjs/core';
import type { IDocObjectParam } from '@univerjs/docs';
import { DocSkeletonManagerService, neoGetDocObject, SetDocZoomRatioCommand, SetDocZoomRatioOperation, TextSelectionManagerService, VIEWPORT_KEY } from '@univerjs/docs';
import type { IRenderContext, IRenderModule, IWheelEvent } from '@univerjs/engine-render';
import { IEditorService } from '@univerjs/ui';
-import { Inject } from '@wendellhu/redi';
interface ISetDocMutationParams {
unitId: string;
diff --git a/packages/docs-ui/src/docs-ui-plugin.ts b/packages/docs-ui/src/docs-ui-plugin.ts
index dfdacf42fc..8b3df68f8d 100644
--- a/packages/docs-ui/src/docs-ui-plugin.ts
+++ b/packages/docs-ui/src/docs-ui-plugin.ts
@@ -16,13 +16,14 @@
import {
ILogService,
+ Inject,
+ Injector,
IUniverInstanceService,
Plugin,
Tools,
UniverInstanceType,
} from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import type { Dependency } from '@univerjs/core';
import { IEditorService, IShortcutService } from '@univerjs/ui';
import { IRenderManagerService } from '@univerjs/engine-render';
import { DocInterceptorService, DocSkeletonManagerService } from '@univerjs/docs';
diff --git a/packages/docs-ui/src/services/clipboard/clipboard.service.ts b/packages/docs-ui/src/services/clipboard/clipboard.service.ts
index c8310f2952..cb58ca57ed 100644
--- a/packages/docs-ui/src/services/clipboard/clipboard.service.ts
+++ b/packages/docs-ui/src/services/clipboard/clipboard.service.ts
@@ -14,11 +14,9 @@
* limitations under the License.
*/
-import type { DocumentDataModel, ICustomRange, IDocumentBody, IParagraph } from '@univerjs/core';
-import { CustomRangeType, DataStreamTreeTokenType, Disposable, ICommandService, ILogService, IUniverInstanceService, normalizeBody, SliceBodyType, toDisposable, Tools, UniverInstanceType } from '@univerjs/core';
+import type { DocumentDataModel, ICustomRange, IDisposable, IDocumentBody, IParagraph } from '@univerjs/core';
+import { createIdentifier, CustomRangeType, DataStreamTreeTokenType, Disposable, ICommandService, ILogService, Inject, IUniverInstanceService, normalizeBody, SliceBodyType, toDisposable, Tools, UniverInstanceType } from '@univerjs/core';
import { HTML_CLIPBOARD_MIME_TYPE, IClipboardInterfaceService, PLAIN_TEXT_CLIPBOARD_MIME_TYPE } from '@univerjs/ui';
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier, Inject } from '@wendellhu/redi';
import { CutContentCommand, DocCustomRangeService, getDeleteSelection, InnerPasteCommand, TextSelectionManagerService } from '@univerjs/docs';
import { copyContentCache, extractId, genId } from './copy-content-cache';
diff --git a/packages/docs-ui/src/services/doc-popup-manager.service.ts b/packages/docs-ui/src/services/doc-popup-manager.service.ts
index 3c1cb8015a..13c1869542 100644
--- a/packages/docs-ui/src/services/doc-popup-manager.service.ts
+++ b/packages/docs-ui/src/services/doc-popup-manager.service.ts
@@ -14,14 +14,12 @@
* limitations under the License.
*/
-import type { ITextRange } from '@univerjs/core';
-import { Disposable, DisposableCollection, ICommandService, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
+import type { IDisposable, ITextRange } from '@univerjs/core';
+import { Disposable, DisposableCollection, ICommandService, Inject, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
import { getLineBounding, IRenderManagerService, NodePositionConvertToCursor } from '@univerjs/engine-render';
import type { BaseObject, Documents, IBoundRectNoAngle, IRender, Scene } from '@univerjs/engine-render';
import type { IPopup } from '@univerjs/ui';
import { ICanvasPopupService } from '@univerjs/ui';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject } from '@wendellhu/redi';
import { BehaviorSubject, map } from 'rxjs';
import { DocSkeletonManagerService, SetDocZoomRatioOperation, VIEWPORT_KEY } from '@univerjs/docs';
diff --git a/packages/docs-ui/src/views/header-footer/panel/DocHeaderFooterOptions.tsx b/packages/docs-ui/src/views/header-footer/panel/DocHeaderFooterOptions.tsx
index eb8f13d669..5b8d454a56 100644
--- a/packages/docs-ui/src/views/header-footer/panel/DocHeaderFooterOptions.tsx
+++ b/packages/docs-ui/src/views/header-footer/panel/DocHeaderFooterOptions.tsx
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { BooleanNumber, ICommandService, IUniverInstanceService, LocaleService, Tools, useDependency } from '@univerjs/core';
import React, { useEffect, useState } from 'react';
import { Button, Checkbox, InputNumber } from '@univerjs/design';
-import { BooleanNumber, ICommandService, IUniverInstanceService, LocaleService, Tools } from '@univerjs/core';
import clsx from 'clsx';
import { DocumentEditArea, IRenderManagerService, ITextSelectionRenderManager } from '@univerjs/engine-render';
import { DocSkeletonManagerService, TextSelectionManagerService } from '@univerjs/docs';
diff --git a/packages/docs-ui/src/views/header-footer/panel/DocHeaderFooterPanel.tsx b/packages/docs-ui/src/views/header-footer/panel/DocHeaderFooterPanel.tsx
index 2e31273aca..f7e64f20b7 100644
--- a/packages/docs-ui/src/views/header-footer/panel/DocHeaderFooterPanel.tsx
+++ b/packages/docs-ui/src/views/header-footer/panel/DocHeaderFooterPanel.tsx
@@ -15,9 +15,8 @@
*/
import React, { useEffect, useState } from 'react';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { IUniverInstanceService, LocaleService, useDependency } from '@univerjs/core';
import { DocSkeletonManagerService } from '@univerjs/docs';
-import { IUniverInstanceService, LocaleService } from '@univerjs/core';
import { DocumentEditArea, IRenderManagerService } from '@univerjs/engine-render';
import styles from './index.module.less';
diff --git a/packages/docs-ui/src/views/header-footer/text-bubble.ts b/packages/docs-ui/src/views/header-footer/text-bubble.ts
index 689d26ca17..d161f65a41 100644
--- a/packages/docs-ui/src/views/header-footer/text-bubble.ts
+++ b/packages/docs-ui/src/views/header-footer/text-bubble.ts
@@ -18,7 +18,8 @@ import type {
IRectProps,
IShapeProps,
Rect,
- UniverRenderingContext } from '@univerjs/engine-render';
+ UniverRenderingContext,
+} from '@univerjs/engine-render';
import { Shape } from '@univerjs/engine-render';
export const COLLAB_CURSOR_LABEL_HEIGHT = 18;
diff --git a/packages/docs/package.json b/packages/docs/package.json
index 4d236915e6..70f854e0b0 100644
--- a/packages/docs/package.json
+++ b/packages/docs/package.json
@@ -62,14 +62,12 @@
"peerDependencies": {
"@univerjs/core": "workspace:*",
"@univerjs/engine-render": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": ">=7.0.0"
},
"devDependencies": {
"@univerjs/core": "workspace:*",
"@univerjs/engine-render": "workspace:*",
"@univerjs/shared": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": "^7.8.1",
"typescript": "^5.5.3",
"vite": "^5.3.4",
diff --git a/packages/docs/src/basics/custom-decoration-factory.ts b/packages/docs/src/basics/custom-decoration-factory.ts
index 03937528cc..727c9f93f1 100644
--- a/packages/docs/src/basics/custom-decoration-factory.ts
+++ b/packages/docs/src/basics/custom-decoration-factory.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { CustomDecorationType, DocumentDataModel, IMutationInfo, ITextRange } from '@univerjs/core';
+import type { CustomDecorationType, DocumentDataModel, IAccessor, IMutationInfo, ITextRange } from '@univerjs/core';
import { getBodySlice, IUniverInstanceService, JSONX, TextX, TextXActionType, Tools, UniverInstanceType, UpdateDocsAttributeType } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { IRichTextEditingMutationParams } from '../commands/mutations/core-editing.mutation';
import { RichTextEditingMutation } from '../commands/mutations/core-editing.mutation';
import { TextSelectionManagerService } from '../services/text-selection-manager.service';
diff --git a/packages/docs/src/basics/custom-range-factory.ts b/packages/docs/src/basics/custom-range-factory.ts
index 44472e363b..27d9e05c21 100644
--- a/packages/docs/src/basics/custom-range-factory.ts
+++ b/packages/docs/src/basics/custom-range-factory.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { CustomRangeType, DocumentDataModel, IDocumentBody, IMutationInfo, ITextRange } from '@univerjs/core';
+import type { CustomRangeType, DocumentDataModel, IAccessor, IDocumentBody, IMutationInfo, ITextRange } from '@univerjs/core';
import { DataStreamTreeTokenType, IUniverInstanceService, JSONX, TextX, TextXActionType, UniverInstanceType } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { IRichTextEditingMutationParams } from '../commands/mutations/core-editing.mutation';
import { RichTextEditingMutation } from '../commands/mutations/core-editing.mutation';
import { TextSelectionManagerService } from '../services/text-selection-manager.service';
diff --git a/packages/docs/src/basics/replace.ts b/packages/docs/src/basics/replace.ts
index f735bd9278..cba4f295d0 100644
--- a/packages/docs/src/basics/replace.ts
+++ b/packages/docs/src/basics/replace.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { DocumentDataModel, IDeleteAction, IDocumentBody, IMutationInfo, IRetainAction, ITextRange } from '@univerjs/core';
+import type { DocumentDataModel, IAccessor, IDeleteAction, IDocumentBody, IMutationInfo, IRetainAction, ITextRange } from '@univerjs/core';
import { IUniverInstanceService, JSONX, TextX, TextXActionType } from '@univerjs/core';
import type { ITextRangeWithStyle } from '@univerjs/engine-render';
-import type { IAccessor } from '@wendellhu/redi';
import type { IRichTextEditingMutationParams } from '../commands/mutations/core-editing.mutation';
import { RichTextEditingMutation } from '../commands/mutations/core-editing.mutation';
import { TextSelectionManagerService } from '../services/text-selection-manager.service';
diff --git a/packages/docs/src/commands/commands/__tests__/clipboard.command.spec.ts b/packages/docs/src/commands/commands/__tests__/clipboard.command.spec.ts
index 7143189c70..498f263b10 100644
--- a/packages/docs/src/commands/commands/__tests__/clipboard.command.spec.ts
+++ b/packages/docs/src/commands/commands/__tests__/clipboard.command.spec.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { DocumentDataModel, ICommand, IDocumentData, IStyleBase, Univer } from '@univerjs/core';
+import type { DocumentDataModel, ICommand, IDocumentData, Injector, IStyleBase, Univer } from '@univerjs/core';
import { BooleanNumber, ICommandService, IUniverInstanceService, UndoCommand, UniverInstanceType } from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest';
import { TextSelectionManagerService } from '../../../services/text-selection-manager.service';
diff --git a/packages/docs/src/commands/commands/__tests__/core-editing.command.spec.ts b/packages/docs/src/commands/commands/__tests__/core-editing.command.spec.ts
index 65b491605e..7f185984d5 100644
--- a/packages/docs/src/commands/commands/__tests__/core-editing.command.spec.ts
+++ b/packages/docs/src/commands/commands/__tests__/core-editing.command.spec.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { Univer } from '@univerjs/core';
+import type { Injector, Univer } from '@univerjs/core';
import { ICommandService } from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { SetInlineFormatBoldCommand } from '../inline-format.command';
diff --git a/packages/docs/src/commands/commands/__tests__/create-command-test-bed.ts b/packages/docs/src/commands/commands/__tests__/create-command-test-bed.ts
index 3a7992289d..3c08164885 100644
--- a/packages/docs/src/commands/commands/__tests__/create-command-test-bed.ts
+++ b/packages/docs/src/commands/commands/__tests__/create-command-test-bed.ts
@@ -16,11 +16,13 @@
/* eslint-disable ts/no-explicit-any */
-import type { DocumentDataModel, IDocumentData, Nullable } from '@univerjs/core';
+import type { Ctor, Dependency, DependencyIdentifier, DocumentDataModel, IDocumentData, Nullable } from '@univerjs/core';
import {
BooleanNumber,
DOCS_NORMAL_EDITOR_UNIT_ID_KEY,
ILogService,
+ Inject,
+ Injector,
IUniverInstanceService,
LogLevel,
Plugin,
@@ -28,8 +30,6 @@ import {
Univer,
UniverInstanceType,
} from '@univerjs/core';
-import type { Ctor, Dependency, DependencyIdentifier } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
import type { DocumentSkeleton, IRender, IRenderContext, IRenderModule } from '@univerjs/engine-render';
import { DocumentViewModel, IRenderManagerService } from '@univerjs/engine-render';
diff --git a/packages/docs/src/commands/commands/__tests__/inline-format.command.spec.ts b/packages/docs/src/commands/commands/__tests__/inline-format.command.spec.ts
index 0927a59547..6598e487d8 100644
--- a/packages/docs/src/commands/commands/__tests__/inline-format.command.spec.ts
+++ b/packages/docs/src/commands/commands/__tests__/inline-format.command.spec.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { DocumentDataModel, ICommand, IStyleBase, Univer } from '@univerjs/core';
+import type { DocumentDataModel, ICommand, Injector, IStyleBase, Univer } from '@univerjs/core';
import { BooleanNumber, ICommandService, IUniverInstanceService, RedoCommand, UndoCommand, UniverInstanceType } from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest';
import { TextSelectionManagerService } from '../../../services/text-selection-manager.service';
diff --git a/packages/docs/src/commands/commands/__tests__/mock-text-selection-render-manager.ts b/packages/docs/src/commands/commands/__tests__/mock-text-selection-render-manager.ts
index 6cb3004d46..0ea5313a00 100644
--- a/packages/docs/src/commands/commands/__tests__/mock-text-selection-render-manager.ts
+++ b/packages/docs/src/commands/commands/__tests__/mock-text-selection-render-manager.ts
@@ -16,7 +16,7 @@
import type { Nullable } from '@univerjs/core';
import type { ITextSelectionInnerParam } from '@univerjs/engine-render';
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier } from '@univerjs/core';
import { BehaviorSubject } from 'rxjs';
export class TextSelectionRenderManager {
diff --git a/packages/docs/src/commands/commands/__tests__/replace-content.command.spec.ts b/packages/docs/src/commands/commands/__tests__/replace-content.command.spec.ts
index bdb1ddaefd..1085e4f4f3 100644
--- a/packages/docs/src/commands/commands/__tests__/replace-content.command.spec.ts
+++ b/packages/docs/src/commands/commands/__tests__/replace-content.command.spec.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { DocumentDataModel, ICommand, IDocumentData, Univer } from '@univerjs/core';
+import type { DocumentDataModel, ICommand, IDocumentData, Injector, Univer } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, RedoCommand, UndoCommand, UniverInstanceType } from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest';
import { TextSelectionManagerService } from '../../../services/text-selection-manager.service';
diff --git a/packages/docs/src/commands/commands/delete.command.ts b/packages/docs/src/commands/commands/delete.command.ts
index 395b623be0..450dbda96d 100644
--- a/packages/docs/src/commands/commands/delete.command.ts
+++ b/packages/docs/src/commands/commands/delete.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICommand, ICustomBlock, IDocumentBody, IMutationInfo, IParagraph, ITextRange, ITextRun, JSONXActions } from '@univerjs/core';
+import type { IAccessor, ICommand, ICustomBlock, IDocumentBody, IMutationInfo, IParagraph, ITextRange, ITextRun, JSONXActions } from '@univerjs/core';
import {
CommandType,
getCustomDecorationSlice,
@@ -30,7 +30,6 @@ import {
import type { IActiveTextRange, ITextRangeWithStyle } from '@univerjs/engine-render';
import { getParagraphByGlyph, hasListGlyph, isFirstGlyph, isIndentByGlyph } from '@univerjs/engine-render';
-import type { IAccessor } from '@wendellhu/redi';
import type { ITextActiveRange } from '../../services/text-selection-manager.service';
import { TextSelectionManagerService } from '../../services/text-selection-manager.service';
import type { IRichTextEditingMutationParams } from '../mutations/core-editing.mutation';
diff --git a/packages/docs/src/commands/commands/set-doc-zoom-ratio.command.ts b/packages/docs/src/commands/commands/set-doc-zoom-ratio.command.ts
index 0e25769cb9..e36fe5ac31 100644
--- a/packages/docs/src/commands/commands/set-doc-zoom-ratio.command.ts
+++ b/packages/docs/src/commands/commands/set-doc-zoom-ratio.command.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType, ICommandService, IUndoRedoService, IUniverInstanceService } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { ISetDocZoomRatioOperationParams } from '../operations/set-doc-zoom-ratio.operation';
import {
diff --git a/packages/docs/src/commands/operations/set-doc-zoom-ratio.operation.ts b/packages/docs/src/commands/operations/set-doc-zoom-ratio.operation.ts
index 691e342dee..85e3fc6c8b 100644
--- a/packages/docs/src/commands/operations/set-doc-zoom-ratio.operation.ts
+++ b/packages/docs/src/commands/operations/set-doc-zoom-ratio.operation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IOperation } from '@univerjs/core';
+import type { IAccessor, IOperation } from '@univerjs/core';
import { CommandType, IUniverInstanceService, Tools } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
export interface ISetDocZoomRatioOperationParams {
zoomRatio: number;
diff --git a/packages/docs/src/commands/util.ts b/packages/docs/src/commands/util.ts
index 054d56bdb8..5545075459 100644
--- a/packages/docs/src/commands/util.ts
+++ b/packages/docs/src/commands/util.ts
@@ -15,8 +15,7 @@
*/
import { IRenderManagerService } from '@univerjs/engine-render';
-import type { IAccessor } from '@wendellhu/redi';
-import type { DocumentDataModel } from '@univerjs/core';
+import type { DocumentDataModel, IAccessor } from '@univerjs/core';
import { DocSkeletonManagerService } from '../services/doc-skeleton-manager.service';
/**
diff --git a/packages/docs/src/controllers/custom-range.controller.ts b/packages/docs/src/controllers/custom-range.controller.ts
index 670a68f4a0..79af7bda96 100644
--- a/packages/docs/src/controllers/custom-range.controller.ts
+++ b/packages/docs/src/controllers/custom-range.controller.ts
@@ -15,8 +15,7 @@
*/
import type { DocumentDataModel } from '@univerjs/core';
-import { Disposable, ICommandService, IUniverInstanceService, LifecycleStages, OnLifecycle } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { Disposable, ICommandService, Inject, IUniverInstanceService, LifecycleStages, OnLifecycle } from '@univerjs/core';
import type { ITextRangeWithStyle } from '@univerjs/engine-render';
import type { ISetTextSelectionsOperationParams } from '../commands/operations/text-selection.operation';
import { SetTextSelectionsOperation } from '../commands/operations/text-selection.operation';
diff --git a/packages/docs/src/controllers/ime-input.controller.ts b/packages/docs/src/controllers/ime-input.controller.ts
index 06ab2c8c67..aa097756c7 100644
--- a/packages/docs/src/controllers/ime-input.controller.ts
+++ b/packages/docs/src/controllers/ime-input.controller.ts
@@ -18,6 +18,7 @@ import type { Nullable } from '@univerjs/core';
import {
Disposable,
ICommandService,
+ Inject,
IUniverInstanceService,
LifecycleStages,
OnLifecycle,
@@ -25,7 +26,6 @@ import {
} from '@univerjs/core';
import type { IEditorInputConfig } from '@univerjs/engine-render';
import { IRenderManagerService, ITextSelectionRenderManager } from '@univerjs/engine-render';
-import { Inject } from '@wendellhu/redi';
import type { Subscription } from 'rxjs';
import { IMEInputCommand } from '../commands/commands/ime-input.command';
diff --git a/packages/docs/src/controllers/move-cursor.controller.ts b/packages/docs/src/controllers/move-cursor.controller.ts
index ccae8004dc..553d78f099 100644
--- a/packages/docs/src/controllers/move-cursor.controller.ts
+++ b/packages/docs/src/controllers/move-cursor.controller.ts
@@ -20,6 +20,7 @@ import {
Direction,
Disposable,
ICommandService,
+ Inject,
IUniverInstanceService,
LifecycleStages,
OnLifecycle,
@@ -32,7 +33,6 @@ import type {
INodeSearch,
} from '@univerjs/engine-render';
import { IRenderManagerService, NodePositionConvertToCursor, RANGE_DIRECTION } from '@univerjs/engine-render';
-import { Inject } from '@wendellhu/redi';
import type { Subscription } from 'rxjs';
import { getDocObject } from '../basics/component-tools';
diff --git a/packages/docs/src/doc-plugin.ts b/packages/docs/src/doc-plugin.ts
index 82ab8c68fc..a9a0669177 100644
--- a/packages/docs/src/doc-plugin.ts
+++ b/packages/docs/src/doc-plugin.ts
@@ -14,15 +14,15 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { Dependency, ICommand } from '@univerjs/core';
import {
ICommandService,
+ Inject,
+ Injector,
Plugin,
UniverInstanceType,
} from '@univerjs/core';
import { ITextSelectionRenderManager, TextSelectionRenderManager } from '@univerjs/engine-render';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
import { BreakLineCommand } from './commands/commands/break-line.command';
import { DeleteCommand, InsertCommand, UpdateCommand } from './commands/commands/core-editing.command';
import { DeleteCustomBlockCommand, DeleteLeftCommand, DeleteRightCommand, MergeTwoParagraphCommand } from './commands/commands/delete.command';
diff --git a/packages/docs/src/services/doc-custom-range.service.ts b/packages/docs/src/services/doc-custom-range.service.ts
index 9e911129cf..97a5f63768 100644
--- a/packages/docs/src/services/doc-custom-range.service.ts
+++ b/packages/docs/src/services/doc-custom-range.service.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICustomRange } from '@univerjs/core';
+import type { ICustomRange, IDisposable } from '@univerjs/core';
import { toDisposable } from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
export interface ICustomRangeData extends ICustomRange {
data?: string;
diff --git a/packages/docs/src/services/doc-interceptor/doc-interceptor.service.ts b/packages/docs/src/services/doc-interceptor/doc-interceptor.service.ts
index 00c0228bf4..724f049263 100644
--- a/packages/docs/src/services/doc-interceptor/doc-interceptor.service.ts
+++ b/packages/docs/src/services/doc-interceptor/doc-interceptor.service.ts
@@ -15,9 +15,8 @@
*/
import type { DocumentDataModel, ICustomDecorationForInterceptor, ICustomRangeForInterceptor, IInterceptor, Nullable } from '@univerjs/core';
-import { composeInterceptors, Disposable, DisposableCollection, DOCS_FORMULA_BAR_EDITOR_UNIT_ID_KEY, DOCS_NORMAL_EDITOR_UNIT_ID_KEY, LifecycleStages, OnLifecycle, remove, toDisposable } from '@univerjs/core';
+import { composeInterceptors, Disposable, DisposableCollection, DOCS_FORMULA_BAR_EDITOR_UNIT_ID_KEY, DOCS_NORMAL_EDITOR_UNIT_ID_KEY, Inject, LifecycleStages, OnLifecycle, remove, toDisposable } from '@univerjs/core';
import type { DocumentViewModel, IRenderContext, IRenderModule } from '@univerjs/engine-render';
-import { Inject } from '@wendellhu/redi';
import { DocSkeletonManagerService } from '../doc-skeleton-manager.service';
import { DOC_INTERCEPTOR_POINT } from './interceptor-const';
diff --git a/packages/docs/src/services/doc-skeleton-manager.service.ts b/packages/docs/src/services/doc-skeleton-manager.service.ts
index 21fb4e18c3..5e84e12034 100644
--- a/packages/docs/src/services/doc-skeleton-manager.service.ts
+++ b/packages/docs/src/services/doc-skeleton-manager.service.ts
@@ -15,10 +15,9 @@
*/
import type { DocumentDataModel, Nullable } from '@univerjs/core';
-import { DOCS_NORMAL_EDITOR_UNIT_ID_KEY, IUniverInstanceService, LocaleService, RxDisposable, UniverInstanceType } from '@univerjs/core';
+import { DOCS_NORMAL_EDITOR_UNIT_ID_KEY, Inject, IUniverInstanceService, LocaleService, RxDisposable, UniverInstanceType } from '@univerjs/core';
import type { IRenderContext, IRenderModule } from '@univerjs/engine-render';
import { DocumentSkeleton, DocumentViewModel } from '@univerjs/engine-render';
-import { Inject } from '@wendellhu/redi';
import { BehaviorSubject, takeUntil } from 'rxjs';
/**
diff --git a/packages/docs/src/services/doc-state-change-manager.service.ts b/packages/docs/src/services/doc-state-change-manager.service.ts
index 210908adb6..36fecdb519 100644
--- a/packages/docs/src/services/doc-state-change-manager.service.ts
+++ b/packages/docs/src/services/doc-state-change-manager.service.ts
@@ -15,9 +15,8 @@
*/
import type { JSONXActions, Nullable } from '@univerjs/core';
-import { ICommandService, IUndoRedoService, IUniverInstanceService, JSONX, RedoCommandId, RxDisposable, UndoCommandId } from '@univerjs/core';
+import { ICommandService, Inject, IUndoRedoService, IUniverInstanceService, JSONX, RedoCommandId, RxDisposable, UndoCommandId } from '@univerjs/core';
import type { ITextRangeWithStyle } from '@univerjs/engine-render';
-import { Inject } from '@wendellhu/redi';
import { BehaviorSubject } from 'rxjs';
import type { IRichTextEditingMutationParams } from '../commands/mutations/core-editing.mutation';
diff --git a/packages/docs/src/services/ime-input-manager.service.ts b/packages/docs/src/services/ime-input-manager.service.ts
index 2e95c01feb..5d98a8d05a 100644
--- a/packages/docs/src/services/ime-input-manager.service.ts
+++ b/packages/docs/src/services/ime-input-manager.service.ts
@@ -15,9 +15,8 @@
*/
import { JSONX } from '@univerjs/core';
-import type { JSONXActions, Nullable } from '@univerjs/core';
+import type { IDisposable, JSONXActions, Nullable } from '@univerjs/core';
import type { ITextRangeWithStyle } from '@univerjs/engine-render';
-import type { IDisposable } from '@wendellhu/redi';
import type { IRichTextEditingMutationParams } from '../commands/mutations/core-editing.mutation';
diff --git a/packages/drawing-ui/package.json b/packages/drawing-ui/package.json
index 8dc4614c9b..68e1e04643 100644
--- a/packages/drawing-ui/package.json
+++ b/packages/drawing-ui/package.json
@@ -68,7 +68,6 @@
"@univerjs/drawing": "workspace:*",
"@univerjs/engine-render": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": ">=2.0.0",
"react": "^16.9.0 || ^17.0.0 || ^18.0.0",
"rxjs": ">=7.0.0"
@@ -83,7 +82,6 @@
"@univerjs/engine-render": "workspace:*",
"@univerjs/shared": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": "^2.1.1",
"less": "^4.2.0",
"react": "18.3.1",
diff --git a/packages/drawing-ui/src/controllers/drawing-ui.controller.ts b/packages/drawing-ui/src/controllers/drawing-ui.controller.ts
index 17ae11680e..7d399a04a7 100644
--- a/packages/drawing-ui/src/controllers/drawing-ui.controller.ts
+++ b/packages/drawing-ui/src/controllers/drawing-ui.controller.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { Disposable, ICommandService, LifecycleStages, LocaleService, OnLifecycle } from '@univerjs/core';
+import { Disposable, ICommandService, Inject, Injector, LifecycleStages, LocaleService, OnLifecycle } from '@univerjs/core';
import { ComponentManager, IMenuService } from '@univerjs/ui';
-import { Inject, Injector } from '@wendellhu/redi';
import { COMPONENT_IMAGE_POPUP_MENU } from '../views/image-popup-menu/component-name';
import { ImagePopupMenu } from '../views/image-popup-menu/ImagePopupMenu';
import { AutoImageCropOperation, CloseImageCropOperation, OpenImageCropOperation } from '../commands/operations/image-crop.operation';
diff --git a/packages/drawing-ui/src/controllers/image-cropper.controller.ts b/packages/drawing-ui/src/controllers/image-cropper.controller.ts
index 5bb6f3e27e..4ef111a1af 100644
--- a/packages/drawing-ui/src/controllers/image-cropper.controller.ts
+++ b/packages/drawing-ui/src/controllers/image-cropper.controller.ts
@@ -15,14 +15,13 @@
*/
import type { ICommandInfo, ISrcRect, Nullable, Workbook } from '@univerjs/core';
-import { checkIfMove, Disposable, ICommandService, IUniverInstanceService, LifecycleStages, LocaleService, OnLifecycle, UniverInstanceType } from '@univerjs/core';
+import { checkIfMove, Disposable, ICommandService, Inject, IUniverInstanceService, LifecycleStages, LocaleService, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import { MessageType } from '@univerjs/design';
import type { IDrawingSearch, IImageData, ITransformState } from '@univerjs/drawing';
import { getDrawingShapeKeyByDrawingSearch, IDrawingManagerService } from '@univerjs/drawing';
import type { BaseObject, Scene } from '@univerjs/engine-render';
import { CURSOR_TYPE, degToRad, Image, IRenderManagerService, precisionTo, Vector2 } from '@univerjs/engine-render';
import { IMessageService } from '@univerjs/ui';
-import { Inject } from '@wendellhu/redi';
import { filter, switchMap } from 'rxjs';
import type { IOpenImageCropOperationBySrcRectParams } from '../commands/operations/image-crop.operation';
import { AutoImageCropOperation, CloseImageCropOperation, CropType, OpenImageCropOperation } from '../commands/operations/image-crop.operation';
diff --git a/packages/drawing-ui/src/controllers/image-update.controller.ts b/packages/drawing-ui/src/controllers/image-update.controller.ts
index e5108f1786..3f2532c05e 100644
--- a/packages/drawing-ui/src/controllers/image-update.controller.ts
+++ b/packages/drawing-ui/src/controllers/image-update.controller.ts
@@ -18,6 +18,7 @@ import type { ICommandInfo, Nullable } from '@univerjs/core';
import {
Disposable,
ICommandService,
+ Inject,
IUniverInstanceService,
LifecycleStages,
OnLifecycle,
@@ -28,7 +29,6 @@ import { CURSOR_TYPE, IRenderManagerService } from '@univerjs/engine-render';
import type { IDrawingSearch, IImageData } from '@univerjs/drawing';
import { DrawingTypeEnum, getDrawingShapeKeyByDrawingSearch, IDrawingManagerService, IImageIoService } from '@univerjs/drawing';
import { IDialogService } from '@univerjs/ui';
-import { Inject } from '@wendellhu/redi';
import { COMPONENT_IMAGE_VIEWER } from '../views/image-viewer/component-name';
import { ImageResetSizeOperation } from '../commands/operations/image-reset-size.operation';
import { DrawingRenderService } from '../services/drawing-render.service';
diff --git a/packages/drawing-ui/src/plugin.ts b/packages/drawing-ui/src/plugin.ts
index 6d4f40ee8f..6e1f8d1d7a 100644
--- a/packages/drawing-ui/src/plugin.ts
+++ b/packages/drawing-ui/src/plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { LocaleService, Plugin } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { Inject, Injector, LocaleService, Plugin } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
import { DrawingUpdateController } from './controllers/drawing-update.controller';
import { DrawingUIController } from './controllers/drawing-ui.controller';
import { ImageCropperController } from './controllers/image-cropper.controller';
diff --git a/packages/drawing-ui/src/views/image-popup-menu/ImagePopupMenu.tsx b/packages/drawing-ui/src/views/image-popup-menu/ImagePopupMenu.tsx
index 60a56078fe..56450fdad5 100644
--- a/packages/drawing-ui/src/views/image-popup-menu/ImagePopupMenu.tsx
+++ b/packages/drawing-ui/src/views/image-popup-menu/ImagePopupMenu.tsx
@@ -15,10 +15,9 @@
*/
import type { IDrawingSearch } from '@univerjs/core';
-import { ICommandService, LocaleService } from '@univerjs/core';
+import { ICommandService, LocaleService, useDependency } from '@univerjs/core';
import { Dropdown } from '@univerjs/design';
import { Autofill, MoreDownSingle } from '@univerjs/icons';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import clsx from 'clsx';
import React, { useState } from 'react';
import styles from './index.module.less';
diff --git a/packages/drawing-ui/src/views/panel/DrawingAlign.tsx b/packages/drawing-ui/src/views/panel/DrawingAlign.tsx
index 558108c2a9..8a89f28b44 100644
--- a/packages/drawing-ui/src/views/panel/DrawingAlign.tsx
+++ b/packages/drawing-ui/src/views/panel/DrawingAlign.tsx
@@ -15,8 +15,7 @@
*/
import type { IDrawingParam } from '@univerjs/core';
-import { ICommandService, LocaleService } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { ICommandService, LocaleService, useDependency } from '@univerjs/core';
import React, { useState } from 'react';
import { Select } from '@univerjs/design';
import clsx from 'clsx';
diff --git a/packages/drawing-ui/src/views/panel/DrawingArrange.tsx b/packages/drawing-ui/src/views/panel/DrawingArrange.tsx
index a468561dd1..61f7fce13e 100644
--- a/packages/drawing-ui/src/views/panel/DrawingArrange.tsx
+++ b/packages/drawing-ui/src/views/panel/DrawingArrange.tsx
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { LocaleService } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { LocaleService, useDependency } from '@univerjs/core';
import React, { useEffect, useState } from 'react';
import { BottomSingle, MoveDownSingle, MoveUpSingle, TopmostSingle } from '@univerjs/icons';
import { Button } from '@univerjs/design';
diff --git a/packages/drawing-ui/src/views/panel/DrawingCommonPanel.tsx b/packages/drawing-ui/src/views/panel/DrawingCommonPanel.tsx
index c1296bb490..75b10ce2e9 100644
--- a/packages/drawing-ui/src/views/panel/DrawingCommonPanel.tsx
+++ b/packages/drawing-ui/src/views/panel/DrawingCommonPanel.tsx
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { LocaleService } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { LocaleService, useDependency } from '@univerjs/core';
import React, { useEffect, useState } from 'react';
import { IRenderManagerService } from '@univerjs/engine-render';
import { IDrawingManagerService, type IDrawingParam } from '@univerjs/drawing';
diff --git a/packages/drawing-ui/src/views/panel/DrawingGroup.tsx b/packages/drawing-ui/src/views/panel/DrawingGroup.tsx
index 8167f9b528..8922f8ca9a 100644
--- a/packages/drawing-ui/src/views/panel/DrawingGroup.tsx
+++ b/packages/drawing-ui/src/views/panel/DrawingGroup.tsx
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { LocaleService, Tools } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { LocaleService, Tools, useDependency } from '@univerjs/core';
import React, { useEffect, useState } from 'react';
import { GroupSingle, UngroupSingle } from '@univerjs/icons';
import { Button } from '@univerjs/design';
diff --git a/packages/drawing-ui/src/views/panel/DrawingTransform.tsx b/packages/drawing-ui/src/views/panel/DrawingTransform.tsx
index 25086fce34..ca95f78888 100644
--- a/packages/drawing-ui/src/views/panel/DrawingTransform.tsx
+++ b/packages/drawing-ui/src/views/panel/DrawingTransform.tsx
@@ -15,8 +15,7 @@
*/
import type { Nullable } from '@univerjs/core';
-import { debounce, LocaleService } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { debounce, LocaleService, useDependency } from '@univerjs/core';
import React, { useEffect, useState } from 'react';
import { Checkbox, InputNumber } from '@univerjs/design';
import clsx from 'clsx';
diff --git a/packages/drawing-ui/src/views/panel/ImageCropper.tsx b/packages/drawing-ui/src/views/panel/ImageCropper.tsx
index 09b80b3dd0..ad4ad1b65a 100644
--- a/packages/drawing-ui/src/views/panel/ImageCropper.tsx
+++ b/packages/drawing-ui/src/views/panel/ImageCropper.tsx
@@ -15,8 +15,7 @@
*/
import type { IDrawingParam } from '@univerjs/core';
-import { ICommandService, LocaleService } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { ICommandService, LocaleService, useDependency } from '@univerjs/core';
import React, { useEffect, useRef, useState } from 'react';
import { CreateCopySingle } from '@univerjs/icons';
import { Button, Select } from '@univerjs/design';
diff --git a/packages/drawing/package.json b/packages/drawing/package.json
index 8c63cd7ec8..491545f970 100644
--- a/packages/drawing/package.json
+++ b/packages/drawing/package.json
@@ -59,7 +59,6 @@
},
"peerDependencies": {
"@univerjs/core": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": ">=7.0.0"
},
"dependencies": {
@@ -69,7 +68,6 @@
"devDependencies": {
"@univerjs/core": "workspace:*",
"@univerjs/shared": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"less": "^4.2.0",
"rxjs": "^7.8.1",
"typescript": "^5.5.3",
diff --git a/packages/drawing/src/plugin.ts b/packages/drawing/src/plugin.ts
index 83b9e4e926..aa1d5735cc 100644
--- a/packages/drawing/src/plugin.ts
+++ b/packages/drawing/src/plugin.ts
@@ -14,10 +14,8 @@
* limitations under the License.
*/
-import type { DependencyOverride } from '@univerjs/core';
-import { mergeOverrideWithDependencies, Plugin } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import type { Dependency, DependencyOverride } from '@univerjs/core';
+import { Inject, Injector, mergeOverrideWithDependencies, Plugin } from '@univerjs/core';
import { ImageIoService } from './services/image-io-impl.service';
import { DrawingManagerService } from './services/drawing-manager-impl.service';
diff --git a/packages/drawing/src/services/drawing-manager.service.ts b/packages/drawing/src/services/drawing-manager.service.ts
index ae6d84f5c6..d7e7ec8f91 100644
--- a/packages/drawing/src/services/drawing-manager.service.ts
+++ b/packages/drawing/src/services/drawing-manager.service.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier } from '@wendellhu/redi';
+import type { BooleanNumber, IDisposable, Nullable } from '@univerjs/core';
+import { createIdentifier } from '@univerjs/core';
import type { Observable } from 'rxjs';
-import type { BooleanNumber, Nullable } from '@univerjs/core';
import type { ITransformState } from './interface';
export const DEFAULT_DOCUMENT_SUB_COMPONENT_ID = '__default_document_sub_component_id20231101__';
diff --git a/packages/drawing/src/services/image-io.service.ts b/packages/drawing/src/services/image-io.service.ts
index 9260504287..2aa320042f 100644
--- a/packages/drawing/src/services/image-io.service.ts
+++ b/packages/drawing/src/services/image-io.service.ts
@@ -15,7 +15,7 @@
*/
import type { Nullable } from '@univerjs/core';
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier } from '@univerjs/core';
import type { Observable } from 'rxjs';
export enum ImageSourceType {
diff --git a/packages/engine-formula/package.json b/packages/engine-formula/package.json
index 39b9e736bc..43358f051f 100644
--- a/packages/engine-formula/package.json
+++ b/packages/engine-formula/package.json
@@ -62,7 +62,6 @@
"peerDependencies": {
"@univerjs/core": "workspace:*",
"@univerjs/rpc": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": ">=7.0.0"
},
"dependencies": {
@@ -74,7 +73,6 @@
"@univerjs/core": "workspace:*",
"@univerjs/rpc": "workspace:*",
"@univerjs/shared": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": "^7.8.1",
"typescript": "^5.5.3",
"vite": "^5.3.4",
diff --git a/packages/engine-formula/src/commands/mutations/set-array-formula-data.mutation.ts b/packages/engine-formula/src/commands/mutations/set-array-formula-data.mutation.ts
index a28ed892dd..1d655862dc 100644
--- a/packages/engine-formula/src/commands/mutations/set-array-formula-data.mutation.ts
+++ b/packages/engine-formula/src/commands/mutations/set-array-formula-data.mutation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IMutation } from '@univerjs/core';
+import type { IAccessor, IMutation } from '@univerjs/core';
import { CommandType } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { IArrayFormulaRangeType, IArrayFormulaUnitCellType } from '../../basics/common';
diff --git a/packages/engine-formula/src/commands/mutations/set-formula-data.mutation.ts b/packages/engine-formula/src/commands/mutations/set-formula-data.mutation.ts
index d83f30eb9f..b21d7e307c 100644
--- a/packages/engine-formula/src/commands/mutations/set-formula-data.mutation.ts
+++ b/packages/engine-formula/src/commands/mutations/set-formula-data.mutation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IMutation } from '@univerjs/core';
+import type { IAccessor, IMutation } from '@univerjs/core';
import { CommandType } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { IFormulaData } from '../../basics/common';
diff --git a/packages/engine-formula/src/controller/calculate.controller.ts b/packages/engine-formula/src/controller/calculate.controller.ts
index 1b7a44dcdb..04089a309f 100644
--- a/packages/engine-formula/src/controller/calculate.controller.ts
+++ b/packages/engine-formula/src/controller/calculate.controller.ts
@@ -15,8 +15,7 @@
*/
import type { ICommandInfo, IUnitRange } from '@univerjs/core';
-import { Disposable, ICommandService, IUniverInstanceService, LifecycleStages, OnLifecycle } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { Disposable, ICommandService, Inject, IUniverInstanceService, LifecycleStages, OnLifecycle } from '@univerjs/core';
import type { IDirtyUnitFeatureMap, IDirtyUnitOtherFormulaMap, IDirtyUnitSheetDefinedNameMap, IDirtyUnitSheetNameMap, IFormulaData } from '../basics/common';
import type { ISetArrayFormulaDataMutationParams } from '../commands/mutations/set-array-formula-data.mutation';
diff --git a/packages/engine-formula/src/controller/formula.controller.ts b/packages/engine-formula/src/controller/formula.controller.ts
index c497c03eb7..7f1e35f866 100644
--- a/packages/engine-formula/src/controller/formula.controller.ts
+++ b/packages/engine-formula/src/controller/formula.controller.ts
@@ -15,7 +15,7 @@
*/
import { Disposable, ICommandService, LifecycleStages, OnLifecycle } from '@univerjs/core';
-import { type Ctor, Optional } from '@wendellhu/redi';
+import { type Ctor, Optional } from '@univerjs/core';
import { DataSyncPrimaryController } from '@univerjs/rpc';
import type { IFunctionNames } from '../basics/function';
diff --git a/packages/engine-formula/src/engine/analysis/__tests__/create-command-test-bed.ts b/packages/engine-formula/src/engine/analysis/__tests__/create-command-test-bed.ts
index b0c6808d6e..92f4cdf691 100644
--- a/packages/engine-formula/src/engine/analysis/__tests__/create-command-test-bed.ts
+++ b/packages/engine-formula/src/engine/analysis/__tests__/create-command-test-bed.ts
@@ -14,10 +14,12 @@
* limitations under the License.
*/
-import type { IWorkbookData, Workbook } from '@univerjs/core';
+import type { Dependency, IWorkbookData, Workbook } from '@univerjs/core';
import {
CellValueType,
ILogService,
+ Inject,
+ Injector,
IUniverInstanceService,
LocaleType,
LogLevel,
@@ -25,10 +27,7 @@ import {
Plugin,
Univer,
UniverInstanceType,
-
} from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
import type { ISheetData } from '../../../basics/common';
import type { FormulaDataModel } from '../../../models/formula-data.model';
diff --git a/packages/engine-formula/src/engine/analysis/__tests__/lexer.spec.ts b/packages/engine-formula/src/engine/analysis/__tests__/lexer.spec.ts
index 57349d66e4..f5214dfb58 100644
--- a/packages/engine-formula/src/engine/analysis/__tests__/lexer.spec.ts
+++ b/packages/engine-formula/src/engine/analysis/__tests__/lexer.spec.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IWorkbookData, Univer, Workbook } from '@univerjs/core';
+import type { Injector, IWorkbookData, Univer, Workbook } from '@univerjs/core';
import { LocaleType } from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { IDefinedNamesService } from '../../../services/defined-names.service';
diff --git a/packages/engine-formula/src/engine/analysis/__tests__/parser.spec.ts b/packages/engine-formula/src/engine/analysis/__tests__/parser.spec.ts
index b08c1419fc..aaef0afc7d 100644
--- a/packages/engine-formula/src/engine/analysis/__tests__/parser.spec.ts
+++ b/packages/engine-formula/src/engine/analysis/__tests__/parser.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { Injector } from '@wendellhu/redi';
+import type { Injector } from '@univerjs/core';
import { beforeEach, describe, expect, it } from 'vitest';
import { ErrorType } from '../../../basics/error-type';
diff --git a/packages/engine-formula/src/engine/analysis/lexer.ts b/packages/engine-formula/src/engine/analysis/lexer.ts
index 1ccc06b0af..0ac32cc9ca 100644
--- a/packages/engine-formula/src/engine/analysis/lexer.ts
+++ b/packages/engine-formula/src/engine/analysis/lexer.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { Disposable } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { Disposable, Inject } from '@univerjs/core';
import { IDefinedNamesService } from '../../services/defined-names.service';
import type { ISequenceArray } from '../utils/sequence';
diff --git a/packages/engine-formula/src/engine/analysis/parser.ts b/packages/engine-formula/src/engine/analysis/parser.ts
index 67ffae64da..8a7d58accc 100644
--- a/packages/engine-formula/src/engine/analysis/parser.ts
+++ b/packages/engine-formula/src/engine/analysis/parser.ts
@@ -15,8 +15,7 @@
*/
import type { Nullable } from '@univerjs/core';
-import { Disposable, sortRules } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { Disposable, Inject, sortRules } from '@univerjs/core';
import { ErrorType } from '../../basics/error-type';
import {
diff --git a/packages/engine-formula/src/engine/ast-node/function-node.ts b/packages/engine-formula/src/engine/ast-node/function-node.ts
index 3aa06f085d..24f8cc7c52 100644
--- a/packages/engine-formula/src/engine/ast-node/function-node.ts
+++ b/packages/engine-formula/src/engine/ast-node/function-node.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import { Inject, Injector } from '@wendellhu/redi';
+import { Inject, Injector } from '@univerjs/core';
import { AstNodePromiseType } from '../../basics/common';
import { ErrorType } from '../../basics/error-type';
diff --git a/packages/engine-formula/src/engine/ast-node/lambda-node.ts b/packages/engine-formula/src/engine/ast-node/lambda-node.ts
index b844619d65..cf70c4be23 100644
--- a/packages/engine-formula/src/engine/ast-node/lambda-node.ts
+++ b/packages/engine-formula/src/engine/ast-node/lambda-node.ts
@@ -15,8 +15,7 @@
*/
import type { Nullable } from '@univerjs/core';
-import { Tools } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { Inject, Tools } from '@univerjs/core';
import { ErrorType } from '../../basics/error-type';
import {
diff --git a/packages/engine-formula/src/engine/ast-node/prefix-node.ts b/packages/engine-formula/src/engine/ast-node/prefix-node.ts
index d5df8ec1de..613da97ead 100644
--- a/packages/engine-formula/src/engine/ast-node/prefix-node.ts
+++ b/packages/engine-formula/src/engine/ast-node/prefix-node.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { Nullable } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import type { IAccessor, Nullable } from '@univerjs/core';
+import { Inject, Injector } from '@univerjs/core';
import { ErrorType } from '../../basics/error-type';
import { prefixToken } from '../../basics/token';
diff --git a/packages/engine-formula/src/engine/ast-node/reference-node.ts b/packages/engine-formula/src/engine/ast-node/reference-node.ts
index c59241ba61..03bf4d9db0 100644
--- a/packages/engine-formula/src/engine/ast-node/reference-node.ts
+++ b/packages/engine-formula/src/engine/ast-node/reference-node.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { IAccessor } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import type { IAccessor, Nullable } from '@univerjs/core';
+import { Inject, Injector } from '@univerjs/core';
-import type { Nullable } from '@univerjs/core';
import { ErrorType } from '../../basics/error-type';
import {
$SUPER_TABLE_COLUMN_REGEX,
diff --git a/packages/engine-formula/src/engine/ast-node/suffix-node.ts b/packages/engine-formula/src/engine/ast-node/suffix-node.ts
index 201f6796b8..14b3c58873 100644
--- a/packages/engine-formula/src/engine/ast-node/suffix-node.ts
+++ b/packages/engine-formula/src/engine/ast-node/suffix-node.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-import type { IAccessor } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import type { IAccessor } from '@univerjs/core';
+import { Inject, Injector } from '@univerjs/core';
import { ErrorType } from '../../basics/error-type';
import { suffixToken } from '../../basics/token';
diff --git a/packages/engine-formula/src/engine/dependency/formula-dependency.ts b/packages/engine-formula/src/engine/dependency/formula-dependency.ts
index 2dc5ad3506..86ac9148d4 100644
--- a/packages/engine-formula/src/engine/dependency/formula-dependency.ts
+++ b/packages/engine-formula/src/engine/dependency/formula-dependency.ts
@@ -15,8 +15,7 @@
*/
import type { IRange, Nullable } from '@univerjs/core';
-import { Disposable, LifecycleStages, ObjectMatrix, OnLifecycle } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { Disposable, Inject, LifecycleStages, ObjectMatrix, OnLifecycle } from '@univerjs/core';
import { FormulaAstLRU } from '../../basics/cache-lru';
import type { IDirtyUnitSheetNameMap, IFormulaData, IOtherFormulaData, IUnitData } from '../../basics/common';
diff --git a/packages/engine-formula/src/engine/utils/prefixHandler.ts b/packages/engine-formula/src/engine/utils/prefixHandler.ts
index acff23a90d..5d839d6413 100644
--- a/packages/engine-formula/src/engine/utils/prefixHandler.ts
+++ b/packages/engine-formula/src/engine/utils/prefixHandler.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import type { Injector } from '@wendellhu/redi';
-import type { Nullable } from '@univerjs/core';
+import type { Injector, Nullable } from '@univerjs/core';
import type { IFunctionService } from '../../services/function.service';
import { PrefixNode } from '../ast-node/prefix-node';
import { prefixToken } from '../../basics/token';
diff --git a/packages/engine-formula/src/functions/__tests__/create-function-test-bed.ts b/packages/engine-formula/src/functions/__tests__/create-function-test-bed.ts
index e0280fa28c..5db056efd8 100644
--- a/packages/engine-formula/src/functions/__tests__/create-function-test-bed.ts
+++ b/packages/engine-formula/src/functions/__tests__/create-function-test-bed.ts
@@ -14,10 +14,12 @@
* limitations under the License.
*/
-import type { IWorkbookData, Workbook } from '@univerjs/core';
+import type { Dependency, IWorkbookData, Workbook } from '@univerjs/core';
import {
CellValueType,
ILogService,
+ Inject,
+ Injector,
IUniverInstanceService,
LocaleType,
LogLevel,
@@ -25,10 +27,7 @@ import {
Plugin,
Univer,
UniverInstanceType,
-
} from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
import type { ISheetData } from '../../basics/common';
import { Lexer } from '../../engine/analysis/lexer';
diff --git a/packages/engine-formula/src/functions/__tests__/nested-functions.spec.ts b/packages/engine-formula/src/functions/__tests__/nested-functions.spec.ts
index d9cb024d2c..f499e3c457 100644
--- a/packages/engine-formula/src/functions/__tests__/nested-functions.spec.ts
+++ b/packages/engine-formula/src/functions/__tests__/nested-functions.spec.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { Injector } from '@wendellhu/redi';
+import type { Injector, IWorkbookData } from '@univerjs/core';
import { beforeEach, describe, expect, it } from 'vitest';
-import type { IWorkbookData } from '@univerjs/core';
import { LocaleType } from '@univerjs/core';
import { Lexer } from '../../engine/analysis/lexer';
import { AstTreeBuilder } from '../../engine/analysis/parser';
diff --git a/packages/engine-formula/src/functions/information/isref/__tests__/index.spec.ts b/packages/engine-formula/src/functions/information/isref/__tests__/index.spec.ts
index 9e2e5588a1..82f484bccf 100644
--- a/packages/engine-formula/src/functions/information/isref/__tests__/index.spec.ts
+++ b/packages/engine-formula/src/functions/information/isref/__tests__/index.spec.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { Injector } from '@wendellhu/redi';
+import type { Injector, IWorkbookData } from '@univerjs/core';
import { beforeEach, describe, expect, it } from 'vitest';
-import type { IWorkbookData } from '@univerjs/core';
import { CellValueType, LocaleType } from '@univerjs/core';
import { Lexer } from '../../../../engine/analysis/lexer';
import type { LexerNode } from '../../../../engine/analysis/lexer-node';
diff --git a/packages/engine-formula/src/functions/logical/makearray/__test__/index.spec.ts b/packages/engine-formula/src/functions/logical/makearray/__test__/index.spec.ts
index 0055ba506c..491b17355a 100644
--- a/packages/engine-formula/src/functions/logical/makearray/__test__/index.spec.ts
+++ b/packages/engine-formula/src/functions/logical/makearray/__test__/index.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { Injector } from '@wendellhu/redi';
+import type { Injector } from '@univerjs/core';
import { beforeEach, describe, expect, it } from 'vitest';
import { Lexer } from '../../../../engine/analysis/lexer';
diff --git a/packages/engine-formula/src/functions/lookup/column/__tests__/index.spec.ts b/packages/engine-formula/src/functions/lookup/column/__tests__/index.spec.ts
index 8d68ec3fc8..d358c7f23b 100644
--- a/packages/engine-formula/src/functions/lookup/column/__tests__/index.spec.ts
+++ b/packages/engine-formula/src/functions/lookup/column/__tests__/index.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { Injector } from '@wendellhu/redi';
+import type { Injector } from '@univerjs/core';
import { beforeEach, describe, expect, it } from 'vitest';
import { Lexer } from '../../../../engine/analysis/lexer';
diff --git a/packages/engine-formula/src/functions/lookup/columns/__tests__/index.spec.ts b/packages/engine-formula/src/functions/lookup/columns/__tests__/index.spec.ts
index dd241a3259..c507ac672e 100644
--- a/packages/engine-formula/src/functions/lookup/columns/__tests__/index.spec.ts
+++ b/packages/engine-formula/src/functions/lookup/columns/__tests__/index.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { Injector } from '@wendellhu/redi';
+import type { Injector } from '@univerjs/core';
import { beforeEach, describe, expect, it } from 'vitest';
import { Lexer } from '../../../../engine/analysis/lexer';
diff --git a/packages/engine-formula/src/functions/lookup/index/__test__/index.spec.ts b/packages/engine-formula/src/functions/lookup/index/__test__/index.spec.ts
index d0b74df3b8..5e1d2c3c1d 100644
--- a/packages/engine-formula/src/functions/lookup/index/__test__/index.spec.ts
+++ b/packages/engine-formula/src/functions/lookup/index/__test__/index.spec.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { Injector } from '@wendellhu/redi';
+import type { Injector, IWorkbookData } from '@univerjs/core';
import { beforeEach, describe, expect, it } from 'vitest';
-import type { IWorkbookData } from '@univerjs/core';
import { CellValueType, LocaleType } from '@univerjs/core';
import { Lexer } from '../../../../engine/analysis/lexer';
import type { LexerNode } from '../../../../engine/analysis/lexer-node';
diff --git a/packages/engine-formula/src/functions/lookup/indirect/__test__/index.spec.ts b/packages/engine-formula/src/functions/lookup/indirect/__test__/index.spec.ts
index 21da987814..8cc9c7dd54 100644
--- a/packages/engine-formula/src/functions/lookup/indirect/__test__/index.spec.ts
+++ b/packages/engine-formula/src/functions/lookup/indirect/__test__/index.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { Injector } from '@wendellhu/redi';
+import type { Injector } from '@univerjs/core';
import { beforeEach, describe, expect, it } from 'vitest';
import { ErrorType } from '../../../../basics/error-type';
diff --git a/packages/engine-formula/src/functions/lookup/offset/__tests__/index.spec.ts b/packages/engine-formula/src/functions/lookup/offset/__tests__/index.spec.ts
index 4f4bf3f718..0a7b8c6b94 100644
--- a/packages/engine-formula/src/functions/lookup/offset/__tests__/index.spec.ts
+++ b/packages/engine-formula/src/functions/lookup/offset/__tests__/index.spec.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { Injector } from '@wendellhu/redi';
+import type { Injector, IWorkbookData } from '@univerjs/core';
import { beforeEach, describe, expect, it } from 'vitest';
-import type { IWorkbookData } from '@univerjs/core';
import { CellValueType, LocaleType } from '@univerjs/core';
import { Lexer } from '../../../../engine/analysis/lexer';
import type { LexerNode } from '../../../../engine/analysis/lexer-node';
diff --git a/packages/engine-formula/src/functions/lookup/row/__tests__/index.spec.ts b/packages/engine-formula/src/functions/lookup/row/__tests__/index.spec.ts
index 6e85555f79..db30d26e9a 100644
--- a/packages/engine-formula/src/functions/lookup/row/__tests__/index.spec.ts
+++ b/packages/engine-formula/src/functions/lookup/row/__tests__/index.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { Injector } from '@wendellhu/redi';
+import type { Injector } from '@univerjs/core';
import { beforeEach, describe, expect, it } from 'vitest';
import { Lexer } from '../../../../engine/analysis/lexer';
diff --git a/packages/engine-formula/src/functions/lookup/rows/__tests__/index.spec.ts b/packages/engine-formula/src/functions/lookup/rows/__tests__/index.spec.ts
index eeae7c8596..497eca6d08 100644
--- a/packages/engine-formula/src/functions/lookup/rows/__tests__/index.spec.ts
+++ b/packages/engine-formula/src/functions/lookup/rows/__tests__/index.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { Injector } from '@wendellhu/redi';
+import type { Injector } from '@univerjs/core';
import { beforeEach, describe, expect, it } from 'vitest';
import { Lexer } from '../../../../engine/analysis/lexer';
diff --git a/packages/engine-formula/src/functions/math/subtotal/__tests__/index.spec.ts b/packages/engine-formula/src/functions/math/subtotal/__tests__/index.spec.ts
index 49b74a2103..c337b0a514 100644
--- a/packages/engine-formula/src/functions/math/subtotal/__tests__/index.spec.ts
+++ b/packages/engine-formula/src/functions/math/subtotal/__tests__/index.spec.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { Injector } from '@wendellhu/redi';
+import type { Injector, IWorkbookData } from '@univerjs/core';
import { beforeEach, describe, expect, it } from 'vitest';
-import type { IWorkbookData } from '@univerjs/core';
import { BooleanNumber, CellValueType, LocaleType } from '@univerjs/core';
import { Lexer } from '../../../../engine/analysis/lexer';
import type { LexerNode } from '../../../../engine/analysis/lexer-node';
diff --git a/packages/engine-formula/src/functions/statistical/averageif/__tests__/index.spec.ts b/packages/engine-formula/src/functions/statistical/averageif/__tests__/index.spec.ts
index ffb57ea6c4..cd2bade968 100644
--- a/packages/engine-formula/src/functions/statistical/averageif/__tests__/index.spec.ts
+++ b/packages/engine-formula/src/functions/statistical/averageif/__tests__/index.spec.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { Injector } from '@wendellhu/redi';
+import type { Injector, IWorkbookData } from '@univerjs/core';
import { beforeEach, describe, expect, it } from 'vitest';
-import type { IWorkbookData } from '@univerjs/core';
import { CellValueType, LocaleType } from '@univerjs/core';
import { Lexer } from '../../../../engine/analysis/lexer';
import type { LexerNode } from '../../../../engine/analysis/lexer-node';
diff --git a/packages/engine-formula/src/models/__tests__/create-command-test-bed.ts b/packages/engine-formula/src/models/__tests__/create-command-test-bed.ts
index b1be6097c8..e0cc95d41c 100644
--- a/packages/engine-formula/src/models/__tests__/create-command-test-bed.ts
+++ b/packages/engine-formula/src/models/__tests__/create-command-test-bed.ts
@@ -14,10 +14,8 @@
* limitations under the License.
*/
-import type { IWorkbookData } from '@univerjs/core';
-import { ILogService, IUniverInstanceService, LocaleType, LogLevel, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import type { Dependency, IWorkbookData } from '@univerjs/core';
+import { ILogService, Inject, Injector, IUniverInstanceService, LocaleType, LogLevel, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
import { LexerTreeBuilder } from '../../engine/analysis/lexer-tree-builder';
import { CalculateFormulaService } from '../../services/calculate-formula.service';
diff --git a/packages/engine-formula/src/models/__tests__/formula-data.model.spec.ts b/packages/engine-formula/src/models/__tests__/formula-data.model.spec.ts
index 1dc7eb42d5..6fdcdad74d 100644
--- a/packages/engine-formula/src/models/__tests__/formula-data.model.spec.ts
+++ b/packages/engine-formula/src/models/__tests__/formula-data.model.spec.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICellData, IWorkbookData, Nullable, Univer } from '@univerjs/core';
+import type { ICellData, Injector, IWorkbookData, Nullable, Univer } from '@univerjs/core';
import { IUniverInstanceService, LocaleType, ObjectMatrix } from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { FormulaDataModel, initSheetFormulaData } from '../formula-data.model';
diff --git a/packages/engine-formula/src/models/formula-data.model.ts b/packages/engine-formula/src/models/formula-data.model.ts
index 23636ea646..d2f774e3bb 100644
--- a/packages/engine-formula/src/models/formula-data.model.ts
+++ b/packages/engine-formula/src/models/formula-data.model.ts
@@ -15,8 +15,7 @@
*/
import type { ICellData, IObjectMatrixPrimitiveType, IRange, Nullable, Workbook } from '@univerjs/core';
-import { Disposable, isFormulaId, isFormulaString, IUniverInstanceService, ObjectMatrix, UniverInstanceType } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { Disposable, Inject, isFormulaId, isFormulaString, IUniverInstanceService, ObjectMatrix, UniverInstanceType } from '@univerjs/core';
import type {
IArrayFormulaRangeType,
diff --git a/packages/engine-formula/src/plugin.ts b/packages/engine-formula/src/plugin.ts
index 39190a09ed..11075a3d67 100644
--- a/packages/engine-formula/src/plugin.ts
+++ b/packages/engine-formula/src/plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { Plugin } from '@univerjs/core';
-import type { Ctor, Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { Inject, Injector, Plugin } from '@univerjs/core';
+import type { Ctor, Dependency } from '@univerjs/core';
import type { IFunctionNames } from './basics/function';
import { CalculateController } from './controller/calculate.controller';
diff --git a/packages/engine-formula/src/services/active-dirty-manager.service.ts b/packages/engine-formula/src/services/active-dirty-manager.service.ts
index a5c7aca0bd..db3d864b38 100644
--- a/packages/engine-formula/src/services/active-dirty-manager.service.ts
+++ b/packages/engine-formula/src/services/active-dirty-manager.service.ts
@@ -15,8 +15,7 @@
*/
import type { ICommandInfo, IUnitRange, Nullable } from '@univerjs/core';
-import { Disposable } from '@univerjs/core';
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier, Disposable } from '@univerjs/core';
import type { IDirtyUnitFeatureMap, IDirtyUnitOtherFormulaMap, IDirtyUnitSheetDefinedNameMap, IDirtyUnitSheetNameMap } from '../basics/common';
export interface IDirtyConversionManagerParams {
diff --git a/packages/engine-formula/src/services/calculate-formula.service.ts b/packages/engine-formula/src/services/calculate-formula.service.ts
index 07ca1b0591..b5ee3fed2d 100644
--- a/packages/engine-formula/src/services/calculate-formula.service.ts
+++ b/packages/engine-formula/src/services/calculate-formula.service.ts
@@ -18,12 +18,12 @@ import type { IUnitRange } from '@univerjs/core';
import {
Disposable,
IConfigService,
+ Inject,
LifecycleStages,
ObjectMatrix,
OnLifecycle,
requestImmediateMacroTask,
} from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
import { Subject } from 'rxjs';
import type {
diff --git a/packages/engine-formula/src/services/current-data.service.ts b/packages/engine-formula/src/services/current-data.service.ts
index ea392b6770..cb0795818d 100644
--- a/packages/engine-formula/src/services/current-data.service.ts
+++ b/packages/engine-formula/src/services/current-data.service.ts
@@ -15,8 +15,7 @@
*/
import type { IUnitRange, Nullable, Workbook } from '@univerjs/core';
-import { Disposable, IUniverInstanceService, ObjectMatrix, UniverInstanceType } from '@univerjs/core';
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier, Disposable, IUniverInstanceService, ObjectMatrix, UniverInstanceType } from '@univerjs/core';
import type {
IDirtyUnitFeatureMap,
diff --git a/packages/engine-formula/src/services/defined-names.service.ts b/packages/engine-formula/src/services/defined-names.service.ts
index cb3e0be1cb..3db40a7e4c 100644
--- a/packages/engine-formula/src/services/defined-names.service.ts
+++ b/packages/engine-formula/src/services/defined-names.service.ts
@@ -15,8 +15,7 @@
*/
import type { IUnitRange, Nullable } from '@univerjs/core';
-import { Disposable } from '@univerjs/core';
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier, Disposable } from '@univerjs/core';
import type { Observable } from 'rxjs';
import { Subject } from 'rxjs';
import { serializeRange } from '../engine/utils/reference';
diff --git a/packages/engine-formula/src/services/dependency-manager.service.ts b/packages/engine-formula/src/services/dependency-manager.service.ts
index 8b0d6cd709..f80d673c8c 100644
--- a/packages/engine-formula/src/services/dependency-manager.service.ts
+++ b/packages/engine-formula/src/services/dependency-manager.service.ts
@@ -15,8 +15,7 @@
*/
import type { Nullable } from '@univerjs/core';
-import { Disposable, ObjectMatrix } from '@univerjs/core';
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier, Disposable, ObjectMatrix } from '@univerjs/core';
import { FormulaDependencyTreeCache } from '../engine/dependency/dependency-tree';
import type { FormulaDependencyTree } from '../engine/dependency/dependency-tree';
diff --git a/packages/engine-formula/src/services/feature-calculation-manager.service.ts b/packages/engine-formula/src/services/feature-calculation-manager.service.ts
index 82c00a7908..af52a6ed50 100644
--- a/packages/engine-formula/src/services/feature-calculation-manager.service.ts
+++ b/packages/engine-formula/src/services/feature-calculation-manager.service.ts
@@ -15,8 +15,7 @@
*/
import type { IUnitRange, Nullable } from '@univerjs/core';
-import { Disposable } from '@univerjs/core';
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier, Disposable } from '@univerjs/core';
import type { IFeatureDirtyRangeType, IRuntimeUnitDataType } from '../basics/common';
import type { FormulaDependencyTree } from '../engine/dependency/dependency-tree';
diff --git a/packages/engine-formula/src/services/function.service.ts b/packages/engine-formula/src/services/function.service.ts
index 804cfd959b..1c0a872e7e 100644
--- a/packages/engine-formula/src/services/function.service.ts
+++ b/packages/engine-formula/src/services/function.service.ts
@@ -14,10 +14,8 @@
* limitations under the License.
*/
-import type { Nullable } from '@univerjs/core';
-import { Disposable, toDisposable } from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier } from '@wendellhu/redi';
+import type { IDisposable, Nullable } from '@univerjs/core';
+import { createIdentifier, Disposable, toDisposable } from '@univerjs/core';
import type { IFunctionInfo, IFunctionNames } from '../basics/function';
import type { BaseFunction } from '../functions/base-function';
diff --git a/packages/engine-formula/src/services/other-formula-manager.service.ts b/packages/engine-formula/src/services/other-formula-manager.service.ts
index 4210495141..5e78dd2b72 100644
--- a/packages/engine-formula/src/services/other-formula-manager.service.ts
+++ b/packages/engine-formula/src/services/other-formula-manager.service.ts
@@ -15,8 +15,7 @@
*/
import type { Nullable } from '@univerjs/core';
-import { Disposable } from '@univerjs/core';
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier, Disposable } from '@univerjs/core';
import type { IDirtyUnitOtherFormulaMap, IFormulaDataItem, IOtherFormulaData } from '../basics/common';
diff --git a/packages/engine-formula/src/services/runtime.service.ts b/packages/engine-formula/src/services/runtime.service.ts
index 67d9fa3bb4..0636d96ee4 100644
--- a/packages/engine-formula/src/services/runtime.service.ts
+++ b/packages/engine-formula/src/services/runtime.service.ts
@@ -15,8 +15,7 @@
*/
import type { ICellData, IRange, Nullable } from '@univerjs/core';
-import { Disposable, isNullCell, ObjectMatrix } from '@univerjs/core';
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier, Disposable, isNullCell, ObjectMatrix } from '@univerjs/core';
import type {
IArrayFormulaRangeType,
diff --git a/packages/engine-formula/src/services/super-table.service.ts b/packages/engine-formula/src/services/super-table.service.ts
index 610c09a618..384368417c 100644
--- a/packages/engine-formula/src/services/super-table.service.ts
+++ b/packages/engine-formula/src/services/super-table.service.ts
@@ -15,8 +15,7 @@
*/
import type { Nullable } from '@univerjs/core';
-import { Disposable } from '@univerjs/core';
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier, Disposable } from '@univerjs/core';
import type { ISuperTable, TableOptionType } from '../basics/common';
diff --git a/packages/engine-render/package.json b/packages/engine-render/package.json
index 484da2bdad..12216f4b5a 100644
--- a/packages/engine-render/package.json
+++ b/packages/engine-render/package.json
@@ -61,7 +61,6 @@
},
"peerDependencies": {
"@univerjs/core": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": ">=7.0.0"
},
"dependencies": {
@@ -75,7 +74,6 @@
"@types/opentype.js": "^1.3.8",
"@univerjs/core": "workspace:*",
"@univerjs/shared": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": "^7.8.1",
"typescript": "^5.5.3",
"vite": "^5.3.4",
diff --git a/packages/engine-render/src/components/component.ts b/packages/engine-render/src/components/component.ts
index 418075aea9..6548b00113 100644
--- a/packages/engine-render/src/components/component.ts
+++ b/packages/engine-render/src/components/component.ts
@@ -15,7 +15,7 @@
*/
import { DisposableCollection, sortRules, toDisposable } from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
+import type { IDisposable } from '@univerjs/core';
import { BaseObject } from '../base-object';
import type { IViewportInfo } from '../basics/vector2';
import type { UniverRenderingContext } from '../context';
diff --git a/packages/engine-render/src/components/docs/layout/hyphenation/hyphen.ts b/packages/engine-render/src/components/docs/layout/hyphenation/hyphen.ts
index 85a9e94653..936b74d3a2 100644
--- a/packages/engine-render/src/components/docs/layout/hyphenation/hyphen.ts
+++ b/packages/engine-render/src/components/docs/layout/hyphenation/hyphen.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import type { IDisposable } from '@wendellhu/redi';
-import type { Nullable } from '@univerjs/core';
+import type { IDisposable, Nullable } from '@univerjs/core';
import { Lang } from './lang';
import { EnUs } from './patterns/en-us';
import type { IHyphenPattern, RawHyphenPattern } from './tools';
diff --git a/packages/engine-render/src/components/docs/layout/hyphenation/language-detector.ts b/packages/engine-render/src/components/docs/layout/hyphenation/language-detector.ts
index d43b1e299b..b4d3125ead 100644
--- a/packages/engine-render/src/components/docs/layout/hyphenation/language-detector.ts
+++ b/packages/engine-render/src/components/docs/layout/hyphenation/language-detector.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IDisposable } from '@wendellhu/redi';
+import type { IDisposable, Nullable } from '@univerjs/core';
import { franc } from 'franc-min';
-import type { Nullable } from '@univerjs/core';
import { Lang } from './lang';
const LANG_MAP_TO_HYPHEN_LANG: Record<string, Lang> = {
diff --git a/packages/engine-render/src/components/docs/text-selection/text-selection-render-manager.ts b/packages/engine-render/src/components/docs/text-selection/text-selection-render-manager.ts
index 3debe6515b..f83724cbb9 100644
--- a/packages/engine-render/src/components/docs/text-selection/text-selection-render-manager.ts
+++ b/packages/engine-render/src/components/docs/text-selection/text-selection-render-manager.ts
@@ -15,8 +15,7 @@
*/
import type { Nullable } from '@univerjs/core';
-import { DataStreamTreeTokenType, ILogService, RxDisposable } from '@univerjs/core';
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier, DataStreamTreeTokenType, ILogService, RxDisposable } from '@univerjs/core';
import type { Observable, Subscription } from 'rxjs';
import { BehaviorSubject, fromEvent, Subject } from 'rxjs';
diff --git a/packages/engine-render/src/components/docs/view-model/document-view-model.ts b/packages/engine-render/src/components/docs/view-model/document-view-model.ts
index 74e9dbed6e..420fcc9dbb 100644
--- a/packages/engine-render/src/components/docs/view-model/document-view-model.ts
+++ b/packages/engine-render/src/components/docs/view-model/document-view-model.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICustomDecorationForInterceptor, ICustomRangeForInterceptor, IDocumentBody, ITextRun, Nullable } from '@univerjs/core';
+import type { ICustomDecorationForInterceptor, ICustomRangeForInterceptor, IDisposable, IDocumentBody, ITextRun, Nullable } from '@univerjs/core';
import { DataStreamTreeNodeType, DataStreamTreeTokenType, DocumentDataModel, toDisposable } from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
import { BehaviorSubject } from 'rxjs';
import { DataStreamTreeNode } from './data-stream-tree-node';
diff --git a/packages/engine-render/src/components/sheets/sheet-skeleton.ts b/packages/engine-render/src/components/sheets/sheet-skeleton.ts
index 0f37c7b894..b963686de5 100644
--- a/packages/engine-render/src/components/sheets/sheet-skeleton.ts
+++ b/packages/engine-render/src/components/sheets/sheet-skeleton.ts
@@ -27,6 +27,7 @@ import {
getColorStyle,
HorizontalAlign,
IContextService,
+ Inject,
isCellCoverable,
isNullCell,
isWhiteColor,
@@ -61,7 +62,6 @@ import type {
Worksheet,
} from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
import { distinctUntilChanged, startWith } from 'rxjs';
import { BORDER_TYPE, COLOR_BLACK_RGB, MAXIMUM_ROW_HEIGHT } from '../../basics/const';
import { getRotateOffsetAndFarthestHypotenuse } from '../../basics/draw';
diff --git a/packages/engine-render/src/components/skeleton.ts b/packages/engine-render/src/components/skeleton.ts
index dccef752a0..4805399db1 100644
--- a/packages/engine-render/src/components/skeleton.ts
+++ b/packages/engine-render/src/components/skeleton.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { Disposable, LocaleService } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { Disposable, Inject, LocaleService } from '@univerjs/core';
import type { IFontLocale } from '../basics/interfaces';
diff --git a/packages/engine-render/src/render-engine.ts b/packages/engine-render/src/render-engine.ts
index e8f60f8259..0c561f9601 100644
--- a/packages/engine-render/src/render-engine.ts
+++ b/packages/engine-render/src/render-engine.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { Plugin } from '@univerjs/core';
-import { createIdentifier, Inject, Injector } from '@wendellhu/redi';
+import { createIdentifier, Inject, Injector, Plugin } from '@univerjs/core';
import { Engine } from './engine';
import { IRenderManagerService, RenderManagerService } from './render-manager/render-manager.service';
diff --git a/packages/engine-render/src/render-manager/render-manager.service.ts b/packages/engine-render/src/render-manager/render-manager.service.ts
index 5d2dc6a5fe..dbd85741d2 100644
--- a/packages/engine-render/src/render-manager/render-manager.service.ts
+++ b/packages/engine-render/src/render-manager/render-manager.service.ts
@@ -14,10 +14,8 @@
* limitations under the License.
*/
-import type { Nullable, UnitModel, UnitType, UniverInstanceType } from '@univerjs/core';
-import { Disposable, IUniverInstanceService, remove, toDisposable } from '@univerjs/core';
-import type { Dependency, DependencyIdentifier, IDisposable } from '@wendellhu/redi';
-import { createIdentifier, Inject, Injector } from '@wendellhu/redi';
+import type { Dependency, DependencyIdentifier, IDisposable, Nullable, UnitModel, UnitType, UniverInstanceType } from '@univerjs/core';
+import { createIdentifier, Disposable, Inject, Injector, IUniverInstanceService, remove, toDisposable } from '@univerjs/core';
import type { Observable } from 'rxjs';
import { BehaviorSubject, Subject } from 'rxjs';
diff --git a/packages/engine-render/src/render-manager/render-unit.ts b/packages/engine-render/src/render-manager/render-unit.ts
index 1612a9d7f9..1eefdc3586 100644
--- a/packages/engine-render/src/render-manager/render-unit.ts
+++ b/packages/engine-render/src/render-manager/render-unit.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { Nullable, UnitModel, UnitType } from '@univerjs/core';
-import { Disposable } from '@univerjs/core';
-import { type Dependency, type DependencyIdentifier, type IDisposable, Inject, Injector, isClassDependencyItem } from '@wendellhu/redi';
+import type { Dependency, DependencyIdentifier, IDisposable, Nullable, UnitModel, UnitType } from '@univerjs/core';
+import { Disposable, Inject, Injector, isClassDependencyItem } from '@univerjs/core';
import type { Engine } from '../engine';
import type { Scene } from '../scene';
import type { RenderComponentType } from './render-manager.service';
diff --git a/packages/engine-render/src/thin-engine.ts b/packages/engine-render/src/thin-engine.ts
index ad0edc1082..dae242b083 100644
--- a/packages/engine-render/src/thin-engine.ts
+++ b/packages/engine-render/src/thin-engine.ts
@@ -15,7 +15,7 @@
*/
import { Disposable, EventSubject } from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
+import type { IDisposable } from '@univerjs/core';
import type { CURSOR_TYPE } from './basics/const';
import { RENDER_CLASS_TYPE } from './basics/const';
diff --git a/packages/facade/package.json b/packages/facade/package.json
index 11336a30b1..e2087160ca 100644
--- a/packages/facade/package.json
+++ b/packages/facade/package.json
@@ -69,7 +69,6 @@
"@univerjs/sheets-formula": "workspace:*",
"@univerjs/sheets-numfmt": "workspace:*",
"@univerjs/sheets-ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": ">=7.0.0"
},
"devDependencies": {
@@ -86,7 +85,6 @@
"@univerjs/sheets-numfmt": "workspace:*",
"@univerjs/sheets-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"jest-canvas-mock": "^2.5.2",
"jsdom": "^24.1.0",
"rxjs": "^7.8.1",
diff --git a/packages/facade/src/apis/__tests__/create-test-bed.ts b/packages/facade/src/apis/__tests__/create-test-bed.ts
index 129989b2d7..35d47f4cd3 100644
--- a/packages/facade/src/apis/__tests__/create-test-bed.ts
+++ b/packages/facade/src/apis/__tests__/create-test-bed.ts
@@ -16,11 +16,13 @@
/* eslint-disable max-lines-per-function */
-import type { IWorkbookData, UnitModel, Workbook } from '@univerjs/core';
+import type { Dependency, IWorkbookData, UnitModel, Workbook } from '@univerjs/core';
import {
AuthzIoLocalService,
IAuthzIoService,
ILogService,
+ Inject,
+ Injector,
IUniverInstanceService,
LocaleService,
LocaleType,
@@ -41,8 +43,6 @@ import {
} from '@univerjs/sheets-formula';
import enUS from '@univerjs/sheets-formula/locale/en-US';
import zhCN from '@univerjs/sheets-formula/locale/zh-CN';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
import { Engine, IRenderingEngine, IRenderManagerService, RenderManagerService } from '@univerjs/engine-render';
import { ISheetSelectionRenderService, SheetRenderController, SheetSelectionRenderService, SheetSkeletonManagerService, SheetsRenderService } from '@univerjs/sheets-ui';
diff --git a/packages/facade/src/apis/__tests__/f-hooks.spec.ts b/packages/facade/src/apis/__tests__/f-hooks.spec.ts
index 1a97f016d7..e60443f6bb 100644
--- a/packages/facade/src/apis/__tests__/f-hooks.spec.ts
+++ b/packages/facade/src/apis/__tests__/f-hooks.spec.ts
@@ -16,7 +16,7 @@
import { beforeEach, describe, expect, it, vi } from 'vitest';
import { LifecycleService, LifecycleStages } from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
+import type { Injector } from '@univerjs/core';
import type { FUniver } from '../facade';
import { createFacadeTestBed } from './create-test-bed';
diff --git a/packages/facade/src/apis/__tests__/facade.spec.ts b/packages/facade/src/apis/__tests__/facade.spec.ts
index 5350d69d0d..a776549972 100644
--- a/packages/facade/src/apis/__tests__/facade.spec.ts
+++ b/packages/facade/src/apis/__tests__/facade.spec.ts
@@ -15,10 +15,9 @@
*/
import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest';
-import type { ICellData, IStyleData, Nullable } from '@univerjs/core';
+import type { ICellData, Injector, IStyleData, Nullable } from '@univerjs/core';
import { ICommandService, IUniverInstanceService } from '@univerjs/core';
import { SetRangeValuesCommand, SetRangeValuesMutation, SetStyleCommand } from '@univerjs/sheets';
-import type { Injector } from '@wendellhu/redi';
import type {
ColumnHeaderLayout,
@@ -26,9 +25,9 @@ import type {
RowHeaderLayout,
SheetComponent,
SpreadsheetColumnHeader,
- SpreadsheetRowHeader } from '@univerjs/engine-render';
-import {
- IRenderManagerService } from '@univerjs/engine-render';
+ SpreadsheetRowHeader,
+} from '@univerjs/engine-render';
+import { IRenderManagerService } from '@univerjs/engine-render';
import { SHEET_VIEW_KEY } from '@univerjs/sheets-ui';
import { RegisterFunctionMutation, SetFormulaCalculationStartMutation } from '@univerjs/engine-formula';
import { IDescriptionService } from '@univerjs/sheets-formula';
diff --git a/packages/facade/src/apis/docs/__tests__/create-test-bed.ts b/packages/facade/src/apis/docs/__tests__/create-test-bed.ts
index c3dc26f3be..a217f92f53 100644
--- a/packages/facade/src/apis/docs/__tests__/create-test-bed.ts
+++ b/packages/facade/src/apis/docs/__tests__/create-test-bed.ts
@@ -14,9 +14,11 @@
* limitations under the License.
*/
-import type { DocumentDataModel, IDocumentData } from '@univerjs/core';
+import type { Dependency, DocumentDataModel, IDocumentData } from '@univerjs/core';
import {
ILogService,
+ Inject,
+ Injector,
IUniverInstanceService,
LocaleService,
LogLevel,
@@ -26,8 +28,6 @@ import {
} from '@univerjs/core';
import enUS from '@univerjs/sheets-formula/locale/en-US';
import zhCN from '@univerjs/sheets-formula/locale/zh-CN';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
import { DocSkeletonManagerService, DocStateChangeManagerService, IMEInputManagerService, TextSelectionManagerService } from '@univerjs/docs';
import { IRenderManagerService, ITextSelectionRenderManager, RenderManagerService, TextSelectionRenderManager } from '@univerjs/engine-render';
import { DocsRenderService } from '@univerjs/docs-ui';
diff --git a/packages/facade/src/apis/docs/__tests__/f-document.spec.ts b/packages/facade/src/apis/docs/__tests__/f-document.spec.ts
index d95bbb1a1d..87e34b1fff 100644
--- a/packages/facade/src/apis/docs/__tests__/f-document.spec.ts
+++ b/packages/facade/src/apis/docs/__tests__/f-document.spec.ts
@@ -15,7 +15,7 @@
*/
import { ICommandService } from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
+import type { Injector } from '@univerjs/core';
import { beforeEach, describe, expect, it } from 'vitest';
import { InsertCommand, RichTextEditingMutation } from '@univerjs/docs';
diff --git a/packages/facade/src/apis/f-hooks.ts b/packages/facade/src/apis/f-hooks.ts
index 4792af242b..5b9cf92d88 100644
--- a/packages/facade/src/apis/f-hooks.ts
+++ b/packages/facade/src/apis/f-hooks.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { LifecycleService, LifecycleStages, toDisposable } from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject } from '@wendellhu/redi';
+import { Inject, LifecycleService, LifecycleStages, toDisposable } from '@univerjs/core';
+import type { IDisposable } from '@univerjs/core';
import { filter } from 'rxjs';
export class FHooks {
diff --git a/packages/facade/src/apis/facade.ts b/packages/facade/src/apis/facade.ts
index bfbb20c63a..afb9260d56 100644
--- a/packages/facade/src/apis/facade.ts
+++ b/packages/facade/src/apis/facade.ts
@@ -16,7 +16,9 @@
import type {
CommandListener,
+ Dependency,
DocumentDataModel,
+ IDisposable,
IDocumentData,
IExecutionOptions,
IWorkbookData,
@@ -27,19 +29,17 @@ import {
BorderStyleTypes,
debounce,
ICommandService,
+ Inject,
+ Injector,
IUniverInstanceService,
+ Quantity,
toDisposable,
UndoCommand,
- Univer,
- UniverInstanceType,
- WrapStrategy,
-} from '@univerjs/core';
+ Univer, UniverInstanceType, WrapStrategy } from '@univerjs/core';
import type { ISocket } from '@univerjs/network';
import { ISocketService, WebSocketService } from '@univerjs/network';
import type { IRegisterFunctionParams } from '@univerjs/sheets-formula';
import { IRegisterFunctionService, RegisterFunctionService } from '@univerjs/sheets-formula';
-import type { Dependency, IDisposable } from '@wendellhu/redi';
-import { Inject, Injector, Quantity } from '@wendellhu/redi';
import type {
IColumnsHeaderCfgParam,
diff --git a/packages/facade/src/apis/sheets/__tests__/create-test-bed.ts b/packages/facade/src/apis/sheets/__tests__/create-test-bed.ts
index aff038e6b0..730493010f 100644
--- a/packages/facade/src/apis/sheets/__tests__/create-test-bed.ts
+++ b/packages/facade/src/apis/sheets/__tests__/create-test-bed.ts
@@ -14,9 +14,11 @@
* limitations under the License.
*/
-import type { IWorkbookData, Workbook } from '@univerjs/core';
+import type { Dependency, IWorkbookData, Workbook } from '@univerjs/core';
import {
ILogService,
+ Inject,
+ Injector,
IUniverInstanceService,
LocaleService,
LocaleType,
@@ -36,8 +38,6 @@ import {
} from '@univerjs/sheets-formula';
import enUS from '@univerjs/sheets-formula/locale/en-US';
import zhCN from '@univerjs/sheets-formula/locale/zh-CN';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
import { FUniver } from '../../facade';
diff --git a/packages/facade/src/apis/sheets/__tests__/f-range.spec.ts b/packages/facade/src/apis/sheets/__tests__/f-range.spec.ts
index 01a0e27eda..f842dc0c6a 100644
--- a/packages/facade/src/apis/sheets/__tests__/f-range.spec.ts
+++ b/packages/facade/src/apis/sheets/__tests__/f-range.spec.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { ICellData, IStyleData, Nullable } from '@univerjs/core';
+import type { ICellData, Injector, IStyleData, Nullable } from '@univerjs/core';
import { HorizontalAlign, ICommandService, IUniverInstanceService, VerticalAlign, WrapStrategy } from '@univerjs/core';
import { SetHorizontalTextAlignCommand, SetRangeValuesCommand, SetRangeValuesMutation, SetStyleCommand, SetTextWrapCommand, SetVerticalTextAlignCommand } from '@univerjs/sheets';
-import type { Injector } from '@wendellhu/redi';
import { beforeEach, describe, expect, it } from 'vitest';
import { FormulaDataModel } from '@univerjs/engine-formula';
diff --git a/packages/facade/src/apis/sheets/__tests__/f-sheet-hooks.spec.ts b/packages/facade/src/apis/sheets/__tests__/f-sheet-hooks.spec.ts
index e6e7783d7c..d4ad76b596 100644
--- a/packages/facade/src/apis/sheets/__tests__/f-sheet-hooks.spec.ts
+++ b/packages/facade/src/apis/sheets/__tests__/f-sheet-hooks.spec.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { ICellData, IStyleData, Nullable, UnitModel, Workbook } from '@univerjs/core';
+import type { ICellData, Injector, IStyleData, Nullable, UnitModel, Workbook } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
import { SetHorizontalTextAlignCommand, SetRangeValuesCommand, SetRangeValuesMutation, SetStyleCommand, SetTextWrapCommand, SetVerticalTextAlignCommand } from '@univerjs/sheets';
-import type { Injector } from '@wendellhu/redi';
import { beforeEach, describe, expect, it } from 'vitest';
import { Subject } from 'rxjs';
diff --git a/packages/facade/src/apis/sheets/__tests__/f-workbook.spec.ts b/packages/facade/src/apis/sheets/__tests__/f-workbook.spec.ts
index 00d62f6c07..cb2837d833 100644
--- a/packages/facade/src/apis/sheets/__tests__/f-workbook.spec.ts
+++ b/packages/facade/src/apis/sheets/__tests__/f-workbook.spec.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { ICellData, IStyleData, Nullable } from '@univerjs/core';
+import type { ICellData, Injector, IStyleData, Nullable } from '@univerjs/core';
import { ICommandService, IUniverInstanceService } from '@univerjs/core';
import { InsertSheetCommand, InsertSheetMutation, RemoveSheetCommand, RemoveSheetMutation, SetHorizontalTextAlignCommand, SetRangeValuesCommand, SetRangeValuesMutation, SetStyleCommand, SetTextWrapCommand, SetVerticalTextAlignCommand, SetWorksheetActiveOperation } from '@univerjs/sheets';
-import type { Injector } from '@wendellhu/redi';
import { beforeEach, describe, expect, it } from 'vitest';
import type { FUniver } from '../../facade';
diff --git a/packages/facade/src/apis/sheets/__tests__/f-worksheet.spec.ts b/packages/facade/src/apis/sheets/__tests__/f-worksheet.spec.ts
index b12d3f7073..f227b63240 100644
--- a/packages/facade/src/apis/sheets/__tests__/f-worksheet.spec.ts
+++ b/packages/facade/src/apis/sheets/__tests__/f-worksheet.spec.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { ICellData, IStyleData, Nullable } from '@univerjs/core';
+import type { ICellData, Injector, IStyleData, Nullable } from '@univerjs/core';
import { ICommandService, IUniverInstanceService } from '@univerjs/core';
import { SetHorizontalTextAlignCommand, SetRangeValuesCommand, SetRangeValuesMutation, SetStyleCommand, SetTextWrapCommand, SetVerticalTextAlignCommand } from '@univerjs/sheets';
-import type { Injector } from '@wendellhu/redi';
import { beforeEach, describe, expect, it } from 'vitest';
import type { FUniver } from '../../facade';
diff --git a/packages/facade/src/apis/sheets/f-range.ts b/packages/facade/src/apis/sheets/f-range.ts
index 176bd79ad6..7d2bc961ec 100644
--- a/packages/facade/src/apis/sheets/f-range.ts
+++ b/packages/facade/src/apis/sheets/f-range.ts
@@ -26,7 +26,7 @@ import type {
Workbook,
Worksheet,
} from '@univerjs/core';
-import { BooleanNumber, ICommandService, WrapStrategy } from '@univerjs/core';
+import { BooleanNumber, ICommandService, Inject, Injector, WrapStrategy } from '@univerjs/core';
import type {
ISetHorizontalTextAlignCommandParams,
ISetStyleCommandParams,
@@ -45,7 +45,6 @@ import type { ISetNumfmtCommandParams } from '@univerjs/sheets-numfmt';
import { SetNumfmtCommand } from '@univerjs/sheets-numfmt';
import { FormulaDataModel } from '@univerjs/engine-formula';
-import { Inject, Injector } from '@wendellhu/redi';
import { ISheetClipboardService, SheetSkeletonManagerService } from '@univerjs/sheets-ui';
import { IRenderManagerService } from '@univerjs/engine-render';
import type { FHorizontalAlignment, FVerticalAlignment } from './utils';
diff --git a/packages/facade/src/apis/sheets/f-selection.ts b/packages/facade/src/apis/sheets/f-selection.ts
index fa4acc81ac..67b2adf84a 100644
--- a/packages/facade/src/apis/sheets/f-selection.ts
+++ b/packages/facade/src/apis/sheets/f-selection.ts
@@ -16,7 +16,7 @@
import type { Workbook, Worksheet } from '@univerjs/core';
import type { ISelectionWithStyle } from '@univerjs/sheets';
-import { Inject, Injector } from '@wendellhu/redi';
+import { Inject, Injector } from '@univerjs/core';
import { FRange } from './f-range';
diff --git a/packages/facade/src/apis/sheets/f-sheet-hooks.ts b/packages/facade/src/apis/sheets/f-sheet-hooks.ts
index 4fbff5ba08..5b462f97ef 100644
--- a/packages/facade/src/apis/sheets/f-sheet-hooks.ts
+++ b/packages/facade/src/apis/sheets/f-sheet-hooks.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { type Nullable, toDisposable } from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject } from '@wendellhu/redi';
+import type { IDisposable, Nullable } from '@univerjs/core';
+import { Inject, toDisposable } from '@univerjs/core';
import type { IDragCellPosition, IHoverCellPosition } from '@univerjs/sheets-ui';
import { DragManagerService, HoverManagerService } from '@univerjs/sheets-ui';
diff --git a/packages/facade/src/apis/sheets/f-workbook.ts b/packages/facade/src/apis/sheets/f-workbook.ts
index 7a4b08f276..0599bcc3aa 100644
--- a/packages/facade/src/apis/sheets/f-workbook.ts
+++ b/packages/facade/src/apis/sheets/f-workbook.ts
@@ -14,9 +14,11 @@
* limitations under the License.
*/
-import type { CommandListener, ICommandInfo, IRange, IWorkbookData, Workbook } from '@univerjs/core';
+import type { CommandListener, ICommandInfo, IDisposable, IRange, IWorkbookData, Workbook } from '@univerjs/core';
import {
ICommandService,
+ Inject,
+ Injector,
IPermissionService,
IResourceLoaderService,
IUniverInstanceService,
@@ -30,8 +32,6 @@ import type {
ISheetCommandSharedParams,
} from '@univerjs/sheets';
import { InsertSheetCommand, RemoveSheetCommand, SetWorksheetActiveOperation, SheetsSelectionsService, WorkbookEditablePermission } from '@univerjs/sheets';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
import { FWorksheet } from './f-worksheet';
diff --git a/packages/facade/src/apis/sheets/f-worksheet.ts b/packages/facade/src/apis/sheets/f-worksheet.ts
index 004c819673..8687531c53 100644
--- a/packages/facade/src/apis/sheets/f-worksheet.ts
+++ b/packages/facade/src/apis/sheets/f-worksheet.ts
@@ -17,7 +17,7 @@
import { ICommandService, type IRange, type Workbook, type Worksheet } from '@univerjs/core';
import type { ISetWorksheetColWidthMutationParams, ISetWorksheetRowHeightMutationParams } from '@univerjs/sheets';
import { SetWorksheetColWidthMutation, SetWorksheetRowHeightMutation, SheetsSelectionsService } from '@univerjs/sheets';
-import { Inject, Injector } from '@wendellhu/redi';
+import { Inject, Injector } from '@univerjs/core';
import { FRange } from './f-range';
import { FSelection } from './f-selection';
diff --git a/packages/find-replace/package.json b/packages/find-replace/package.json
index 3e555a4ace..3677b89faf 100644
--- a/packages/find-replace/package.json
+++ b/packages/find-replace/package.json
@@ -69,7 +69,6 @@
"@univerjs/design": "workspace:*",
"@univerjs/engine-render": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"react": "^16.9.0 || ^17.0.0 || ^18.0.0",
"rxjs": ">=7.0.0"
},
@@ -84,7 +83,6 @@
"@univerjs/engine-render": "workspace:*",
"@univerjs/shared": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"less": "^4.2.0",
"react": "18.3.1",
"rxjs": "^7.8.1",
diff --git a/packages/find-replace/src/controllers/find-replace.controller.ts b/packages/find-replace/src/controllers/find-replace.controller.ts
index ce8ff1b6ac..c5426ee1cb 100644
--- a/packages/find-replace/src/controllers/find-replace.controller.ts
+++ b/packages/find-replace/src/controllers/find-replace.controller.ts
@@ -16,6 +16,8 @@
import {
ICommandService,
+ Inject,
+ Injector,
IUniverInstanceService,
LifecycleStages,
LocaleService,
@@ -23,8 +25,7 @@ import {
RxDisposable,
} from '@univerjs/core';
import { SearchSingle16 } from '@univerjs/icons';
-import type {
- MenuConfig } from '@univerjs/ui';
+import type { MenuConfig } from '@univerjs/ui';
import {
ComponentManager,
IDialogService,
@@ -32,7 +33,6 @@ import {
IMenuService,
IShortcutService,
} from '@univerjs/ui';
-import { Inject, Injector } from '@wendellhu/redi';
import { takeUntil } from 'rxjs';
import {
diff --git a/packages/find-replace/src/controllers/find-replace.menu.ts b/packages/find-replace/src/controllers/find-replace.menu.ts
index ea6f384078..584c0cabaa 100644
--- a/packages/find-replace/src/controllers/find-replace.menu.ts
+++ b/packages/find-replace/src/controllers/find-replace.menu.ts
@@ -17,7 +17,7 @@
import { EDITOR_ACTIVATED, FOCUSING_SHEET, IContextService, UniverInstanceType } from '@univerjs/core';
import type { IMenuButtonItem } from '@univerjs/ui';
import { getMenuHiddenObservable, MenuGroup, MenuItemType, MenuPosition } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor } from '@univerjs/core';
import { combineLatest, map } from 'rxjs';
import { OpenFindDialogOperation } from '../commands/operations/find-replace.operation';
diff --git a/packages/find-replace/src/plugin.ts b/packages/find-replace/src/plugin.ts
index c3cb22d9d4..7b907eb204 100644
--- a/packages/find-replace/src/plugin.ts
+++ b/packages/find-replace/src/plugin.ts
@@ -15,7 +15,7 @@
*/
import { LocaleService, Plugin, Tools } from '@univerjs/core';
-import { type Dependency, Inject, Injector } from '@wendellhu/redi';
+import { type Dependency, Inject, Injector } from '@univerjs/core';
import type { IUniverFindReplaceConfig } from './controllers/find-replace.controller';
import { DefaultFindReplaceConfig, FindReplaceController } from './controllers/find-replace.controller';
diff --git a/packages/find-replace/src/services/find-replace.service.ts b/packages/find-replace/src/services/find-replace.service.ts
index 76a4c114d0..5a94a52d71 100644
--- a/packages/find-replace/src/services/find-replace.service.ts
+++ b/packages/find-replace/src/services/find-replace.service.ts
@@ -14,11 +14,9 @@
* limitations under the License.
*/
-import type { Nullable } from '@univerjs/core';
-import { Disposable, DisposableCollection, IContextService, IUniverInstanceService, toDisposable } from '@univerjs/core';
+import type { IDisposable, Nullable } from '@univerjs/core';
+import { createIdentifier, Disposable, DisposableCollection, IContextService, Inject, Injector, IUniverInstanceService, toDisposable } from '@univerjs/core';
import { RENDER_RAW_FORMULA_KEY } from '@univerjs/engine-render';
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier, Inject, Injector } from '@wendellhu/redi';
import type { Observable } from 'rxjs';
import { BehaviorSubject, combineLatest, debounceTime, Subject, throttleTime } from 'rxjs';
import { FIND_REPLACE_REPLACE_REVEALED } from './context-keys';
diff --git a/packages/find-replace/src/views/dialog/FindReplaceDialog.stories.tsx b/packages/find-replace/src/views/dialog/FindReplaceDialog.stories.tsx
index 65b82355f9..c47c3abd7e 100644
--- a/packages/find-replace/src/views/dialog/FindReplaceDialog.stories.tsx
+++ b/packages/find-replace/src/views/dialog/FindReplaceDialog.stories.tsx
@@ -15,12 +15,11 @@
*/
import type { Meta } from '@storybook/react';
-import type { Dependency } from '@wendellhu/redi';
-import { RediContext } from '@wendellhu/redi/react-bindings';
+import type { Dependency } from '@univerjs/core';
+import { LocaleService, LocaleType, RediContext } from '@univerjs/core';
import React, { useContext, useMemo, useState } from 'react';
import { DesktopLayoutService, ILayoutService } from '@univerjs/ui';
-import { LocaleService, LocaleType } from '@univerjs/core';
import { FindReplaceService, IFindReplaceService } from '../../services/find-replace.service';
import { FindReplaceController } from '../../controllers/find-replace.controller';
import enUS from '../../locale/en-US';
diff --git a/packages/find-replace/src/views/dialog/FindReplaceDialog.tsx b/packages/find-replace/src/views/dialog/FindReplaceDialog.tsx
index 0f8d8be693..39be35990c 100644
--- a/packages/find-replace/src/views/dialog/FindReplaceDialog.tsx
+++ b/packages/find-replace/src/views/dialog/FindReplaceDialog.tsx
@@ -16,10 +16,8 @@
import { Button, Checkbox, FormDualColumnLayout, FormLayout, Input, MessageType, Select } from '@univerjs/design';
import { ILayoutService, IMessageService, useObservable } from '@univerjs/ui';
-import type { Nullable } from '@univerjs/core';
-import { ICommandService, IContextService, LocaleService } from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import type { IDisposable, Nullable } from '@univerjs/core';
+import { ICommandService, IContextService, LocaleService, useDependency } from '@univerjs/core';
import type { ForwardedRef } from 'react';
import React, { forwardRef, Fragment, useCallback, useEffect, useImperativeHandle, useMemo, useRef } from 'react';
import { fromEvent } from 'rxjs';
diff --git a/packages/network/package.json b/packages/network/package.json
index 8480da310c..91349d699a 100644
--- a/packages/network/package.json
+++ b/packages/network/package.json
@@ -60,13 +60,11 @@
},
"peerDependencies": {
"@univerjs/core": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": ">=7.0.0"
},
"devDependencies": {
"@univerjs/core": "workspace:*",
"@univerjs/shared": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": "^7.8.1",
"typescript": "^5.5.3",
"vite": "^5.3.4",
diff --git a/packages/network/src/services/http/__testing__/http-testing-utils.ts b/packages/network/src/services/http/__testing__/http-testing-utils.ts
index 307db23350..d535722243 100644
--- a/packages/network/src/services/http/__testing__/http-testing-utils.ts
+++ b/packages/network/src/services/http/__testing__/http-testing-utils.ts
@@ -19,9 +19,8 @@
import type { Observer } from 'rxjs';
import { Observable, Subject } from 'rxjs';
-import { Disposable } from '@univerjs/core';
+import { Disposable, Injector } from '@univerjs/core';
-import { Injector } from '@wendellhu/redi';
import { IHTTPImplementation } from '../implementations/implementation';
import type { HTTPRequest } from '../request';
import type { HTTPEvent, HTTPResponse, HTTPResponseError } from '../response';
diff --git a/packages/network/src/services/http/http.service.ts b/packages/network/src/services/http/http.service.ts
index 2ca842881a..54ab1d6353 100644
--- a/packages/network/src/services/http/http.service.ts
+++ b/packages/network/src/services/http/http.service.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { Nullable } from '@univerjs/core';
+import type { IDisposable, Nullable } from '@univerjs/core';
import { Disposable, remove, toDisposable } from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
import type { Observable } from 'rxjs';
import { firstValueFrom, of } from 'rxjs';
import { concatMap } from 'rxjs/operators';
diff --git a/packages/network/src/services/http/implementations/implementation.ts b/packages/network/src/services/http/implementations/implementation.ts
index 2dfe11806a..3144812e7e 100644
--- a/packages/network/src/services/http/implementations/implementation.ts
+++ b/packages/network/src/services/http/implementations/implementation.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier } from '@univerjs/core';
import type { Observable } from 'rxjs';
import type { HTTPRequest } from '../request';
diff --git a/packages/network/src/services/http/interceptors/__tests__/auth-interceptor.spec.ts b/packages/network/src/services/http/interceptors/__tests__/auth-interceptor.spec.ts
index e3d6548d05..f287f090e4 100644
--- a/packages/network/src/services/http/interceptors/__tests__/auth-interceptor.spec.ts
+++ b/packages/network/src/services/http/interceptors/__tests__/auth-interceptor.spec.ts
@@ -15,7 +15,7 @@
*/
import { afterEach, beforeEach, describe, expect, it, vitest } from 'vitest';
-import type { Injector } from '@wendellhu/redi';
+import type { Injector } from '@univerjs/core';
import { HTTPService } from '../../http.service';
import { createHTTPTestBed, type MockHTTPImplementation } from '../../__testing__/http-testing-utils';
import { IHTTPImplementation } from '../../implementations/implementation';
diff --git a/packages/network/src/services/http/interceptors/__tests__/merge-interceptor.spec.ts b/packages/network/src/services/http/interceptors/__tests__/merge-interceptor.spec.ts
index 6f888f42bd..d653321a54 100644
--- a/packages/network/src/services/http/interceptors/__tests__/merge-interceptor.spec.ts
+++ b/packages/network/src/services/http/interceptors/__tests__/merge-interceptor.spec.ts
@@ -16,7 +16,7 @@
import { afterEach, beforeEach, describe, expect, it, vitest } from 'vitest';
-import type { Injector } from '@wendellhu/redi';
+import type { Injector } from '@univerjs/core';
import { HTTPService } from '../../http.service';
import { createHTTPTestBed, type MockHTTPImplementation } from '../../__testing__/http-testing-utils';
import { IHTTPImplementation } from '../../implementations/implementation';
diff --git a/packages/network/src/services/http/interceptors/__tests__/retry-interceptor.spec.ts b/packages/network/src/services/http/interceptors/__tests__/retry-interceptor.spec.ts
index 86ecb17595..de0fe8ea09 100644
--- a/packages/network/src/services/http/interceptors/__tests__/retry-interceptor.spec.ts
+++ b/packages/network/src/services/http/interceptors/__tests__/retry-interceptor.spec.ts
@@ -16,7 +16,7 @@
import { afterEach, beforeEach, describe, expect, it, vitest } from 'vitest';
-import type { Injector } from '@wendellhu/redi';
+import type { Injector } from '@univerjs/core';
import { HTTPService } from '../../http.service';
import { createHTTPTestBed, type MockHTTPImplementation } from '../../__testing__/http-testing-utils';
import { IHTTPImplementation } from '../../implementations/implementation';
diff --git a/packages/network/src/services/http/interceptors/__tests__/threshold-interceptor.spec.ts b/packages/network/src/services/http/interceptors/__tests__/threshold-interceptor.spec.ts
index f596617024..d91016bd38 100644
--- a/packages/network/src/services/http/interceptors/__tests__/threshold-interceptor.spec.ts
+++ b/packages/network/src/services/http/interceptors/__tests__/threshold-interceptor.spec.ts
@@ -15,7 +15,7 @@
*/
import { afterEach, beforeEach, describe, expect, it, vitest } from 'vitest';
-import type { Injector } from '@wendellhu/redi';
+import type { Injector } from '@univerjs/core';
import { HTTPService } from '../../http.service';
import { createHTTPTestBed, type MockHTTPImplementation } from '../../__testing__/http-testing-utils';
import { IHTTPImplementation } from '../../implementations/implementation';
diff --git a/packages/network/src/services/web-socket/web-socket.service.ts b/packages/network/src/services/web-socket/web-socket.service.ts
index e01c2efb1f..d14a6e559c 100644
--- a/packages/network/src/services/web-socket/web-socket.service.ts
+++ b/packages/network/src/services/web-socket/web-socket.service.ts
@@ -15,8 +15,7 @@
*/
import type { Nullable } from '@univerjs/core';
-import { Disposable, DisposableCollection, toDisposable } from '@univerjs/core';
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier, Disposable, DisposableCollection, toDisposable } from '@univerjs/core';
import { Observable } from 'rxjs';
import { share } from 'rxjs/operators';
diff --git a/packages/rpc/package.json b/packages/rpc/package.json
index 8ed53b535d..bfb994e95e 100644
--- a/packages/rpc/package.json
+++ b/packages/rpc/package.json
@@ -57,13 +57,11 @@
},
"peerDependencies": {
"@univerjs/core": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": ">=7.0.0"
},
"devDependencies": {
"@univerjs/core": "workspace:*",
"@univerjs/shared": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": "^7.8.1",
"typescript": "^5.5.3",
"vite": "^5.3.4",
diff --git a/packages/rpc/src/controllers/data-sync/data-sync-primary.controller.ts b/packages/rpc/src/controllers/data-sync/data-sync-primary.controller.ts
index 48ccffac78..5853c97e33 100644
--- a/packages/rpc/src/controllers/data-sync/data-sync-primary.controller.ts
+++ b/packages/rpc/src/controllers/data-sync/data-sync-primary.controller.ts
@@ -14,10 +14,12 @@
* limitations under the License.
*/
-import type { IMutation, IMutationInfo, Workbook } from '@univerjs/core';
+import type { IDisposable, IMutation, IMutationInfo, Workbook } from '@univerjs/core';
import {
CommandType,
ICommandService,
+ Inject,
+ Injector,
IUniverInstanceService,
LifecycleStages,
OnLifecycle,
@@ -25,8 +27,6 @@ import {
toDisposable,
UniverInstanceType,
} from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
import { takeUntil } from 'rxjs/operators';
import type { IRemoteSyncMutationOptions } from '../../services/remote-instance/remote-instance.service';
diff --git a/packages/rpc/src/controllers/data-sync/data-sync-replica.controller.ts b/packages/rpc/src/controllers/data-sync/data-sync-replica.controller.ts
index 4d17da17aa..3f0816b8fd 100644
--- a/packages/rpc/src/controllers/data-sync/data-sync-replica.controller.ts
+++ b/packages/rpc/src/controllers/data-sync/data-sync-replica.controller.ts
@@ -15,8 +15,7 @@
*/
import type { IMutationInfo } from '@univerjs/core';
-import { CommandType, Disposable, ICommandService, LifecycleStages, OnLifecycle } from '@univerjs/core';
-import { Inject, Injector } from '@wendellhu/redi';
+import { CommandType, Disposable, ICommandService, Inject, Injector, LifecycleStages, OnLifecycle } from '@univerjs/core';
import type { IRemoteSyncMutationOptions } from '../../services/remote-instance/remote-instance.service';
import {
diff --git a/packages/rpc/src/plugin.ts b/packages/rpc/src/plugin.ts
index c9987c18a8..b71b7f0148 100644
--- a/packages/rpc/src/plugin.ts
+++ b/packages/rpc/src/plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { Plugin } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { Inject, Injector, Plugin } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
import { DataSyncPrimaryController } from './controllers/data-sync/data-sync-primary.controller';
import { DataSyncReplicaController } from './controllers/data-sync/data-sync-replica.controller';
diff --git a/packages/rpc/src/services/remote-instance/remote-instance.service.ts b/packages/rpc/src/services/remote-instance/remote-instance.service.ts
index 6d92652ebb..34d6c5b07d 100644
--- a/packages/rpc/src/services/remote-instance/remote-instance.service.ts
+++ b/packages/rpc/src/services/remote-instance/remote-instance.service.ts
@@ -15,8 +15,7 @@
*/
import type { IExecutionOptions, IMutationInfo, IWorkbookData } from '@univerjs/core';
-import { ICommandService, ILogService, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier, ICommandService, ILogService, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
export interface IRemoteSyncMutationOptions extends IExecutionOptions {
/** If this mutation is executed after it was sent from the peer univer instance (e.g. in a web worker). */
diff --git a/packages/rpc/src/services/rpc/channel.service.ts b/packages/rpc/src/services/rpc/channel.service.ts
index 5d23eaa8b6..5de377bc72 100644
--- a/packages/rpc/src/services/rpc/channel.service.ts
+++ b/packages/rpc/src/services/rpc/channel.service.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier } from '@wendellhu/redi';
+import type { IDisposable } from '@univerjs/core';
+import { createIdentifier } from '@univerjs/core';
import type { IChannel, IMessageProtocol } from './rpc.service';
import { ChannelClient, ChannelServer } from './rpc.service';
diff --git a/packages/sheets-conditional-formatting-ui/package.json b/packages/sheets-conditional-formatting-ui/package.json
index 4c6f3b8995..3946944a4c 100644
--- a/packages/sheets-conditional-formatting-ui/package.json
+++ b/packages/sheets-conditional-formatting-ui/package.json
@@ -73,7 +73,6 @@
"@univerjs/sheets-conditional-formatting": "workspace:*",
"@univerjs/sheets-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": ">=2.0.0",
"react": "^16.9.0 || ^17.0.0 || ^18.0.0",
"react-dom": "^16.9.0 || ^17.0.0 || ^18.0.0",
@@ -101,7 +100,6 @@
"@univerjs/sheets-conditional-formatting": "workspace:*",
"@univerjs/sheets-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": "^2.1.1",
"less": "^4.2.0",
"react": "18.3.1",
diff --git a/packages/sheets-conditional-formatting-ui/src/commands/operations/open-conditional-formatting-panel.ts b/packages/sheets-conditional-formatting-ui/src/commands/operations/open-conditional-formatting-panel.ts
index 6ffa56ac7e..57bb3420af 100644
--- a/packages/sheets-conditional-formatting-ui/src/commands/operations/open-conditional-formatting-panel.ts
+++ b/packages/sheets-conditional-formatting-ui/src/commands/operations/open-conditional-formatting-panel.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType, ICommandService } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { SheetsSelectionsService } from '@univerjs/sheets';
import { CFRuleType, CFSubRuleType, createDefaultRule } from '@univerjs/sheets-conditional-formatting';
import type { IColorScale, IConditionFormattingRule, IDataBar, IFormulaHighlightCell, IIconSet, IRankHighlightCell } from '@univerjs/sheets-conditional-formatting';
diff --git a/packages/sheets-conditional-formatting-ui/src/components/color-picker/index.tsx b/packages/sheets-conditional-formatting-ui/src/components/color-picker/index.tsx
index 14d0d089df..f09870c143 100644
--- a/packages/sheets-conditional-formatting-ui/src/components/color-picker/index.tsx
+++ b/packages/sheets-conditional-formatting-ui/src/components/color-picker/index.tsx
@@ -15,9 +15,8 @@
*/
import { Dropdown, ColorPicker as OriginColorPicker } from '@univerjs/design';
-import { ColorKit } from '@univerjs/core';
+import { ColorKit, useDependency } from '@univerjs/core';
import { ComponentManager } from '@univerjs/ui';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import React, { useMemo } from 'react';
import { MoreDownSingle } from '@univerjs/icons';
diff --git a/packages/sheets-conditional-formatting-ui/src/components/conditional-style-editor/index.tsx b/packages/sheets-conditional-formatting-ui/src/components/conditional-style-editor/index.tsx
index c2b553d2de..dc238f009b 100644
--- a/packages/sheets-conditional-formatting-ui/src/components/conditional-style-editor/index.tsx
+++ b/packages/sheets-conditional-formatting-ui/src/components/conditional-style-editor/index.tsx
@@ -15,9 +15,8 @@
*/
import React, { useEffect, useState } from 'react';
-import { BooleanNumber } from '@univerjs/core';
+import { BooleanNumber, useDependency } from '@univerjs/core';
import { ComponentManager } from '@univerjs/ui';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import cl from 'clsx';
import type { IHighlightCell } from '@univerjs/sheets-conditional-formatting';
import { removeUndefinedAttr } from '@univerjs/sheets-conditional-formatting';
diff --git a/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/colorScale.tsx b/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/colorScale.tsx
index 9076e31bd3..eb3cf25bca 100644
--- a/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/colorScale.tsx
+++ b/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/colorScale.tsx
@@ -15,9 +15,8 @@
*/
import React, { useEffect, useMemo, useState } from 'react';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { createInternalEditorID, IUniverInstanceService, LocaleService, UniverInstanceType, useDependency } from '@univerjs/core';
import type { Workbook } from '@univerjs/core';
-import { createInternalEditorID, IUniverInstanceService, LocaleService, UniverInstanceType } from '@univerjs/core';
import { InputNumber, Select } from '@univerjs/design';
import { TextEditor } from '@univerjs/ui';
import { CFRuleType, CFValueType, createDefaultValueByValueType, SHEET_CONDITIONAL_FORMATTING_PLUGIN } from '@univerjs/sheets-conditional-formatting';
diff --git a/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/dataBar.tsx b/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/dataBar.tsx
index 15632d7060..f6c1eb7c97 100644
--- a/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/dataBar.tsx
+++ b/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/dataBar.tsx
@@ -16,9 +16,8 @@
import React, { useEffect, useMemo, useRef, useState } from 'react';
import { Checkbox, InputNumber, Radio, RadioGroup, Select } from '@univerjs/design';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { createInternalEditorID, IUniverInstanceService, LocaleService, UniverInstanceType, useDependency } from '@univerjs/core';
import type { Workbook } from '@univerjs/core';
-import { createInternalEditorID, IUniverInstanceService, LocaleService, UniverInstanceType } from '@univerjs/core';
import { TextEditor } from '@univerjs/ui';
import { CFRuleType, CFValueType, createDefaultValueByValueType, SHEET_CONDITIONAL_FORMATTING_PLUGIN } from '@univerjs/sheets-conditional-formatting';
import type { IConditionalFormattingRuleConfig, IValueConfig } from '@univerjs/sheets-conditional-formatting';
diff --git a/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/formula.tsx b/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/formula.tsx
index ab2b252c9c..47185a520f 100644
--- a/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/formula.tsx
+++ b/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/formula.tsx
@@ -15,9 +15,8 @@
*/
import React, { useEffect, useState } from 'react';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { createInternalEditorID, IUniverInstanceService, LocaleService, UniverInstanceType, useDependency } from '@univerjs/core';
import type { Workbook } from '@univerjs/core';
-import { createInternalEditorID, IUniverInstanceService, LocaleService, UniverInstanceType } from '@univerjs/core';
import { TextEditor } from '@univerjs/ui';
import { CFRuleType, CFSubRuleType, SHEET_CONDITIONAL_FORMATTING_PLUGIN } from '@univerjs/sheets-conditional-formatting';
import type { IAverageHighlightCell, IConditionalFormattingRuleConfig, IHighlightCell, IRankHighlightCell } from '@univerjs/sheets-conditional-formatting';
diff --git a/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/highlightCell.tsx b/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/highlightCell.tsx
index caf47f7180..6c666c43be 100644
--- a/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/highlightCell.tsx
+++ b/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/highlightCell.tsx
@@ -16,8 +16,7 @@
import React, { useEffect, useMemo, useState } from 'react';
import { Input, InputNumber, Select } from '@univerjs/design';
-import { useDependency } from '@wendellhu/redi/react-bindings';
-import { LocaleService } from '@univerjs/core';
+import { LocaleService, useDependency } from '@univerjs/core';
import {
CFNumberOperator,
CFRuleType,
diff --git a/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/iconSet.tsx b/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/iconSet.tsx
index fe6587ca75..5eab1b8608 100644
--- a/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/iconSet.tsx
+++ b/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/iconSet.tsx
@@ -20,10 +20,9 @@ import get from 'lodash.get';
import { MoreDownSingle, SlashSingle } from '@univerjs/icons';
import { Checkbox, Dropdown, InputNumber, Select } from '@univerjs/design';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { createInternalEditorID, IUniverInstanceService, LocaleService, Tools, UniverInstanceType, useDependency } from '@univerjs/core';
import type { Workbook } from '@univerjs/core';
-import { createInternalEditorID, IUniverInstanceService, LocaleService, Tools, UniverInstanceType } from '@univerjs/core';
import { ILayoutService, TextEditor, useScrollYOverContainer } from '@univerjs/ui';
import type { IIconSet, IIconType } from '@univerjs/sheets-conditional-formatting';
import { CFNumberOperator, CFRuleType, CFSubRuleType, CFValueType, compareWithNumber, createDefaultValue, EMPTY_ICON_TYPE, getOppositeOperator, iconGroup, iconMap, SHEET_CONDITIONAL_FORMATTING_PLUGIN } from '@univerjs/sheets-conditional-formatting';
diff --git a/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/index.tsx b/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/index.tsx
index a4908fb078..f1cdddd436 100644
--- a/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/index.tsx
+++ b/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/index.tsx
@@ -16,8 +16,7 @@
import React, { useEffect, useMemo, useRef, useState } from 'react';
import type { IRange, IUnitRange, Workbook } from '@univerjs/core';
-import { createInternalEditorID, ICommandService, InterceptorManager, IUniverInstanceService, LocaleService, UniverInstanceType } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { createInternalEditorID, ICommandService, InterceptorManager, IUniverInstanceService, LocaleService, UniverInstanceType, useDependency } from '@univerjs/core';
import { serializeRange } from '@univerjs/engine-formula';
import { Button, Select } from '@univerjs/design';
diff --git a/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/rank.tsx b/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/rank.tsx
index dcc98e88eb..6f47dd52d5 100644
--- a/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/rank.tsx
+++ b/packages/sheets-conditional-formatting-ui/src/components/panel/rule-edit/rank.tsx
@@ -15,8 +15,7 @@
*/
import React, { useEffect, useState } from 'react';
-import { useDependency } from '@wendellhu/redi/react-bindings';
-import { LocaleService } from '@univerjs/core';
+import { LocaleService, useDependency } from '@univerjs/core';
import { Checkbox, InputNumber, Select } from '@univerjs/design';
import { CFNumberOperator, CFRuleType, CFSubRuleType } from '@univerjs/sheets-conditional-formatting';
import type { IAverageHighlightCell, IConditionalFormattingRuleConfig, IHighlightCell, IRankHighlightCell } from '@univerjs/sheets-conditional-formatting';
diff --git a/packages/sheets-conditional-formatting-ui/src/components/panel/rule-list/index.tsx b/packages/sheets-conditional-formatting-ui/src/components/panel/rule-list/index.tsx
index 380c32a3ef..319ea55283 100644
--- a/packages/sheets-conditional-formatting-ui/src/components/panel/rule-list/index.tsx
+++ b/packages/sheets-conditional-formatting-ui/src/components/panel/rule-list/index.tsx
@@ -19,9 +19,8 @@ import { Select, Tooltip } from '@univerjs/design';
import { useObservable } from '@univerjs/ui';
import { useHighlightRange } from '@univerjs/sheets-ui';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { ICommandService, IUniverInstanceService, LocaleService, Rectangle, UniverInstanceType, useDependency } from '@univerjs/core';
import type { ICellDataForSheetInterceptor, IRange, Workbook } from '@univerjs/core';
-import { ICommandService, IUniverInstanceService, LocaleService, Rectangle, UniverInstanceType } from '@univerjs/core';
import type { ICellPermission } from '@univerjs/sheets';
import { SetSelectionsOperation, SetWorksheetActiveOperation, SheetsSelectionsService } from '@univerjs/sheets';
import { serializeRange } from '@univerjs/engine-formula';
diff --git a/packages/sheets-conditional-formatting-ui/src/controllers/cf.auto-fill.controller.ts b/packages/sheets-conditional-formatting-ui/src/controllers/cf.auto-fill.controller.ts
index 2fb7f46f72..91b9ef0efa 100644
--- a/packages/sheets-conditional-formatting-ui/src/controllers/cf.auto-fill.controller.ts
+++ b/packages/sheets-conditional-formatting-ui/src/controllers/cf.auto-fill.controller.ts
@@ -15,12 +15,11 @@
*/
import type { IMutationInfo, IRange, Workbook } from '@univerjs/core';
-import { Disposable, IUniverInstanceService, LifecycleStages, ObjectMatrix, OnLifecycle, Range, Rectangle, UniverInstanceType } from '@univerjs/core';
+import { Disposable, Inject, Injector, IUniverInstanceService, LifecycleStages, ObjectMatrix, OnLifecycle, Range, Rectangle, UniverInstanceType } from '@univerjs/core';
import { createTopMatrixFromMatrix, findAllRectangle } from '@univerjs/sheets';
import type { IDiscreteRange, ISheetAutoFillHook } from '@univerjs/sheets-ui';
import { APPLY_TYPE, getAutoFillRepeatRange, IAutoFillService, virtualizeDiscreteRanges } from '@univerjs/sheets-ui';
-import { Inject, Injector } from '@wendellhu/redi';
import { ConditionalFormattingRuleModel, ConditionalFormattingViewModel, DeleteConditionalRuleMutation, DeleteConditionalRuleMutationUndoFactory, SetConditionalRuleMutation, setConditionalRuleMutationUndoFactory, SHEET_CONDITIONAL_FORMATTING_PLUGIN } from '@univerjs/sheets-conditional-formatting';
import type { IDeleteConditionalRuleMutationParams, ISetConditionalRuleMutationParams } from '@univerjs/sheets-conditional-formatting';
diff --git a/packages/sheets-conditional-formatting-ui/src/controllers/cf.clear.controller.ts b/packages/sheets-conditional-formatting-ui/src/controllers/cf.clear.controller.ts
index 655682ed41..4b35d7604a 100644
--- a/packages/sheets-conditional-formatting-ui/src/controllers/cf.clear.controller.ts
+++ b/packages/sheets-conditional-formatting-ui/src/controllers/cf.clear.controller.ts
@@ -15,9 +15,8 @@
*/
import type { IMutationInfo, Workbook } from '@univerjs/core';
-import { Disposable, IUniverInstanceService, LifecycleStages, OnLifecycle, Rectangle, UniverInstanceType } from '@univerjs/core';
+import { Disposable, Inject, Injector, IUniverInstanceService, LifecycleStages, OnLifecycle, Rectangle, UniverInstanceType } from '@univerjs/core';
import { ClearSelectionAllCommand, ClearSelectionFormatCommand, RangeMergeUtil, SheetInterceptorService, SheetsSelectionsService } from '@univerjs/sheets';
-import { Inject, Injector } from '@wendellhu/redi';
import { ConditionalFormattingRuleModel, DeleteConditionalRuleMutation, DeleteConditionalRuleMutationUndoFactory, SetConditionalRuleMutation, setConditionalRuleMutationUndoFactory } from '@univerjs/sheets-conditional-formatting';
import type { IDeleteConditionalRuleMutationParams, ISetConditionalRuleMutationParams } from '@univerjs/sheets-conditional-formatting';
diff --git a/packages/sheets-conditional-formatting-ui/src/controllers/cf.copy-paste.controller.ts b/packages/sheets-conditional-formatting-ui/src/controllers/cf.copy-paste.controller.ts
index b99239ad14..b4c62227ad 100644
--- a/packages/sheets-conditional-formatting-ui/src/controllers/cf.copy-paste.controller.ts
+++ b/packages/sheets-conditional-formatting-ui/src/controllers/cf.copy-paste.controller.ts
@@ -17,6 +17,8 @@
import type { IRange, Nullable, Workbook } from '@univerjs/core';
import {
Disposable,
+ Inject,
+ Injector,
IUniverInstanceService,
LifecycleStages,
ObjectMatrix,
@@ -31,7 +33,6 @@ import {
} from '@univerjs/sheets';
import type { IDiscreteRange } from '@univerjs/sheets-ui';
import { COPY_TYPE, getRepeatRange, ISheetClipboardService, PREDEFINED_HOOK_NAME, rangeToDiscreteRange, virtualizeDiscreteRanges } from '@univerjs/sheets-ui';
-import { Inject, Injector } from '@wendellhu/redi';
import { AddConditionalRuleMutation, AddConditionalRuleMutationUndoFactory, ConditionalFormattingRuleModel, ConditionalFormattingViewModel, DeleteConditionalRuleMutation, DeleteConditionalRuleMutationUndoFactory, SetConditionalRuleMutation, setConditionalRuleMutationUndoFactory, SHEET_CONDITIONAL_FORMATTING_PLUGIN } from '@univerjs/sheets-conditional-formatting';
import type { IAddConditionalRuleMutationParams, IConditionalFormattingRuleConfig, IConditionFormattingRule, IDeleteConditionalRuleMutationParams, ISetConditionalRuleMutationParams } from '@univerjs/sheets-conditional-formatting';
diff --git a/packages/sheets-conditional-formatting-ui/src/controllers/cf.editor.controller.ts b/packages/sheets-conditional-formatting-ui/src/controllers/cf.editor.controller.ts
index 14b1a73020..51be7d17b1 100644
--- a/packages/sheets-conditional-formatting-ui/src/controllers/cf.editor.controller.ts
+++ b/packages/sheets-conditional-formatting-ui/src/controllers/cf.editor.controller.ts
@@ -16,13 +16,13 @@
import {
Disposable,
+ Inject,
LifecycleStages,
OnLifecycle,
toDisposable,
} from '@univerjs/core';
import { IEditorBridgeService } from '@univerjs/sheets-ui';
-import { Inject } from '@wendellhu/redi';
import { ConditionalFormattingService, getStringFromDataStream } from '@univerjs/sheets-conditional-formatting';
@OnLifecycle(LifecycleStages.Rendered, ConditionalFormattingEditorController)
diff --git a/packages/sheets-conditional-formatting-ui/src/controllers/cf.i18n.controller.ts b/packages/sheets-conditional-formatting-ui/src/controllers/cf.i18n.controller.ts
index afacca42ba..4200fbfaee 100644
--- a/packages/sheets-conditional-formatting-ui/src/controllers/cf.i18n.controller.ts
+++ b/packages/sheets-conditional-formatting-ui/src/controllers/cf.i18n.controller.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { Disposable, LifecycleStages, LocaleService, OnLifecycle } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { Disposable, Inject, LifecycleStages, LocaleService, OnLifecycle } from '@univerjs/core';
import type { ReactNode } from 'react';
diff --git a/packages/sheets-conditional-formatting-ui/src/controllers/cf.menu.controller.ts b/packages/sheets-conditional-formatting-ui/src/controllers/cf.menu.controller.ts
index ba26e91fc3..60686f52b6 100644
--- a/packages/sheets-conditional-formatting-ui/src/controllers/cf.menu.controller.ts
+++ b/packages/sheets-conditional-formatting-ui/src/controllers/cf.menu.controller.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
-import { Disposable, IUniverInstanceService, LifecycleStages, LocaleService, OnLifecycle, Tools, UniverInstanceType } from '@univerjs/core';
+import type { IDisposable } from '@univerjs/core';
+import { Disposable, Inject, Injector, IUniverInstanceService, LifecycleStages, LocaleService, OnLifecycle, Tools, UniverInstanceType } from '@univerjs/core';
import type { MenuConfig } from '@univerjs/ui';
import { ComponentManager, IMenuService, ISidebarService } from '@univerjs/ui';
import type { IConditionFormattingRule } from '@univerjs/sheets-conditional-formatting';
diff --git a/packages/sheets-conditional-formatting-ui/src/controllers/cf.permission.controller.ts b/packages/sheets-conditional-formatting-ui/src/controllers/cf.permission.controller.ts
index 1a2e7150b4..05e042db09 100644
--- a/packages/sheets-conditional-formatting-ui/src/controllers/cf.permission.controller.ts
+++ b/packages/sheets-conditional-formatting-ui/src/controllers/cf.permission.controller.ts
@@ -15,11 +15,10 @@
*/
import type { ICommandInfo } from '@univerjs/core';
-import { Disposable, ICommandService, LifecycleStages, LocaleService, OnLifecycle } from '@univerjs/core';
+import { Disposable, ICommandService, Inject, LifecycleStages, LocaleService, OnLifecycle } from '@univerjs/core';
import { RangeProtectionPermissionEditPoint, WorkbookEditablePermission, WorksheetEditPermission, WorksheetSetCellStylePermission } from '@univerjs/sheets';
import { SheetPermissionInterceptorBaseController } from '@univerjs/sheets-ui';
-import { Inject } from '@wendellhu/redi';
import type { IAddCfCommandParams } from '../commands/commands/add-cf.command';
import { AddCfCommand } from '../commands/commands/add-cf.command';
diff --git a/packages/sheets-conditional-formatting-ui/src/controllers/cf.ref-range.controller.ts b/packages/sheets-conditional-formatting-ui/src/controllers/cf.ref-range.controller.ts
index 45035eaea4..78c5b6ffc8 100644
--- a/packages/sheets-conditional-formatting-ui/src/controllers/cf.ref-range.controller.ts
+++ b/packages/sheets-conditional-formatting-ui/src/controllers/cf.ref-range.controller.ts
@@ -15,10 +15,9 @@
*/
import type { IRange, Workbook } from '@univerjs/core';
-import { Disposable, IUniverInstanceService, LifecycleStages, OnLifecycle, toDisposable, UniverInstanceType } from '@univerjs/core';
+import { Disposable, Inject, Injector, IUniverInstanceService, LifecycleStages, OnLifecycle, toDisposable, UniverInstanceType } from '@univerjs/core';
import type { EffectRefRangeParams } from '@univerjs/sheets';
import { handleDefaultRangeChangeWithEffectRefCommands, RefRangeService } from '@univerjs/sheets';
-import { Inject, Injector } from '@wendellhu/redi';
import { ConditionalFormattingRuleModel, DeleteConditionalRuleMutation, DeleteConditionalRuleMutationUndoFactory, isRangesEqual, SetConditionalRuleMutation, setConditionalRuleMutationUndoFactory } from '@univerjs/sheets-conditional-formatting';
import type { IConditionFormattingRule, IDeleteConditionalRuleMutationParams, ISetConditionalRuleMutationParams } from '@univerjs/sheets-conditional-formatting';
diff --git a/packages/sheets-conditional-formatting-ui/src/controllers/cf.render.controller.ts b/packages/sheets-conditional-formatting-ui/src/controllers/cf.render.controller.ts
index 46aea63dfc..c1fe0f020c 100644
--- a/packages/sheets-conditional-formatting-ui/src/controllers/cf.render.controller.ts
+++ b/packages/sheets-conditional-formatting-ui/src/controllers/cf.render.controller.ts
@@ -15,10 +15,9 @@
*/
import type { Workbook } from '@univerjs/core';
-import { Disposable, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
+import { Disposable, Inject, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import { INTERCEPTOR_POINT, SheetInterceptorService } from '@univerjs/sheets';
import { SheetSkeletonManagerService } from '@univerjs/sheets-ui';
-import { Inject } from '@wendellhu/redi';
import { bufferTime, filter } from 'rxjs/operators';
import type { ISheetFontRenderExtension } from '@univerjs/engine-render';
import { IRenderManagerService } from '@univerjs/engine-render';
diff --git a/packages/sheets-conditional-formatting-ui/src/menu/manage-rule.ts b/packages/sheets-conditional-formatting-ui/src/menu/manage-rule.ts
index 2d8820a3e8..ab690950ec 100644
--- a/packages/sheets-conditional-formatting-ui/src/menu/manage-rule.ts
+++ b/packages/sheets-conditional-formatting-ui/src/menu/manage-rule.ts
@@ -16,12 +16,11 @@
import { merge, Observable } from 'rxjs';
import type { IMenuSelectorItem } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor, ICellDataForSheetInterceptor, IRange, Workbook } from '@univerjs/core';
import { getMenuHiddenObservable, MenuGroup, MenuItemType, MenuPosition } from '@univerjs/ui';
import { RangeProtectionPermissionEditPoint, SetWorksheetActiveOperation, SheetsSelectionsService, WorkbookEditablePermission, WorksheetEditPermission, WorksheetSetCellStylePermission } from '@univerjs/sheets';
import { debounceTime } from 'rxjs/operators';
-import type { ICellDataForSheetInterceptor, IRange, Workbook } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, Rectangle, UniverInstanceType } from '@univerjs/core';
import { AddConditionalRuleMutation, ConditionalFormattingRuleModel, DeleteConditionalRuleMutation, MoveConditionalRuleMutation, SetConditionalRuleMutation } from '@univerjs/sheets-conditional-formatting';
diff --git a/packages/sheets-conditional-formatting-ui/src/mobile-plugin.ts b/packages/sheets-conditional-formatting-ui/src/mobile-plugin.ts
index 4ac94fe199..aa82851903 100644
--- a/packages/sheets-conditional-formatting-ui/src/mobile-plugin.ts
+++ b/packages/sheets-conditional-formatting-ui/src/mobile-plugin.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { DependentOn, ICommandService, Plugin, Tools, UniverInstanceType } from '@univerjs/core';
-import { Inject, Injector } from '@wendellhu/redi';
+import { DependentOn, ICommandService, Inject, Injector, Plugin, Tools, UniverInstanceType } from '@univerjs/core';
import { SHEET_CONDITIONAL_FORMATTING_PLUGIN, UniverSheetsConditionalFormattingPlugin } from '@univerjs/sheets-conditional-formatting';
import { AddAverageCfCommand } from './commands/commands/add-average-cf.command';
import { AddColorScaleConditionalRuleCommand } from './commands/commands/add-color-scale-cf.command';
diff --git a/packages/sheets-conditional-formatting-ui/src/plugin.ts b/packages/sheets-conditional-formatting-ui/src/plugin.ts
index 9cf97997e5..446580c6ef 100644
--- a/packages/sheets-conditional-formatting-ui/src/plugin.ts
+++ b/packages/sheets-conditional-formatting-ui/src/plugin.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { DependentOn, ICommandService, Plugin, Tools, UniverInstanceType } from '@univerjs/core';
-import { Inject, Injector } from '@wendellhu/redi';
+import { DependentOn, ICommandService, Inject, Injector, Plugin, Tools, UniverInstanceType } from '@univerjs/core';
import { SHEET_CONDITIONAL_FORMATTING_PLUGIN, UniverSheetsConditionalFormattingPlugin } from '@univerjs/sheets-conditional-formatting';
import { AddAverageCfCommand } from './commands/commands/add-average-cf.command';
import { AddColorScaleConditionalRuleCommand } from './commands/commands/add-color-scale-cf.command';
diff --git a/packages/sheets-conditional-formatting/package.json b/packages/sheets-conditional-formatting/package.json
index f60d8cadc3..0095521d3b 100644
--- a/packages/sheets-conditional-formatting/package.json
+++ b/packages/sheets-conditional-formatting/package.json
@@ -65,7 +65,6 @@
"@univerjs/engine-formula": "workspace:*",
"@univerjs/engine-render": "workspace:*",
"@univerjs/sheets": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"dayjs": ">=1.11.0",
"rxjs": ">=7.0.0"
},
@@ -79,7 +78,6 @@
"@univerjs/icons-svg": "^0.1.55",
"@univerjs/shared": "workspace:*",
"@univerjs/sheets": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"dayjs": "^1.11.11",
"rxjs": "^7.8.1",
"sharp": "^0.33.4",
diff --git a/packages/sheets-conditional-formatting/src/commands/mutations/add-conditional-rule.mutation.ts b/packages/sheets-conditional-formatting/src/commands/mutations/add-conditional-rule.mutation.ts
index 519a5c394e..63487fa38b 100644
--- a/packages/sheets-conditional-formatting/src/commands/mutations/add-conditional-rule.mutation.ts
+++ b/packages/sheets-conditional-formatting/src/commands/mutations/add-conditional-rule.mutation.ts
@@ -14,11 +14,10 @@
* limitations under the License.
*/
-import type { IMutation } from '@univerjs/core';
+import type { IAccessor, IMutation } from '@univerjs/core';
import {
CommandType,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { ConditionalFormattingRuleModel } from '../../models/conditional-formatting-rule-model';
import type { IConditionFormattingRule } from '../../models/type';
import type { IDeleteConditionalRuleMutationParams } from './delete-conditional-rule.mutation';
diff --git a/packages/sheets-conditional-formatting/src/commands/mutations/delete-conditional-rule.mutation.ts b/packages/sheets-conditional-formatting/src/commands/mutations/delete-conditional-rule.mutation.ts
index 67bc402aef..59143b0f26 100644
--- a/packages/sheets-conditional-formatting/src/commands/mutations/delete-conditional-rule.mutation.ts
+++ b/packages/sheets-conditional-formatting/src/commands/mutations/delete-conditional-rule.mutation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IMutation, IMutationInfo } from '@univerjs/core';
+import type { IAccessor, IMutation, IMutationInfo } from '@univerjs/core';
import { CommandType, Tools } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { ConditionalFormattingRuleModel } from '../../models/conditional-formatting-rule-model';
import { transformSupportSymmetryAnchor } from '../../utils/anchor';
import type { IAddConditionalRuleMutationParams } from './add-conditional-rule.mutation';
diff --git a/packages/sheets-conditional-formatting/src/commands/mutations/set-conditional-rule.mutation.ts b/packages/sheets-conditional-formatting/src/commands/mutations/set-conditional-rule.mutation.ts
index ada8cf6229..7a92362f84 100644
--- a/packages/sheets-conditional-formatting/src/commands/mutations/set-conditional-rule.mutation.ts
+++ b/packages/sheets-conditional-formatting/src/commands/mutations/set-conditional-rule.mutation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IMutation } from '@univerjs/core';
+import type { IAccessor, IMutation } from '@univerjs/core';
import { CommandType, Tools } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { ConditionalFormattingRuleModel } from '../../models/conditional-formatting-rule-model';
import type { IConditionFormattingRule } from '../../models/type';
diff --git a/packages/sheets-conditional-formatting/src/models/conditional-formatting-rule-model.ts b/packages/sheets-conditional-formatting/src/models/conditional-formatting-rule-model.ts
index 3c4c768508..05ad6e7eea 100644
--- a/packages/sheets-conditional-formatting/src/models/conditional-formatting-rule-model.ts
+++ b/packages/sheets-conditional-formatting/src/models/conditional-formatting-rule-model.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { Inject, Injector } from '@wendellhu/redi';
-import { Range } from '@univerjs/core';
+import { Inject, Injector, Range } from '@univerjs/core';
import { Subject } from 'rxjs';
import { createCfId } from '../utils/create-cf-id';
import { ConditionalFormattingService } from '../services/conditional-formatting.service';
diff --git a/packages/sheets-conditional-formatting/src/plugin.ts b/packages/sheets-conditional-formatting/src/plugin.ts
index 4d42dc5ca5..93fec14066 100644
--- a/packages/sheets-conditional-formatting/src/plugin.ts
+++ b/packages/sheets-conditional-formatting/src/plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { ICommandService, Plugin, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { ICommandService, Inject, Injector, Plugin, UniverInstanceType } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
import { SHEET_CONDITIONAL_FORMATTING_PLUGIN } from './base/const';
import { ConditionalFormattingService } from './services/conditional-formatting.service';
import { ConditionalFormattingRuleModel } from './models/conditional-formatting-rule-model';
diff --git a/packages/sheets-conditional-formatting/src/services/__test__/test.util.ts b/packages/sheets-conditional-formatting/src/services/__test__/test.util.ts
index a13ef6e5bb..b66fcb5bc4 100644
--- a/packages/sheets-conditional-formatting/src/services/__test__/test.util.ts
+++ b/packages/sheets-conditional-formatting/src/services/__test__/test.util.ts
@@ -14,14 +14,12 @@
* limitations under the License.
*/
-import type { IWorkbookData } from '@univerjs/core';
-import { ICommandService, IUniverInstanceService, LocaleType, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
+import type { Dependency, IWorkbookData } from '@univerjs/core';
+import { ICommandService, Inject, Injector, IUniverInstanceService, LocaleType, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
import {
SheetInterceptorService,
} from '@univerjs/sheets';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
import { IActiveDirtyManagerService } from '@univerjs/engine-formula';
import { ConditionalFormattingService } from '../conditional-formatting.service';
import { ConditionalFormattingFormulaService } from '../conditional-formatting-formula.service';
diff --git a/packages/sheets-conditional-formatting/src/services/calculate-unit/type.ts b/packages/sheets-conditional-formatting/src/services/calculate-unit/type.ts
index 5ecbea3ad7..eeff816d4e 100644
--- a/packages/sheets-conditional-formatting/src/services/calculate-unit/type.ts
+++ b/packages/sheets-conditional-formatting/src/services/calculate-unit/type.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import type { IAccessor } from '@wendellhu/redi';
-import type { ObjectMatrix, Workbook, Worksheet } from '@univerjs/core';
+import type { IAccessor, ObjectMatrix, Workbook, Worksheet } from '@univerjs/core';
import type { CFRuleType } from '../../base/const';
import type { IConditionFormattingRule } from '../../models/type';
diff --git a/packages/sheets-conditional-formatting/src/services/conditional-formatting-formula.service.ts b/packages/sheets-conditional-formatting/src/services/conditional-formatting-formula.service.ts
index b78665cf44..bb7cffc81e 100644
--- a/packages/sheets-conditional-formatting/src/services/conditional-formatting-formula.service.ts
+++ b/packages/sheets-conditional-formatting/src/services/conditional-formatting-formula.service.ts
@@ -15,12 +15,14 @@
*/
import type { ICellData, Nullable, ObjectMatrix } from '@univerjs/core';
-import { BooleanNumber, CellValueType, Disposable, ICommandService, RefAlias, toDisposable, Tools } from '@univerjs/core';
-import { Inject, Injector } from '@wendellhu/redi';
+import { BooleanNumber, CellValueType, Disposable, ICommandService, Inject, Injector, RefAlias, toDisposable, Tools } from '@univerjs/core';
import type { IRemoveOtherFormulaMutationParams, ISetFormulaCalculationResultMutation, ISetOtherFormulaMutationParams } from '@univerjs/engine-formula';
-import { IActiveDirtyManagerService, RemoveOtherFormulaMutation,
+import {
+ IActiveDirtyManagerService,
+ RemoveOtherFormulaMutation,
SetFormulaCalculationResultMutation,
- SetOtherFormulaMutation } from '@univerjs/engine-formula';
+ SetOtherFormulaMutation,
+} from '@univerjs/engine-formula';
import { Subject } from 'rxjs';
import { bufferTime, filter, map } from 'rxjs/operators';
diff --git a/packages/sheets-conditional-formatting/src/services/conditional-formatting.service.ts b/packages/sheets-conditional-formatting/src/services/conditional-formatting.service.ts
index 7e72012444..068935de99 100644
--- a/packages/sheets-conditional-formatting/src/services/conditional-formatting.service.ts
+++ b/packages/sheets-conditional-formatting/src/services/conditional-formatting.service.ts
@@ -15,10 +15,9 @@
*/
import type { IMutationInfo, IRange, Workbook } from '@univerjs/core';
-import { createInterceptorKey, Disposable, ICommandService, InterceptorManager, IResourceManagerService, IUniverInstanceService, LifecycleStages, ObjectMatrix, OnLifecycle, Rectangle, Tools, UniverInstanceType } from '@univerjs/core';
+import { createInterceptorKey, Disposable, ICommandService, Inject, Injector, InterceptorManager, IResourceManagerService, IUniverInstanceService, LifecycleStages, ObjectMatrix, OnLifecycle, Rectangle, Tools, UniverInstanceType } from '@univerjs/core';
import type { IInsertColMutationParams, IMoveColumnsMutationParams, IMoveRangeMutationParams, IMoveRowsMutationParams, IRemoveRowsMutationParams, IRemoveSheetCommandParams, IReorderRangeMutationParams, ISetRangeValuesMutationParams } from '@univerjs/sheets';
import { InsertColMutation, InsertRowMutation, MoveColsMutation, MoveRangeMutation, MoveRowsMutation, RemoveColMutation, RemoveRowMutation, RemoveSheetCommand, ReorderRangeMutation, SetRangeValuesMutation, SheetInterceptorService } from '@univerjs/sheets';
-import { Inject, Injector } from '@wendellhu/redi';
import { Subject } from 'rxjs';
import { bufferTime, filter, map } from 'rxjs/operators';
import type { IDeleteConditionalRuleMutationParams } from '../commands/mutations/delete-conditional-rule.mutation';
diff --git a/packages/sheets-data-validation/package.json b/packages/sheets-data-validation/package.json
index 9da194e4bf..4d3e675c6c 100644
--- a/packages/sheets-data-validation/package.json
+++ b/packages/sheets-data-validation/package.json
@@ -72,7 +72,6 @@
"@univerjs/sheets-formula": "workspace:*",
"@univerjs/sheets-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": ">=2.0.0",
"dayjs": ">=1.11.0",
"react": "^16.9.0 || ^17.0.0 || ^18.0.0",
@@ -94,7 +93,6 @@
"@univerjs/sheets-formula": "workspace:*",
"@univerjs/sheets-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": "^2.1.1",
"dayjs": "^1.11.11",
"less": "^4.2.0",
diff --git a/packages/sheets-data-validation/src/commands/commands/data-validation.command.ts b/packages/sheets-data-validation/src/commands/commands/data-validation.command.ts
index 1769ed7edf..825871eb94 100644
--- a/packages/sheets-data-validation/src/commands/commands/data-validation.command.ts
+++ b/packages/sheets-data-validation/src/commands/commands/data-validation.command.ts
@@ -15,12 +15,11 @@
*/
import { CommandType, DataValidationType, ICommandService, IUndoRedoService, IUniverInstanceService, ObjectMatrix, Range, sequenceExecute, sequenceExecuteAsync, Tools } from '@univerjs/core';
-import type { CellValue, ICellData, ICommand, IDataValidationRuleBase, IDataValidationRuleOptions, IMutationInfo, IRange, ISheetDataValidationRule, Nullable } from '@univerjs/core';
+import type { CellValue, IAccessor, ICellData, ICommand, IDataValidationRuleBase, IDataValidationRuleOptions, IMutationInfo, IRange, ISheetDataValidationRule, Nullable } from '@univerjs/core';
import type { IAddDataValidationMutationParams, IUpdateDataValidationMutationParams } from '@univerjs/data-validation';
import { AddDataValidationMutation, createDefaultNewRule, DataValidationModel, DataValidatorRegistryService, getRuleOptions, getRuleSetting, RemoveDataValidationMutation, UpdateDataValidationMutation, UpdateRuleType } from '@univerjs/data-validation';
import type { ISetRangeValuesMutationParams, ISheetCommandSharedParams } from '@univerjs/sheets';
import { getSheetCommandTarget, SetRangeValuesMutation, SetRangeValuesUndoMutationFactory } from '@univerjs/sheets';
-import type { IAccessor } from '@wendellhu/redi';
import type { SheetDataValidationManager } from '../../models/sheet-data-validation-manager';
import { OpenValidationPanelOperation } from '../operations/data-validation.operation';
import type { RangeMutation } from '../../models/rule-matrix';
diff --git a/packages/sheets-data-validation/src/controllers/dv-alert.controller.ts b/packages/sheets-data-validation/src/controllers/dv-alert.controller.ts
index 9abead2456..6afee7d312 100644
--- a/packages/sheets-data-validation/src/controllers/dv-alert.controller.ts
+++ b/packages/sheets-data-validation/src/controllers/dv-alert.controller.ts
@@ -15,9 +15,8 @@
*/
import type { Workbook } from '@univerjs/core';
-import { DataValidationStatus, Disposable, IUniverInstanceService, LifecycleStages, LocaleService, OnLifecycle, UniverInstanceType } from '@univerjs/core';
+import { DataValidationStatus, Disposable, Inject, IUniverInstanceService, LifecycleStages, LocaleService, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import { CellAlertManagerService, CellAlertType, HoverManagerService } from '@univerjs/sheets-ui';
-import { Inject } from '@wendellhu/redi';
import type { BaseDataValidator } from '@univerjs/data-validation';
import { debounceTime } from 'rxjs';
diff --git a/packages/sheets-data-validation/src/controllers/dv-auto-fill.controller.ts b/packages/sheets-data-validation/src/controllers/dv-auto-fill.controller.ts
index 305ba35dba..85ba906b59 100644
--- a/packages/sheets-data-validation/src/controllers/dv-auto-fill.controller.ts
+++ b/packages/sheets-data-validation/src/controllers/dv-auto-fill.controller.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { DataValidationType, Disposable, LifecycleStages, OnLifecycle, Range, Rectangle } from '@univerjs/core';
+import { DataValidationType, Disposable, Inject, Injector, LifecycleStages, OnLifecycle, Range, Rectangle } from '@univerjs/core';
import type { IAutoFillLocation, ISheetAutoFillHook } from '@univerjs/sheets-ui';
import { APPLY_TYPE, getAutoFillRepeatRange, IAutoFillService, virtualizeDiscreteRanges } from '@univerjs/sheets-ui';
-import { Inject, Injector } from '@wendellhu/redi';
import { DataValidationModel } from '@univerjs/data-validation';
import { DATA_VALIDATION_PLUGIN_NAME } from '../common/const';
import type { SheetDataValidationManager } from '../models/sheet-data-validation-manager';
diff --git a/packages/sheets-data-validation/src/controllers/dv-copy-paste.controller.ts b/packages/sheets-data-validation/src/controllers/dv-copy-paste.controller.ts
index 3c55e987ed..cd6bfa2914 100644
--- a/packages/sheets-data-validation/src/controllers/dv-copy-paste.controller.ts
+++ b/packages/sheets-data-validation/src/controllers/dv-copy-paste.controller.ts
@@ -15,10 +15,9 @@
*/
import type { IRange, ISheetDataValidationRule, Nullable } from '@univerjs/core';
-import { Disposable, LifecycleStages, ObjectMatrix, OnLifecycle, Rectangle } from '@univerjs/core';
+import { Disposable, Inject, Injector, LifecycleStages, ObjectMatrix, OnLifecycle, Rectangle } from '@univerjs/core';
import type { IDiscreteRange } from '@univerjs/sheets-ui';
import { COPY_TYPE, getRepeatRange, ISheetClipboardService, PREDEFINED_HOOK_NAME, rangeToDiscreteRange, virtualizeDiscreteRanges } from '@univerjs/sheets-ui';
-import { Inject, Injector } from '@wendellhu/redi';
import { DataValidationModel } from '@univerjs/data-validation';
import type { SheetDataValidationManager } from '../models/sheet-data-validation-manager';
import { DATA_VALIDATION_PLUGIN_NAME } from '../common/const';
diff --git a/packages/sheets-data-validation/src/controllers/dv-formula.controller.ts b/packages/sheets-data-validation/src/controllers/dv-formula.controller.ts
index 90051cec1d..a52abee820 100644
--- a/packages/sheets-data-validation/src/controllers/dv-formula.controller.ts
+++ b/packages/sheets-data-validation/src/controllers/dv-formula.controller.ts
@@ -15,11 +15,10 @@
*/
import type { ICellDataForSheetInterceptor, Nullable, Workbook, Worksheet } from '@univerjs/core';
-import { Disposable, IPermissionService, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
+import { Disposable, Inject, IPermissionService, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import { deserializeRangeWithSheet, LexerTreeBuilder } from '@univerjs/engine-formula';
import { type ICellPermission, WorksheetViewPermission } from '@univerjs/sheets';
import { UnitAction } from '@univerjs/protocol';
-import { Inject } from '@wendellhu/redi';
@OnLifecycle(LifecycleStages.Rendered, DataValidationFormulaController)
export class DataValidationFormulaController extends Disposable {
diff --git a/packages/sheets-data-validation/src/controllers/dv-model.controller.ts b/packages/sheets-data-validation/src/controllers/dv-model.controller.ts
index d3bf04191d..651cfa4374 100644
--- a/packages/sheets-data-validation/src/controllers/dv-model.controller.ts
+++ b/packages/sheets-data-validation/src/controllers/dv-model.controller.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { Disposable, IResourceManagerService, IUniverInstanceService, LifecycleStages, OnLifecycle } from '@univerjs/core';
+import { Disposable, Inject, Injector, IResourceManagerService, IUniverInstanceService, LifecycleStages, OnLifecycle } from '@univerjs/core';
import { DataValidationModel } from '@univerjs/data-validation';
-import { Inject, Injector } from '@wendellhu/redi';
import { SheetDataValidationManager } from '../models/sheet-data-validation-manager';
@OnLifecycle(LifecycleStages.Starting, DataValidationModelController)
diff --git a/packages/sheets-data-validation/src/controllers/dv-permission.controller.ts b/packages/sheets-data-validation/src/controllers/dv-permission.controller.ts
index 19fe1c2e37..a460d1aebf 100644
--- a/packages/sheets-data-validation/src/controllers/dv-permission.controller.ts
+++ b/packages/sheets-data-validation/src/controllers/dv-permission.controller.ts
@@ -15,9 +15,8 @@
*/
import type { ICommandInfo } from '@univerjs/core';
-import { Disposable, ICommandService, LifecycleStages, LocaleService, OnLifecycle } from '@univerjs/core';
+import { Disposable, ICommandService, Inject, LifecycleStages, LocaleService, OnLifecycle } from '@univerjs/core';
import { SheetPermissionInterceptorBaseController } from '@univerjs/sheets-ui';
-import { Inject } from '@wendellhu/redi';
import { AddDataValidationCommand } from '@univerjs/data-validation';
import { RangeProtectionPermissionEditPoint, WorkbookEditablePermission, WorksheetEditPermission, WorksheetSetCellStylePermission } from '@univerjs/sheets';
import type { IUpdateSheetDataValidationRangeCommandParams } from '../commands/commands/data-validation.command';
diff --git a/packages/sheets-data-validation/src/controllers/dv-ref-range.controller.ts b/packages/sheets-data-validation/src/controllers/dv-ref-range.controller.ts
index c9fb7c5b2c..98395a2227 100644
--- a/packages/sheets-data-validation/src/controllers/dv-ref-range.controller.ts
+++ b/packages/sheets-data-validation/src/controllers/dv-ref-range.controller.ts
@@ -15,10 +15,9 @@
*/
import type { IRange, ISheetDataValidationRule } from '@univerjs/core';
-import { DataValidationType, Disposable, isRangesEqual, LifecycleStages, OnLifecycle, toDisposable } from '@univerjs/core';
+import { DataValidationType, Disposable, Inject, Injector, isRangesEqual, LifecycleStages, OnLifecycle, toDisposable } from '@univerjs/core';
import type { EffectRefRangeParams } from '@univerjs/sheets';
import { handleCommonDefaultRangeChangeWithEffectRefCommands, RefRangeService } from '@univerjs/sheets';
-import { Inject, Injector } from '@wendellhu/redi';
import type { IRemoveDataValidationMutationParams, IUpdateDataValidationMutationParams } from '@univerjs/data-validation';
import { DataValidationModel, RemoveDataValidationMutation, removeDataValidationUndoFactory, UpdateDataValidationMutation, UpdateRuleType } from '@univerjs/data-validation';
import { FormulaRefRangeService } from '@univerjs/sheets-formula';
diff --git a/packages/sheets-data-validation/src/controllers/dv-reject-input.controller.ts b/packages/sheets-data-validation/src/controllers/dv-reject-input.controller.ts
index bacec8f305..143839f30f 100644
--- a/packages/sheets-data-validation/src/controllers/dv-reject-input.controller.ts
+++ b/packages/sheets-data-validation/src/controllers/dv-reject-input.controller.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { DataValidationErrorStyle, Disposable, LifecycleStages, LocaleService, OnLifecycle } from '@univerjs/core';
+import { DataValidationErrorStyle, Disposable, Inject, LifecycleStages, LocaleService, OnLifecycle } from '@univerjs/core';
import { DataValidationModel, DataValidatorRegistryService } from '@univerjs/data-validation';
import { IEditorBridgeService } from '@univerjs/sheets-ui';
-import { Inject } from '@wendellhu/redi';
import { IDialogService } from '@univerjs/ui';
import React from 'react';
import { Button } from '@univerjs/design';
diff --git a/packages/sheets-data-validation/src/controllers/dv-render.controller.ts b/packages/sheets-data-validation/src/controllers/dv-render.controller.ts
index 6dfa6c7c75..e46fe35514 100644
--- a/packages/sheets-data-validation/src/controllers/dv-render.controller.ts
+++ b/packages/sheets-data-validation/src/controllers/dv-render.controller.ts
@@ -15,11 +15,10 @@
*/
import type { ICellDataForSheetInterceptor, ICellRenderContext, IRange, Workbook } from '@univerjs/core';
-import { DataValidationRenderMode, DataValidationStatus, DataValidationType, ICommandService, IUniverInstanceService, LifecycleStages, OnLifecycle, RxDisposable, sequenceExecute, UniverInstanceType, WrapStrategy } from '@univerjs/core';
+import { DataValidationRenderMode, DataValidationStatus, DataValidationType, ICommandService, Inject, Injector, IUniverInstanceService, LifecycleStages, OnLifecycle, Optional, RxDisposable, sequenceExecute, UniverInstanceType, WrapStrategy } from '@univerjs/core';
import { DataValidationModel, DataValidatorRegistryService } from '@univerjs/data-validation';
import type { MenuConfig } from '@univerjs/ui';
import { ComponentManager, IMenuService } from '@univerjs/ui';
-import { Inject, Injector, Optional } from '@wendellhu/redi';
import { AutoHeightController, IEditorBridgeService, SheetSkeletonManagerService } from '@univerjs/sheets-ui';
import type { Spreadsheet } from '@univerjs/engine-render';
import { IRenderManagerService } from '@univerjs/engine-render';
diff --git a/packages/sheets-data-validation/src/controllers/dv.controller.ts b/packages/sheets-data-validation/src/controllers/dv.controller.ts
index ec906e21a4..834be298b8 100644
--- a/packages/sheets-data-validation/src/controllers/dv.controller.ts
+++ b/packages/sheets-data-validation/src/controllers/dv.controller.ts
@@ -15,9 +15,8 @@
*/
import type { Workbook } from '@univerjs/core';
-import { DisposableCollection, IUniverInstanceService, LifecycleStages, OnLifecycle, RxDisposable, toDisposable, UniverInstanceType } from '@univerjs/core';
+import { DisposableCollection, Inject, Injector, IUniverInstanceService, LifecycleStages, OnLifecycle, RxDisposable, toDisposable, UniverInstanceType } from '@univerjs/core';
import { DataValidationModel, DataValidatorRegistryService } from '@univerjs/data-validation';
-import { Inject, Injector } from '@wendellhu/redi';
import { DataValidationSingle } from '@univerjs/icons';
import { ComponentManager } from '@univerjs/ui';
import { ClearSelectionAllCommand, SheetInterceptorService, SheetsSelectionsService } from '@univerjs/sheets';
diff --git a/packages/sheets-data-validation/src/controllers/dv.menu.ts b/packages/sheets-data-validation/src/controllers/dv.menu.ts
index 1d329e783a..1b63a2357a 100644
--- a/packages/sheets-data-validation/src/controllers/dv.menu.ts
+++ b/packages/sheets-data-validation/src/controllers/dv.menu.ts
@@ -15,7 +15,7 @@
*/
import { getMenuHiddenObservable, type IMenuItem, MenuGroup, MenuItemType, MenuPosition } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor } from '@univerjs/core';
import { UniverInstanceType } from '@univerjs/core';
import { getCurrentRangeDisable$ } from '@univerjs/sheets-ui';
import { RangeProtectionPermissionEditPoint, WorkbookEditablePermission, WorksheetEditPermission, WorksheetSetCellStylePermission } from '@univerjs/sheets';
diff --git a/packages/sheets-data-validation/src/mobile-plugin.ts b/packages/sheets-data-validation/src/mobile-plugin.ts
index d3e1eb73d9..ba6d5776f7 100644
--- a/packages/sheets-data-validation/src/mobile-plugin.ts
+++ b/packages/sheets-data-validation/src/mobile-plugin.ts
@@ -15,7 +15,7 @@
*/
import { DependentOn, ICommandService, LocaleService, Plugin, Tools, UniverInstanceType } from '@univerjs/core';
-import { type Dependency, Inject, Injector } from '@wendellhu/redi';
+import { type Dependency, Inject, Injector } from '@univerjs/core';
import { UniverDataValidationPlugin } from '@univerjs/data-validation';
import { UniverSheetsPlugin } from '@univerjs/sheets';
import { UniverSheetsUIPlugin } from '@univerjs/sheets-ui';
diff --git a/packages/sheets-data-validation/src/models/sheet-data-validation-manager.ts b/packages/sheets-data-validation/src/models/sheet-data-validation-manager.ts
index 405faec747..3c88d34626 100644
--- a/packages/sheets-data-validation/src/models/sheet-data-validation-manager.ts
+++ b/packages/sheets-data-validation/src/models/sheet-data-validation-manager.ts
@@ -14,12 +14,11 @@
* limitations under the License.
*/
-import type { CellValue, ISheetDataValidationRule, Nullable, Workbook } from '@univerjs/core';
+import type { CellValue, Injector, ISheetDataValidationRule, Nullable, Workbook } from '@univerjs/core';
import { DataValidationManager, DataValidatorRegistryService, UpdateRuleType } from '@univerjs/data-validation';
import { DataValidationStatus, DataValidationType, IUniverInstanceService, ObjectMatrix, Range, UniverInstanceType } from '@univerjs/core';
import type { IUpdateRulePayload } from '@univerjs/data-validation';
import type { ISheetLocationBase } from '@univerjs/sheets';
-import type { Injector } from '@wendellhu/redi';
import { isReferenceString } from '@univerjs/engine-formula';
import type { IDataValidationResCache } from '../services/dv-cache.service';
import { DataValidationCacheService } from '../services/dv-cache.service';
diff --git a/packages/sheets-data-validation/src/plugin.ts b/packages/sheets-data-validation/src/plugin.ts
index 195bb2ac09..c1bf69b974 100644
--- a/packages/sheets-data-validation/src/plugin.ts
+++ b/packages/sheets-data-validation/src/plugin.ts
@@ -15,7 +15,7 @@
*/
import { DependentOn, ICommandService, LocaleService, Plugin, Tools, UniverInstanceType } from '@univerjs/core';
-import { type Dependency, Inject, Injector } from '@wendellhu/redi';
+import { type Dependency, Inject, Injector } from '@univerjs/core';
import { UniverDataValidationPlugin } from '@univerjs/data-validation';
import { UniverSheetsPlugin } from '@univerjs/sheets';
import { UniverSheetsUIPlugin } from '@univerjs/sheets-ui';
diff --git a/packages/sheets-data-validation/src/services/data-validation-panel.service.ts b/packages/sheets-data-validation/src/services/data-validation-panel.service.ts
index eaa2629900..3e15f98303 100644
--- a/packages/sheets-data-validation/src/services/data-validation-panel.service.ts
+++ b/packages/sheets-data-validation/src/services/data-validation-panel.service.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { IDataValidationRule, Nullable } from '@univerjs/core';
+import type { IDataValidationRule, IDisposable, Nullable } from '@univerjs/core';
import { Disposable, IUniverInstanceService, toDisposable, UniverInstanceType } from '@univerjs/core';
import { ISidebarService } from '@univerjs/ui';
-import type { IDisposable } from '@wendellhu/redi';
import { BehaviorSubject, distinctUntilChanged, filter } from 'rxjs';
export class DataValidationPanelService extends Disposable {
diff --git a/packages/sheets-data-validation/src/services/dropdown-manager.service.ts b/packages/sheets-data-validation/src/services/dropdown-manager.service.ts
index 6ee1957e1f..10705f4cec 100644
--- a/packages/sheets-data-validation/src/services/dropdown-manager.service.ts
+++ b/packages/sheets-data-validation/src/services/dropdown-manager.service.ts
@@ -14,11 +14,10 @@
* limitations under the License.
*/
-import { Disposable, DisposableCollection, DOCS_FORMULA_BAR_EDITOR_UNIT_ID_KEY, IUniverInstanceService, type Nullable } from '@univerjs/core';
+import type { IDisposable, Nullable } from '@univerjs/core';
+import { Disposable, DisposableCollection, DOCS_FORMULA_BAR_EDITOR_UNIT_ID_KEY, Inject, IUniverInstanceService } from '@univerjs/core';
import type { ISheetLocation } from '@univerjs/sheets';
import { Subject } from 'rxjs';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject } from '@wendellhu/redi';
import { SheetCanvasPopManagerService } from '@univerjs/sheets-ui';
import { DataValidationModel, DataValidatorRegistryService } from '@univerjs/data-validation';
import { IZenZoneService } from '@univerjs/ui';
diff --git a/packages/sheets-data-validation/src/services/dv-custom-formula.service.ts b/packages/sheets-data-validation/src/services/dv-custom-formula.service.ts
index ab39e8a7bc..9f7344a54c 100644
--- a/packages/sheets-data-validation/src/services/dv-custom-formula.service.ts
+++ b/packages/sheets-data-validation/src/services/dv-custom-formula.service.ts
@@ -15,9 +15,8 @@
*/
import type { IRange, ISheetDataValidationRule } from '@univerjs/core';
-import { DataValidationType, Disposable, isFormulaString, ObjectMatrix, Range } from '@univerjs/core';
+import { DataValidationType, Disposable, Inject, isFormulaString, ObjectMatrix, Range } from '@univerjs/core';
import { isFormulaTransformable, LexerTreeBuilder, transformFormula } from '@univerjs/engine-formula';
-import { Inject } from '@wendellhu/redi';
import { DataValidationModel } from '@univerjs/data-validation';
import { RegisterOtherFormulaService } from '@univerjs/sheets-formula';
import { DataValidationCacheService } from './dv-cache.service';
diff --git a/packages/sheets-data-validation/src/services/dv-formula.service.ts b/packages/sheets-data-validation/src/services/dv-formula.service.ts
index b90c3b42e0..191beeec69 100644
--- a/packages/sheets-data-validation/src/services/dv-formula.service.ts
+++ b/packages/sheets-data-validation/src/services/dv-formula.service.ts
@@ -15,8 +15,7 @@
*/
import type { Nullable } from '@univerjs/core';
-import { Disposable, isFormulaString } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { Disposable, Inject, isFormulaString } from '@univerjs/core';
import { DataValidationModel } from '@univerjs/data-validation';
import type { IFormulaInfo, IOtherFormulaResult } from '@univerjs/sheets-formula';
import { RegisterOtherFormulaService } from '@univerjs/sheets-formula';
diff --git a/packages/sheets-data-validation/src/services/dv-validator-service.ts b/packages/sheets-data-validation/src/services/dv-validator-service.ts
index e7016bfc0f..72b5c88384 100644
--- a/packages/sheets-data-validation/src/services/dv-validator-service.ts
+++ b/packages/sheets-data-validation/src/services/dv-validator-service.ts
@@ -15,9 +15,8 @@
*/
import type { Nullable, ObjectMatrix, Workbook } from '@univerjs/core';
-import { DataValidationStatus, IUniverInstanceService, Range, UniverInstanceType } from '@univerjs/core';
+import { DataValidationStatus, Inject, IUniverInstanceService, Range, UniverInstanceType } from '@univerjs/core';
import { DataValidationModel } from '@univerjs/data-validation';
-import { Inject } from '@wendellhu/redi';
import type { SheetDataValidationManager } from '../models/sheet-data-validation-manager';
import { getCellValueOrigin } from '../utils/get-cell-data-origin';
import type { IDataValidationResCache } from './dv-cache.service';
diff --git a/packages/sheets-data-validation/src/services/dv.service.ts b/packages/sheets-data-validation/src/services/dv.service.ts
index ed2969897b..d7a5d846f4 100644
--- a/packages/sheets-data-validation/src/services/dv.service.ts
+++ b/packages/sheets-data-validation/src/services/dv.service.ts
@@ -17,7 +17,7 @@
import { Disposable, type Nullable } from '@univerjs/core';
import { Subject } from 'rxjs';
import { DataValidationModel } from '@univerjs/data-validation';
-import { Inject } from '@wendellhu/redi';
+import { Inject } from '@univerjs/core';
import type { SheetDataValidationManager } from '../models/sheet-data-validation-manager';
export interface ICurrentDataValidationManager {
diff --git a/packages/sheets-data-validation/src/views/date-dropdown/index.tsx b/packages/sheets-data-validation/src/views/date-dropdown/index.tsx
index 0e7e9158c3..4d5cdf21b5 100644
--- a/packages/sheets-data-validation/src/views/date-dropdown/index.tsx
+++ b/packages/sheets-data-validation/src/views/date-dropdown/index.tsx
@@ -16,8 +16,7 @@
import React, { useState } from 'react';
import type { CellValue, Nullable } from '@univerjs/core';
-import { DataValidationErrorStyle, ICommandService } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { DataValidationErrorStyle, ICommandService, useDependency } from '@univerjs/core';
import { Button, DatePanel } from '@univerjs/design';
import { SetRangeValuesCommand } from '@univerjs/sheets';
import dayjs from 'dayjs';
diff --git a/packages/sheets-data-validation/src/views/detail/index.tsx b/packages/sheets-data-validation/src/views/detail/index.tsx
index c23e8438d3..2deffe2a7d 100644
--- a/packages/sheets-data-validation/src/views/detail/index.tsx
+++ b/packages/sheets-data-validation/src/views/detail/index.tsx
@@ -15,11 +15,10 @@
*/
import type { DataValidationOperator, DataValidationType, IDataValidationRuleBase, IDataValidationRuleOptions, IExecutionOptions, ISheetDataValidationRule, IUnitRange } from '@univerjs/core';
-import { createInternalEditorID, debounce, ICommandService, isUnitRangesEqual, isValidRange, LocaleService, RedoCommand, shallowEqual, UndoCommand } from '@univerjs/core';
+import { createInternalEditorID, debounce, ICommandService, isUnitRangesEqual, isValidRange, LocaleService, RedoCommand, shallowEqual, UndoCommand, useDependency } from '@univerjs/core';
import { DataValidationModel, DataValidatorRegistryScope, DataValidatorRegistryService, getRuleOptions, getRuleSetting, RemoveDataValidationCommand, TWO_FORMULA_OPERATOR_COUNT } from '@univerjs/data-validation';
import { Button, FormLayout, Select } from '@univerjs/design';
import { ComponentManager, RangeSelector, useEvent, useObservable } from '@univerjs/ui';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import React, { useEffect, useMemo, useState } from 'react';
import { serializeRange } from '@univerjs/engine-formula';
import type { IUpdateSheetDataValidationRangeCommandParams } from '../../commands/commands/data-validation.command';
diff --git a/packages/sheets-data-validation/src/views/drop-down/CellDropdown.tsx b/packages/sheets-data-validation/src/views/drop-down/CellDropdown.tsx
index 016390bc12..89e28cb0e6 100644
--- a/packages/sheets-data-validation/src/views/drop-down/CellDropdown.tsx
+++ b/packages/sheets-data-validation/src/views/drop-down/CellDropdown.tsx
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { useDependency } from '@univerjs/core';
import { ComponentManager, useObservable } from '@univerjs/ui';
import React from 'react';
import { DataValidationDropdownManagerService } from '../../services/dropdown-manager.service';
diff --git a/packages/sheets-data-validation/src/views/formula-input/base-formula-input.tsx b/packages/sheets-data-validation/src/views/formula-input/base-formula-input.tsx
index eae38f935c..1fe6ea65cb 100644
--- a/packages/sheets-data-validation/src/views/formula-input/base-formula-input.tsx
+++ b/packages/sheets-data-validation/src/views/formula-input/base-formula-input.tsx
@@ -17,8 +17,7 @@
import type { IFormulaInputProps } from '@univerjs/data-validation';
import { FormLayout, Input } from '@univerjs/design';
import React from 'react';
-import { useDependency } from '@wendellhu/redi/react-bindings';
-import { LocaleService } from '@univerjs/core';
+import { LocaleService, useDependency } from '@univerjs/core';
import styles from './index.module.less';
export const BaseFormulaInput = (props: IFormulaInputProps) => {
diff --git a/packages/sheets-data-validation/src/views/formula-input/checkbox-formula-input.tsx b/packages/sheets-data-validation/src/views/formula-input/checkbox-formula-input.tsx
index 9769c1cb60..8c0c37d4be 100644
--- a/packages/sheets-data-validation/src/views/formula-input/checkbox-formula-input.tsx
+++ b/packages/sheets-data-validation/src/views/formula-input/checkbox-formula-input.tsx
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { LocaleService } from '@univerjs/core';
+import { LocaleService, useDependency } from '@univerjs/core';
import type { IFormulaInputProps } from '@univerjs/data-validation';
import { Checkbox, FormLayout, Input } from '@univerjs/design';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import React, { useState } from 'react';
import styles from './index.module.less';
diff --git a/packages/sheets-data-validation/src/views/formula-input/list-formula-input.tsx b/packages/sheets-data-validation/src/views/formula-input/list-formula-input.tsx
index 00fdd04597..06ffc8228c 100644
--- a/packages/sheets-data-validation/src/views/formula-input/list-formula-input.tsx
+++ b/packages/sheets-data-validation/src/views/formula-input/list-formula-input.tsx
@@ -17,8 +17,7 @@
import { TextEditor, useEvent, useObservable } from '@univerjs/ui';
import React, { useEffect, useMemo, useRef, useState } from 'react';
import { DraggableList, FormLayout, Input, Radio, RadioGroup, Select } from '@univerjs/design';
-import { useDependency } from '@wendellhu/redi/react-bindings';
-import { createInternalEditorID, DataValidationType, isFormulaString, LocaleService, Tools } from '@univerjs/core';
+import { createInternalEditorID, DataValidationType, isFormulaString, LocaleService, Tools, useDependency } from '@univerjs/core';
import { DataValidationModel, DataValidatorRegistryService, type IFormulaInputProps } from '@univerjs/data-validation';
import { DeleteSingle, IncreaseSingle, SequenceSingle } from '@univerjs/icons';
import cs from 'clsx';
diff --git a/packages/sheets-data-validation/src/views/item/index.tsx b/packages/sheets-data-validation/src/views/item/index.tsx
index 1e67537608..d1044d8f18 100644
--- a/packages/sheets-data-validation/src/views/item/index.tsx
+++ b/packages/sheets-data-validation/src/views/item/index.tsx
@@ -16,7 +16,7 @@
import { ICommandService, type ISheetDataValidationRule } from '@univerjs/core';
import { DataValidatorRegistryService, RemoveDataValidationCommand } from '@univerjs/data-validation';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { useDependency } from '@univerjs/core';
import React, { useEffect, useRef, useState } from 'react';
import { serializeRange } from '@univerjs/engine-formula';
import { DeleteSingle } from '@univerjs/icons';
diff --git a/packages/sheets-data-validation/src/views/list-dropdown/index.tsx b/packages/sheets-data-validation/src/views/list-dropdown/index.tsx
index 907efe02fd..5348cc9bcd 100644
--- a/packages/sheets-data-validation/src/views/list-dropdown/index.tsx
+++ b/packages/sheets-data-validation/src/views/list-dropdown/index.tsx
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { DataValidationRenderMode, DataValidationType, ICommandService, LocaleService } from '@univerjs/core';
+import { DataValidationRenderMode, DataValidationType, ICommandService, LocaleService, useDependency } from '@univerjs/core';
import type { ISetRangeValuesCommandParams } from '@univerjs/sheets';
import { SetRangeValuesCommand } from '@univerjs/sheets';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import React, { useMemo, useState } from 'react';
import { CheckMarkSingle } from '@univerjs/icons';
import { IEditorBridgeService } from '@univerjs/sheets-ui';
diff --git a/packages/sheets-data-validation/src/views/list/index.tsx b/packages/sheets-data-validation/src/views/list/index.tsx
index a855243f02..dd5121660d 100644
--- a/packages/sheets-data-validation/src/views/list/index.tsx
+++ b/packages/sheets-data-validation/src/views/list/index.tsx
@@ -15,10 +15,8 @@
*/
import React, { useEffect, useState } from 'react';
-import { Injector } from '@wendellhu/redi';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { ICommandService, Injector, IUniverInstanceService, LocaleService, UniverInstanceType, useDependency } from '@univerjs/core';
import type { ICellDataForSheetInterceptor, ISheetDataValidationRule, Workbook } from '@univerjs/core';
-import { ICommandService, IUniverInstanceService, LocaleService, UniverInstanceType } from '@univerjs/core';
import { createDefaultNewRule, DataValidationModel, RemoveAllDataValidationCommand } from '@univerjs/data-validation';
import { Button } from '@univerjs/design';
import { useObservable } from '@univerjs/ui';
diff --git a/packages/sheets-data-validation/src/views/options/index.tsx b/packages/sheets-data-validation/src/views/options/index.tsx
index cddf0c7252..5a6a654ed2 100644
--- a/packages/sheets-data-validation/src/views/options/index.tsx
+++ b/packages/sheets-data-validation/src/views/options/index.tsx
@@ -17,7 +17,7 @@
import { DataValidationErrorStyle, type IDataValidationRuleOptions, LocaleService } from '@univerjs/core';
import { Checkbox, FormLayout, Input, Radio, RadioGroup } from '@univerjs/design';
import React, { useState } from 'react';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { useDependency } from '@univerjs/core';
import { MoreDownSingle, MoreUpSingle } from '@univerjs/icons';
import { ComponentManager } from '@univerjs/ui';
import styles from './index.module.less';
diff --git a/packages/sheets-data-validation/src/views/panel/index.tsx b/packages/sheets-data-validation/src/views/panel/index.tsx
index be36f41b38..fe7ce536ce 100644
--- a/packages/sheets-data-validation/src/views/panel/index.tsx
+++ b/packages/sheets-data-validation/src/views/panel/index.tsx
@@ -15,7 +15,7 @@
*/
import React from 'react';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { useDependency } from '@univerjs/core';
import { useObservable } from '@univerjs/ui';
import { DataValidationDetail } from '../detail';
import { DataValidationList } from '../list';
diff --git a/packages/sheets-data-validation/src/views/render-mode/index.tsx b/packages/sheets-data-validation/src/views/render-mode/index.tsx
index 6bc17a5f23..c4467e1ca9 100644
--- a/packages/sheets-data-validation/src/views/render-mode/index.tsx
+++ b/packages/sheets-data-validation/src/views/render-mode/index.tsx
@@ -15,9 +15,8 @@
*/
import { type IDataValidationRuleOptions, LocaleService } from '@univerjs/core';
-import { DataValidationRenderMode } from '@univerjs/core';
+import { DataValidationRenderMode, useDependency } from '@univerjs/core';
import { FormLayout, Radio, RadioGroup } from '@univerjs/design';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import React from 'react';
export interface IListRenderModeInputProps {
diff --git a/packages/sheets-data-validation/src/views/show-time/index.tsx b/packages/sheets-data-validation/src/views/show-time/index.tsx
index bf83548ddf..f11384e203 100644
--- a/packages/sheets-data-validation/src/views/show-time/index.tsx
+++ b/packages/sheets-data-validation/src/views/show-time/index.tsx
@@ -16,7 +16,7 @@
import { type IDataValidationRuleOptions, LocaleService } from '@univerjs/core';
import { Checkbox, FormLayout } from '@univerjs/design';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { useDependency } from '@univerjs/core';
import React from 'react';
export interface IDateShowTimeOptionProps {
diff --git a/packages/sheets-data-validation/src/widgets/checkbox-widget.ts b/packages/sheets-data-validation/src/widgets/checkbox-widget.ts
index 8727b9e22d..b15faf142f 100644
--- a/packages/sheets-data-validation/src/widgets/checkbox-widget.ts
+++ b/packages/sheets-data-validation/src/widgets/checkbox-widget.ts
@@ -16,12 +16,11 @@
import type { IMouseEvent, IPointerEvent, UniverRenderingContext, UniverRenderingContext2D } from '@univerjs/engine-render';
import { Checkbox, fixLineWidthByScale, Transform } from '@univerjs/engine-render';
-import { HorizontalAlign, ICommandService, isFormulaString, ThemeService, VerticalAlign } from '@univerjs/core';
+import { HorizontalAlign, ICommandService, Inject, isFormulaString, ThemeService, VerticalAlign } from '@univerjs/core';
import type { ICellRenderContext, IDataValidationRule, IStyleData, Nullable } from '@univerjs/core';
import type { ISetRangeValuesCommandParams } from '@univerjs/sheets';
import { SetRangeValuesCommand } from '@univerjs/sheets';
import type { BaseDataValidator, IBaseDataValidationWidget, IFormulaResult } from '@univerjs/data-validation';
-import { Inject } from '@wendellhu/redi';
import type { CheckboxValidator } from '../validators/checkbox-validator';
import { CHECKBOX_FORMULA_1, CHECKBOX_FORMULA_2 } from '../validators/checkbox-validator';
import { DataValidationFormulaService } from '../services/dv-formula.service';
diff --git a/packages/sheets-data-validation/src/widgets/dropdown-widget.ts b/packages/sheets-data-validation/src/widgets/dropdown-widget.ts
index a5ff899d99..b1158241c5 100644
--- a/packages/sheets-data-validation/src/widgets/dropdown-widget.ts
+++ b/packages/sheets-data-validation/src/widgets/dropdown-widget.ts
@@ -14,11 +14,10 @@
* limitations under the License.
*/
-import { BooleanNumber, DataValidationRenderMode, DEFAULT_EMPTY_DOCUMENT_VALUE, DocumentDataModel, HorizontalAlign, ICommandService, LocaleService, Tools, VerticalAlign, WrapStrategy } from '@univerjs/core';
+import { BooleanNumber, DataValidationRenderMode, DEFAULT_EMPTY_DOCUMENT_VALUE, DocumentDataModel, HorizontalAlign, ICommandService, Inject, LocaleService, Tools, VerticalAlign, WrapStrategy } from '@univerjs/core';
import type { ICellRenderContext, IDocumentData, IPaddingData, IStyleData, Nullable } from '@univerjs/core';
import { Documents, DocumentSkeleton, DocumentViewModel, getDocsSkeletonPageSize, Rect } from '@univerjs/engine-render';
import type { IMouseEvent, IPointerEvent, ISheetFontRenderExtension, SpreadsheetSkeleton, UniverRenderingContext, UniverRenderingContext2D } from '@univerjs/engine-render';
-import { Inject } from '@wendellhu/redi';
import type { IBaseDataValidationWidget } from '@univerjs/data-validation';
import { getCellValueOrigin } from '../utils/get-cell-data-origin';
import { type IShowDataValidationDropdownParams, ShowDataValidationDropdown } from '../commands/operations/data-validation.operation';
diff --git a/packages/sheets-drawing-ui/package.json b/packages/sheets-drawing-ui/package.json
index 9ed444da53..de8720e7bd 100644
--- a/packages/sheets-drawing-ui/package.json
+++ b/packages/sheets-drawing-ui/package.json
@@ -72,7 +72,6 @@
"@univerjs/sheets-drawing": "workspace:*",
"@univerjs/sheets-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": ">=2.0.0",
"react": "^16.9.0 || ^17.0.0 || ^18.0.0",
"rxjs": ">=7.0.0"
@@ -91,7 +90,6 @@
"@univerjs/sheets-drawing": "workspace:*",
"@univerjs/sheets-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": "^2.1.1",
"less": "^4.2.0",
"react": "18.3.1",
diff --git a/packages/sheets-drawing-ui/src/commands/commands/delete-drawings.command.ts b/packages/sheets-drawing-ui/src/commands/commands/delete-drawings.command.ts
index 87cea14c81..2f15ae87cf 100644
--- a/packages/sheets-drawing-ui/src/commands/commands/delete-drawings.command.ts
+++ b/packages/sheets-drawing-ui/src/commands/commands/delete-drawings.command.ts
@@ -14,10 +14,10 @@
* limitations under the License.
*/
-import { CommandType, type ICommand, ICommandService } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
+import { CommandType, ICommandService } from '@univerjs/core';
import type { ISheetDrawing } from '@univerjs/sheets-drawing';
import { ISheetDrawingService } from '@univerjs/sheets-drawing';
-import type { IAccessor } from '@wendellhu/redi';
import { RemoveSheetDrawingCommand } from './remove-sheet-drawing.command';
import type { IDeleteDrawingCommandParams } from './interfaces';
diff --git a/packages/sheets-drawing-ui/src/commands/commands/group-sheet-drawing.command.ts b/packages/sheets-drawing-ui/src/commands/commands/group-sheet-drawing.command.ts
index 7f5eb486e4..208cb05616 100644
--- a/packages/sheets-drawing-ui/src/commands/commands/group-sheet-drawing.command.ts
+++ b/packages/sheets-drawing-ui/src/commands/commands/group-sheet-drawing.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import {
CommandType,
ICommandService,
@@ -22,7 +22,6 @@ import {
} from '@univerjs/core';
import { DrawingApplyType, ISheetDrawingService, SetDrawingApplyMutation } from '@univerjs/sheets-drawing';
-import type { IAccessor } from '@wendellhu/redi';
import type { IDrawingGroupUpdateParam, IDrawingJsonUndo1 } from '@univerjs/drawing';
import { ClearSheetDrawingTransformerOperation } from '../operations/clear-drawing-transformer.operation';
import { groupToUngroup } from './utils';
diff --git a/packages/sheets-drawing-ui/src/commands/commands/insert-sheet-drawing.command.ts b/packages/sheets-drawing-ui/src/commands/commands/insert-sheet-drawing.command.ts
index eecce8aa2d..6ca8353b2e 100644
--- a/packages/sheets-drawing-ui/src/commands/commands/insert-sheet-drawing.command.ts
+++ b/packages/sheets-drawing-ui/src/commands/commands/insert-sheet-drawing.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import {
CommandType,
ICommandService,
@@ -22,7 +22,6 @@ import {
} from '@univerjs/core';
import { DrawingApplyType, ISheetDrawingService, SetDrawingApplyMutation } from '@univerjs/sheets-drawing';
-import type { IAccessor } from '@wendellhu/redi';
import type { IDrawingJsonUndo1 } from '@univerjs/drawing';
import { ClearSheetDrawingTransformerOperation } from '../operations/clear-drawing-transformer.operation';
import type { IInsertDrawingCommandParams } from './interfaces';
diff --git a/packages/sheets-drawing-ui/src/commands/commands/move-drawings.command.ts b/packages/sheets-drawing-ui/src/commands/commands/move-drawings.command.ts
index b087be6487..d95609f220 100644
--- a/packages/sheets-drawing-ui/src/commands/commands/move-drawings.command.ts
+++ b/packages/sheets-drawing-ui/src/commands/commands/move-drawings.command.ts
@@ -14,11 +14,10 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType, Direction, ICommandService } from '@univerjs/core';
import type { ISheetDrawing } from '@univerjs/sheets-drawing';
import { ISheetDrawingService } from '@univerjs/sheets-drawing';
-import type { IAccessor } from '@wendellhu/redi';
import { ISheetSelectionRenderService } from '@univerjs/sheets-ui';
import { transformToDrawingPosition } from '../../basics/transform-position';
diff --git a/packages/sheets-drawing-ui/src/commands/commands/remove-sheet-drawing.command.ts b/packages/sheets-drawing-ui/src/commands/commands/remove-sheet-drawing.command.ts
index 57d0bd84e1..b0c0745600 100644
--- a/packages/sheets-drawing-ui/src/commands/commands/remove-sheet-drawing.command.ts
+++ b/packages/sheets-drawing-ui/src/commands/commands/remove-sheet-drawing.command.ts
@@ -14,14 +14,13 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import {
CommandType,
ICommandService,
IUndoRedoService,
} from '@univerjs/core';
import { DrawingApplyType, ISheetDrawingService, SetDrawingApplyMutation } from '@univerjs/sheets-drawing';
-import type { IAccessor } from '@wendellhu/redi';
import type { IDrawingJsonUndo1 } from '@univerjs/drawing';
import { ClearSheetDrawingTransformerOperation } from '../operations/clear-drawing-transformer.operation';
import type { IDeleteDrawingCommandParams } from './interfaces';
diff --git a/packages/sheets-drawing-ui/src/commands/commands/set-drawing-arrange.command.ts b/packages/sheets-drawing-ui/src/commands/commands/set-drawing-arrange.command.ts
index e607364b4e..b31b733bbe 100644
--- a/packages/sheets-drawing-ui/src/commands/commands/set-drawing-arrange.command.ts
+++ b/packages/sheets-drawing-ui/src/commands/commands/set-drawing-arrange.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICommand, Nullable } from '@univerjs/core';
+import type { IAccessor, ICommand, Nullable } from '@univerjs/core';
import {
CommandType,
ICommandService,
@@ -23,7 +23,6 @@ import {
import type { IDrawingJsonUndo1, IDrawingOrderMapParam } from '@univerjs/drawing';
import { ArrangeTypeEnum } from '@univerjs/drawing';
import { DrawingApplyType, ISheetDrawingService, SetDrawingApplyMutation } from '@univerjs/sheets-drawing';
-import type { IAccessor } from '@wendellhu/redi';
export interface ISetDrawingArrangeCommandParams extends IDrawingOrderMapParam {
arrangeType: ArrangeTypeEnum;
diff --git a/packages/sheets-drawing-ui/src/commands/commands/set-sheet-drawing.command.ts b/packages/sheets-drawing-ui/src/commands/commands/set-sheet-drawing.command.ts
index b2bc5444a4..a7b0c13a75 100644
--- a/packages/sheets-drawing-ui/src/commands/commands/set-sheet-drawing.command.ts
+++ b/packages/sheets-drawing-ui/src/commands/commands/set-sheet-drawing.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import {
CommandType,
ICommandService,
@@ -23,7 +23,6 @@ import {
import type { ISheetDrawing } from '@univerjs/sheets-drawing';
import { DrawingApplyType, ISheetDrawingService, SetDrawingApplyMutation } from '@univerjs/sheets-drawing';
-import type { IAccessor } from '@wendellhu/redi';
import type { IDrawingJsonUndo1 } from '@univerjs/drawing';
import { ClearSheetDrawingTransformerOperation } from '../operations/clear-drawing-transformer.operation';
import type { ISetDrawingCommandParams } from './interfaces';
diff --git a/packages/sheets-drawing-ui/src/commands/commands/ungroup-sheet-drawing.command.ts b/packages/sheets-drawing-ui/src/commands/commands/ungroup-sheet-drawing.command.ts
index 1f92d41e1e..3d17a3c43c 100644
--- a/packages/sheets-drawing-ui/src/commands/commands/ungroup-sheet-drawing.command.ts
+++ b/packages/sheets-drawing-ui/src/commands/commands/ungroup-sheet-drawing.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import {
CommandType,
ICommandService,
@@ -22,7 +22,6 @@ import {
} from '@univerjs/core';
import { DrawingApplyType, ISheetDrawingService, SetDrawingApplyMutation } from '@univerjs/sheets-drawing';
-import type { IAccessor } from '@wendellhu/redi';
import type { IDrawingGroupUpdateParam, IDrawingJsonUndo1 } from '@univerjs/drawing';
import { ClearSheetDrawingTransformerOperation } from '../operations/clear-drawing-transformer.operation';
import { ungroupToGroup } from './utils';
diff --git a/packages/sheets-drawing-ui/src/commands/operations/edit-sheet-drawing.operation.ts b/packages/sheets-drawing-ui/src/commands/operations/edit-sheet-drawing.operation.ts
index 44a08157e6..cddbad66c7 100644
--- a/packages/sheets-drawing-ui/src/commands/operations/edit-sheet-drawing.operation.ts
+++ b/packages/sheets-drawing-ui/src/commands/operations/edit-sheet-drawing.operation.ts
@@ -14,12 +14,11 @@
* limitations under the License.
*/
-import type { IOperation } from '@univerjs/core';
+import type { IAccessor, IOperation } from '@univerjs/core';
import {
CommandType,
ICommandService,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { IDrawingSearch } from '@univerjs/drawing';
import { IDrawingManagerService } from '@univerjs/drawing';
import { SidebarSheetDrawingOperation } from './open-drawing-panel.operation';
diff --git a/packages/sheets-drawing-ui/src/commands/operations/open-drawing-panel.operation.ts b/packages/sheets-drawing-ui/src/commands/operations/open-drawing-panel.operation.ts
index 9ccd62f365..3b3effda0c 100644
--- a/packages/sheets-drawing-ui/src/commands/operations/open-drawing-panel.operation.ts
+++ b/packages/sheets-drawing-ui/src/commands/operations/open-drawing-panel.operation.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType, IUniverInstanceService, LocaleService } from '@univerjs/core';
import { ISidebarService } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
import { getSheetCommandTarget } from '@univerjs/sheets';
import { IDrawingManagerService } from '@univerjs/drawing';
import { COMPONENT_SHEET_DRAWING_PANEL } from '../../views/sheet-image-panel/component-name';
diff --git a/packages/sheets-drawing-ui/src/controllers/drawing-popup-menu.controller.ts b/packages/sheets-drawing-ui/src/controllers/drawing-popup-menu.controller.ts
index 6d912fac09..d7c9edac81 100644
--- a/packages/sheets-drawing-ui/src/controllers/drawing-popup-menu.controller.ts
+++ b/packages/sheets-drawing-ui/src/controllers/drawing-popup-menu.controller.ts
@@ -14,10 +14,8 @@
* limitations under the License.
*/
-import type { Nullable, Workbook } from '@univerjs/core';
-import { FOCUSING_COMMON_DRAWINGS, IContextService, IUniverInstanceService, LifecycleStages, OnLifecycle, RxDisposable, toDisposable, UniverInstanceType } from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import type { IDisposable, Nullable, Workbook } from '@univerjs/core';
+import { connectInjector, FOCUSING_COMMON_DRAWINGS, IContextService, Inject, Injector, IUniverInstanceService, LifecycleStages, OnLifecycle, RxDisposable, toDisposable, UniverInstanceType } from '@univerjs/core';
import type { BaseObject, Scene } from '@univerjs/engine-render';
import { IRenderManagerService } from '@univerjs/engine-render';
import { COMPONENT_IMAGE_POPUP_MENU, ImageCropperObject, ImageResetSizeOperation, OpenImageCropOperation } from '@univerjs/drawing-ui';
@@ -25,7 +23,6 @@ import { SheetCanvasPopManagerService } from '@univerjs/sheets-ui';
import { takeUntil } from 'rxjs';
import { IDrawingManagerService } from '@univerjs/drawing';
import { BuiltInUIPart, IUIPartsService } from '@univerjs/ui';
-import { connectInjector } from '@wendellhu/redi/react-bindings';
import { RemoveSheetDrawingCommand } from '../commands/commands/remove-sheet-drawing.command';
import { EditSheetDrawingOperation } from '../commands/operations/edit-sheet-drawing.operation';
diff --git a/packages/sheets-drawing-ui/src/controllers/sheet-drawing-permission.controller.ts b/packages/sheets-drawing-ui/src/controllers/sheet-drawing-permission.controller.ts
index 5735bea238..66b08b6fe3 100644
--- a/packages/sheets-drawing-ui/src/controllers/sheet-drawing-permission.controller.ts
+++ b/packages/sheets-drawing-ui/src/controllers/sheet-drawing-permission.controller.ts
@@ -15,11 +15,10 @@
*/
import type { Workbook } from '@univerjs/core';
-import { Disposable, IPermissionService, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType, UserManagerService } from '@univerjs/core';
+import { Disposable, Inject, IPermissionService, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType, UserManagerService } from '@univerjs/core';
import { IDrawingManagerService } from '@univerjs/drawing';
import { IRenderManagerService, RENDER_CLASS_TYPE } from '@univerjs/engine-render';
import { WorkbookEditablePermission, WorkbookViewPermission, WorksheetEditPermission, WorksheetViewPermission } from '@univerjs/sheets';
-import { Inject } from '@wendellhu/redi';
import { combineLatest, distinctUntilChanged, filter, map } from 'rxjs';
@OnLifecycle(LifecycleStages.Rendered, SheetDrawingPermissionController)
diff --git a/packages/sheets-drawing-ui/src/controllers/sheet-drawing-printing.controller.ts b/packages/sheets-drawing-ui/src/controllers/sheet-drawing-printing.controller.ts
index a3f4116743..be95e9f832 100644
--- a/packages/sheets-drawing-ui/src/controllers/sheet-drawing-printing.controller.ts
+++ b/packages/sheets-drawing-ui/src/controllers/sheet-drawing-printing.controller.ts
@@ -15,12 +15,11 @@
*/
import type { IRange } from '@univerjs/core';
-import { Disposable, LifecycleStages, OnLifecycle, Tools } from '@univerjs/core';
+import { Disposable, Inject, LifecycleStages, OnLifecycle, Tools } from '@univerjs/core';
import { DrawingTypeEnum, IDrawingManagerService } from '@univerjs/drawing';
import { DrawingRenderService } from '@univerjs/drawing-ui';
import { IRenderManagerService } from '@univerjs/engine-render';
import { SheetPrintInterceptorService, SheetSkeletonManagerService } from '@univerjs/sheets-ui';
-import { Inject } from '@wendellhu/redi';
@OnLifecycle(LifecycleStages.Rendered, SheetDrawingPrintingController)
export class SheetDrawingPrintingController extends Disposable {
diff --git a/packages/sheets-drawing-ui/src/controllers/sheet-drawing-transform-affected.controller.ts b/packages/sheets-drawing-ui/src/controllers/sheet-drawing-transform-affected.controller.ts
index 574fa0ab61..6e48b99635 100644
--- a/packages/sheets-drawing-ui/src/controllers/sheet-drawing-transform-affected.controller.ts
+++ b/packages/sheets-drawing-ui/src/controllers/sheet-drawing-transform-affected.controller.ts
@@ -15,8 +15,7 @@
*/
import type { ICommandInfo, IMutationInfo, IRange, Nullable } from '@univerjs/core';
-import { Disposable, ICommandService, IUniverInstanceService, LifecycleStages, OnLifecycle, Rectangle, UniverInstanceType } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { Disposable, ICommandService, Inject, IUniverInstanceService, LifecycleStages, OnLifecycle, Rectangle, UniverInstanceType } from '@univerjs/core';
import { ISheetSelectionRenderService, SheetSkeletonManagerService } from '@univerjs/sheets-ui';
import { type IDrawingJsonUndo1, IDrawingManagerService, type IDrawingParam, type ITransformState } from '@univerjs/drawing';
import type { IInsertColCommandParams, IInsertRowCommandParams, IRemoveRowColCommandParams, ISetColHiddenMutationParams, ISetColVisibleMutationParams, ISetRowHiddenMutationParams, ISetRowVisibleMutationParams, ISetSpecificColsVisibleCommandParams, ISetSpecificRowsVisibleCommandParams, ISetWorksheetActiveOperationParams, ISetWorksheetColWidthMutationParams, ISetWorksheetRowHeightMutationParams, ISetWorksheetRowIsAutoHeightMutationParams } from '@univerjs/sheets';
diff --git a/packages/sheets-drawing-ui/src/controllers/sheet-drawing-update.controller.ts b/packages/sheets-drawing-ui/src/controllers/sheet-drawing-update.controller.ts
index 933ebeb54a..c78d490800 100644
--- a/packages/sheets-drawing-ui/src/controllers/sheet-drawing-update.controller.ts
+++ b/packages/sheets-drawing-ui/src/controllers/sheet-drawing-update.controller.ts
@@ -15,8 +15,7 @@
*/
import type { ICommandInfo, IDrawingSearch, IRange, Nullable, Workbook } from '@univerjs/core';
-import { Disposable, FOCUSING_COMMON_DRAWINGS, ICommandService, IContextService, IUniverInstanceService, LifecycleStages, LocaleService, OnLifecycle, UniverInstanceType } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { Disposable, FOCUSING_COMMON_DRAWINGS, ICommandService, IContextService, Inject, IUniverInstanceService, LifecycleStages, LocaleService, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import type { IImageData, IImageIoServiceParam } from '@univerjs/drawing';
import { DRAWING_IMAGE_ALLOW_SIZE, DRAWING_IMAGE_COUNT_LIMIT, DRAWING_IMAGE_HEIGHT_LIMIT, DRAWING_IMAGE_WIDTH_LIMIT, DrawingTypeEnum, getImageSize, IDrawingManagerService, IImageIoService, ImageUploadStatusType } from '@univerjs/drawing';
import type { ISheetDrawing, ISheetDrawingPosition } from '@univerjs/sheets-drawing';
diff --git a/packages/sheets-drawing-ui/src/controllers/sheet-drawing.controller.ts b/packages/sheets-drawing-ui/src/controllers/sheet-drawing.controller.ts
index ec50d0a2e6..7f36e63301 100644
--- a/packages/sheets-drawing-ui/src/controllers/sheet-drawing.controller.ts
+++ b/packages/sheets-drawing-ui/src/controllers/sheet-drawing.controller.ts
@@ -15,10 +15,9 @@
*/
import type { DependencyOverride } from '@univerjs/core';
-import { Disposable, ICommandService, LifecycleStages, OnLifecycle } from '@univerjs/core';
+import { Disposable, ICommandService, Inject, Injector, LifecycleStages, OnLifecycle } from '@univerjs/core';
import type { MenuConfig } from '@univerjs/ui';
import { ComponentManager, IMenuService, IShortcutService } from '@univerjs/ui';
-import { Inject, Injector } from '@wendellhu/redi';
import { AddImageSingle } from '@univerjs/icons';
import { UploadFileMenu } from '../views/upload-component/UploadFile';
diff --git a/packages/sheets-drawing-ui/src/plugin.ts b/packages/sheets-drawing-ui/src/plugin.ts
index e684e0794f..7f17b6b6dd 100644
--- a/packages/sheets-drawing-ui/src/plugin.ts
+++ b/packages/sheets-drawing-ui/src/plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { DependentOn, LocaleService, Plugin, Tools, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { DependentOn, Inject, Injector, LocaleService, Plugin, Tools, UniverInstanceType } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
import { UniverDrawingUIPlugin } from '@univerjs/drawing-ui';
import { UniverSheetsDrawingPlugin } from '@univerjs/sheets-drawing';
import { UniverDrawingPlugin } from '@univerjs/drawing';
diff --git a/packages/sheets-drawing-ui/src/services/canvas-float-dom-manager.service.ts b/packages/sheets-drawing-ui/src/services/canvas-float-dom-manager.service.ts
index 16df0fbea7..a60d8e6cac 100644
--- a/packages/sheets-drawing-ui/src/services/canvas-float-dom-manager.service.ts
+++ b/packages/sheets-drawing-ui/src/services/canvas-float-dom-manager.service.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-import type { IPosition, ITransformState, Nullable, Worksheet } from '@univerjs/core';
-import { Disposable, DisposableCollection, DrawingTypeEnum, ICommandService, IUniverInstanceService, Tools } from '@univerjs/core';
+import type { IDisposable, IPosition, ITransformState, Nullable, Worksheet } from '@univerjs/core';
+import { Disposable, DisposableCollection, DrawingTypeEnum, ICommandService, Inject, IUniverInstanceService, Tools } from '@univerjs/core';
import type { IDrawingJsonUndo1 } from '@univerjs/drawing';
import { getDrawingShapeKeyByDrawingSearch, IDrawingManagerService } from '@univerjs/drawing';
import type { BaseObject, IBoundRectNoAngle, IRectProps, IRender, Scene, SpreadsheetSkeleton } from '@univerjs/engine-render';
@@ -27,8 +27,6 @@ import { DrawingApplyType, ISheetDrawingService, SetDrawingApplyMutation } from
import { ISheetSelectionRenderService, SetScrollOperation, SetZoomRatioOperation, SheetSkeletonManagerService } from '@univerjs/sheets-ui';
import type { IFloatDomLayout } from '@univerjs/ui';
import { CanvasFloatDomService } from '@univerjs/ui';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject } from '@wendellhu/redi';
import { BehaviorSubject, Subject } from 'rxjs';
import { InsertSheetDrawingCommand } from '../commands/commands/insert-sheet-drawing.command';
import type { IInsertDrawingCommandParams } from '../commands/commands/interfaces';
diff --git a/packages/sheets-drawing-ui/src/views/menu/image.menu.ts b/packages/sheets-drawing-ui/src/views/menu/image.menu.ts
index 49ceae5c0f..74b3f535a8 100644
--- a/packages/sheets-drawing-ui/src/views/menu/image.menu.ts
+++ b/packages/sheets-drawing-ui/src/views/menu/image.menu.ts
@@ -15,7 +15,7 @@
*/
import { getMenuHiddenObservable, type IMenuItem, MenuGroup, MenuItemType, MenuPosition } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor } from '@univerjs/core';
import { UniverInstanceType } from '@univerjs/core';
import { getCurrentRangeDisable$ } from '@univerjs/sheets-ui';
import { RangeProtectionPermissionEditPoint, WorkbookEditablePermission, WorksheetEditPermission } from '@univerjs/sheets';
diff --git a/packages/sheets-drawing-ui/src/views/sheet-image-panel/SheetDrawingAnchor.tsx b/packages/sheets-drawing-ui/src/views/sheet-image-panel/SheetDrawingAnchor.tsx
index 0bdba4a767..cd43f31fef 100644
--- a/packages/sheets-drawing-ui/src/views/sheet-image-panel/SheetDrawingAnchor.tsx
+++ b/packages/sheets-drawing-ui/src/views/sheet-image-panel/SheetDrawingAnchor.tsx
@@ -15,8 +15,7 @@
*/
import type { Nullable } from '@univerjs/core';
-import { ICommandService, LocaleService } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { ICommandService, LocaleService, useDependency } from '@univerjs/core';
import React, { useEffect, useState } from 'react';
import { Radio, RadioGroup } from '@univerjs/design';
import clsx from 'clsx';
diff --git a/packages/sheets-drawing-ui/src/views/sheet-image-panel/SheetDrawingPanel.tsx b/packages/sheets-drawing-ui/src/views/sheet-image-panel/SheetDrawingPanel.tsx
index b5ccce2822..3840a2a2e1 100644
--- a/packages/sheets-drawing-ui/src/views/sheet-image-panel/SheetDrawingPanel.tsx
+++ b/packages/sheets-drawing-ui/src/views/sheet-image-panel/SheetDrawingPanel.tsx
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { useDependency } from '@univerjs/core';
import React, { useEffect, useState } from 'react';
import { DrawingCommonPanel } from '@univerjs/drawing-ui';
import type { IDrawingParam } from '@univerjs/drawing';
diff --git a/packages/sheets-drawing-ui/src/views/upload-component/UploadFile.tsx b/packages/sheets-drawing-ui/src/views/upload-component/UploadFile.tsx
index 9e2df793f0..0fed121341 100644
--- a/packages/sheets-drawing-ui/src/views/upload-component/UploadFile.tsx
+++ b/packages/sheets-drawing-ui/src/views/upload-component/UploadFile.tsx
@@ -15,8 +15,7 @@
*/
import type { Nullable } from '@univerjs/core';
-import { ICommandService } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { ICommandService, useDependency } from '@univerjs/core';
import React, { useRef } from 'react';
import type { ICustomComponentProps } from '@univerjs/ui';
import { DRAWING_IMAGE_ALLOW_IMAGE_LIST } from '@univerjs/drawing';
diff --git a/packages/sheets-drawing-ui/src/views/upload-loading/UploadLoading.tsx b/packages/sheets-drawing-ui/src/views/upload-loading/UploadLoading.tsx
index b284bfadc7..82e8bcef98 100644
--- a/packages/sheets-drawing-ui/src/views/upload-loading/UploadLoading.tsx
+++ b/packages/sheets-drawing-ui/src/views/upload-loading/UploadLoading.tsx
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { LocaleService } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { LocaleService, useDependency } from '@univerjs/core';
import React, { useEffect } from 'react';
import { IImageIoService } from '@univerjs/drawing';
diff --git a/packages/sheets-drawing/package.json b/packages/sheets-drawing/package.json
index 5420e8922a..1b30b1d184 100644
--- a/packages/sheets-drawing/package.json
+++ b/packages/sheets-drawing/package.json
@@ -60,7 +60,6 @@
"peerDependencies": {
"@univerjs/core": "workspace:*",
"@univerjs/drawing": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": ">=7.0.0"
},
"devDependencies": {
@@ -68,7 +67,6 @@
"@univerjs/drawing": "workspace:*",
"@univerjs/shared": "workspace:*",
"@univerjs/sheets": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"typescript": "^5.5.3",
"vite": "^5.3.4",
"vitest": "^2.0.3"
diff --git a/packages/sheets-drawing/src/controllers/sheet-drawing.controller.ts b/packages/sheets-drawing/src/controllers/sheet-drawing.controller.ts
index d203453c7f..0aeb174373 100644
--- a/packages/sheets-drawing/src/controllers/sheet-drawing.controller.ts
+++ b/packages/sheets-drawing/src/controllers/sheet-drawing.controller.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { Disposable, ICommandService, IResourceManagerService, IUniverInstanceService, LifecycleService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
+import { Disposable, ICommandService, Inject, IResourceManagerService, IUniverInstanceService, LifecycleService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import type { IDrawingSubunitMap } from '@univerjs/drawing';
import { IDrawingManagerService } from '@univerjs/drawing';
-import { Inject } from '@wendellhu/redi';
import { filter, first } from 'rxjs/operators';
import type { ISheetDrawing } from '../services/sheet-drawing.service';
import { ISheetDrawingService } from '../services/sheet-drawing.service';
diff --git a/packages/sheets-drawing/src/plugin.ts b/packages/sheets-drawing/src/plugin.ts
index a5ab69c5b7..29384a7f85 100644
--- a/packages/sheets-drawing/src/plugin.ts
+++ b/packages/sheets-drawing/src/plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { Plugin, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { Inject, Injector, Plugin, UniverInstanceType } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
import { SHEET_DRAWING_PLUGIN, SheetsDrawingController, SheetsDrawingLoadController } from './controllers/sheet-drawing.controller';
import { ISheetDrawingService, SheetDrawingService } from './services/sheet-drawing.service';
diff --git a/packages/sheets-drawing/src/services/sheet-drawing.service.ts b/packages/sheets-drawing/src/services/sheet-drawing.service.ts
index ae6d5bc1ac..b37c0b9bea 100644
--- a/packages/sheets-drawing/src/services/sheet-drawing.service.ts
+++ b/packages/sheets-drawing/src/services/sheet-drawing.service.ts
@@ -15,7 +15,7 @@
*/
import { type IDrawingParam, type IImageData, type IRotationSkewFlipTransform, type IUnitDrawingService, UnitDrawingService } from '@univerjs/drawing';
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier } from '@univerjs/core';
interface ICellPosition {
column: number; // column number
diff --git a/packages/sheets-filter-ui/package.json b/packages/sheets-filter-ui/package.json
index eea7d8dcc0..120d9a255d 100644
--- a/packages/sheets-filter-ui/package.json
+++ b/packages/sheets-filter-ui/package.json
@@ -70,7 +70,6 @@
"@univerjs/sheets-filter": "workspace:*",
"@univerjs/sheets-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"react": "^16.9.0 || ^17.0.0 || ^18.0.0",
"react-dom": "^16.9.0 || ^17.0.0 || ^18.0.0",
"rxjs": ">=7.0.0"
@@ -89,7 +88,6 @@
"@univerjs/sheets-filter": "workspace:*",
"@univerjs/sheets-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": "^2.1.1",
"less": "^4.2.0",
"react": "18.3.1",
diff --git a/packages/sheets-filter-ui/src/commands/commands/__tests__/sheets-filter.command.spec.ts b/packages/sheets-filter-ui/src/commands/commands/__tests__/sheets-filter.command.spec.ts
index d9a06ca872..d8def4e409 100644
--- a/packages/sheets-filter-ui/src/commands/commands/__tests__/sheets-filter.command.spec.ts
+++ b/packages/sheets-filter-ui/src/commands/commands/__tests__/sheets-filter.command.spec.ts
@@ -14,14 +14,12 @@
* limitations under the License.
*/
-import type { IRange, IWorkbookData } from '@univerjs/core';
-import { AuthzIoLocalService, IAuthzIoService, ICommandService, IUniverInstanceService, LocaleType, Plugin, RANGE_TYPE, RedoCommand, UndoCommand, Univer, UniverInstanceType } from '@univerjs/core';
+import type { Dependency, IRange, IWorkbookData } from '@univerjs/core';
+import { AuthzIoLocalService, IAuthzIoService, ICommandService, Inject, Injector, IUniverInstanceService, LocaleType, Plugin, RANGE_TYPE, RedoCommand, UndoCommand, Univer, UniverInstanceType } from '@univerjs/core';
import type { ISetRangeValuesCommandParams } from '@univerjs/sheets';
import { RangeProtectionRuleModel, RefRangeService, SetRangeValuesCommand, SetRangeValuesMutation, SheetInterceptorService, SheetsSelectionsService, WorkbookPermissionService, WorksheetPermissionService, WorksheetProtectionPointModel, WorksheetProtectionRuleModel } from '@univerjs/sheets';
import type { FilterModel, ISetSheetsFilterRangeMutationParams } from '@univerjs/sheets-filter';
import { SetSheetsFilterRangeMutation, SheetsFilterService, UniverSheetsFilterPlugin } from '@univerjs/sheets-filter';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { IMessageService } from '@univerjs/ui';
import { MockMessageService } from '@univerjs/ui/services/message/__testing__/mock-message.service.js';
diff --git a/packages/sheets-filter-ui/src/commands/commands/sheets-filter.command.ts b/packages/sheets-filter-ui/src/commands/commands/sheets-filter.command.ts
index 6c1cdafc67..6db56426e5 100644
--- a/packages/sheets-filter-ui/src/commands/commands/sheets-filter.command.ts
+++ b/packages/sheets-filter-ui/src/commands/commands/sheets-filter.command.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-import type { ICommand, IMutationInfo, Nullable, Workbook } from '@univerjs/core';
-import { CommandType, ICommandService, IUndoRedoService, IUniverInstanceService, LocaleService, sequenceExecute, UniverInstanceType } from '@univerjs/core';
+import type { IAccessor, ICommand, IMutationInfo, Nullable, Workbook } from '@univerjs/core';
+import { CommandType, ICommandService, IUndoRedoService, IUniverInstanceService, LocaleService, Quantity, sequenceExecute, UniverInstanceType } from '@univerjs/core';
import { MessageType } from '@univerjs/design';
import type { ISheetCommandSharedParams } from '@univerjs/sheets';
import { isSingleCellSelection, SheetsSelectionsService } from '@univerjs/sheets';
@@ -23,7 +23,6 @@ import type { FilterColumn, IAutoFilter, IFilterColumn, IReCalcSheetsFilterMutat
import { ReCalcSheetsFilterMutation, RemoveSheetsFilterMutation, SetSheetsFilterCriteriaMutation, SetSheetsFilterRangeMutation, SheetsFilterService } from '@univerjs/sheets-filter';
import { expandToContinuousRange } from '@univerjs/sheets-ui';
import { IMessageService } from '@univerjs/ui';
-import { type IAccessor, Quantity } from '@wendellhu/redi';
/**
* This command is for toggling filter in the currently active Worksheet.
diff --git a/packages/sheets-filter-ui/src/commands/operations/__tests__/sheets-filter.operation.spec.ts b/packages/sheets-filter-ui/src/commands/operations/__tests__/sheets-filter.operation.spec.ts
index 0dbb416595..964342c7d2 100644
--- a/packages/sheets-filter-ui/src/commands/operations/__tests__/sheets-filter.operation.spec.ts
+++ b/packages/sheets-filter-ui/src/commands/operations/__tests__/sheets-filter.operation.spec.ts
@@ -14,12 +14,10 @@
* limitations under the License.
*/
-import type { IOperation, IWorkbookData } from '@univerjs/core';
-import { CommandType, ICommandService, IContextService, LocaleService, LocaleType, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
+import type { Dependency, IOperation, IWorkbookData } from '@univerjs/core';
+import { CommandType, ICommandService, IContextService, Inject, Injector, LocaleService, LocaleType, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
import type { ISetSheetsFilterRangeMutationParams } from '@univerjs/sheets-filter';
import { SetSheetsFilterRangeMutation, UniverSheetsFilterPlugin } from '@univerjs/sheets-filter';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest';
import { RefRangeService, SheetInterceptorService, SheetsSelectionsService } from '@univerjs/sheets';
import type { IEditorBridgeServiceVisibleParam } from '@univerjs/sheets-ui';
diff --git a/packages/sheets-filter-ui/src/commands/operations/sheets-filter.operation.ts b/packages/sheets-filter-ui/src/commands/operations/sheets-filter.operation.ts
index fc32ba4ace..62146fa924 100644
--- a/packages/sheets-filter-ui/src/commands/operations/sheets-filter.operation.ts
+++ b/packages/sheets-filter-ui/src/commands/operations/sheets-filter.operation.ts
@@ -17,7 +17,7 @@
import { CommandType, ICommandService, IContextService, type IOperation } from '@univerjs/core';
import { SheetsFilterService } from '@univerjs/sheets-filter';
import { ILayoutService } from '@univerjs/ui';
-import { Quantity } from '@wendellhu/redi';
+import { Quantity } from '@univerjs/core';
import { SetCellEditVisibleOperation } from '@univerjs/sheets-ui';
import type { FilterBy } from '../../services/sheets-filter-panel.service';
import { SheetsFilterPanelService } from '../../services/sheets-filter-panel.service';
diff --git a/packages/sheets-filter-ui/src/controllers/__tests__/sheets-filter.menu.spec.ts b/packages/sheets-filter-ui/src/controllers/__tests__/sheets-filter.menu.spec.ts
index ac7802254c..628e3a70f3 100644
--- a/packages/sheets-filter-ui/src/controllers/__tests__/sheets-filter.menu.spec.ts
+++ b/packages/sheets-filter-ui/src/controllers/__tests__/sheets-filter.menu.spec.ts
@@ -15,12 +15,11 @@
*/
import type { IWorkbookData } from '@univerjs/core';
-import { AuthzIoLocalService, DisposableCollection, IAuthzIoService, ICommandService, LocaleType, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
+import { AuthzIoLocalService, DisposableCollection, IAuthzIoService, ICommandService, Injector, LocaleType, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
import { RangeProtectionRuleModel, RefRangeService, SetWorksheetActiveOperation, SheetInterceptorService, SheetsSelectionsService, WorkbookPermissionService, WorksheetPermissionService, WorksheetProtectionPointModel, WorksheetProtectionRuleModel } from '@univerjs/sheets';
import type { ISetSheetsFilterCriteriaMutationParams, ISetSheetsFilterRangeMutationParams } from '@univerjs/sheets-filter';
import { RemoveSheetsFilterMutation, SetSheetsFilterCriteriaMutation, SetSheetsFilterRangeMutation, UniverSheetsFilterPlugin } from '@univerjs/sheets-filter';
import { IMenuService, IPlatformService, IShortcutService, MenuService, PlatformService, ShortcutService } from '@univerjs/ui';
-import { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { ClearSheetsFilterCriteriaCommand, ReCalcSheetsFilterCommand, SmartToggleSheetsFilterCommand } from '../../commands/commands/sheets-filter.command';
import { CloseFilterPanelOperation, OpenFilterPanelOperation } from '../../commands/operations/sheets-filter.operation';
diff --git a/packages/sheets-filter-ui/src/controllers/sheets-filter-mobile-ui.controller.ts b/packages/sheets-filter-ui/src/controllers/sheets-filter-mobile-ui.controller.ts
index d99b116778..34944372e4 100644
--- a/packages/sheets-filter-ui/src/controllers/sheets-filter-mobile-ui.controller.ts
+++ b/packages/sheets-filter-ui/src/controllers/sheets-filter-mobile-ui.controller.ts
@@ -16,7 +16,7 @@
import { LifecycleStages, runOnLifecycle, RxDisposable, UniverInstanceType } from '@univerjs/core';
import { IRenderManagerService } from '@univerjs/engine-render';
-import type { Dependency } from '@wendellhu/redi';
+import type { Dependency } from '@univerjs/core';
import { SheetsFilterRenderController } from './sheets-filter-render.controller';
export class SheetsFilterMobileUIController extends RxDisposable {
diff --git a/packages/sheets-filter-ui/src/controllers/sheets-filter-permission.controller.ts b/packages/sheets-filter-ui/src/controllers/sheets-filter-permission.controller.ts
index 5f3fbe5708..0b9f074c08 100644
--- a/packages/sheets-filter-ui/src/controllers/sheets-filter-permission.controller.ts
+++ b/packages/sheets-filter-ui/src/controllers/sheets-filter-permission.controller.ts
@@ -15,9 +15,8 @@
*/
import type { ICommandInfo } from '@univerjs/core';
-import { Disposable, ICommandService, LifecycleStages, LocaleService, OnLifecycle, Tools } from '@univerjs/core';
+import { Disposable, ICommandService, Inject, LifecycleStages, LocaleService, OnLifecycle, Tools } from '@univerjs/core';
import type { MenuConfig } from '@univerjs/ui';
-import { Inject } from '@wendellhu/redi';
import { SheetPermissionInterceptorBaseController } from '@univerjs/sheets-ui';
diff --git a/packages/sheets-filter-ui/src/controllers/sheets-filter-render.controller.ts b/packages/sheets-filter-ui/src/controllers/sheets-filter-render.controller.ts
index f0582d597b..5dbd35ce35 100644
--- a/packages/sheets-filter-ui/src/controllers/sheets-filter-render.controller.ts
+++ b/packages/sheets-filter-ui/src/controllers/sheets-filter-render.controller.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-import type { IRange, Workbook } from '@univerjs/core';
-import { CommandType, fromCallback, ICommandService, RxDisposable, ThemeService } from '@univerjs/core';
+import type { IDisposable, IRange, Workbook } from '@univerjs/core';
+import { CommandType, fromCallback, ICommandService, Inject, Injector, RxDisposable, ThemeService } from '@univerjs/core';
import type { IRenderContext, IRenderModule, SpreadsheetSkeleton } from '@univerjs/engine-render';
import { IRenderManagerService } from '@univerjs/engine-render';
import type { ISelectionStyle, ISheetCommandSharedParams } from '@univerjs/sheets';
@@ -23,8 +23,6 @@ import { INTERCEPTOR_POINT, SheetInterceptorService } from '@univerjs/sheets';
import type { FilterModel } from '@univerjs/sheets-filter';
import { FILTER_MUTATIONS, ReCalcSheetsFilterMutation, RemoveSheetsFilterMutation, SetSheetsFilterCriteriaMutation, SetSheetsFilterRangeMutation, SheetsFilterService } from '@univerjs/sheets-filter';
import { getCoordByCell, ISheetSelectionRenderService, SelectionShape, SheetSkeletonManagerService, SheetsRenderService } from '@univerjs/sheets-ui';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
import { filter, map, of, startWith, switchMap, takeUntil, throttleTime } from 'rxjs';
import type { ISheetsFilterButtonShapeProps } from '../views/widgets/filter-button.shape';
diff --git a/packages/sheets-filter-ui/src/controllers/sheets-filter-ui.controller.ts b/packages/sheets-filter-ui/src/controllers/sheets-filter-ui.controller.ts
index 0b53933e4e..ffe2ba5967 100644
--- a/packages/sheets-filter-ui/src/controllers/sheets-filter-ui.controller.ts
+++ b/packages/sheets-filter-ui/src/controllers/sheets-filter-ui.controller.ts
@@ -14,12 +14,10 @@
* limitations under the License.
*/
-import type { Nullable } from '@univerjs/core';
-import { ICommandService, IContextService, LifecycleStages, LocaleService, OnLifecycle } from '@univerjs/core';
+import type { IDisposable, Nullable } from '@univerjs/core';
+import { ICommandService, IContextService, Inject, Injector, LifecycleStages, LocaleService, OnLifecycle } from '@univerjs/core';
import { ComponentManager, IMenuService, IMessageService, IShortcutService } from '@univerjs/ui';
import type { IMenuItemFactory, MenuConfig } from '@univerjs/ui';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
import { distinctUntilChanged } from 'rxjs';
import { SheetCanvasPopManagerService } from '@univerjs/sheets-ui';
diff --git a/packages/sheets-filter-ui/src/controllers/sheets-filter.menu.ts b/packages/sheets-filter-ui/src/controllers/sheets-filter.menu.ts
index c6b7a7f5ff..d23d8d34cc 100644
--- a/packages/sheets-filter-ui/src/controllers/sheets-filter.menu.ts
+++ b/packages/sheets-filter-ui/src/controllers/sheets-filter.menu.ts
@@ -16,7 +16,7 @@
import { getMenuHiddenObservable, MenuGroup, MenuItemType, MenuPosition } from '@univerjs/ui';
import type { IMenuButtonItem, IMenuSelectorItem } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor } from '@univerjs/core';
import { SheetsFilterService } from '@univerjs/sheets-filter';
import { UniverInstanceType } from '@univerjs/core';
diff --git a/packages/sheets-filter-ui/src/mobile-plugin.ts b/packages/sheets-filter-ui/src/mobile-plugin.ts
index c7a82bbed0..c6ae0ed8e7 100644
--- a/packages/sheets-filter-ui/src/mobile-plugin.ts
+++ b/packages/sheets-filter-ui/src/mobile-plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { DependentOn, Plugin, Tools, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { DependentOn, Inject, Injector, Plugin, Tools, UniverInstanceType } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
import { UniverSheetsFilterPlugin } from '@univerjs/sheets-filter';
import type { IUniverSheetsFilterUIConfig } from './controllers/sheets-filter-ui.controller';
diff --git a/packages/sheets-filter-ui/src/plugin.ts b/packages/sheets-filter-ui/src/plugin.ts
index dd983c577c..78d072bf1d 100644
--- a/packages/sheets-filter-ui/src/plugin.ts
+++ b/packages/sheets-filter-ui/src/plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { DependentOn, LocaleService, Plugin, Tools, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { DependentOn, Inject, Injector, LocaleService, Plugin, Tools, UniverInstanceType } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
import { UniverSheetsFilterPlugin } from '@univerjs/sheets-filter';
import type { IUniverSheetsFilterUIConfig } from './controllers/sheets-filter-ui.controller';
diff --git a/packages/sheets-filter-ui/src/services/__tests__/sheets-filter-panel.service.spec.ts b/packages/sheets-filter-ui/src/services/__tests__/sheets-filter-panel.service.spec.ts
index 62cae92c5b..5a45e663d1 100644
--- a/packages/sheets-filter-ui/src/services/__tests__/sheets-filter-panel.service.spec.ts
+++ b/packages/sheets-filter-ui/src/services/__tests__/sheets-filter-panel.service.spec.ts
@@ -14,11 +14,9 @@
* limitations under the License.
*/
-import type { IOperation, IWorkbookData } from '@univerjs/core';
-import { CommandType, ICommandService, LocaleService, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
+import type { Dependency, IOperation, IWorkbookData } from '@univerjs/core';
+import { CommandType, ICommandService, Inject, Injector, LocaleService, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
import { RefRangeService, SheetInterceptorService, SheetsSelectionsService } from '@univerjs/sheets';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it, vitest } from 'vitest';
import { CustomFilterOperator, SheetsFilterService, UniverSheetsFilterPlugin } from '@univerjs/sheets-filter';
import type { IEditorBridgeServiceVisibleParam } from '@univerjs/sheets-ui';
diff --git a/packages/sheets-filter-ui/src/services/sheets-filter-panel.service.ts b/packages/sheets-filter-ui/src/services/sheets-filter-panel.service.ts
index 766e64aa6c..34c1351732 100644
--- a/packages/sheets-filter-ui/src/services/sheets-filter-panel.service.ts
+++ b/packages/sheets-filter-ui/src/services/sheets-filter-panel.service.ts
@@ -14,12 +14,10 @@
* limitations under the License.
*/
-import type { IRange, Nullable } from '@univerjs/core';
-import { Disposable, extractPureTextFromCell, ICommandService, IUniverInstanceService, LocaleService } from '@univerjs/core';
+import type { IDisposable, IRange, Nullable } from '@univerjs/core';
+import { createIdentifier, Disposable, extractPureTextFromCell, ICommandService, Inject, Injector, IUniverInstanceService, LocaleService } from '@univerjs/core';
import { SheetsFilterService } from '@univerjs/sheets-filter';
import type { FilterColumn, FilterModel, IFilterColumn } from '@univerjs/sheets-filter';
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier, Inject, Injector } from '@wendellhu/redi';
import type { Observable } from 'rxjs';
import { BehaviorSubject, combineLatest, map, merge, of, ReplaySubject, shareReplay, startWith, Subject, throttleTime } from 'rxjs';
import { RefRangeService } from '@univerjs/sheets';
diff --git a/packages/sheets-filter-ui/src/views/components/SheetsFilterByConditionsPanel.tsx b/packages/sheets-filter-ui/src/views/components/SheetsFilterByConditionsPanel.tsx
index b399976668..f0a365c2bb 100644
--- a/packages/sheets-filter-ui/src/views/components/SheetsFilterByConditionsPanel.tsx
+++ b/packages/sheets-filter-ui/src/views/components/SheetsFilterByConditionsPanel.tsx
@@ -14,11 +14,10 @@
* limitations under the License.
*/
-import { LocaleService } from '@univerjs/core';
+import { LocaleService, useDependency } from '@univerjs/core';
import type { ISelectProps } from '@univerjs/design';
import { Input, Radio, RadioGroup, Select } from '@univerjs/design';
import { useObservable } from '@univerjs/ui';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import React, { useCallback, useMemo } from 'react';
import type { ByConditionsModel } from '../../services/sheets-filter-panel.service';
diff --git a/packages/sheets-filter-ui/src/views/components/SheetsFilterByValuesPanel.tsx b/packages/sheets-filter-ui/src/views/components/SheetsFilterByValuesPanel.tsx
index 0aef61d613..6c33635b99 100644
--- a/packages/sheets-filter-ui/src/views/components/SheetsFilterByValuesPanel.tsx
+++ b/packages/sheets-filter-ui/src/views/components/SheetsFilterByValuesPanel.tsx
@@ -15,8 +15,7 @@
*/
import React, { useCallback } from 'react';
-import { useDependency } from '@wendellhu/redi/react-bindings';
-import { LocaleService } from '@univerjs/core';
+import { LocaleService, useDependency } from '@univerjs/core';
import { useObservable } from '@univerjs/ui';
import List from 'rc-virtual-list';
import { Button, Checkbox, Input, Tooltip } from '@univerjs/design';
diff --git a/packages/sheets-filter-ui/src/views/components/SheetsFilterPanel.stories.tsx b/packages/sheets-filter-ui/src/views/components/SheetsFilterPanel.stories.tsx
index 4a9f99ef28..4543f71bba 100644
--- a/packages/sheets-filter-ui/src/views/components/SheetsFilterPanel.stories.tsx
+++ b/packages/sheets-filter-ui/src/views/components/SheetsFilterPanel.stories.tsx
@@ -16,11 +16,9 @@
import React, { useState } from 'react';
import type { Meta } from '@storybook/react';
-import { RediContext } from '@wendellhu/redi/react-bindings';
-import type { Injector } from '@wendellhu/redi';
+import { CommandType, ICommandService, ILogService, LocaleService, LocaleType, LogLevel, Plugin, RediContext, Univer, UniverInstanceType } from '@univerjs/core';
+import type { Injector, IWorkbookData } from '@univerjs/core';
import { UniverSheetsFilterPlugin } from '@univerjs/sheets-filter';
-import type { IWorkbookData } from '@univerjs/core';
-import { CommandType, ICommandService, ILogService, LocaleService, LocaleType, LogLevel, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
import { RefRangeService, SheetInterceptorService, SheetsSelectionsService, WorksheetProtectionPointModel } from '@univerjs/sheets';
import { IMenuService, IShortcutService, MenuService, ShortcutService } from '@univerjs/ui';
import { SetCellEditVisibleOperation } from '@univerjs/sheets-ui';
diff --git a/packages/sheets-filter-ui/src/views/components/SheetsFilterPanel.tsx b/packages/sheets-filter-ui/src/views/components/SheetsFilterPanel.tsx
index a58811b406..cf20390f3b 100644
--- a/packages/sheets-filter-ui/src/views/components/SheetsFilterPanel.tsx
+++ b/packages/sheets-filter-ui/src/views/components/SheetsFilterPanel.tsx
@@ -16,9 +16,8 @@
import React, { useCallback, useMemo } from 'react';
import { Button, type ISegmentedProps, Segmented } from '@univerjs/design';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { ICommandService, LocaleService, useDependency } from '@univerjs/core';
import { ComponentContainer, useComponentsOfPart, useObservable } from '@univerjs/ui';
-import { ICommandService, LocaleService } from '@univerjs/core';
import { of } from 'rxjs';
import { SheetsFilterService } from '@univerjs/sheets-filter';
diff --git a/packages/sheets-filter-ui/src/views/widgets/filter-button.shape.ts b/packages/sheets-filter-ui/src/views/widgets/filter-button.shape.ts
index ad9e47b2fe..7c2fb5a4bd 100644
--- a/packages/sheets-filter-ui/src/views/widgets/filter-button.shape.ts
+++ b/packages/sheets-filter-ui/src/views/widgets/filter-button.shape.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { ICommandService, IContextService, ThemeService } from '@univerjs/core';
+import { ICommandService, IContextService, Inject, ThemeService } from '@univerjs/core';
import { type IMouseEvent, type IPointerEvent, type IShapeProps, Shape, type UniverRenderingContext2D } from '@univerjs/engine-render';
-import { Inject } from '@wendellhu/redi';
import { FILTER_PANEL_OPENED_KEY, type IOpenFilterPanelOperationParams, OpenFilterPanelOperation } from '../../commands/operations/sheets-filter.operation';
import { FilterButton } from './drawings';
diff --git a/packages/sheets-filter/package.json b/packages/sheets-filter/package.json
index 75a170a84b..3ea32ac5b9 100644
--- a/packages/sheets-filter/package.json
+++ b/packages/sheets-filter/package.json
@@ -60,14 +60,12 @@
"peerDependencies": {
"@univerjs/core": "workspace:*",
"@univerjs/sheets": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": ">=7.0.0"
},
"devDependencies": {
"@univerjs/core": "workspace:*",
"@univerjs/shared": "workspace:*",
"@univerjs/sheets": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": "^7.8.1",
"typescript": "^5.5.3",
"vite": "^5.3.4",
diff --git a/packages/sheets-filter/src/commands/mutations/__tests__/sheets-filter.mutation.spec.ts b/packages/sheets-filter/src/commands/mutations/__tests__/sheets-filter.mutation.spec.ts
index 4dad1ce629..7162123eb5 100644
--- a/packages/sheets-filter/src/commands/mutations/__tests__/sheets-filter.mutation.spec.ts
+++ b/packages/sheets-filter/src/commands/mutations/__tests__/sheets-filter.mutation.spec.ts
@@ -15,8 +15,7 @@
*/
import type { IWorkbookData } from '@univerjs/core';
-import { ICommandService, LocaleType, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
-import { Inject, Injector } from '@wendellhu/redi';
+import { ICommandService, Inject, Injector, LocaleType, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
import { afterEach, describe, expect, it } from 'vitest';
import { SHEET_FILTER_SNAPSHOT_ID, SheetsFilterService } from '../../../services/sheet-filter.service';
import type { ISetSheetsFilterCriteriaMutationParams, ISetSheetsFilterRangeMutationParams } from '../sheets-filter.mutation';
diff --git a/packages/sheets-filter/src/controllers/sheets-filter.controller.ts b/packages/sheets-filter/src/controllers/sheets-filter.controller.ts
index 0f951addf5..9fa687e813 100644
--- a/packages/sheets-filter/src/controllers/sheets-filter.controller.ts
+++ b/packages/sheets-filter/src/controllers/sheets-filter.controller.ts
@@ -15,10 +15,9 @@
*/
import type { ICommandInfo, IMutationInfo, IObjectArrayPrimitiveType, IRange, Nullable, Workbook } from '@univerjs/core';
-import { Disposable, DisposableCollection, ICommandService, IUniverInstanceService, LifecycleStages, moveMatrixArray, OnLifecycle, Rectangle } from '@univerjs/core';
+import { Disposable, DisposableCollection, ICommandService, Inject, IUniverInstanceService, LifecycleStages, moveMatrixArray, OnLifecycle, Rectangle } from '@univerjs/core';
import type { EffectRefRangeParams, IAddWorksheetMergeMutationParams, IInsertColCommandParams, IInsertRowCommandParams, IInsertRowMutationParams, IMoveColsCommandParams, IMoveRangeCommandParams, IMoveRowsCommandParams, IRemoveColMutationParams, IRemoveRowsMutationParams, IRemoveSheetCommandParams, ISetRangeValuesMutationParams, ISetWorksheetActivateCommandParams, ISheetCommandSharedParams } from '@univerjs/sheets';
import { EffectRefRangId, expandToContinuousRange, getSheetCommandTarget, InsertColCommand, InsertRowCommand, InsertRowMutation, INTERCEPTOR_POINT, MoveRangeCommand, MoveRowsCommand, RefRangeService, RemoveColCommand, RemoveRowCommand, RemoveRowMutation, RemoveSheetCommand, SetRangeValuesMutation, SetWorksheetActivateCommand, SheetInterceptorService } from '@univerjs/sheets';
-import { Inject } from '@wendellhu/redi';
import { SheetsFilterService } from '../services/sheet-filter.service';
import type { IRemoveSheetsFilterMutationParams, ISetSheetsFilterCriteriaMutationParams, ISetSheetsFilterRangeMutationParams } from '../commands/mutations/sheets-filter.mutation';
diff --git a/packages/sheets-filter/src/models/__tests__/filter-interceptor.spec.ts b/packages/sheets-filter/src/models/__tests__/filter-interceptor.spec.ts
index 93d99c79ed..516dfa756d 100644
--- a/packages/sheets-filter/src/models/__tests__/filter-interceptor.spec.ts
+++ b/packages/sheets-filter/src/models/__tests__/filter-interceptor.spec.ts
@@ -15,10 +15,8 @@
*/
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
-import type { IWorkbookData, LocaleType } from '@univerjs/core';
-import { Direction, ICommandService, Plugin, RANGE_TYPE, Univer, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import type { Dependency, IWorkbookData, LocaleType } from '@univerjs/core';
+import { Direction, ICommandService, Inject, Injector, Plugin, RANGE_TYPE, Univer, UniverInstanceType } from '@univerjs/core';
import type { IInsertColCommandParams, IInsertRowCommandParams, IMoveColsCommandParams, IMoveRowsCommandParams, IRemoveRowColCommandParams, IRemoveSheetCommandParams, ISetSelectionsOperationParams } from '@univerjs/sheets';
import { InsertColCommand, InsertColMutation, InsertRowCommand, InsertRowMutation, MoveColsCommand, MoveColsMutation, MoveRowsCommand, MoveRowsMutation, RefRangeService, RemoveColCommand, RemoveColMutation, RemoveRowCommand, RemoveRowMutation, RemoveSheetCommand, RemoveSheetMutation, SetSelectionsOperation, SheetInterceptorService, SheetsSelectionsService } from '@univerjs/sheets';
diff --git a/packages/sheets-filter/src/models/__tests__/filter-model.spec.ts b/packages/sheets-filter/src/models/__tests__/filter-model.spec.ts
index 7e299e97f6..09d8a9e671 100644
--- a/packages/sheets-filter/src/models/__tests__/filter-model.spec.ts
+++ b/packages/sheets-filter/src/models/__tests__/filter-model.spec.ts
@@ -15,9 +15,8 @@
*/
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
-import type { IWorkbookData, Workbook } from '@univerjs/core';
+import type { Injector, IWorkbookData, Workbook } from '@univerjs/core';
import { ILogService, IUniverInstanceService, LocaleType, LogLevel, Univer, UniverInstanceType } from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { FilterColumn, generateFilterFn } from '../filter-model';
import { CustomFilterOperator } from '../types';
diff --git a/packages/sheets-filter/src/plugin.ts b/packages/sheets-filter/src/plugin.ts
index 1d922e36a4..29aceee47e 100644
--- a/packages/sheets-filter/src/plugin.ts
+++ b/packages/sheets-filter/src/plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { Plugin, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { Inject, Injector, Plugin, UniverInstanceType } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
import { SHEET_FILTER_SNAPSHOT_ID, SheetsFilterService } from './services/sheet-filter.service';
import { SheetsFilterController } from './controllers/sheets-filter.controller';
diff --git a/packages/sheets-find-replace/package.json b/packages/sheets-find-replace/package.json
index 46fc7a7b30..20171396d2 100644
--- a/packages/sheets-find-replace/package.json
+++ b/packages/sheets-find-replace/package.json
@@ -67,7 +67,6 @@
"@univerjs/find-replace": "workspace:*",
"@univerjs/sheets": "workspace:*",
"@univerjs/sheets-ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": ">=7.0.0"
},
"dependencies": {
@@ -81,7 +80,6 @@
"@univerjs/shared": "workspace:*",
"@univerjs/sheets": "workspace:*",
"@univerjs/sheets-ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": "^7.8.1",
"typescript": "^5.5.3",
"vite": "^5.3.4",
diff --git a/packages/sheets-find-replace/src/commands/commands/sheet-replace.command.ts b/packages/sheets-find-replace/src/commands/commands/sheet-replace.command.ts
index 38852618e7..51ad1e5eba 100644
--- a/packages/sheets-find-replace/src/commands/commands/sheet-replace.command.ts
+++ b/packages/sheets-find-replace/src/commands/commands/sheet-replace.command.ts
@@ -15,10 +15,9 @@
*/
import { CommandType, ICommandService, IUndoRedoService } from '@univerjs/core';
-import type { ICellData, ICommand, IObjectArrayPrimitiveType } from '@univerjs/core';
+import type { IAccessor, ICellData, ICommand, IObjectArrayPrimitiveType } from '@univerjs/core';
import type { IReplaceAllResult } from '@univerjs/find-replace';
import { type ISetRangeValuesCommandParams, SetRangeValuesCommand } from '@univerjs/sheets';
-import type { IAccessor } from '@wendellhu/redi';
export interface ISheetReplaceCommandParams {
unitId: string;
diff --git a/packages/sheets-find-replace/src/controllers/__tests__/utils.spec.ts b/packages/sheets-find-replace/src/controllers/__tests__/utils.spec.ts
index 477bbe0454..c6b49ee324 100644
--- a/packages/sheets-find-replace/src/controllers/__tests__/utils.spec.ts
+++ b/packages/sheets-find-replace/src/controllers/__tests__/utils.spec.ts
@@ -16,9 +16,8 @@
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
-import type { IWorkbookData, Worksheet } from '@univerjs/core';
+import type { Dependency, IWorkbookData, Worksheet } from '@univerjs/core';
import { ILogService, IUniverInstanceService, LocaleType, LogLevel, Univer } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
import type { IFindQuery } from '@univerjs/find-replace';
import { FindBy, FindDirection, FindScope } from '@univerjs/find-replace';
import {
diff --git a/packages/sheets-find-replace/src/controllers/sheet-find-replace.controller.ts b/packages/sheets-find-replace/src/controllers/sheet-find-replace.controller.ts
index 6d65ae312c..b75bd79dda 100644
--- a/packages/sheets-find-replace/src/controllers/sheet-find-replace.controller.ts
+++ b/packages/sheets-find-replace/src/controllers/sheet-find-replace.controller.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-import type { ICellData, IObjectMatrixPrimitiveType, IRange, Nullable, Workbook, Worksheet } from '@univerjs/core';
-import { ColorKit, CommandType, Disposable, EDITOR_ACTIVATED, fromCallback, groupBy, ICommandService, IContextService, IUniverInstanceService, LifecycleStages, ObjectMatrix, OnLifecycle, replaceInDocumentBody, rotate, ThemeService, Tools, UniverInstanceType } from '@univerjs/core';
+import type { ICellData, IDisposable, IObjectMatrixPrimitiveType, IRange, Nullable, Workbook, Worksheet } from '@univerjs/core';
+import { ColorKit, CommandType, Disposable, EDITOR_ACTIVATED, fromCallback, groupBy, ICommandService, IContextService, Inject, Injector, IUniverInstanceService, LifecycleStages, ObjectMatrix, OnLifecycle, replaceInDocumentBody, rotate, ThemeService, Tools, UniverInstanceType } from '@univerjs/core';
import { IRenderManagerService, RENDER_RAW_FORMULA_KEY } from '@univerjs/engine-render';
import type { IFindComplete, IFindMatch, IFindMoveParams, IFindQuery, IFindReplaceProvider, IReplaceAllResult } from '@univerjs/find-replace';
import { FindBy, FindDirection, FindModel, FindReplaceController, FindScope, IFindReplaceService } from '@univerjs/find-replace';
@@ -23,7 +23,6 @@ import type { ISelectionWithStyle, ISetRangeValuesCommandParams, ISetSelectionsO
import { SetRangeValuesCommand, SetSelectionsOperation, SetWorksheetActivateCommand, SetWorksheetActiveOperation, SheetsSelectionsService } from '@univerjs/sheets';
import type { IScrollToCellCommandParams } from '@univerjs/sheets-ui';
import { getCoordByCell, getSheetObject, ScrollToCellCommand, SheetSkeletonManagerService } from '@univerjs/sheets-ui';
-import { type IDisposable, Inject, Injector } from '@wendellhu/redi';
import { debounceTime, filter, merge, skip, Subject, throttleTime } from 'rxjs';
import type { ISheetFindReplaceHighlightShapeProps } from '../views/shapes/find-replace-highlight.shape';
diff --git a/packages/sheets-find-replace/src/plugin.ts b/packages/sheets-find-replace/src/plugin.ts
index e193de6dc4..d176e4ef9a 100644
--- a/packages/sheets-find-replace/src/plugin.ts
+++ b/packages/sheets-find-replace/src/plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { DependentOn, Plugin, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { DependentOn, Inject, Injector, Plugin, UniverInstanceType } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
import { UniverFindReplacePlugin } from '@univerjs/find-replace';
import { UniverSheetsPlugin } from '@univerjs/sheets';
import { SheetsFindReplaceController } from './controllers/sheet-find-replace.controller';
diff --git a/packages/sheets-formula/package.json b/packages/sheets-formula/package.json
index e4e116a914..1db3db0eb1 100644
--- a/packages/sheets-formula/package.json
+++ b/packages/sheets-formula/package.json
@@ -73,7 +73,6 @@
"@univerjs/sheets": "workspace:*",
"@univerjs/sheets-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"react": "^16.9.0 || ^17.0.0 || ^18.0.0",
"rxjs": ">=7.0.0"
},
@@ -94,7 +93,6 @@
"@univerjs/sheets-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
"@vitejs/plugin-react": "^4.3.1",
- "@wendellhu/redi": "0.16.0",
"less": "^4.2.0",
"react": "18.3.1",
"rxjs": "^7.8.1",
diff --git a/packages/sheets-formula/src/commands/commands/insert-function.command.ts b/packages/sheets-formula/src/commands/commands/insert-function.command.ts
index 3634ec26db..3c4167109e 100644
--- a/packages/sheets-formula/src/commands/commands/insert-function.command.ts
+++ b/packages/sheets-formula/src/commands/commands/insert-function.command.ts
@@ -14,11 +14,10 @@
* limitations under the License.
*/
-import type { ICellData, ICommand, IRange } from '@univerjs/core';
+import type { IAccessor, ICellData, ICommand, IRange } from '@univerjs/core';
import { CommandType, ICommandService, ObjectMatrix, Tools } from '@univerjs/core';
import type { ISetRangeValuesCommandParams } from '@univerjs/sheets';
import { SetRangeValuesCommand } from '@univerjs/sheets';
-import type { IAccessor } from '@wendellhu/redi';
export interface IInsertFunction {
/**
diff --git a/packages/sheets-formula/src/commands/operations/__tests__/create-command-test-bed.ts b/packages/sheets-formula/src/commands/operations/__tests__/create-command-test-bed.ts
index 3712830397..521ae3ab7f 100644
--- a/packages/sheets-formula/src/commands/operations/__tests__/create-command-test-bed.ts
+++ b/packages/sheets-formula/src/commands/operations/__tests__/create-command-test-bed.ts
@@ -14,12 +14,10 @@
* limitations under the License.
*/
-import type { IWorkbookData } from '@univerjs/core';
-import { AuthzIoLocalService, IAuthzIoService, ILogService, IUniverInstanceService, LocaleType, LogLevel, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
+import type { Dependency, IWorkbookData } from '@univerjs/core';
+import { AuthzIoLocalService, IAuthzIoService, ILogService, Inject, Injector, IUniverInstanceService, LocaleType, LogLevel, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
import { LexerTreeBuilder } from '@univerjs/engine-formula';
import { RangeProtectionRuleModel, SheetInterceptorService, SheetsSelectionsService, WorkbookPermissionService, WorksheetPermissionService, WorksheetProtectionPointModel, WorksheetProtectionRuleModel } from '@univerjs/sheets';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
import { EditorService, IEditorService } from '@univerjs/ui';
import { IRenderManagerService, RenderManagerService } from '@univerjs/engine-render';
import { EditorBridgeService, IEditorBridgeService, ISheetSelectionRenderService, SheetSelectionRenderService, SheetSkeletonManagerService } from '@univerjs/sheets-ui';
diff --git a/packages/sheets-formula/src/commands/operations/__tests__/insert-function.operation.spec.ts b/packages/sheets-formula/src/commands/operations/__tests__/insert-function.operation.spec.ts
index 99923df681..51f89e3b72 100644
--- a/packages/sheets-formula/src/commands/operations/__tests__/insert-function.operation.spec.ts
+++ b/packages/sheets-formula/src/commands/operations/__tests__/insert-function.operation.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { Univer } from '@univerjs/core';
+import type { Injector, Univer } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, RANGE_TYPE, RedoCommand, UndoCommand } from '@univerjs/core';
import {
SetRangeValuesCommand,
@@ -22,7 +22,6 @@ import {
SetSelectionsOperation,
SheetsSelectionsService,
} from '@univerjs/sheets';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { InsertFunctionCommand } from '../../commands/insert-function.command';
diff --git a/packages/sheets-formula/src/commands/operations/help-function.operation.ts b/packages/sheets-formula/src/commands/operations/help-function.operation.ts
index 978b786c5b..83a902f8b7 100644
--- a/packages/sheets-formula/src/commands/operations/help-function.operation.ts
+++ b/packages/sheets-formula/src/commands/operations/help-function.operation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { IHelpFunctionOperationParams } from '../../services/prompt.service';
import { IFormulaPromptService } from '../../services/prompt.service';
diff --git a/packages/sheets-formula/src/commands/operations/insert-function.operation.ts b/packages/sheets-formula/src/commands/operations/insert-function.operation.ts
index 0eab450974..b6f867399b 100644
--- a/packages/sheets-formula/src/commands/operations/insert-function.operation.ts
+++ b/packages/sheets-formula/src/commands/operations/insert-function.operation.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICellData, ICommand, IRange, Nullable, ObjectMatrix } from '@univerjs/core';
+import type { IAccessor, ICellData, ICommand, IRange, Nullable, ObjectMatrix } from '@univerjs/core';
import {
CellValueType,
CommandType,
@@ -32,7 +32,6 @@ import {
SetSelectionsOperation,
SheetsSelectionsService,
} from '@univerjs/sheets';
-import type { IAccessor } from '@wendellhu/redi';
import { IEditorService } from '@univerjs/ui';
import type { IInsertFunction } from '../commands/insert-function.command';
diff --git a/packages/sheets-formula/src/commands/operations/more-functions.operation.ts b/packages/sheets-formula/src/commands/operations/more-functions.operation.ts
index dde0ca3560..83e93f8872 100644
--- a/packages/sheets-formula/src/commands/operations/more-functions.operation.ts
+++ b/packages/sheets-formula/src/commands/operations/more-functions.operation.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType } from '@univerjs/core';
import { ISidebarService } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
import { MORE_FUNCTIONS_COMPONENT } from '../../views/more-functions/interface';
diff --git a/packages/sheets-formula/src/commands/operations/reference-absolute.operation.ts b/packages/sheets-formula/src/commands/operations/reference-absolute.operation.ts
index c1e3fed4ae..1ce473b17c 100644
--- a/packages/sheets-formula/src/commands/operations/reference-absolute.operation.ts
+++ b/packages/sheets-formula/src/commands/operations/reference-absolute.operation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
export const ReferenceAbsoluteOperation: ICommand = {
id: 'formula-ui.operation.change-ref-to-absolute',
diff --git a/packages/sheets-formula/src/commands/operations/search-function.operation.ts b/packages/sheets-formula/src/commands/operations/search-function.operation.ts
index 2322af73d8..9ad0d78a3e 100644
--- a/packages/sheets-formula/src/commands/operations/search-function.operation.ts
+++ b/packages/sheets-formula/src/commands/operations/search-function.operation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { ISearchFunctionOperationParams } from '../../services/prompt.service';
import { IFormulaPromptService } from '../../services/prompt.service';
diff --git a/packages/sheets-formula/src/controllers/__tests__/create-command-test-bed.ts b/packages/sheets-formula/src/controllers/__tests__/create-command-test-bed.ts
index d1ad59e92f..1f87f53267 100644
--- a/packages/sheets-formula/src/controllers/__tests__/create-command-test-bed.ts
+++ b/packages/sheets-formula/src/controllers/__tests__/create-command-test-bed.ts
@@ -14,15 +14,13 @@
* limitations under the License.
*/
-import type { IWorkbookData, Workbook } from '@univerjs/core';
-import { ILogService, IUniverInstanceService, LocaleType, LogLevel, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
+import type { Dependency, IWorkbookData, Workbook } from '@univerjs/core';
+import { ILogService, Inject, Injector, IUniverInstanceService, LocaleType, LogLevel, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
import { CalculateFormulaService, DefinedNamesService, FormulaCurrentConfigService, FormulaDataModel, FormulaRuntimeService, IDefinedNamesService, IFormulaCurrentConfigService, IFormulaRuntimeService, LexerTreeBuilder } from '@univerjs/engine-formula';
import { IRenderManagerService, RenderManagerService } from '@univerjs/engine-render';
import { IRefSelectionsService, SheetInterceptorService, SheetsSelectionsService } from '@univerjs/sheets';
import { EditorBridgeService, IEditorBridgeService, SheetSkeletonManagerService } from '@univerjs/sheets-ui';
import { EditorService, IEditorService } from '@univerjs/ui';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
const TEST_WORKBOOK_DATA_DEMO: IWorkbookData = {
id: 'test',
diff --git a/packages/sheets-formula/src/controllers/__tests__/formula-auto-fill.controller.spec.ts b/packages/sheets-formula/src/controllers/__tests__/formula-auto-fill.controller.spec.ts
index 63fdb0f42f..51c507ca91 100644
--- a/packages/sheets-formula/src/controllers/__tests__/formula-auto-fill.controller.spec.ts
+++ b/packages/sheets-formula/src/controllers/__tests__/formula-auto-fill.controller.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICellData, Nullable, Univer } from '@univerjs/core';
+import type { ICellData, Injector, Nullable, Univer } from '@univerjs/core';
import {
ICommandService,
IUniverInstanceService,
@@ -43,7 +43,6 @@ import {
SheetsRenderService,
} from '@univerjs/sheets-ui';
import { IPlatformService, IShortcutService, PlatformService, ShortcutService } from '@univerjs/ui';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { FormulaAutoFillController } from '../formula-auto-fill.controller';
diff --git a/packages/sheets-formula/src/controllers/__tests__/formula-clipboard.controller.spec.ts b/packages/sheets-formula/src/controllers/__tests__/formula-clipboard.controller.spec.ts
index f082126f6b..01a206a667 100644
--- a/packages/sheets-formula/src/controllers/__tests__/formula-clipboard.controller.spec.ts
+++ b/packages/sheets-formula/src/controllers/__tests__/formula-clipboard.controller.spec.ts
@@ -14,13 +14,12 @@
* limitations under the License.
*/
-import type { ICellData, Nullable, Univer } from '@univerjs/core';
+import type { ICellData, Injector, Nullable, Univer } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, ObjectMatrix } from '@univerjs/core';
import { FormulaDataModel, LexerTreeBuilder } from '@univerjs/engine-formula';
import { type ISetRangeValuesMutationParams, SetRangeValuesMutation } from '@univerjs/sheets';
import type { ICellDataWithSpanInfo } from '@univerjs/sheets-ui';
import { COPY_TYPE, ISheetSelectionRenderService, PREDEFINED_HOOK_NAME, SheetSelectionRenderService } from '@univerjs/sheets-ui';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { getSetCellFormulaMutations } from '../formula-clipboard.controller';
diff --git a/packages/sheets-formula/src/controllers/__tests__/update-formula.controller.spec.ts b/packages/sheets-formula/src/controllers/__tests__/update-formula.controller.spec.ts
index 43ae50a298..d69aee165f 100644
--- a/packages/sheets-formula/src/controllers/__tests__/update-formula.controller.spec.ts
+++ b/packages/sheets-formula/src/controllers/__tests__/update-formula.controller.spec.ts
@@ -14,11 +14,10 @@
* limitations under the License.
*/
-import type { ICellData, IObjectMatrixPrimitiveType, IWorkbookData, Nullable, Univer } from '@univerjs/core';
+import type { ICellData, Injector, IObjectMatrixPrimitiveType, IWorkbookData, Nullable, Univer } from '@univerjs/core';
import { CellValueType, Direction, ICommandService, IUniverInstanceService, LocaleType, RANGE_TYPE, RedoCommand, UndoCommand } from '@univerjs/core';
import type { IDeleteRangeMoveLeftCommandParams, IDeleteRangeMoveUpCommandParams, IInsertColCommandParams, IInsertRowCommandParams, IMoveColsCommandParams, IMoveRangeCommandParams, IMoveRowsCommandParams, InsertRangeMoveDownCommandParams, InsertRangeMoveRightCommandParams, IRemoveRowColCommandParams, IRemoveSheetCommandParams, ISetWorksheetNameCommandParams } from '@univerjs/sheets';
import { DeleteRangeMoveLeftCommand, DeleteRangeMoveUpCommand, InsertColCommand, InsertColMutation, InsertRangeMoveDownCommand, InsertRangeMoveRightCommand, InsertRowCommand, InsertRowMutation, MoveColsCommand, MoveColsMutation, MoveRangeCommand, MoveRangeMutation, MoveRowsCommand, MoveRowsMutation, RemoveColCommand, RemoveColMutation, RemoveRowCommand, RemoveRowMutation, RemoveSheetCommand, RemoveSheetMutation, SetRangeValuesMutation, SetSelectionsOperation, SetWorksheetNameCommand, SetWorksheetNameMutation, SheetsSelectionsService } from '@univerjs/sheets';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { SetArrayFormulaDataMutation, SetFormulaDataMutation } from '@univerjs/engine-formula';
diff --git a/packages/sheets-formula/src/controllers/active-dirty.controller.ts b/packages/sheets-formula/src/controllers/active-dirty.controller.ts
index 39def9f38f..7515f428d6 100644
--- a/packages/sheets-formula/src/controllers/active-dirty.controller.ts
+++ b/packages/sheets-formula/src/controllers/active-dirty.controller.ts
@@ -18,6 +18,7 @@ import type { ICellData, ICommandInfo, IObjectMatrixPrimitiveType, IRange, IUnit
import {
Dimension,
Disposable,
+ Inject,
IUniverInstanceService,
LifecycleStages,
ObjectMatrix,
@@ -51,7 +52,6 @@ import {
SetRangeValuesMutation,
SetStyleCommand,
} from '@univerjs/sheets';
-import { Inject } from '@wendellhu/redi';
@OnLifecycle(LifecycleStages.Ready, ActiveDirtyController)
export class ActiveDirtyController extends Disposable {
diff --git a/packages/sheets-formula/src/controllers/array-formula-display.controller.ts b/packages/sheets-formula/src/controllers/array-formula-display.controller.ts
index 5c7248723a..9123be2521 100644
--- a/packages/sheets-formula/src/controllers/array-formula-display.controller.ts
+++ b/packages/sheets-formula/src/controllers/array-formula-display.controller.ts
@@ -15,11 +15,10 @@
*/
import type { ICommandInfo } from '@univerjs/core';
-import { CellValueType, Disposable, ICommandService, LifecycleStages, OnLifecycle, ThemeService } from '@univerjs/core';
+import { CellValueType, Disposable, ICommandService, Inject, LifecycleStages, OnLifecycle, ThemeService } from '@univerjs/core';
import type { ISetArrayFormulaDataMutationParams } from '@univerjs/engine-formula';
import { FormulaDataModel, SetArrayFormulaDataMutation, stripErrorMargin } from '@univerjs/engine-formula';
import { INTERCEPTOR_POINT, SheetInterceptorService } from '@univerjs/sheets';
-import { Inject } from '@wendellhu/redi';
@OnLifecycle(LifecycleStages.Ready, ArrayFormulaDisplayController)
export class ArrayFormulaDisplayController extends Disposable {
diff --git a/packages/sheets-formula/src/controllers/formula-alert-render.controller.ts b/packages/sheets-formula/src/controllers/formula-alert-render.controller.ts
index 94dc7f2df0..40bc1038ab 100644
--- a/packages/sheets-formula/src/controllers/formula-alert-render.controller.ts
+++ b/packages/sheets-formula/src/controllers/formula-alert-render.controller.ts
@@ -15,10 +15,9 @@
*/
import type { Workbook } from '@univerjs/core';
-import { Disposable, isICellData, LocaleService } from '@univerjs/core';
+import { Disposable, Inject, isICellData, LocaleService } from '@univerjs/core';
import { ErrorType } from '@univerjs/engine-formula';
import { CellAlertManagerService, CellAlertType, HoverManagerService } from '@univerjs/sheets-ui';
-import { Inject } from '@wendellhu/redi';
import type { IRenderContext, IRenderModule } from '@univerjs/engine-render';
import { extractFormulaError } from './utils/utils';
diff --git a/packages/sheets-formula/src/controllers/formula-auto-fill.controller.ts b/packages/sheets-formula/src/controllers/formula-auto-fill.controller.ts
index 3b9e091fcd..d08ed6258f 100644
--- a/packages/sheets-formula/src/controllers/formula-auto-fill.controller.ts
+++ b/packages/sheets-formula/src/controllers/formula-auto-fill.controller.ts
@@ -18,6 +18,7 @@ import type { ICellData, Nullable } from '@univerjs/core';
import {
Direction,
Disposable,
+ Inject,
isFormulaId,
isFormulaString,
LifecycleStages,
@@ -27,7 +28,6 @@ import {
import { LexerTreeBuilder } from '@univerjs/engine-formula';
import type { AutoFillService, IAutoFillRule, ICopyDataInTypeIndexInfo, ICopyDataPiece } from '@univerjs/sheets-ui';
import { APPLY_TYPE, DATA_TYPE, IAutoFillService } from '@univerjs/sheets-ui';
-import { Inject } from '@wendellhu/redi';
@OnLifecycle(LifecycleStages.Ready, FormulaAutoFillController)
export class FormulaAutoFillController extends Disposable {
diff --git a/packages/sheets-formula/src/controllers/formula-clipboard.controller.ts b/packages/sheets-formula/src/controllers/formula-clipboard.controller.ts
index d63296eeaf..164d266295 100644
--- a/packages/sheets-formula/src/controllers/formula-clipboard.controller.ts
+++ b/packages/sheets-formula/src/controllers/formula-clipboard.controller.ts
@@ -14,10 +14,12 @@
* limitations under the License.
*/
-import type { ICellData, IMutationInfo, Workbook } from '@univerjs/core';
+import type { IAccessor, ICellData, IMutationInfo, Workbook } from '@univerjs/core';
import {
DEFAULT_EMPTY_DOCUMENT_VALUE,
Disposable,
+ Inject,
+ Injector,
isFormulaId,
isFormulaString,
IUniverInstanceService,
@@ -32,8 +34,6 @@ import type { ISetRangeValuesMutationParams } from '@univerjs/sheets';
import { SetRangeValuesMutation, SetRangeValuesUndoMutationFactory } from '@univerjs/sheets';
import { COPY_TYPE, ISheetClipboardService, PREDEFINED_HOOK_NAME } from '@univerjs/sheets-ui';
import type { ICellDataWithSpanInfo, ICopyPastePayload, IDiscreteRange, ISheetClipboardHook, ISheetDiscreteRangeLocation } from '@univerjs/sheets-ui';
-import type { IAccessor } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
export const DEFAULT_PASTE_FORMULA = 'default-paste-formula';
diff --git a/packages/sheets-formula/src/controllers/formula-editor-show.controller.ts b/packages/sheets-formula/src/controllers/formula-editor-show.controller.ts
index db1a7d31a1..534f6de631 100644
--- a/packages/sheets-formula/src/controllers/formula-editor-show.controller.ts
+++ b/packages/sheets-formula/src/controllers/formula-editor-show.controller.ts
@@ -19,6 +19,7 @@ import {
ColorKit,
Disposable,
ICommandService,
+ Inject,
ObjectMatrix,
Rectangle,
ThemeService,
@@ -40,7 +41,6 @@ import {
SelectionShape,
SheetSkeletonManagerService,
} from '@univerjs/sheets-ui';
-import { Inject } from '@wendellhu/redi';
const REFRESH_ARRAY_SHAPE_MUTATIONS = [
SetWorksheetRowHeightMutation.id,
diff --git a/packages/sheets-formula/src/controllers/formula-render.controller.ts b/packages/sheets-formula/src/controllers/formula-render.controller.ts
index e673f0a62a..3b86041690 100644
--- a/packages/sheets-formula/src/controllers/formula-render.controller.ts
+++ b/packages/sheets-formula/src/controllers/formula-render.controller.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { LifecycleStages, OnLifecycle, RxDisposable } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { Inject, LifecycleStages, OnLifecycle, RxDisposable } from '@univerjs/core';
import { INTERCEPTOR_POINT, SheetInterceptorService } from '@univerjs/sheets';
import { extractFormulaError } from './utils/utils';
diff --git a/packages/sheets-formula/src/controllers/formula-ui.controller.ts b/packages/sheets-formula/src/controllers/formula-ui.controller.ts
index 73479c1c02..e45f07c7b3 100644
--- a/packages/sheets-formula/src/controllers/formula-ui.controller.ts
+++ b/packages/sheets-formula/src/controllers/formula-ui.controller.ts
@@ -14,12 +14,10 @@
* limitations under the License.
*/
-import { Disposable, ICommandService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
+import { connectInjector, Disposable, ICommandService, Inject, Injector, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import type { MenuConfig } from '@univerjs/ui';
import { BuiltInUIPart, ComponentManager, IMenuService, IShortcutService, IUIPartsService } from '@univerjs/ui';
-import type { Ctor, Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
-import { connectInjector } from '@wendellhu/redi/react-bindings';
+import type { Ctor, Dependency } from '@univerjs/core';
import { IRenderManagerService } from '@univerjs/engine-render';
import type { BaseFunction, IFunctionInfo, IFunctionNames } from '@univerjs/engine-formula';
diff --git a/packages/sheets-formula/src/controllers/menu.ts b/packages/sheets-formula/src/controllers/menu.ts
index ffb4511fea..df86e35a24 100644
--- a/packages/sheets-formula/src/controllers/menu.ts
+++ b/packages/sheets-formula/src/controllers/menu.ts
@@ -14,12 +14,11 @@
* limitations under the License.
*/
-import type { Workbook } from '@univerjs/core';
+import type { IAccessor, Workbook } from '@univerjs/core';
import { IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
import { getCurrentRangeDisable$, PASTE_SPECIAL_MENU_ID } from '@univerjs/sheets-ui';
import type { IMenuItem } from '@univerjs/ui';
import { getMenuHiddenObservable, IClipboardInterfaceService, MenuGroup, MenuItemType, MenuPosition } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
import { combineLatestWith, map, Observable, of, switchMap } from 'rxjs';
import { RangeProtectionPermissionEditPoint, WorkbookEditablePermission, WorksheetEditPermission, WorksheetSetCellValuePermission } from '@univerjs/sheets';
diff --git a/packages/sheets-formula/src/controllers/prompt.controller.ts b/packages/sheets-formula/src/controllers/prompt.controller.ts
index a7012de2bc..7200ab5459 100644
--- a/packages/sheets-formula/src/controllers/prompt.controller.ts
+++ b/packages/sheets-formula/src/controllers/prompt.controller.ts
@@ -19,6 +19,7 @@
import type {
DocumentDataModel,
ICommandInfo,
+ IDisposable,
IRange,
IRangeWithCoord,
ITextRun,
@@ -36,6 +37,7 @@ import {
getCellInfoInMergeData,
ICommandService,
IContextService,
+ Inject,
isFormulaString,
IUniverInstanceService,
LifecycleStages,
@@ -93,8 +95,6 @@ import {
SheetSkeletonManagerService,
} from '@univerjs/sheets-ui';
import { IContextMenuService, IEditorService, KeyCode, MetaKeys, SetEditorResizeOperation, UNI_DISABLE_CHANGING_FOCUS_KEY } from '@univerjs/ui';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject } from '@wendellhu/redi';
import type { ISelectEditorFormulaOperationParam } from '../commands/operations/editor-formula.operation';
import { SelectEditorFormulaOperation } from '../commands/operations/editor-formula.operation';
diff --git a/packages/sheets-formula/src/controllers/trigger-calculation.controller.ts b/packages/sheets-formula/src/controllers/trigger-calculation.controller.ts
index f70936e2b6..9e3eefe11d 100644
--- a/packages/sheets-formula/src/controllers/trigger-calculation.controller.ts
+++ b/packages/sheets-formula/src/controllers/trigger-calculation.controller.ts
@@ -15,7 +15,7 @@
*/
import type { ICommandInfo, IUnitRange, Nullable } from '@univerjs/core';
-import { Disposable, ICommandService, LifecycleStages, OnLifecycle, throttle } from '@univerjs/core';
+import { Disposable, ICommandService, Inject, LifecycleStages, OnLifecycle, throttle } from '@univerjs/core';
import type {
IDirtyUnitFeatureMap,
IDirtyUnitOtherFormulaMap,
@@ -43,8 +43,6 @@ import {
} from '@univerjs/sheets';
import { IProgressService } from '@univerjs/ui';
-import { Inject } from '@wendellhu/redi';
-
@OnLifecycle(LifecycleStages.Ready, TriggerCalculationController)
export class TriggerCalculationController extends Disposable {
private _waitingCommandQueue: ICommandInfo[] = [];
diff --git a/packages/sheets-formula/src/controllers/update-formula.controller.ts b/packages/sheets-formula/src/controllers/update-formula.controller.ts
index 25fe291ab3..ad8b5d5df1 100644
--- a/packages/sheets-formula/src/controllers/update-formula.controller.ts
+++ b/packages/sheets-formula/src/controllers/update-formula.controller.ts
@@ -28,6 +28,8 @@ import {
Direction,
Disposable,
ICommandService,
+ Inject,
+ Injector,
IUniverInstanceService,
LifecycleStages,
ObjectMatrix,
@@ -104,7 +106,6 @@ import {
SheetInterceptorService,
SheetsSelectionsService,
} from '@univerjs/sheets';
-import { Inject, Injector } from '@wendellhu/redi';
import { filter, map, merge } from 'rxjs';
import { IEditorService } from '@univerjs/ui';
diff --git a/packages/sheets-formula/src/formula-ui-plugin.ts b/packages/sheets-formula/src/formula-ui-plugin.ts
index 2c755115ff..14196273f1 100644
--- a/packages/sheets-formula/src/formula-ui-plugin.ts
+++ b/packages/sheets-formula/src/formula-ui-plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { DependentOn, Plugin, Tools, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { DependentOn, Inject, Injector, Plugin, Tools, UniverInstanceType } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
import { fromModule, IRPCChannelService, toModule } from '@univerjs/rpc';
import { UniverFormulaEnginePlugin } from '@univerjs/engine-formula';
import { IRenderManagerService } from '@univerjs/engine-render';
diff --git a/packages/sheets-formula/src/services/description.service.ts b/packages/sheets-formula/src/services/description.service.ts
index 966f3bf06d..552db1709d 100644
--- a/packages/sheets-formula/src/services/description.service.ts
+++ b/packages/sheets-formula/src/services/description.service.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import { LocaleService, toDisposable } from '@univerjs/core';
+import { createIdentifier, Inject, LocaleService, toDisposable } from '@univerjs/core';
import type { IFunctionInfo, IFunctionNames } from '@univerjs/engine-formula';
import {
functionArray,
@@ -37,8 +37,7 @@ import {
IFunctionService,
isReferenceStrings,
} from '@univerjs/engine-formula';
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier, Inject } from '@wendellhu/redi';
+import type { IDisposable } from '@univerjs/core';
import { FUNCTION_LIST } from './function-list/function-list';
import { getFunctionName } from './utils';
diff --git a/packages/sheets-formula/src/services/formula-ref-range.service.ts b/packages/sheets-formula/src/services/formula-ref-range.service.ts
index 0e6036ae76..00d8e2fcd5 100644
--- a/packages/sheets-formula/src/services/formula-ref-range.service.ts
+++ b/packages/sheets-formula/src/services/formula-ref-range.service.ts
@@ -14,13 +14,11 @@
* limitations under the License.
*/
-import type { IMutationInfo, IRange, Workbook } from '@univerjs/core';
-import { Disposable, DisposableCollection, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
+import type { IDisposable, IMutationInfo, IRange, Workbook } from '@univerjs/core';
+import { Disposable, DisposableCollection, Inject, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
import { deserializeRangeWithSheet, ErrorType, generateStringWithSequence, LexerTreeBuilder, sequenceNodeType, serializeRange, serializeRangeWithSheet, serializeRangeWithSpreadsheet } from '@univerjs/engine-formula';
import type { EffectRefRangeParams } from '@univerjs/sheets';
import { handleDefaultRangeChangeWithEffectRefCommands, RefRangeService } from '@univerjs/sheets';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject } from '@wendellhu/redi';
export type FormulaChangeMap = Record<string, Record<string, Record<string, string>>>;
diff --git a/packages/sheets-formula/src/services/prompt.service.ts b/packages/sheets-formula/src/services/prompt.service.ts
index ce55119585..51f0069dbf 100644
--- a/packages/sheets-formula/src/services/prompt.service.ts
+++ b/packages/sheets-formula/src/services/prompt.service.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { Direction } from '@univerjs/core';
+import type { Direction, IDisposable } from '@univerjs/core';
import { type IFunctionInfo, type ISequenceNode, sequenceNodeType } from '@univerjs/engine-formula';
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier } from '@univerjs/core';
import type { Observable } from 'rxjs';
import { Subject } from 'rxjs';
diff --git a/packages/sheets-formula/src/services/register-function.service.ts b/packages/sheets-formula/src/services/register-function.service.ts
index 163c983cdf..fcfdf8ab6f 100644
--- a/packages/sheets-formula/src/services/register-function.service.ts
+++ b/packages/sheets-formula/src/services/register-function.service.ts
@@ -14,12 +14,10 @@
* limitations under the License.
*/
-import type { ILocales } from '@univerjs/core';
-import { Disposable, DisposableCollection, LocaleService, toDisposable } from '@univerjs/core';
+import type { IDisposable, ILocales } from '@univerjs/core';
+import { createIdentifier, Disposable, DisposableCollection, Inject, LocaleService, Optional, toDisposable } from '@univerjs/core';
import type { IFunctionInfo, PrimitiveValueType } from '@univerjs/engine-formula';
import { CustomFunction, FunctionType, IFunctionService } from '@univerjs/engine-formula';
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier, Inject, Optional } from '@wendellhu/redi';
import { IDescriptionService } from './description.service';
import { IRemoteRegisterFunctionService } from './remote/remote-register-function.service';
diff --git a/packages/sheets-formula/src/services/remote/remote-register-function.service.ts b/packages/sheets-formula/src/services/remote/remote-register-function.service.ts
index 74826d9c02..f89dff9617 100644
--- a/packages/sheets-formula/src/services/remote/remote-register-function.service.ts
+++ b/packages/sheets-formula/src/services/remote/remote-register-function.service.ts
@@ -16,7 +16,7 @@
import type { BaseFunction } from '@univerjs/engine-formula';
import { CustomFunction, IFunctionService } from '@univerjs/engine-formula';
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier } from '@univerjs/core';
export interface IRemoteRegisterFunctionService {
registerFunctions(serializedFuncs: Array<[string, string]>): Promise<void>;
diff --git a/packages/sheets-formula/src/services/render-services/ref-selections.render-service.ts b/packages/sheets-formula/src/services/render-services/ref-selections.render-service.ts
index 5fe27394a2..e399047bcd 100644
--- a/packages/sheets-formula/src/services/render-services/ref-selections.render-service.ts
+++ b/packages/sheets-formula/src/services/render-services/ref-selections.render-service.ts
@@ -14,15 +14,13 @@
* limitations under the License.
*/
-import type { Nullable, Workbook } from '@univerjs/core';
-import { DisposableCollection, RANGE_TYPE, ThemeService, toDisposable } from '@univerjs/core';
+import type { IDisposable, Nullable, Workbook } from '@univerjs/core';
+import { DisposableCollection, Inject, Injector, RANGE_TYPE, ThemeService, toDisposable } from '@univerjs/core';
import type { IMouseEvent, IPointerEvent, IRenderContext, IRenderModule } from '@univerjs/engine-render';
import { IRenderManagerService, ScrollTimerType, SHEET_VIEWPORT_KEY, Vector2 } from '@univerjs/engine-render';
import { convertSelectionDataToRange, getNormalSelectionStyle, IRefSelectionsService, type ISelectionWithCoordAndStyle, type SheetsSelectionsService, type WorkbookSelections } from '@univerjs/sheets';
import { BaseSelectionRenderService, checkInHeaderRanges, getAllSelection, getCoordByOffset, getSheetObject, SheetSkeletonManagerService } from '@univerjs/sheets-ui';
import { IShortcutService } from '@univerjs/ui';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
/**
* This service extends the existing `SelectionRenderService` to provide the rendering of prompt selections
diff --git a/packages/sheets-formula/src/views/more-functions/MoreFunctions.tsx b/packages/sheets-formula/src/views/more-functions/MoreFunctions.tsx
index 75de5703aa..48a3fbf479 100644
--- a/packages/sheets-formula/src/views/more-functions/MoreFunctions.tsx
+++ b/packages/sheets-formula/src/views/more-functions/MoreFunctions.tsx
@@ -14,11 +14,10 @@
* limitations under the License.
*/
-import { LocaleService } from '@univerjs/core';
+import { LocaleService, useDependency } from '@univerjs/core';
import { Button } from '@univerjs/design';
import type { IFunctionInfo } from '@univerjs/engine-formula';
import { IEditorService } from '@univerjs/ui';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import React, { useState } from 'react';
import { useActiveWorkbook } from '@univerjs/sheets-ui';
import styles from './index.module.less';
diff --git a/packages/sheets-formula/src/views/more-functions/select-function/SelectFunction.tsx b/packages/sheets-formula/src/views/more-functions/select-function/SelectFunction.tsx
index f66bfefaf0..43a23a72ac 100644
--- a/packages/sheets-formula/src/views/more-functions/select-function/SelectFunction.tsx
+++ b/packages/sheets-formula/src/views/more-functions/select-function/SelectFunction.tsx
@@ -14,12 +14,11 @@
* limitations under the License.
*/
-import { LocaleService } from '@univerjs/core';
+import { LocaleService, useDependency } from '@univerjs/core';
import { Input, Select } from '@univerjs/design';
import type { IFunctionInfo, IFunctionParam } from '@univerjs/engine-formula';
import { FunctionType } from '@univerjs/engine-formula';
import { CheckMarkSingle } from '@univerjs/icons';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import React, { useEffect, useState } from 'react';
import type { ISearchItem } from '../../../services/description.service';
diff --git a/packages/sheets-formula/src/views/prompt/help-function/HelpFunction.tsx b/packages/sheets-formula/src/views/prompt/help-function/HelpFunction.tsx
index 723075afd8..ec04e8b37b 100644
--- a/packages/sheets-formula/src/views/prompt/help-function/HelpFunction.tsx
+++ b/packages/sheets-formula/src/views/prompt/help-function/HelpFunction.tsx
@@ -14,11 +14,10 @@
* limitations under the License.
*/
-import { IUniverInstanceService, LocaleService } from '@univerjs/core';
+import { IUniverInstanceService, LocaleService, useDependency, useInjector } from '@univerjs/core';
import { Popup } from '@univerjs/design';
import type { IFunctionInfo, IFunctionParam } from '@univerjs/engine-formula';
import { CloseSingle, DetailsSingle, MoreSingle } from '@univerjs/icons';
-import { useDependency, useInjector } from '@wendellhu/redi/react-bindings';
import React, { useEffect, useState } from 'react';
import { IEditorService, ISidebarService } from '@univerjs/ui';
diff --git a/packages/sheets-formula/src/views/prompt/search-function/SearchFunction.tsx b/packages/sheets-formula/src/views/prompt/search-function/SearchFunction.tsx
index 0f14b8e81b..fdbad092f8 100644
--- a/packages/sheets-formula/src/views/prompt/search-function/SearchFunction.tsx
+++ b/packages/sheets-formula/src/views/prompt/search-function/SearchFunction.tsx
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { Direction, IUniverInstanceService } from '@univerjs/core';
+import { Direction, IUniverInstanceService, useDependency } from '@univerjs/core';
import { Popup } from '@univerjs/design';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import React, { useEffect, useRef, useState } from 'react';
import { IEditorService } from '@univerjs/ui';
diff --git a/packages/sheets-hyper-link-ui/package.json b/packages/sheets-hyper-link-ui/package.json
index dfe1b897d4..9312bb7448 100644
--- a/packages/sheets-hyper-link-ui/package.json
+++ b/packages/sheets-hyper-link-ui/package.json
@@ -75,7 +75,6 @@
"@univerjs/sheets-hyper-link": "workspace:*",
"@univerjs/sheets-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": ">=2.0.0",
"react": "^16.9.0 || ^17.0.0 || ^18.0.0",
"rxjs": ">=7.0.0"
@@ -94,7 +93,6 @@
"@univerjs/sheets": "workspace:*",
"@univerjs/sheets-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": "^2.1.1",
"rxjs": "^7.8.1",
"typescript": "^5.5.3",
diff --git a/packages/sheets-hyper-link-ui/src/controllers/auto-fill.controller.ts b/packages/sheets-hyper-link-ui/src/controllers/auto-fill.controller.ts
index 71ee08284f..8a54fbbb81 100644
--- a/packages/sheets-hyper-link-ui/src/controllers/auto-fill.controller.ts
+++ b/packages/sheets-hyper-link-ui/src/controllers/auto-fill.controller.ts
@@ -15,11 +15,10 @@
*/
import type { IMutationInfo } from '@univerjs/core';
-import { Disposable, LifecycleStages, OnLifecycle, Range, Rectangle, Tools } from '@univerjs/core';
+import { Disposable, Inject, LifecycleStages, OnLifecycle, Range, Rectangle, Tools } from '@univerjs/core';
import { AddHyperLinkMutation, HyperLinkModel, RemoveHyperLinkMutation } from '@univerjs/sheets-hyper-link';
import type { IAutoFillLocation, ISheetAutoFillHook } from '@univerjs/sheets-ui';
import { APPLY_TYPE, getAutoFillRepeatRange, IAutoFillService, virtualizeDiscreteRanges } from '@univerjs/sheets-ui';
-import { Inject } from '@wendellhu/redi';
import { SHEET_HYPER_LINK_UI_PLUGIN } from '../types/const';
@OnLifecycle(LifecycleStages.Ready, SheetsHyperLinkAutoFillController)
diff --git a/packages/sheets-hyper-link-ui/src/controllers/copy-paste.controller.ts b/packages/sheets-hyper-link-ui/src/controllers/copy-paste.controller.ts
index b98bdadbde..8ad76b1380 100644
--- a/packages/sheets-hyper-link-ui/src/controllers/copy-paste.controller.ts
+++ b/packages/sheets-hyper-link-ui/src/controllers/copy-paste.controller.ts
@@ -15,11 +15,10 @@
*/
import type { IMutationInfo, IRange, Nullable } from '@univerjs/core';
-import { Disposable, LifecycleStages, ObjectMatrix, OnLifecycle, Range, Rectangle, Tools } from '@univerjs/core';
+import { Disposable, Inject, Injector, LifecycleStages, ObjectMatrix, OnLifecycle, Range, Rectangle, Tools } from '@univerjs/core';
import { AddHyperLinkMutation, HyperLinkModel, RemoveHyperLinkMutation } from '@univerjs/sheets-hyper-link';
import type { IDiscreteRange, ISheetDiscreteRangeLocation } from '@univerjs/sheets-ui';
import { COPY_TYPE, getRepeatRange, ISheetClipboardService, PREDEFINED_HOOK_NAME, rangeToDiscreteRange, virtualizeDiscreteRanges } from '@univerjs/sheets-ui';
-import { Inject, Injector } from '@wendellhu/redi';
import { SHEET_HYPER_LINK_UI_PLUGIN } from '../types/const';
import { isLegalLink, serializeUrl } from '../common/util';
import { SheetsHyperLinkResolverService } from '../services/resolver.service';
diff --git a/packages/sheets-hyper-link-ui/src/controllers/hyper-link-permission.controller.ts b/packages/sheets-hyper-link-ui/src/controllers/hyper-link-permission.controller.ts
index 11e95ecc52..e41436319e 100644
--- a/packages/sheets-hyper-link-ui/src/controllers/hyper-link-permission.controller.ts
+++ b/packages/sheets-hyper-link-ui/src/controllers/hyper-link-permission.controller.ts
@@ -15,9 +15,8 @@
*/
import type { ICommandInfo } from '@univerjs/core';
-import { Disposable, ICommandService, LifecycleStages, LocaleService, OnLifecycle } from '@univerjs/core';
+import { Disposable, ICommandService, Inject, LifecycleStages, LocaleService, OnLifecycle } from '@univerjs/core';
import { SheetPermissionInterceptorBaseController } from '@univerjs/sheets-ui';
-import { Inject } from '@wendellhu/redi';
import { RangeProtectionPermissionEditPoint, WorkbookEditablePermission, WorksheetEditPermission, WorksheetInsertHyperlinkPermission, WorksheetSetCellValuePermission } from '@univerjs/sheets';
import { InsertLinkShortcut } from './menu';
diff --git a/packages/sheets-hyper-link-ui/src/controllers/menu.ts b/packages/sheets-hyper-link-ui/src/controllers/menu.ts
index 01e33df1c5..124067d6a1 100644
--- a/packages/sheets-hyper-link-ui/src/controllers/menu.ts
+++ b/packages/sheets-hyper-link-ui/src/controllers/menu.ts
@@ -17,7 +17,7 @@
import { UniverInstanceType } from '@univerjs/core';
import type { IMenuItem, IShortcutItem } from '@univerjs/ui';
import { getMenuHiddenObservable, KeyCode, MenuGroup, MenuItemType, MenuPosition, MetaKeys } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor } from '@univerjs/core';
import { getCurrentRangeDisable$, whenSheetEditorFocused } from '@univerjs/sheets-ui';
import { RangeProtectionPermissionEditPoint, WorkbookEditablePermission, WorksheetEditPermission, WorksheetInsertHyperlinkPermission, WorksheetSetCellValuePermission } from '@univerjs/sheets';
import { InsertHyperLinkOperation, InsertHyperLinkToolbarOperation } from '../commands/operations/sidebar.operations';
diff --git a/packages/sheets-hyper-link-ui/src/controllers/popup.controller.ts b/packages/sheets-hyper-link-ui/src/controllers/popup.controller.ts
index 1e2b21a7c5..153f01a004 100644
--- a/packages/sheets-hyper-link-ui/src/controllers/popup.controller.ts
+++ b/packages/sheets-hyper-link-ui/src/controllers/popup.controller.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { Disposable, IPermissionService, LifecycleStages, OnLifecycle, Rectangle } from '@univerjs/core';
+import { Disposable, Inject, IPermissionService, LifecycleStages, OnLifecycle, Rectangle } from '@univerjs/core';
import { HoverManagerService, SheetPermissionInterceptorBaseController, SheetSkeletonManagerService } from '@univerjs/sheets-ui';
-import { Inject } from '@wendellhu/redi';
import { debounceTime } from 'rxjs';
import { IRenderManagerService } from '@univerjs/engine-render';
import { RangeProtectionPermissionEditPoint, RangeProtectionPermissionViewPoint, WorkbookCopyPermission, WorkbookEditablePermission, WorkbookViewPermission, WorksheetCopyPermission, WorksheetEditPermission, WorksheetInsertHyperlinkPermission, WorksheetViewPermission } from '@univerjs/sheets';
diff --git a/packages/sheets-hyper-link-ui/src/controllers/remove-sheet.controller.ts b/packages/sheets-hyper-link-ui/src/controllers/remove-sheet.controller.ts
index e17c764d3f..6db71892e3 100644
--- a/packages/sheets-hyper-link-ui/src/controllers/remove-sheet.controller.ts
+++ b/packages/sheets-hyper-link-ui/src/controllers/remove-sheet.controller.ts
@@ -15,10 +15,9 @@
*/
import type { Workbook } from '@univerjs/core';
-import { Disposable, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
+import { Disposable, Inject, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import type { IRemoveSheetCommandParams } from '@univerjs/sheets';
import { RemoveSheetCommand, SheetInterceptorService } from '@univerjs/sheets';
-import { Inject } from '@wendellhu/redi';
import { AddHyperLinkMutation, HyperLinkModel, RemoveHyperLinkMutation } from '@univerjs/sheets-hyper-link';
@OnLifecycle(LifecycleStages.Ready, SheetsHyperLinkRemoveSheetController)
diff --git a/packages/sheets-hyper-link-ui/src/controllers/render-controllers/render.controller.ts b/packages/sheets-hyper-link-ui/src/controllers/render-controllers/render.controller.ts
index c36f6b830c..978102783e 100644
--- a/packages/sheets-hyper-link-ui/src/controllers/render-controllers/render.controller.ts
+++ b/packages/sheets-hyper-link-ui/src/controllers/render-controllers/render.controller.ts
@@ -15,9 +15,8 @@
*/
import type { Workbook } from '@univerjs/core';
-import { BooleanNumber, Disposable, LifecycleStages, OnLifecycle, ThemeService } from '@univerjs/core';
+import { BooleanNumber, Disposable, Inject, LifecycleStages, OnLifecycle, ThemeService } from '@univerjs/core';
import { INTERCEPTOR_POINT, SheetInterceptorService } from '@univerjs/sheets';
-import { Inject } from '@wendellhu/redi';
import { SheetSkeletonManagerService } from '@univerjs/sheets-ui';
import type { IRenderContext, IRenderModule, Spreadsheet } from '@univerjs/engine-render';
import { IRenderManagerService } from '@univerjs/engine-render';
diff --git a/packages/sheets-hyper-link-ui/src/controllers/set-range.controller.ts b/packages/sheets-hyper-link-ui/src/controllers/set-range.controller.ts
index 43afb4df86..dfb6b4f99e 100644
--- a/packages/sheets-hyper-link-ui/src/controllers/set-range.controller.ts
+++ b/packages/sheets-hyper-link-ui/src/controllers/set-range.controller.ts
@@ -15,8 +15,7 @@
*/
import type { IMutationInfo, Workbook } from '@univerjs/core';
-import { CellValueType, CustomRangeType, Disposable, IUniverInstanceService, LifecycleStages, ObjectMatrix, OnLifecycle, Range, Tools, UniverInstanceType } from '@univerjs/core';
-import { Inject, Injector } from '@wendellhu/redi';
+import { CellValueType, CustomRangeType, Disposable, Inject, Injector, IUniverInstanceService, LifecycleStages, ObjectMatrix, OnLifecycle, Range, Tools, UniverInstanceType } from '@univerjs/core';
import type { ISetRangeValuesMutationParams } from '@univerjs/sheets';
import { ClearSelectionAllCommand, ClearSelectionContentCommand, ClearSelectionFormatCommand, getSheetCommandTarget, SetRangeValuesCommand, SetRangeValuesMutation, SetRangeValuesUndoMutationFactory, SheetInterceptorService, SheetsSelectionsService } from '@univerjs/sheets';
import type { IAddHyperLinkCommandParams, IUpdateHyperLinkCommandParams } from '@univerjs/sheets-hyper-link';
diff --git a/packages/sheets-hyper-link-ui/src/controllers/ui.controller.ts b/packages/sheets-hyper-link-ui/src/controllers/ui.controller.ts
index ca5811b04b..6a40404a4e 100644
--- a/packages/sheets-hyper-link-ui/src/controllers/ui.controller.ts
+++ b/packages/sheets-hyper-link-ui/src/controllers/ui.controller.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { Disposable, ICommandService, LifecycleStages, LocaleService, OnLifecycle } from '@univerjs/core';
+import { Disposable, ICommandService, Inject, Injector, LifecycleStages, LocaleService, OnLifecycle } from '@univerjs/core';
import type { MenuConfig } from '@univerjs/ui';
import { ComponentManager, IMenuService, IShortcutService } from '@univerjs/ui';
-import { Inject, Injector } from '@wendellhu/redi';
import { LinkSingle } from '@univerjs/icons';
import { CellLinkPopup } from '../views/CellLinkPopup';
import { CellLinkEdit } from '../views/CellLinkEdit';
diff --git a/packages/sheets-hyper-link-ui/src/controllers/url.controller.ts b/packages/sheets-hyper-link-ui/src/controllers/url.controller.ts
index 98624d2f0b..41f65c3a39 100644
--- a/packages/sheets-hyper-link-ui/src/controllers/url.controller.ts
+++ b/packages/sheets-hyper-link-ui/src/controllers/url.controller.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { Disposable, LifecycleStages, OnLifecycle } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { Disposable, Inject, LifecycleStages, OnLifecycle } from '@univerjs/core';
import { SheetsHyperLinkResolverService } from '../services/resolver.service';
@OnLifecycle(LifecycleStages.Rendered, SheetHyperLinkUrlController)
diff --git a/packages/sheets-hyper-link-ui/src/plugin.ts b/packages/sheets-hyper-link-ui/src/plugin.ts
index fd97e01cee..db1acdd738 100644
--- a/packages/sheets-hyper-link-ui/src/plugin.ts
+++ b/packages/sheets-hyper-link-ui/src/plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
-import { DependentOn, Plugin, UniverInstanceType } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
+import { DependentOn, Inject, Injector, Plugin, UniverInstanceType } from '@univerjs/core';
import { UniverSheetsHyperLinkPlugin } from '@univerjs/sheets-hyper-link';
import { IRenderManagerService } from '@univerjs/engine-render';
import { SheetsHyperLinkRemoveSheetController } from './controllers/remove-sheet.controller';
diff --git a/packages/sheets-hyper-link-ui/src/services/popup.service.ts b/packages/sheets-hyper-link-ui/src/services/popup.service.ts
index e814cd0094..e3575f01e2 100644
--- a/packages/sheets-hyper-link-ui/src/services/popup.service.ts
+++ b/packages/sheets-hyper-link-ui/src/services/popup.service.ts
@@ -17,10 +17,9 @@
import type { ISheetLocationBase } from '@univerjs/sheets';
import { HyperLinkModel } from '@univerjs/sheets-hyper-link';
import { SheetCanvasPopManagerService } from '@univerjs/sheets-ui';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject } from '@wendellhu/redi';
+import type { IDisposable } from '@univerjs/core';
+import { Disposable, Inject } from '@univerjs/core';
import { BehaviorSubject, Subject } from 'rxjs';
-import { Disposable } from '@univerjs/core';
import { CellLinkPopup } from '../views/CellLinkPopup';
export interface IHyperLinkPopup {
diff --git a/packages/sheets-hyper-link-ui/src/services/resolver.service.ts b/packages/sheets-hyper-link-ui/src/services/resolver.service.ts
index 18a0b49a5b..5bdc068097 100644
--- a/packages/sheets-hyper-link-ui/src/services/resolver.service.ts
+++ b/packages/sheets-hyper-link-ui/src/services/resolver.service.ts
@@ -15,7 +15,7 @@
*/
import type { IRange, Workbook, Worksheet } from '@univerjs/core';
-import { ICommandService, isValidRange, IUniverInstanceService, LocaleService, RANGE_TYPE, Rectangle, UniverInstanceType } from '@univerjs/core';
+import { ICommandService, Inject, isValidRange, IUniverInstanceService, LocaleService, RANGE_TYPE, Rectangle, UniverInstanceType } from '@univerjs/core';
import { MessageType } from '@univerjs/design';
import { deserializeRangeWithSheet, IDefinedNamesService, serializeRangeWithSheet } from '@univerjs/engine-formula';
import type { ISetSelectionsOperationParams } from '@univerjs/sheets';
@@ -23,7 +23,6 @@ import { SetSelectionsOperation, SetWorksheetActiveOperation } from '@univerjs/s
import { ERROR_RANGE } from '@univerjs/sheets-hyper-link';
import { ScrollToRangeOperation } from '@univerjs/sheets-ui';
import { IMessageService } from '@univerjs/ui';
-import { Inject } from '@wendellhu/redi';
interface ISheetUrlParams {
gid?: string;
diff --git a/packages/sheets-hyper-link-ui/src/views/CellLinkEdit/index.tsx b/packages/sheets-hyper-link-ui/src/views/CellLinkEdit/index.tsx
index dd667071a4..6b5b092e8f 100644
--- a/packages/sheets-hyper-link-ui/src/views/CellLinkEdit/index.tsx
+++ b/packages/sheets-hyper-link-ui/src/views/CellLinkEdit/index.tsx
@@ -16,9 +16,8 @@
import React, { useEffect, useMemo, useRef, useState } from 'react';
import { Button, FormLayout, Input, Select } from '@univerjs/design';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { createInternalEditorID, ICommandService, isValidRange, IUniverInstanceService, LocaleService, Tools, UniverInstanceType, useDependency } from '@univerjs/core';
import type { IUnitRangeWithName, Workbook } from '@univerjs/core';
-import { createInternalEditorID, ICommandService, isValidRange, IUniverInstanceService, LocaleService, Tools, UniverInstanceType } from '@univerjs/core';
import { RangeSelector, useEvent, useObservable } from '@univerjs/ui';
import { deserializeRangeWithSheet, IDefinedNamesService, serializeRange, serializeRangeToRefString, serializeRangeWithSheet } from '@univerjs/engine-formula';
import { AddHyperLinkCommand, ERROR_RANGE, HyperLinkModel, UpdateHyperLinkCommand } from '@univerjs/sheets-hyper-link';
diff --git a/packages/sheets-hyper-link-ui/src/views/CellLinkPopup/index.tsx b/packages/sheets-hyper-link-ui/src/views/CellLinkPopup/index.tsx
index 3cc53694c5..64a46ba34d 100644
--- a/packages/sheets-hyper-link-ui/src/views/CellLinkPopup/index.tsx
+++ b/packages/sheets-hyper-link-ui/src/views/CellLinkPopup/index.tsx
@@ -14,11 +14,10 @@
* limitations under the License.
*/
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { ICommandService, LocaleService, useDependency } from '@univerjs/core';
import { CancelHyperLinkCommand, HyperLinkModel } from '@univerjs/sheets-hyper-link';
import React, { useEffect, useState } from 'react';
import { AllBorderSingle, CopySingle, LinkSingle, UnlinkSingle, WriteSingle, Xlsx } from '@univerjs/icons';
-import { ICommandService, LocaleService } from '@univerjs/core';
import cs from 'clsx';
import { MessageType, Tooltip } from '@univerjs/design';
import { IMessageService } from '@univerjs/ui';
diff --git a/packages/sheets-hyper-link/package.json b/packages/sheets-hyper-link/package.json
index 2e54105757..fde6c19b53 100644
--- a/packages/sheets-hyper-link/package.json
+++ b/packages/sheets-hyper-link/package.json
@@ -62,7 +62,6 @@
"@univerjs/engine-formula": "workspace:*",
"@univerjs/sheets": "workspace:*",
"@univerjs/sheets-hyper-link": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": ">=7.0.0"
},
"devDependencies": {
@@ -71,7 +70,6 @@
"@univerjs/protocol": "0.1.38-alpha.23",
"@univerjs/shared": "workspace:*",
"@univerjs/sheets": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": "^7.8.1",
"typescript": "^5.5.3",
"vite": "^5.3.4",
diff --git a/packages/sheets-hyper-link/src/controllers/ref-range.controller.ts b/packages/sheets-hyper-link/src/controllers/ref-range.controller.ts
index b7927cea67..94a1976feb 100644
--- a/packages/sheets-hyper-link/src/controllers/ref-range.controller.ts
+++ b/packages/sheets-hyper-link/src/controllers/ref-range.controller.ts
@@ -14,14 +14,12 @@
* limitations under the License.
*/
-import type { IRange, Nullable } from '@univerjs/core';
-import { Disposable, ICommandService, isValidRange, LifecycleStages, OnLifecycle, sequenceExecuteAsync, toDisposable } from '@univerjs/core';
+import type { IDisposable, IRange, Nullable } from '@univerjs/core';
+import { Disposable, ICommandService, Inject, isValidRange, LifecycleStages, OnLifecycle, sequenceExecuteAsync, toDisposable } from '@univerjs/core';
import type { EffectRefRangeParams } from '@univerjs/sheets';
import { handleDefaultRangeChangeWithEffectRefCommandsSkipNoInterests, RefRangeService, SheetsSelectionsService } from '@univerjs/sheets';
import type { IAddHyperLinkMutationParams, ICellHyperLink, IRemoveHyperLinkMutationParams, IUpdateHyperLinkMutationParams, IUpdateHyperLinkRefMutationParams } from '@univerjs/sheets-hyper-link';
import { AddHyperLinkMutation, HyperLinkModel, RemoveHyperLinkMutation, UpdateHyperLinkMutation, UpdateHyperLinkRefMutation } from '@univerjs/sheets-hyper-link';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject } from '@wendellhu/redi';
import { deserializeRangeWithSheet, serializeRange } from '@univerjs/engine-formula';
import { ERROR_RANGE } from '../types/const';
diff --git a/packages/sheets-hyper-link/src/controllers/sheet-hyper-link-resource.controller.ts b/packages/sheets-hyper-link/src/controllers/sheet-hyper-link-resource.controller.ts
index b37c447154..0ba555216b 100644
--- a/packages/sheets-hyper-link/src/controllers/sheet-hyper-link-resource.controller.ts
+++ b/packages/sheets-hyper-link/src/controllers/sheet-hyper-link-resource.controller.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { Disposable, IResourceManagerService, LifecycleStages, OnLifecycle } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { Disposable, Inject, IResourceManagerService, LifecycleStages, OnLifecycle } from '@univerjs/core';
import { UniverType } from '@univerjs/protocol';
import { HyperLinkModel } from '../models/hyper-link.model';
import type { ICellHyperLink } from '../types/interfaces/i-hyper-link';
diff --git a/packages/sheets-hyper-link/src/plugin.ts b/packages/sheets-hyper-link/src/plugin.ts
index 701576b015..dda7defa86 100644
--- a/packages/sheets-hyper-link/src/plugin.ts
+++ b/packages/sheets-hyper-link/src/plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { DependentOn, Plugin, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { DependentOn, Inject, Injector, Plugin, UniverInstanceType } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
import { UniverSheetsPlugin } from '@univerjs/sheets';
import { SheetsHyperLinkController } from './controllers/sheet-hyper-link.controller';
import { HyperLinkModel } from './models/hyper-link.model';
diff --git a/packages/sheets-numfmt/package.json b/packages/sheets-numfmt/package.json
index 738c44a98e..28f0e5d192 100644
--- a/packages/sheets-numfmt/package.json
+++ b/packages/sheets-numfmt/package.json
@@ -72,7 +72,6 @@
"@univerjs/sheets": "workspace:*",
"@univerjs/sheets-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"react": "^16.9.0 || ^17.0.0 || ^18.0.0",
"rxjs": ">=7.0.0"
},
@@ -90,7 +89,6 @@
"@univerjs/sheets": "workspace:*",
"@univerjs/sheets-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"less": "^4.2.0",
"react": "18.3.1",
"rxjs": "^7.8.1",
diff --git a/packages/sheets-numfmt/src/commands/commands/add-decimal.command.ts b/packages/sheets-numfmt/src/commands/commands/add-decimal.command.ts
index 11bf6e73b1..92c12d04ce 100644
--- a/packages/sheets-numfmt/src/commands/commands/add-decimal.command.ts
+++ b/packages/sheets-numfmt/src/commands/commands/add-decimal.command.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType, ICommandService, IUniverInstanceService, Range } from '@univerjs/core';
import { getSheetCommandTarget, INumfmtService, SheetsSelectionsService } from '@univerjs/sheets';
-import type { IAccessor } from '@wendellhu/redi';
import { getDecimalFromPattern, setPatternDecimal } from '../../utils/decimal';
import type { ISetNumfmtCommandParams } from './set-numfmt.command';
diff --git a/packages/sheets-numfmt/src/commands/commands/set-currency.command.ts b/packages/sheets-numfmt/src/commands/commands/set-currency.command.ts
index 25d68662d1..4fc9f84e7c 100644
--- a/packages/sheets-numfmt/src/commands/commands/set-currency.command.ts
+++ b/packages/sheets-numfmt/src/commands/commands/set-currency.command.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType, ICommandService, Range } from '@univerjs/core';
import { SheetsSelectionsService } from '@univerjs/sheets';
-import type { IAccessor } from '@wendellhu/redi';
import { CURRENCYFORMAT } from '../../base/const/FORMATDETAIL';
import type { ISetNumfmtCommandParams } from './set-numfmt.command';
diff --git a/packages/sheets-numfmt/src/commands/commands/set-numfmt.command.ts b/packages/sheets-numfmt/src/commands/commands/set-numfmt.command.ts
index 6d250b005c..1c4f8ebbe6 100644
--- a/packages/sheets-numfmt/src/commands/commands/set-numfmt.command.ts
+++ b/packages/sheets-numfmt/src/commands/commands/set-numfmt.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICommand, IMutationInfo } from '@univerjs/core';
+import type { IAccessor, ICommand, IMutationInfo } from '@univerjs/core';
import {
CommandType,
ICommandService,
@@ -37,7 +37,6 @@ import {
SetNumfmtMutation,
transformCellsToRange,
} from '@univerjs/sheets';
-import type { IAccessor } from '@wendellhu/redi';
export interface ISetNumfmtCommandParams {
unitId?: string;
diff --git a/packages/sheets-numfmt/src/commands/commands/set-percent.command.ts b/packages/sheets-numfmt/src/commands/commands/set-percent.command.ts
index 814f4dae83..17d6ecf3ea 100644
--- a/packages/sheets-numfmt/src/commands/commands/set-percent.command.ts
+++ b/packages/sheets-numfmt/src/commands/commands/set-percent.command.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType, ICommandService, Range } from '@univerjs/core';
import { SheetsSelectionsService } from '@univerjs/sheets';
-import type { IAccessor } from '@wendellhu/redi';
import type { ISetNumfmtCommandParams } from './set-numfmt.command';
import { SetNumfmtCommand } from './set-numfmt.command';
diff --git a/packages/sheets-numfmt/src/commands/commands/subtract-decimal.command.ts b/packages/sheets-numfmt/src/commands/commands/subtract-decimal.command.ts
index f0ab3b4352..325e3c5e6d 100644
--- a/packages/sheets-numfmt/src/commands/commands/subtract-decimal.command.ts
+++ b/packages/sheets-numfmt/src/commands/commands/subtract-decimal.command.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType, ICommandService, IUniverInstanceService, Range } from '@univerjs/core';
import { getSheetCommandTarget, INumfmtService, SheetsSelectionsService } from '@univerjs/sheets';
-import type { IAccessor } from '@wendellhu/redi';
import { getDecimalFromPattern, setPatternDecimal } from '../../utils/decimal';
import type { ISetNumfmtCommandParams } from './set-numfmt.command';
diff --git a/packages/sheets-numfmt/src/commands/operations/open.numfmt.panel.operation.ts b/packages/sheets-numfmt/src/commands/operations/open.numfmt.panel.operation.ts
index c1b65d2174..c301e6d9a2 100644
--- a/packages/sheets-numfmt/src/commands/operations/open.numfmt.panel.operation.ts
+++ b/packages/sheets-numfmt/src/commands/operations/open.numfmt.panel.operation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { INumfmtController } from '../../controllers/type';
diff --git a/packages/sheets-numfmt/src/components/accounting/index.tsx b/packages/sheets-numfmt/src/components/accounting/index.tsx
index 01ca450e3b..47a7f46667 100644
--- a/packages/sheets-numfmt/src/components/accounting/index.tsx
+++ b/packages/sheets-numfmt/src/components/accounting/index.tsx
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { LocaleService } from '@univerjs/core';
+import { LocaleService, useDependency } from '@univerjs/core';
import { InputNumber, Select } from '@univerjs/design';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import type { FC } from 'react';
import React, { useContext, useMemo, useState } from 'react';
diff --git a/packages/sheets-numfmt/src/components/currency/index.tsx b/packages/sheets-numfmt/src/components/currency/index.tsx
index 05dd7f1736..cf6ecf28aa 100644
--- a/packages/sheets-numfmt/src/components/currency/index.tsx
+++ b/packages/sheets-numfmt/src/components/currency/index.tsx
@@ -17,9 +17,8 @@
// FIXME: DO NOT USE GLOBAL STYLES
import './index.less';
-import { LocaleService } from '@univerjs/core';
+import { LocaleService, useDependency } from '@univerjs/core';
import { InputNumber, Select, SelectList } from '@univerjs/design';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import type { FC } from 'react';
import React, { useContext, useMemo, useState } from 'react';
diff --git a/packages/sheets-numfmt/src/components/date/index.tsx b/packages/sheets-numfmt/src/components/date/index.tsx
index ef037d86a9..d6d00b16d4 100644
--- a/packages/sheets-numfmt/src/components/date/index.tsx
+++ b/packages/sheets-numfmt/src/components/date/index.tsx
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { LocaleService } from '@univerjs/core';
+import { LocaleService, useDependency } from '@univerjs/core';
import { SelectList } from '@univerjs/design';
import { numfmt } from '@univerjs/engine-numfmt';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import type { FC } from 'react';
import React, { useMemo, useState } from 'react';
diff --git a/packages/sheets-numfmt/src/components/general/index.tsx b/packages/sheets-numfmt/src/components/general/index.tsx
index 0a53634a56..c89642ee5d 100644
--- a/packages/sheets-numfmt/src/components/general/index.tsx
+++ b/packages/sheets-numfmt/src/components/general/index.tsx
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { LocaleService } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { LocaleService, useDependency } from '@univerjs/core';
import type { FC } from 'react';
import React from 'react';
diff --git a/packages/sheets-numfmt/src/components/index.tsx b/packages/sheets-numfmt/src/components/index.tsx
index e8952cddd4..21815cde86 100644
--- a/packages/sheets-numfmt/src/components/index.tsx
+++ b/packages/sheets-numfmt/src/components/index.tsx
@@ -17,10 +17,9 @@
// FIXME: DO NOT USE GLOBAL STYLES
import './index.less';
-import { LocaleService } from '@univerjs/core';
+import { LocaleService, useDependency } from '@univerjs/core';
import type { ISelectProps } from '@univerjs/design';
import { Button, Select } from '@univerjs/design';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import type { FC } from 'react';
import React, { useEffect, useMemo, useRef, useState } from 'react';
diff --git a/packages/sheets-numfmt/src/components/more-numfmt-type/MoreNumfmtType.tsx b/packages/sheets-numfmt/src/components/more-numfmt-type/MoreNumfmtType.tsx
index 8c492158b6..194fcffb4a 100644
--- a/packages/sheets-numfmt/src/components/more-numfmt-type/MoreNumfmtType.tsx
+++ b/packages/sheets-numfmt/src/components/more-numfmt-type/MoreNumfmtType.tsx
@@ -17,11 +17,10 @@
// FIXME: DO NOT USE GLOBAL STYLES
import './index.less';
-import { ICommandService, LocaleService, Range } from '@univerjs/core';
+import { ICommandService, LocaleService, Range, useDependency, useInjector } from '@univerjs/core';
import { ITextSelectionRenderManager } from '@univerjs/engine-render';
import type { FormatType } from '@univerjs/sheets';
import { SheetsSelectionsService } from '@univerjs/sheets';
-import { useDependency, useInjector } from '@wendellhu/redi/react-bindings';
import React from 'react';
import { MENU_OPTIONS } from '../../base/const/MENU-OPTIONS';
diff --git a/packages/sheets-numfmt/src/components/stories/Panel.stories.tsx b/packages/sheets-numfmt/src/components/stories/Panel.stories.tsx
index 458640dd4d..d72928b30c 100644
--- a/packages/sheets-numfmt/src/components/stories/Panel.stories.tsx
+++ b/packages/sheets-numfmt/src/components/stories/Panel.stories.tsx
@@ -15,9 +15,8 @@
*/
import type { Meta, StoryObj } from '@storybook/react';
-import { LocaleService, LocaleType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { RediContext } from '@wendellhu/redi/react-bindings';
+import { LocaleService, LocaleType, RediContext } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
import React, { useContext, useState } from 'react';
import enUS from '../../locale/en-US';
import zhCN from '../../locale/zh-CN';
diff --git a/packages/sheets-numfmt/src/components/thousandth-percentile/index.tsx b/packages/sheets-numfmt/src/components/thousandth-percentile/index.tsx
index 45da9a41a3..6a87ecc488 100644
--- a/packages/sheets-numfmt/src/components/thousandth-percentile/index.tsx
+++ b/packages/sheets-numfmt/src/components/thousandth-percentile/index.tsx
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { LocaleService } from '@univerjs/core';
+import { LocaleService, useDependency } from '@univerjs/core';
import { InputNumber, SelectList } from '@univerjs/design';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import type { FC } from 'react';
import React, { useMemo, useState } from 'react';
diff --git a/packages/sheets-numfmt/src/controllers/__tests__/test.util.ts b/packages/sheets-numfmt/src/controllers/__tests__/test.util.ts
index 000f7a4fba..014d1626ea 100644
--- a/packages/sheets-numfmt/src/controllers/__tests__/test.util.ts
+++ b/packages/sheets-numfmt/src/controllers/__tests__/test.util.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-import type { IWorkbookData } from '@univerjs/core';
-import { ICommandService, IUniverInstanceService, LocaleType, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
+import type { Dependency, IWorkbookData } from '@univerjs/core';
+import { ICommandService, Inject, Injector, IUniverInstanceService, LocaleType, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
import { LexerTreeBuilder } from '@univerjs/engine-formula';
import {
INumfmtService,
@@ -25,8 +25,6 @@ import {
SheetInterceptorService,
} from '@univerjs/sheets';
import { SheetSkeletonManagerService } from '@univerjs/sheets-ui';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
const TEST_WORKBOOK_DATA_DEMO: () => IWorkbookData = () => ({
id: 'test',
diff --git a/packages/sheets-numfmt/src/controllers/numfmt.cell-content.controller.ts b/packages/sheets-numfmt/src/controllers/numfmt.cell-content.controller.ts
index f8c393e8ad..f49e8b6102 100644
--- a/packages/sheets-numfmt/src/controllers/numfmt.cell-content.controller.ts
+++ b/packages/sheets-numfmt/src/controllers/numfmt.cell-content.controller.ts
@@ -23,6 +23,7 @@ import {
CellValueType,
Disposable,
ICommandService,
+ Inject,
IUniverInstanceService,
LifecycleStages,
LocaleService,
@@ -34,7 +35,6 @@ import {
} from '@univerjs/core';
import type { ISetNumfmtMutationParams, ISetRangeValuesMutationParams } from '@univerjs/sheets';
import { INTERCEPTOR_POINT, INumfmtService, SetNumfmtMutation, SetRangeValuesMutation, SheetInterceptorService } from '@univerjs/sheets';
-import { Inject } from '@wendellhu/redi';
import { of, skip, switchMap } from 'rxjs';
import { getPatternPreview } from '../utils/pattern';
diff --git a/packages/sheets-numfmt/src/controllers/numfmt.controller.ts b/packages/sheets-numfmt/src/controllers/numfmt.controller.ts
index 9a95035049..769f87d4f5 100644
--- a/packages/sheets-numfmt/src/controllers/numfmt.controller.ts
+++ b/packages/sheets-numfmt/src/controllers/numfmt.controller.ts
@@ -14,12 +14,13 @@
* limitations under the License.
*/
-import type { IRange, Workbook } from '@univerjs/core';
+import type { IDisposable, IRange, Workbook } from '@univerjs/core';
import {
CellValueType,
Disposable,
DisposableCollection,
ICommandService,
+ Inject,
IUniverInstanceService,
LifecycleStages,
LocaleService,
@@ -40,8 +41,6 @@ import {
SheetsSelectionsService,
} from '@univerjs/sheets';
import { ComponentManager, ISidebarService } from '@univerjs/ui';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject } from '@wendellhu/redi';
import { combineLatest, Observable } from 'rxjs';
import { debounceTime, map, switchMap, tap } from 'rxjs/operators';
diff --git a/packages/sheets-numfmt/src/controllers/numfmt.editor.controller.ts b/packages/sheets-numfmt/src/controllers/numfmt.editor.controller.ts
index 9375e0c8c5..61865b20f0 100644
--- a/packages/sheets-numfmt/src/controllers/numfmt.editor.controller.ts
+++ b/packages/sheets-numfmt/src/controllers/numfmt.editor.controller.ts
@@ -18,9 +18,12 @@ import type { IRange, Nullable, Workbook } from '@univerjs/core';
import {
CellValueType,
Disposable,
+ Inject,
+ Injector,
IUniverInstanceService,
LifecycleStages,
OnLifecycle,
+ Optional,
toDisposable,
UniverInstanceType,
} from '@univerjs/core';
@@ -42,7 +45,6 @@ import {
transformCellsToRange,
} from '@univerjs/sheets';
import { IEditorBridgeService } from '@univerjs/sheets-ui';
-import { Inject, Injector, Optional } from '@wendellhu/redi';
import { getPatternType } from '../utils/pattern';
diff --git a/packages/sheets-numfmt/src/controllers/numfmt.i18n.controller.ts b/packages/sheets-numfmt/src/controllers/numfmt.i18n.controller.ts
index 889d34600f..7a8c9b5259 100644
--- a/packages/sheets-numfmt/src/controllers/numfmt.i18n.controller.ts
+++ b/packages/sheets-numfmt/src/controllers/numfmt.i18n.controller.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { Disposable, LifecycleStages, LocaleService, OnLifecycle } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { Disposable, Inject, LifecycleStages, LocaleService, OnLifecycle } from '@univerjs/core';
@OnLifecycle(LifecycleStages.Rendered, NumfmtI18nController)
export class NumfmtI18nController extends Disposable {
diff --git a/packages/sheets-numfmt/src/controllers/numfmt.menu.controller.ts b/packages/sheets-numfmt/src/controllers/numfmt.menu.controller.ts
index 0cf507a65d..0c7a8022d6 100644
--- a/packages/sheets-numfmt/src/controllers/numfmt.menu.controller.ts
+++ b/packages/sheets-numfmt/src/controllers/numfmt.menu.controller.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { Disposable, LifecycleStages, OnLifecycle } from '@univerjs/core';
+import { Disposable, Inject, Injector, LifecycleStages, OnLifecycle } from '@univerjs/core';
import type { MenuConfig } from '@univerjs/ui';
import { ComponentManager, IMenuService } from '@univerjs/ui';
-import { Inject, Injector } from '@wendellhu/redi';
import { AddDecimalMenuItem, CurrencyMenuItem, FactoryOtherMenuItem, PercentMenuItem, SubtractDecimalMenuItem } from '../menu/menu';
import { MORE_NUMFMT_TYPE_KEY, MoreNumfmtType, Options, OPTIONS_KEY } from '../components/more-numfmt-type/MoreNumfmtType';
diff --git a/packages/sheets-numfmt/src/controllers/type.ts b/packages/sheets-numfmt/src/controllers/type.ts
index 00d740386b..6efe9b9d88 100644
--- a/packages/sheets-numfmt/src/controllers/type.ts
+++ b/packages/sheets-numfmt/src/controllers/type.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { LifecycleStages, runOnLifecycle } from '@univerjs/core';
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier, LifecycleStages, runOnLifecycle } from '@univerjs/core';
export interface INumfmtController {
openPanel(): void;
diff --git a/packages/sheets-numfmt/src/controllers/user-habit.controller.ts b/packages/sheets-numfmt/src/controllers/user-habit.controller.ts
index e9caf20f22..ed0184ea5b 100644
--- a/packages/sheets-numfmt/src/controllers/user-habit.controller.ts
+++ b/packages/sheets-numfmt/src/controllers/user-habit.controller.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { ILocalStorageService } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { ILocalStorageService, Inject } from '@univerjs/core';
type HabitValue = string | number;
interface IUserHabitController {
diff --git a/packages/sheets-numfmt/src/hooks/useCurrencyOptions.ts b/packages/sheets-numfmt/src/hooks/useCurrencyOptions.ts
index 9a24030baf..85f260d46c 100644
--- a/packages/sheets-numfmt/src/hooks/useCurrencyOptions.ts
+++ b/packages/sheets-numfmt/src/hooks/useCurrencyOptions.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { useDependency } from '@univerjs/core';
import { useEffect, useState } from 'react';
import { currencySymbols } from '../base/const/CURRENCY-SYMBOLS';
diff --git a/packages/sheets-numfmt/src/menu/menu.ts b/packages/sheets-numfmt/src/menu/menu.ts
index 6446c3f23b..27540302c4 100644
--- a/packages/sheets-numfmt/src/menu/menu.ts
+++ b/packages/sheets-numfmt/src/menu/menu.ts
@@ -27,7 +27,7 @@ import {
} from '@univerjs/sheets';
import type { IMenuSelectorItem } from '@univerjs/ui';
import { getMenuHiddenObservable, MenuGroup, MenuItemType, MenuPosition } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor } from '@univerjs/core';
import { merge, Observable } from 'rxjs';
import { deriveStateFromActiveSheet$, getCurrentRangeDisable$ } from '@univerjs/sheets-ui';
diff --git a/packages/sheets-numfmt/src/numfmt-plugin.ts b/packages/sheets-numfmt/src/numfmt-plugin.ts
index beeef0d036..86eb68fdb8 100644
--- a/packages/sheets-numfmt/src/numfmt-plugin.ts
+++ b/packages/sheets-numfmt/src/numfmt-plugin.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { DependentOn, Plugin, Tools, UniverInstanceType } from '@univerjs/core';
-import { Inject, Injector } from '@wendellhu/redi';
+import { DependentOn, Inject, Injector, Plugin, Tools, UniverInstanceType } from '@univerjs/core';
import { UniverSheetsPlugin } from '@univerjs/sheets';
import { UniverSheetsUIPlugin } from '@univerjs/sheets-ui';
diff --git a/packages/sheets-sort-ui/package.json b/packages/sheets-sort-ui/package.json
index 8331354d14..6949f18ca9 100644
--- a/packages/sheets-sort-ui/package.json
+++ b/packages/sheets-sort-ui/package.json
@@ -69,7 +69,6 @@
"@univerjs/sheets-sort": "workspace:*",
"@univerjs/sheets-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"react": "^16.9.0 || ^17.0.0 || ^18.0.0",
"rxjs": ">=7.0.0"
},
@@ -86,7 +85,6 @@
"@univerjs/sheets-sort": "workspace:*",
"@univerjs/sheets-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": "^2.1.1",
"less": "^4.2.0",
"react": "18.3.1",
diff --git a/packages/sheets-sort-ui/src/commands/commands/sheets-sort.command.ts b/packages/sheets-sort-ui/src/commands/commands/sheets-sort.command.ts
index 95d22630a9..c8cbb8af42 100644
--- a/packages/sheets-sort-ui/src/commands/commands/sheets-sort.command.ts
+++ b/packages/sheets-sort-ui/src/commands/commands/sheets-sort.command.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-import { CommandType, type ICommand } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor, ICommand } from '@univerjs/core';
+import { CommandType } from '@univerjs/core';
import { SheetsSortUIService } from './../../services/sheets-sort-ui.service';
export const SortRangeAscCommand: ICommand = {
diff --git a/packages/sheets-sort-ui/src/controllers/sheets-sort-ui.controller.ts b/packages/sheets-sort-ui/src/controllers/sheets-sort-ui.controller.ts
index b460df940b..028191cb45 100644
--- a/packages/sheets-sort-ui/src/controllers/sheets-sort-ui.controller.ts
+++ b/packages/sheets-sort-ui/src/controllers/sheets-sort-ui.controller.ts
@@ -14,15 +14,13 @@
* limitations under the License.
*/
-import { ICommandService, LifecycleStages, LocaleService, OnLifecycle, RxDisposable } from '@univerjs/core';
+import { connectInjector, ICommandService, Inject, Injector, LifecycleStages, LocaleService, OnLifecycle, RxDisposable } from '@univerjs/core';
-import { Inject, Injector } from '@wendellhu/redi';
import type { MenuConfig, UIPartsService } from '@univerjs/ui';
import { ComponentManager, IDialogService, ILayoutService, IMenuService, IUIPartsService } from '@univerjs/ui';
import { takeUntil } from 'rxjs';
import { serializeRange } from '@univerjs/engine-formula';
import { AscendingSingle, CustomSortSingle, DescendingSingle, ExpandAscendingSingle, ExpandDescendingSingle } from '@univerjs/icons';
-import { connectInjector } from '@wendellhu/redi/react-bindings';
import { SheetsRenderService, SheetsUIPart } from '@univerjs/sheets-ui';
import { SortRangeCommand } from '@univerjs/sheets-sort';
import { SortRangeAscCommand, SortRangeAscExtCommand, SortRangeAscExtInCtxMenuCommand, SortRangeAscInCtxMenuCommand, SortRangeCustomCommand, SortRangeCustomInCtxMenuCommand, SortRangeDescCommand, SortRangeDescExtCommand, SortRangeDescExtInCtxMenuCommand, SortRangeDescInCtxMenuCommand } from '../commands/commands/sheets-sort.command';
diff --git a/packages/sheets-sort-ui/src/controllers/sheets-sort.menu.ts b/packages/sheets-sort-ui/src/controllers/sheets-sort.menu.ts
index 9ca0dc1d7f..81e7020c16 100644
--- a/packages/sheets-sort-ui/src/controllers/sheets-sort.menu.ts
+++ b/packages/sheets-sort-ui/src/controllers/sheets-sort.menu.ts
@@ -16,7 +16,7 @@
import { UniverInstanceType } from '@univerjs/core';
import { getMenuHiddenObservable, type IMenuItem, MenuGroup, MenuItemType, MenuPosition } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor } from '@univerjs/core';
import { getCurrentRangeDisable$, SheetMenuPosition } from '@univerjs/sheets-ui';
import { RangeProtectionPermissionEditPoint, WorkbookEditablePermission, WorksheetEditPermission, WorksheetSortPermission } from '@univerjs/sheets';
import { SortRangeAscCommand, SortRangeAscExtCommand, SortRangeAscExtInCtxMenuCommand, SortRangeAscInCtxMenuCommand, SortRangeCustomCommand, SortRangeCustomInCtxMenuCommand, SortRangeDescCommand, SortRangeDescExtCommand, SortRangeDescExtInCtxMenuCommand, SortRangeDescInCtxMenuCommand } from '../commands/commands/sheets-sort.command';
diff --git a/packages/sheets-sort-ui/src/plugin.ts b/packages/sheets-sort-ui/src/plugin.ts
index 65f684a313..37a707e23c 100644
--- a/packages/sheets-sort-ui/src/plugin.ts
+++ b/packages/sheets-sort-ui/src/plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { DependentOn, LocaleService, Plugin, Tools, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { DependentOn, Inject, Injector, LocaleService, Plugin, Tools, UniverInstanceType } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
import { UniverSheetsSortPlugin } from '@univerjs/sheets-sort';
import { SheetsSortUIService } from './services/sheets-sort-ui.service';
diff --git a/packages/sheets-sort-ui/src/services/sheets-sort-ui.service.tsx b/packages/sheets-sort-ui/src/services/sheets-sort-ui.service.tsx
index 95559cda9d..38dac303d1 100644
--- a/packages/sheets-sort-ui/src/services/sheets-sort-ui.service.tsx
+++ b/packages/sheets-sort-ui/src/services/sheets-sort-ui.service.tsx
@@ -15,8 +15,11 @@
*/
import type { IRange, Nullable, Workbook, Worksheet } from '@univerjs/core';
-import { Disposable, ICommandService,
+import {
+ Disposable,
+ ICommandService,
ILogService,
+ Inject,
IUniverInstanceService,
LifecycleStages,
LocaleService,
@@ -28,7 +31,6 @@ import { Disposable, ICommandService,
import { getPrimaryForRange, SetSelectionsOperation, SheetsSelectionsService } from '@univerjs/sheets';
import type { ISheetRangeLocation } from '@univerjs/sheets';
-import { Inject } from '@wendellhu/redi';
import { expandToContinuousRange } from '@univerjs/sheets-ui';
import type { ISortOption } from '@univerjs/sheets-sort';
diff --git a/packages/sheets-sort-ui/src/views/CustomSortPanel.tsx b/packages/sheets-sort-ui/src/views/CustomSortPanel.tsx
index f9ca49cece..9a16be4160 100644
--- a/packages/sheets-sort-ui/src/views/CustomSortPanel.tsx
+++ b/packages/sheets-sort-ui/src/views/CustomSortPanel.tsx
@@ -15,11 +15,10 @@
*/
import type { IRange, Nullable } from '@univerjs/core';
-import { LocaleService, LocaleType, throttle } from '@univerjs/core';
+import { LocaleService, LocaleType, throttle, useDependency } from '@univerjs/core';
import React, { useCallback, useEffect, useRef, useState } from 'react';
import { type IOrderRule, SheetsSortService, SortType } from '@univerjs/sheets-sort';
import { Button, Checkbox, DraggableList, Dropdown, Radio, RadioGroup } from '@univerjs/design';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import { CheckMarkSingle, DeleteEmptySingle, IncreaseSingle, MoreDownSingle, SequenceSingle } from '@univerjs/icons';
import { SheetsSortUIService } from '../services/sheets-sort-ui.service';
diff --git a/packages/sheets-sort-ui/src/views/EmbedSortBtn.tsx b/packages/sheets-sort-ui/src/views/EmbedSortBtn.tsx
index 1bccae9e4f..50682f6982 100644
--- a/packages/sheets-sort-ui/src/views/EmbedSortBtn.tsx
+++ b/packages/sheets-sort-ui/src/views/EmbedSortBtn.tsx
@@ -16,7 +16,7 @@
import React, { useCallback } from 'react';
import { type IRange, IUniverInstanceService, LocaleService } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { useDependency } from '@univerjs/core';
import { getSheetCommandTarget } from '@univerjs/sheets';
import { AscendingSingle, DescendingSingle } from '@univerjs/icons';
import { SheetsSortUIService } from '../services/sheets-sort-ui.service';
diff --git a/packages/sheets-sort-ui/src/views/ExtendConfirm.tsx b/packages/sheets-sort-ui/src/views/ExtendConfirm.tsx
index 156aecbce8..f957651245 100644
--- a/packages/sheets-sort-ui/src/views/ExtendConfirm.tsx
+++ b/packages/sheets-sort-ui/src/views/ExtendConfirm.tsx
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { LocaleService } from '@univerjs/core';
+import { LocaleService, useDependency } from '@univerjs/core';
import { Radio, RadioGroup } from '@univerjs/design';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import React, { useState } from 'react';
import styles from './index.module.less';
diff --git a/packages/sheets-sort/package.json b/packages/sheets-sort/package.json
index ba20386af7..4950d5f443 100644
--- a/packages/sheets-sort/package.json
+++ b/packages/sheets-sort/package.json
@@ -61,15 +61,13 @@
"peerDependencies": {
"@univerjs/core": "workspace:*",
"@univerjs/engine-formula": "workspace:*",
- "@univerjs/sheets": "workspace:*",
- "@wendellhu/redi": "0.16.0"
+ "@univerjs/sheets": "workspace:*"
},
"devDependencies": {
"@univerjs/core": "workspace:*",
"@univerjs/engine-formula": "workspace:*",
"@univerjs/shared": "workspace:*",
"@univerjs/sheets": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": "^7.8.1",
"typescript": "^5.5.3",
"vite": "^5.3.4",
diff --git a/packages/sheets-sort/src/commands/commands/__tests__/create-command-test-bed.ts b/packages/sheets-sort/src/commands/commands/__tests__/create-command-test-bed.ts
index 950d9cfbd7..8d6575608d 100644
--- a/packages/sheets-sort/src/commands/commands/__tests__/create-command-test-bed.ts
+++ b/packages/sheets-sort/src/commands/commands/__tests__/create-command-test-bed.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { BooleanNumber, ILogService, IUniverInstanceService, type IWorkbookData, LocaleService, LocaleType, LogLevel, Plugin, Tools, Univer, UniverInstanceType, type Workbook } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import type { Dependency, IWorkbookData, Workbook } from '@univerjs/core';
+import { BooleanNumber, ILogService, Inject, Injector, IUniverInstanceService, LocaleService, LocaleType, LogLevel, Plugin, Tools, Univer, UniverInstanceType } from '@univerjs/core';
import { SheetInterceptorService, SheetsSelectionsService } from '@univerjs/sheets';
import { FormulaDataModel } from '@univerjs/engine-formula';
import enUS from '../../../locale/en-US';
diff --git a/packages/sheets-sort/src/commands/commands/__tests__/sheets-reorder.command.spec.ts b/packages/sheets-sort/src/commands/commands/__tests__/sheets-reorder.command.spec.ts
index 6efadeff03..50aad32359 100644
--- a/packages/sheets-sort/src/commands/commands/__tests__/sheets-reorder.command.spec.ts
+++ b/packages/sheets-sort/src/commands/commands/__tests__/sheets-reorder.command.spec.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICellData, Nullable, Univer, Workbook } from '@univerjs/core';
+import type { ICellData, Injector, Nullable, Univer, Workbook } from '@univerjs/core';
import { ICommandService, IUniverInstanceService } from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { ReorderRangeCommand, ReorderRangeMutation, SetSelectionsOperation } from '@univerjs/sheets';
import type { ISortRangeCommandParams } from '../sheets-sort.command';
diff --git a/packages/sheets-sort/src/commands/commands/sheets-sort.command.ts b/packages/sheets-sort/src/commands/commands/sheets-sort.command.ts
index c760903780..c864086e47 100644
--- a/packages/sheets-sort/src/commands/commands/sheets-sort.command.ts
+++ b/packages/sheets-sort/src/commands/commands/sheets-sort.command.ts
@@ -18,10 +18,9 @@
// These models would be held on `SheetsFilterService`.
import { CommandType, ICommandService, IUniverInstanceService, Rectangle, sequenceExecute } from '@univerjs/core';
-import type { ICellData, ICommand, IRange, Nullable, Worksheet } from '@univerjs/core';
+import type { IAccessor, ICellData, ICommand, IRange, Nullable, Worksheet } from '@univerjs/core';
import type { IReorderRangeCommandParams, ISheetCommandSharedParams } from '@univerjs/sheets';
import { getSheetCommandTarget, ReorderRangeCommand } from '@univerjs/sheets';
-import type { IAccessor } from '@wendellhu/redi';
import type { IOrderRule, SortType } from '../../services/interface';
import { SheetsSortService } from '../../services/sheets-sort.service';
diff --git a/packages/sheets-sort/src/controllers/sheets-sort.controller.ts b/packages/sheets-sort/src/controllers/sheets-sort.controller.ts
index 039cfbc2f4..3f967a3c40 100644
--- a/packages/sheets-sort/src/controllers/sheets-sort.controller.ts
+++ b/packages/sheets-sort/src/controllers/sheets-sort.controller.ts
@@ -15,9 +15,8 @@
*/
import type { ICellData, Nullable } from '@univerjs/core';
-import { CellValueType, Disposable, ICommandService, LifecycleStages, OnLifecycle } from '@univerjs/core';
+import { CellValueType, Disposable, ICommandService, Inject, LifecycleStages, OnLifecycle } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
import type { ICellValueCompareFn } from '../commands/commands/sheets-sort.command';
import { SortRangeCommand } from '../commands/commands/sheets-sort.command';
import { SheetsSortService } from '../services/sheets-sort.service';
diff --git a/packages/sheets-sort/src/plugin.ts b/packages/sheets-sort/src/plugin.ts
index 96cf425cb0..5074e3e6e5 100644
--- a/packages/sheets-sort/src/plugin.ts
+++ b/packages/sheets-sort/src/plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { Plugin, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { Inject, Injector, Plugin, UniverInstanceType } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
import { SheetsSortController } from './controllers/sheets-sort.controller';
import { SheetsSortService } from './services/sheets-sort.service';
diff --git a/packages/sheets-sort/src/services/sheets-sort.service.ts b/packages/sheets-sort/src/services/sheets-sort.service.ts
index 228cb7b21f..4a13f2701f 100644
--- a/packages/sheets-sort/src/services/sheets-sort.service.ts
+++ b/packages/sheets-sort/src/services/sheets-sort.service.ts
@@ -15,7 +15,10 @@
*/
import type { IRange, Workbook } from '@univerjs/core';
-import { Disposable, ICommandService,
+import {
+ Disposable,
+ ICommandService,
+ Inject,
IUniverInstanceService,
LifecycleStages,
OnLifecycle,
@@ -24,7 +27,6 @@ import { Disposable, ICommandService,
import type { ISheetRangeLocation } from '@univerjs/sheets';
import { getSheetCommandTarget } from '@univerjs/sheets';
-import { Inject } from '@wendellhu/redi';
import { FormulaDataModel } from '@univerjs/engine-formula';
import { type ICellValueCompareFn, SortRangeCommand } from '../commands/commands/sheets-sort.command';
import { isNullValue } from '../controllers/utils';
diff --git a/packages/sheets-thread-comment-base/package.json b/packages/sheets-thread-comment-base/package.json
index 69df03d00e..561e74b5dd 100644
--- a/packages/sheets-thread-comment-base/package.json
+++ b/packages/sheets-thread-comment-base/package.json
@@ -61,7 +61,6 @@
"@univerjs/engine-formula": "workspace:*",
"@univerjs/sheets": "workspace:*",
"@univerjs/thread-comment": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": ">=7.0.0"
},
"devDependencies": {
@@ -71,7 +70,6 @@
"@univerjs/shared": "workspace:*",
"@univerjs/thread-comment": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"react": "18.3.1",
"rxjs": "^7.8.1",
"typescript": "^5.5.3",
diff --git a/packages/sheets-thread-comment-base/src/controllers/sheets-thread-comment-ref-range.controller.ts b/packages/sheets-thread-comment-base/src/controllers/sheets-thread-comment-ref-range.controller.ts
index 387bd8fa94..434f7dd037 100644
--- a/packages/sheets-thread-comment-base/src/controllers/sheets-thread-comment-ref-range.controller.ts
+++ b/packages/sheets-thread-comment-base/src/controllers/sheets-thread-comment-ref-range.controller.ts
@@ -14,10 +14,8 @@
* limitations under the License.
*/
-import type { IRange, Nullable } from '@univerjs/core';
-import { Disposable, ICommandService, LifecycleStages, OnLifecycle, sequenceExecuteAsync, toDisposable } from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject } from '@wendellhu/redi';
+import type { IDisposable, IRange, Nullable } from '@univerjs/core';
+import { Disposable, ICommandService, Inject, LifecycleStages, OnLifecycle, sequenceExecuteAsync, toDisposable } from '@univerjs/core';
import type { EffectRefRangeParams } from '@univerjs/sheets';
import { handleDefaultRangeChangeWithEffectRefCommandsSkipNoInterests, RefRangeService, SheetsSelectionsService } from '@univerjs/sheets';
import type { IAddCommentMutationParams, IUpdateCommentRefMutationParams } from '@univerjs/thread-comment';
diff --git a/packages/sheets-thread-comment-base/src/models/sheets-thread-comment.model.ts b/packages/sheets-thread-comment-base/src/models/sheets-thread-comment.model.ts
index 41f6211c4c..8f25ee39ec 100644
--- a/packages/sheets-thread-comment-base/src/models/sheets-thread-comment.model.ts
+++ b/packages/sheets-thread-comment-base/src/models/sheets-thread-comment.model.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { Disposable, IUniverInstanceService, ObjectMatrix, UniverInstanceType } from '@univerjs/core';
+import { Disposable, Inject, IUniverInstanceService, ObjectMatrix, UniverInstanceType } from '@univerjs/core';
import type { CommentUpdate, IThreadComment } from '@univerjs/thread-comment';
import { ThreadCommentModel } from '@univerjs/thread-comment';
-import { Inject } from '@wendellhu/redi';
import { singleReferenceToGrid } from '@univerjs/engine-formula';
import { Subject } from 'rxjs';
diff --git a/packages/sheets-thread-comment-base/src/plugin.ts b/packages/sheets-thread-comment-base/src/plugin.ts
index 75ec29c297..8877e05d07 100644
--- a/packages/sheets-thread-comment-base/src/plugin.ts
+++ b/packages/sheets-thread-comment-base/src/plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
-import { DependentOn, ICommandService, Plugin, UniverInstanceType } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
+import { DependentOn, ICommandService, Inject, Injector, Plugin, UniverInstanceType } from '@univerjs/core';
import { UniverThreadCommentPlugin } from '@univerjs/thread-comment';
import { SheetsThreadCommentRefRangeController } from './controllers/sheets-thread-comment-ref-range.controller';
import { SheetsThreadCommentModel } from './models/sheets-thread-comment.model';
diff --git a/packages/sheets-thread-comment/package.json b/packages/sheets-thread-comment/package.json
index 227b409077..16ca00fb5e 100644
--- a/packages/sheets-thread-comment/package.json
+++ b/packages/sheets-thread-comment/package.json
@@ -69,7 +69,6 @@
"@univerjs/thread-comment": "workspace:*",
"@univerjs/thread-comment-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"react": "^16.9.0 || ^17.0.0 || ^18.0.0",
"rxjs": ">=7.0.0"
},
@@ -85,7 +84,6 @@
"@univerjs/thread-comment": "workspace:*",
"@univerjs/thread-comment-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": "^2.1.1",
"react": "18.3.1",
"rxjs": "^7.8.1",
diff --git a/packages/sheets-thread-comment/src/controllers/menu.ts b/packages/sheets-thread-comment/src/controllers/menu.ts
index c18c840bce..3cc9417875 100644
--- a/packages/sheets-thread-comment/src/controllers/menu.ts
+++ b/packages/sheets-thread-comment/src/controllers/menu.ts
@@ -16,7 +16,7 @@
import type { IMenuItem, IShortcutItem } from '@univerjs/ui';
import { getMenuHiddenObservable, KeyCode, MenuGroup, MenuItemType, MenuPosition, MetaKeys } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor } from '@univerjs/core';
import { ToggleSheetCommentPanelOperation } from '@univerjs/thread-comment-ui';
import { UniverInstanceType } from '@univerjs/core';
import { getCurrentRangeDisable$, whenSheetEditorFocused } from '@univerjs/sheets-ui';
diff --git a/packages/sheets-thread-comment/src/controllers/render-controllers/render.controller.ts b/packages/sheets-thread-comment/src/controllers/render-controllers/render.controller.ts
index ad4b3b3175..026bda87bb 100644
--- a/packages/sheets-thread-comment/src/controllers/render-controllers/render.controller.ts
+++ b/packages/sheets-thread-comment/src/controllers/render-controllers/render.controller.ts
@@ -15,9 +15,8 @@
*/
import type { Workbook } from '@univerjs/core';
-import { Disposable, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
+import { Disposable, Inject, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import { INTERCEPTOR_POINT, SheetInterceptorService } from '@univerjs/sheets';
-import { Inject } from '@wendellhu/redi';
import { SheetSkeletonManagerService } from '@univerjs/sheets-ui';
import type { Spreadsheet } from '@univerjs/engine-render';
import { IRenderManagerService } from '@univerjs/engine-render';
diff --git a/packages/sheets-thread-comment/src/controllers/sheets-thread-comment-copy-paste.controller.ts b/packages/sheets-thread-comment/src/controllers/sheets-thread-comment-copy-paste.controller.ts
index 8b61f287d7..b33bdf8533 100644
--- a/packages/sheets-thread-comment/src/controllers/sheets-thread-comment-copy-paste.controller.ts
+++ b/packages/sheets-thread-comment/src/controllers/sheets-thread-comment-copy-paste.controller.ts
@@ -15,9 +15,8 @@
*/
import type { IMutationInfo, IRange, Nullable } from '@univerjs/core';
-import { Disposable, LifecycleStages, OnLifecycle, Range } from '@univerjs/core';
+import { Disposable, Inject, LifecycleStages, OnLifecycle, Range } from '@univerjs/core';
import { COPY_TYPE, ISheetClipboardService } from '@univerjs/sheets-ui';
-import { Inject } from '@wendellhu/redi';
import { AddCommentMutation, DeleteCommentMutation, type IThreadComment, IThreadCommentDataSourceService } from '@univerjs/thread-comment';
import { serializeRange, singleReferenceToGrid } from '@univerjs/engine-formula';
import { SheetsThreadCommentModel } from '@univerjs/sheets-thread-comment-base';
diff --git a/packages/sheets-thread-comment/src/controllers/sheets-thread-comment-hover.controller.ts b/packages/sheets-thread-comment/src/controllers/sheets-thread-comment-hover.controller.ts
index e47a5d47a3..f0e68fa5f2 100644
--- a/packages/sheets-thread-comment/src/controllers/sheets-thread-comment-hover.controller.ts
+++ b/packages/sheets-thread-comment/src/controllers/sheets-thread-comment-hover.controller.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { Disposable, LifecycleStages, OnLifecycle } from '@univerjs/core';
+import { Disposable, Inject, LifecycleStages, OnLifecycle } from '@univerjs/core';
import { HoverManagerService, SheetPermissionInterceptorBaseController } from '@univerjs/sheets-ui';
-import { Inject } from '@wendellhu/redi';
import { debounceTime } from 'rxjs';
import { SheetsThreadCommentModel } from '@univerjs/sheets-thread-comment-base';
import { RangeProtectionPermissionViewPoint, WorkbookCommentPermission, WorksheetViewPermission } from '@univerjs/sheets';
diff --git a/packages/sheets-thread-comment/src/controllers/sheets-thread-comment-remove.controller.ts b/packages/sheets-thread-comment/src/controllers/sheets-thread-comment-remove.controller.ts
index daea6b5269..9e9c9a9087 100644
--- a/packages/sheets-thread-comment/src/controllers/sheets-thread-comment-remove.controller.ts
+++ b/packages/sheets-thread-comment/src/controllers/sheets-thread-comment-remove.controller.ts
@@ -15,8 +15,7 @@
*/
import type { Workbook } from '@univerjs/core';
-import { Disposable, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { Disposable, Inject, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import type { IRemoveSheetCommandParams } from '@univerjs/sheets';
import { RemoveSheetCommand, SheetInterceptorService } from '@univerjs/sheets';
import type { IDeleteCommentMutationParams } from '@univerjs/thread-comment';
diff --git a/packages/sheets-thread-comment/src/controllers/sheets-thread-comment.controller.ts b/packages/sheets-thread-comment/src/controllers/sheets-thread-comment.controller.ts
index 97258e7327..e9cbeafb9e 100644
--- a/packages/sheets-thread-comment/src/controllers/sheets-thread-comment.controller.ts
+++ b/packages/sheets-thread-comment/src/controllers/sheets-thread-comment.controller.ts
@@ -15,10 +15,9 @@
*/
import type { DependencyOverride, Nullable, Workbook } from '@univerjs/core';
-import { Disposable, ICommandService, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
+import { Disposable, ICommandService, Inject, Injector, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import type { MenuConfig } from '@univerjs/ui';
import { ComponentManager, IMenuService, IShortcutService } from '@univerjs/ui';
-import { Inject, Injector } from '@wendellhu/redi';
import { CommentSingle } from '@univerjs/icons';
import { SetActiveCommentOperation, THREAD_COMMENT_PANEL, ThreadCommentPanelService } from '@univerjs/thread-comment-ui';
import type { ISetSelectionsOperationParams } from '@univerjs/sheets';
diff --git a/packages/sheets-thread-comment/src/index.ts b/packages/sheets-thread-comment/src/index.ts
index 61115f82a7..eed5ac07c2 100644
--- a/packages/sheets-thread-comment/src/index.ts
+++ b/packages/sheets-thread-comment/src/index.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-export type { Dependency } from '@wendellhu/redi';
-export { Inject, Injector } from '@wendellhu/redi';
+export type { Dependency } from '@univerjs/core';
+export { Inject, Injector } from '@univerjs/core';
export { ICommandService, Plugin, UniverInstanceType } from '@univerjs/core';
export { UniverThreadCommentUIPlugin } from '@univerjs/thread-comment-ui';
export { SheetsThreadCommentController } from './controllers/sheets-thread-comment.controller';
diff --git a/packages/sheets-thread-comment/src/plugin.ts b/packages/sheets-thread-comment/src/plugin.ts
index 2e9c022037..dc527efc4e 100644
--- a/packages/sheets-thread-comment/src/plugin.ts
+++ b/packages/sheets-thread-comment/src/plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
-import { DependentOn, ICommandService, Plugin, Tools, UniverInstanceType } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
+import { DependentOn, ICommandService, Inject, Injector, Plugin, Tools, UniverInstanceType } from '@univerjs/core';
import { UniverThreadCommentUIPlugin } from '@univerjs/thread-comment-ui';
import { UniverSheetsThreadCommentBasePlugin } from '@univerjs/sheets-thread-comment-base';
import type { IUniverSheetsThreadCommentConfig } from './controllers/sheets-thread-comment.controller';
diff --git a/packages/sheets-thread-comment/src/services/sheets-thread-comment-popup.service.ts b/packages/sheets-thread-comment/src/services/sheets-thread-comment-popup.service.ts
index 10ba8195fd..87591dd997 100644
--- a/packages/sheets-thread-comment/src/services/sheets-thread-comment-popup.service.ts
+++ b/packages/sheets-thread-comment/src/services/sheets-thread-comment-popup.service.ts
@@ -14,12 +14,11 @@
* limitations under the License.
*/
-import type { Nullable } from '@univerjs/core';
-import { Disposable, DisposableCollection } from '@univerjs/core';
+import type { IDisposable, Nullable } from '@univerjs/core';
+import { Disposable, DisposableCollection, Inject } from '@univerjs/core';
import type { ISheetLocationBase } from '@univerjs/sheets';
import { SheetCanvasPopManagerService } from '@univerjs/sheets-ui';
import { IZenZoneService } from '@univerjs/ui';
-import { type IDisposable, Inject } from '@wendellhu/redi';
import { BehaviorSubject } from 'rxjs';
import { SHEETS_THREAD_COMMENT_MODAL } from '../types/const';
diff --git a/packages/sheets-thread-comment/src/views/sheets-thread-comment-cell/index.tsx b/packages/sheets-thread-comment/src/views/sheets-thread-comment-cell/index.tsx
index 79133a49e0..a5d1ec9ed3 100644
--- a/packages/sheets-thread-comment/src/views/sheets-thread-comment-cell/index.tsx
+++ b/packages/sheets-thread-comment/src/views/sheets-thread-comment-cell/index.tsx
@@ -14,11 +14,10 @@
* limitations under the License.
*/
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { IUniverInstanceService, Tools, UniverInstanceType, useDependency } from '@univerjs/core';
import React from 'react';
import { ThreadCommentTree } from '@univerjs/thread-comment-ui';
import type { Workbook } from '@univerjs/core';
-import { IUniverInstanceService, Tools, UniverInstanceType } from '@univerjs/core';
import { useObservable } from '@univerjs/ui';
import { SheetsThreadCommentModel } from '@univerjs/sheets-thread-comment-base';
import { SheetsThreadCommentPopupService } from '../../services/sheets-thread-comment-popup.service';
diff --git a/packages/sheets-thread-comment/src/views/sheets-thread-comment-panel/index.tsx b/packages/sheets-thread-comment/src/views/sheets-thread-comment-panel/index.tsx
index 6e673672a4..e935f65f58 100644
--- a/packages/sheets-thread-comment/src/views/sheets-thread-comment-panel/index.tsx
+++ b/packages/sheets-thread-comment/src/views/sheets-thread-comment-panel/index.tsx
@@ -15,9 +15,8 @@
*/
import type { Workbook } from '@univerjs/core';
-import { ICommandService, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
+import { ICommandService, IUniverInstanceService, UniverInstanceType, useDependency } from '@univerjs/core';
import { ThreadCommentPanel, ThreadCommentPanelService } from '@univerjs/thread-comment-ui';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import { useObservable } from '@univerjs/ui';
import React, { useCallback, useEffect, useMemo, useRef } from 'react';
import { map } from 'rxjs';
diff --git a/packages/sheets-ui/package.json b/packages/sheets-ui/package.json
index df01c52e06..0d5998d6ab 100644
--- a/packages/sheets-ui/package.json
+++ b/packages/sheets-ui/package.json
@@ -74,7 +74,6 @@
"@univerjs/engine-render": "workspace:*",
"@univerjs/sheets": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": ">=2.0.0",
"react": "^16.9.0 || ^17.0.0 || ^18.0.0",
"rxjs": ">=7.0.0"
@@ -94,7 +93,6 @@
"@univerjs/shared": "workspace:*",
"@univerjs/sheets": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": "^2.1.1",
"less": "^4.2.0",
"react": "18.3.1",
diff --git a/packages/sheets-ui/src/commands/commands/__tests__/add-worksheet-merge.command.spec.ts b/packages/sheets-ui/src/commands/commands/__tests__/add-worksheet-merge.command.spec.ts
index 1d7a06a722..8ce8ef02e6 100644
--- a/packages/sheets-ui/src/commands/commands/__tests__/add-worksheet-merge.command.spec.ts
+++ b/packages/sheets-ui/src/commands/commands/__tests__/add-worksheet-merge.command.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { IRange, Univer, Workbook } from '@univerjs/core';
+import type { IDisposable, Injector, IRange, Univer, Workbook } from '@univerjs/core';
import {
ICommandService,
IUniverInstanceService,
@@ -50,7 +50,6 @@ import {
SheetsSelectionsService,
} from '@univerjs/sheets';
import { type IConfirmPartMethodOptions, IConfirmService } from '@univerjs/ui';
-import type { IDisposable, Injector } from '@wendellhu/redi';
import { Subject } from 'rxjs';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
diff --git a/packages/sheets-ui/src/commands/commands/__tests__/auto-fill.controller.spec.ts b/packages/sheets-ui/src/commands/commands/__tests__/auto-fill.controller.spec.ts
index 974fdc505f..04f01c3a14 100644
--- a/packages/sheets-ui/src/commands/commands/__tests__/auto-fill.controller.spec.ts
+++ b/packages/sheets-ui/src/commands/commands/__tests__/auto-fill.controller.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICellData, IStyleData, Nullable, Univer, Workbook } from '@univerjs/core';
+import type { ICellData, Injector, IStyleData, Nullable, Univer, Workbook } from '@univerjs/core';
import {
CellValueType,
ICommandService,
@@ -33,7 +33,6 @@ import {
SheetsSelectionsService,
} from '@univerjs/sheets';
import { EditorService, IEditorService, IPlatformService, IShortcutService, PlatformService, ShortcutService } from '@univerjs/ui';
-import type { Injector } from '@wendellhu/redi';
import { beforeEach, describe, expect, it } from 'vitest';
import { IRenderManagerService, RenderManagerService } from '@univerjs/engine-render';
diff --git a/packages/sheets-ui/src/commands/commands/__tests__/create-command-test-bed.ts b/packages/sheets-ui/src/commands/commands/__tests__/create-command-test-bed.ts
index b2368742ad..e32ca879ac 100644
--- a/packages/sheets-ui/src/commands/commands/__tests__/create-command-test-bed.ts
+++ b/packages/sheets-ui/src/commands/commands/__tests__/create-command-test-bed.ts
@@ -14,11 +14,13 @@
* limitations under the License.
*/
-import type { IWorkbookData, Workbook } from '@univerjs/core';
+import type { Dependency, IWorkbookData, Workbook } from '@univerjs/core';
import {
BooleanNumber,
DisposableCollection,
ILogService,
+ Inject,
+ Injector,
IUniverInstanceService,
LocaleService,
LocaleType,
@@ -36,8 +38,6 @@ import {
SheetsSelectionsService, WorkbookPermissionService, WorksheetPermissionService, WorksheetProtectionPointModel, WorksheetProtectionRuleModel,
} from '@univerjs/sheets';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
import { LexerTreeBuilder } from '@univerjs/engine-formula';
import type { IRenderContext } from '@univerjs/engine-render';
diff --git a/packages/sheets-ui/src/commands/commands/__tests__/hide-row-col-confirm.command.spec.ts b/packages/sheets-ui/src/commands/commands/__tests__/hide-row-col-confirm.command.spec.ts
index 94fa42f8b4..53a404b50e 100644
--- a/packages/sheets-ui/src/commands/commands/__tests__/hide-row-col-confirm.command.spec.ts
+++ b/packages/sheets-ui/src/commands/commands/__tests__/hide-row-col-confirm.command.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { IRange, Univer } from '@univerjs/core';
+import type { IDisposable, Injector, IRange, Univer } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, LocaleService, RANGE_TYPE } from '@univerjs/core';
import {
AddWorksheetMergeMutation,
@@ -29,7 +29,6 @@ import {
SheetsSelectionsService,
} from '@univerjs/sheets';
import { type IConfirmPartMethodOptions, IConfirmService } from '@univerjs/ui';
-import type { IDisposable, Injector } from '@wendellhu/redi';
import { Subject } from 'rxjs';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
diff --git a/packages/sheets-ui/src/commands/commands/__tests__/remove-row-col-confirm.command.spec.ts b/packages/sheets-ui/src/commands/commands/__tests__/remove-row-col-confirm.command.spec.ts
index 60eff500b9..86a7f6277c 100644
--- a/packages/sheets-ui/src/commands/commands/__tests__/remove-row-col-confirm.command.spec.ts
+++ b/packages/sheets-ui/src/commands/commands/__tests__/remove-row-col-confirm.command.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { Univer } from '@univerjs/core';
+import type { IDisposable, Injector, Univer } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, LocaleService, RANGE_TYPE } from '@univerjs/core';
import {
AddWorksheetMergeMutation,
@@ -29,7 +29,6 @@ import {
SheetsSelectionsService,
} from '@univerjs/sheets';
import { type IConfirmPartMethodOptions, IConfirmService } from '@univerjs/ui';
-import type { IDisposable, Injector } from '@wendellhu/redi';
import { Subject } from 'rxjs';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
diff --git a/packages/sheets-ui/src/commands/commands/__tests__/set-format-painter.command.spec.ts b/packages/sheets-ui/src/commands/commands/__tests__/set-format-painter.command.spec.ts
index 48b66bfc97..60b3911aba 100644
--- a/packages/sheets-ui/src/commands/commands/__tests__/set-format-painter.command.spec.ts
+++ b/packages/sheets-ui/src/commands/commands/__tests__/set-format-painter.command.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { Univer, Workbook } from '@univerjs/core';
+import type { DependencyIdentifier, Injector, Univer, Workbook } from '@univerjs/core';
import {
Disposable,
ICommandService,
@@ -34,7 +34,6 @@ import {
SetRangeValuesMutation,
SetSelectionsOperation,
} from '@univerjs/sheets';
-import type { DependencyIdentifier, Injector } from '@wendellhu/redi';
import { BehaviorSubject } from 'rxjs';
import { beforeEach, describe, expect, it } from 'vitest';
diff --git a/packages/sheets-ui/src/commands/commands/__tests__/set-frozen.command.spec.ts b/packages/sheets-ui/src/commands/commands/__tests__/set-frozen.command.spec.ts
index a5b7fb2fbd..4090cfee87 100644
--- a/packages/sheets-ui/src/commands/commands/__tests__/set-frozen.command.spec.ts
+++ b/packages/sheets-ui/src/commands/commands/__tests__/set-frozen.command.spec.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { IFreeze, IWorkbookData, Univer, Workbook } from '@univerjs/core';
+import type { IFreeze, Injector, IWorkbookData, Univer, Workbook } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, RANGE_TYPE, UniverInstanceType } from '@univerjs/core';
import { SheetsSelectionsService } from '@univerjs/sheets';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { SheetScrollManagerService } from '../../../services/scroll-manager.service';
diff --git a/packages/sheets-ui/src/commands/commands/__tests__/set-selections.command.spec.ts b/packages/sheets-ui/src/commands/commands/__tests__/set-selections.command.spec.ts
index 833bdf779c..5acfc05094 100644
--- a/packages/sheets-ui/src/commands/commands/__tests__/set-selections.command.spec.ts
+++ b/packages/sheets-ui/src/commands/commands/__tests__/set-selections.command.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { IWorkbookData, Univer, Workbook } from '@univerjs/core';
+import type { Injector, IWorkbookData, Univer, Workbook } from '@univerjs/core';
import { Direction, ICommandService, IUniverInstanceService, RANGE_TYPE, UniverInstanceType } from '@univerjs/core';
import {
SetColHiddenCommand,
@@ -27,7 +27,6 @@ import {
SetSelectedRowsVisibleCommand,
SheetsSelectionsService,
} from '@univerjs/sheets';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import type {
diff --git a/packages/sheets-ui/src/commands/commands/add-worksheet-merge.command.ts b/packages/sheets-ui/src/commands/commands/add-worksheet-merge.command.ts
index 2d77fef0fb..c7e98e17dc 100644
--- a/packages/sheets-ui/src/commands/commands/add-worksheet-merge.command.ts
+++ b/packages/sheets-ui/src/commands/commands/add-worksheet-merge.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICommand, IMutationInfo, IRange, Workbook } from '@univerjs/core';
+import type { IAccessor, ICommand, IMutationInfo, IRange, Workbook } from '@univerjs/core';
import {
CommandType,
Dimension,
@@ -36,7 +36,6 @@ import {
RemoveWorksheetMergeMutation, SheetsSelectionsService,
} from '@univerjs/sheets';
import { IConfirmService } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
import { checkCellContentInRanges, getClearContentMutationParamsForRanges } from '../../common/utils';
import { getMergeableSelectionsByType, MergeType } from './utils/selection-utils';
diff --git a/packages/sheets-ui/src/commands/commands/auto-fill.command.ts b/packages/sheets-ui/src/commands/commands/auto-fill.command.ts
index a2408e4151..43fe6756a6 100644
--- a/packages/sheets-ui/src/commands/commands/auto-fill.command.ts
+++ b/packages/sheets-ui/src/commands/commands/auto-fill.command.ts
@@ -14,11 +14,10 @@
* limitations under the License.
*/
-import type { ICommand, IRange } from '@univerjs/core';
+import type { IAccessor, ICommand, IRange } from '@univerjs/core';
import { CommandType, ICommandService, IUndoRedoService, IUniverInstanceService } from '@univerjs/core';
import type { ISetRangeValuesMutationParams } from '@univerjs/sheets';
import { generateNullCellValue, getSheetCommandTarget, SetRangeValuesMutation, SetRangeValuesUndoMutationFactory, SetSelectionsOperation } from '@univerjs/sheets';
-import type { IAccessor } from '@wendellhu/redi';
import { IAutoFillService } from '../../services/auto-fill/auto-fill.service';
diff --git a/packages/sheets-ui/src/commands/commands/clipboard.command.ts b/packages/sheets-ui/src/commands/commands/clipboard.command.ts
index df89bf7374..643eada07d 100644
--- a/packages/sheets-ui/src/commands/commands/clipboard.command.ts
+++ b/packages/sheets-ui/src/commands/commands/clipboard.command.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { ICommand, IMultiCommand } from '@univerjs/core';
+import type { IAccessor, ICommand, IMultiCommand } from '@univerjs/core';
import { CommandType, ICommandService } from '@univerjs/core';
import { CopyCommand, CutCommand, IClipboardInterfaceService, PasteCommand } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
import { whenSheetFocused } from '../../controllers/shortcuts/utils';
import { ISheetClipboardService, PREDEFINED_HOOK_NAME } from '../../services/clipboard/clipboard.service';
diff --git a/packages/sheets-ui/src/commands/commands/hide-row-col-confirm.command.ts b/packages/sheets-ui/src/commands/commands/hide-row-col-confirm.command.ts
index 44e38752d7..3c4b692667 100644
--- a/packages/sheets-ui/src/commands/commands/hide-row-col-confirm.command.ts
+++ b/packages/sheets-ui/src/commands/commands/hide-row-col-confirm.command.ts
@@ -14,11 +14,10 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType, ICommandService, IUniverInstanceService, LocaleService } from '@univerjs/core';
import { getSheetCommandTarget, SetColHiddenCommand, SetRowHiddenCommand, SheetsSelectionsService } from '@univerjs/sheets';
import { IConfirmService } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
import { isAllColumnsCovered, isAllRowsCovered } from './utils/selection-utils';
diff --git a/packages/sheets-ui/src/commands/commands/refill.command.ts b/packages/sheets-ui/src/commands/commands/refill.command.ts
index 420b7ffdc7..0587d27f15 100644
--- a/packages/sheets-ui/src/commands/commands/refill.command.ts
+++ b/packages/sheets-ui/src/commands/commands/refill.command.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { IAutoFillService } from '../../services/auto-fill/auto-fill.service';
import type { APPLY_TYPE } from '../../services/auto-fill/type';
diff --git a/packages/sheets-ui/src/commands/commands/remove-row-col-confirm.command.ts b/packages/sheets-ui/src/commands/commands/remove-row-col-confirm.command.ts
index 6e3ab2b984..1ced89f89c 100644
--- a/packages/sheets-ui/src/commands/commands/remove-row-col-confirm.command.ts
+++ b/packages/sheets-ui/src/commands/commands/remove-row-col-confirm.command.ts
@@ -14,12 +14,11 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType, ICommandService, IUniverInstanceService, LocaleService } from '@univerjs/core';
import type { IRemoveRowColCommandParams } from '@univerjs/sheets';
import { getSheetCommandTarget, RemoveColCommand, RemoveRowCommand, SheetsSelectionsService } from '@univerjs/sheets';
import { IConfirmService } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
import { isAllColumnsCovered, isAllRowsCovered } from './utils/selection-utils';
diff --git a/packages/sheets-ui/src/commands/commands/remove-sheet-confirm.command.ts b/packages/sheets-ui/src/commands/commands/remove-sheet-confirm.command.ts
index ef5ffa2411..ca65c8e473 100644
--- a/packages/sheets-ui/src/commands/commands/remove-sheet-confirm.command.ts
+++ b/packages/sheets-ui/src/commands/commands/remove-sheet-confirm.command.ts
@@ -14,11 +14,10 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType, ICommandService, LocaleService } from '@univerjs/core';
import { RemoveSheetCommand } from '@univerjs/sheets';
import { IConfirmService } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
interface IRemoveSheetConfirmCommandParams {
subUnitId: string;
diff --git a/packages/sheets-ui/src/commands/commands/set-format-painter.command.ts b/packages/sheets-ui/src/commands/commands/set-format-painter.command.ts
index 628cb3489d..a5146258f3 100644
--- a/packages/sheets-ui/src/commands/commands/set-format-painter.command.ts
+++ b/packages/sheets-ui/src/commands/commands/set-format-painter.command.ts
@@ -14,12 +14,11 @@
* limitations under the License.
*/
-import type { ICommand, IRange } from '@univerjs/core';
+import type { IAccessor, ICommand, IRange } from '@univerjs/core';
import {
CommandType,
ICommandService,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { FormatPainterStatus, IFormatPainterService } from '../../services/format-painter/format-painter.service';
import { SetFormatPainterOperation } from '../operations/set-format-painter.operation';
diff --git a/packages/sheets-ui/src/commands/commands/unhide.command.ts b/packages/sheets-ui/src/commands/commands/unhide.command.ts
index 45b1cc5865..0626d0c19c 100644
--- a/packages/sheets-ui/src/commands/commands/unhide.command.ts
+++ b/packages/sheets-ui/src/commands/commands/unhide.command.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { ISheetBarService } from '../../services/sheet-bar/sheet-bar.service';
diff --git a/packages/sheets-ui/src/commands/operations/rename-sheet.operation.ts b/packages/sheets-ui/src/commands/operations/rename-sheet.operation.ts
index 79f3d7a8af..2a638ab2e7 100644
--- a/packages/sheets-ui/src/commands/operations/rename-sheet.operation.ts
+++ b/packages/sheets-ui/src/commands/operations/rename-sheet.operation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { ISheetBarService } from '../../services/sheet-bar/sheet-bar.service';
diff --git a/packages/sheets-ui/src/commands/operations/sidebar-defined-name.operation.ts b/packages/sheets-ui/src/commands/operations/sidebar-defined-name.operation.ts
index 92881c7d9a..d12c5b0928 100644
--- a/packages/sheets-ui/src/commands/operations/sidebar-defined-name.operation.ts
+++ b/packages/sheets-ui/src/commands/operations/sidebar-defined-name.operation.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType, IUniverInstanceService, LocaleService } from '@univerjs/core';
import { IEditorService, ISidebarService } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
import { getSheetCommandTarget } from '@univerjs/sheets';
import { DEFINED_NAME_CONTAINER } from '../../views/defined-name/component-name';
diff --git a/packages/sheets-ui/src/common/utils.ts b/packages/sheets-ui/src/common/utils.ts
index 28a2fa9535..273a73a294 100644
--- a/packages/sheets-ui/src/common/utils.ts
+++ b/packages/sheets-ui/src/common/utils.ts
@@ -14,12 +14,11 @@
* limitations under the License.
*/
-import type { ICellData, IMutationInfo, IPosition, IRange, Nullable, Workbook, Worksheet } from '@univerjs/core';
+import type { IAccessor, ICellData, IMutationInfo, IPosition, IRange, Nullable, Workbook, Worksheet } from '@univerjs/core';
import { ObjectMatrix } from '@univerjs/core';
import { SHEET_VIEWPORT_KEY, Vector2 } from '@univerjs/engine-render';
import type { ISetRangeValuesMutationParams, ISheetLocation } from '@univerjs/sheets';
import { SetRangeValuesMutation, SetRangeValuesUndoMutationFactory } from '@univerjs/sheets';
-import type { IAccessor } from '@wendellhu/redi';
import type { IBoundRectNoAngle, IRender, Scene, SpreadsheetSkeleton } from '@univerjs/engine-render';
import type { ICollaborator } from '@univerjs/protocol';
import type { ISheetSkeletonManagerParam } from '../services/sheet-skeleton-manager.service';
diff --git a/packages/sheets-ui/src/components/border-panel/BorderPanel.tsx b/packages/sheets-ui/src/components/border-panel/BorderPanel.tsx
index 4ec6343615..2ba1b54920 100644
--- a/packages/sheets-ui/src/components/border-panel/BorderPanel.tsx
+++ b/packages/sheets-ui/src/components/border-panel/BorderPanel.tsx
@@ -14,12 +14,11 @@
* limitations under the License.
*/
-import { BorderStyleTypes } from '@univerjs/core';
+import { BorderStyleTypes, useDependency } from '@univerjs/core';
import { ColorPicker, Dropdown, Menu, MenuItem } from '@univerjs/design';
import { MoreDownSingle, PaintBucket } from '@univerjs/icons';
import { BorderStyleManagerService, type IBorderInfo } from '@univerjs/sheets';
import { ComponentManager } from '@univerjs/ui';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import React from 'react';
import { BorderLine } from './border-line/BorderLine';
diff --git a/packages/sheets-ui/src/components/hook.ts b/packages/sheets-ui/src/components/hook.ts
index 34f88a6e97..20b8e88cb5 100644
--- a/packages/sheets-ui/src/components/hook.ts
+++ b/packages/sheets-ui/src/components/hook.ts
@@ -16,7 +16,7 @@
import { IUniverInstanceService, UniverInstanceType, type Workbook } from '@univerjs/core';
import { useObservable } from '@univerjs/ui';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { useDependency } from '@univerjs/core';
import { of } from 'rxjs';
export function useActiveWorkbook(): Workbook | null {
diff --git a/packages/sheets-ui/src/components/menu-item-input/MenuItemInput.tsx b/packages/sheets-ui/src/components/menu-item-input/MenuItemInput.tsx
index d3a4d8b4c9..de1e251ad9 100644
--- a/packages/sheets-ui/src/components/menu-item-input/MenuItemInput.tsx
+++ b/packages/sheets-ui/src/components/menu-item-input/MenuItemInput.tsx
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { LocaleService } from '@univerjs/core';
+import { LocaleService, useDependency } from '@univerjs/core';
import { InputNumber } from '@univerjs/design';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import React, { useEffect, useState } from 'react';
import styles from './index.module.less';
diff --git a/packages/sheets-ui/src/controllers/auto-fill.controller.ts b/packages/sheets-ui/src/controllers/auto-fill.controller.ts
index b7aa6f8758..7d80426135 100644
--- a/packages/sheets-ui/src/controllers/auto-fill.controller.ts
+++ b/packages/sheets-ui/src/controllers/auto-fill.controller.ts
@@ -21,6 +21,8 @@ import {
DisposableCollection,
getCellInfoInMergeData,
ICommandService,
+ Inject,
+ Injector,
IUniverInstanceService,
LifecycleStages,
ObjectMatrix,
@@ -59,7 +61,6 @@ import {
SetWorksheetColWidthMutation,
SetWorksheetRowHeightMutation,
} from '@univerjs/sheets';
-import { Inject, Injector } from '@wendellhu/redi';
import { AutoClearContentCommand, AutoFillCommand } from '../commands/commands/auto-fill.command';
import { IAutoFillService } from '../services/auto-fill/auto-fill.service';
diff --git a/packages/sheets-ui/src/controllers/auto-height.controller.ts b/packages/sheets-ui/src/controllers/auto-height.controller.ts
index 69d430d58c..d0402ea8f5 100644
--- a/packages/sheets-ui/src/controllers/auto-height.controller.ts
+++ b/packages/sheets-ui/src/controllers/auto-height.controller.ts
@@ -15,7 +15,7 @@
*/
import type { IRange, Workbook } from '@univerjs/core';
-import { Disposable, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
+import { Disposable, Inject, Injector, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import type {
ISetRangeValuesRangeMutationParams,
ISetStyleCommandParams,
@@ -31,7 +31,6 @@ import {
SheetInterceptorService,
SheetsSelectionsService,
} from '@univerjs/sheets';
-import { Inject, Injector } from '@wendellhu/redi';
import type { RenderManagerService } from '@univerjs/engine-render';
import { IRenderManagerService } from '@univerjs/engine-render';
import { SheetSkeletonManagerService } from '../services/sheet-skeleton-manager.service';
diff --git a/packages/sheets-ui/src/controllers/cell-alert.controller.ts b/packages/sheets-ui/src/controllers/cell-alert.controller.ts
index 20dde5d787..713e64395a 100644
--- a/packages/sheets-ui/src/controllers/cell-alert.controller.ts
+++ b/packages/sheets-ui/src/controllers/cell-alert.controller.ts
@@ -15,9 +15,8 @@
*/
import type { Workbook } from '@univerjs/core';
-import { Disposable, LifecycleStages, OnLifecycle } from '@univerjs/core';
+import { Disposable, Inject, LifecycleStages, OnLifecycle } from '@univerjs/core';
import { ComponentManager } from '@univerjs/ui';
-import { Inject } from '@wendellhu/redi';
import type { IRenderContext, IRenderModule } from '@univerjs/engine-render';
import { CellAlert } from '../views/cell-alert/CellAlertPopup';
import { CELL_ALERT_KEY } from '../views/cell-alert';
diff --git a/packages/sheets-ui/src/controllers/cell-custom-render.controller.ts b/packages/sheets-ui/src/controllers/cell-custom-render.controller.ts
index 61e17ecac9..7920032092 100644
--- a/packages/sheets-ui/src/controllers/cell-custom-render.controller.ts
+++ b/packages/sheets-ui/src/controllers/cell-custom-render.controller.ts
@@ -15,10 +15,9 @@
*/
import type { ICellCustomRender, ICellRenderContext, Nullable, UniverInstanceService, Workbook } from '@univerjs/core';
-import { Disposable, DisposableCollection, IUniverInstanceService, LifecycleStages, OnLifecycle, sortRules } from '@univerjs/core';
+import { Disposable, DisposableCollection, Inject, IUniverInstanceService, LifecycleStages, OnLifecycle, sortRules } from '@univerjs/core';
import type { IMouseEvent, IPointerEvent, IRenderContext, IRenderModule, RenderManagerService, Spreadsheet } from '@univerjs/engine-render';
import { IRenderManagerService, Vector2 } from '@univerjs/engine-render';
-import { Inject } from '@wendellhu/redi';
import type { ISheetSkeletonManagerParam } from '../services/sheet-skeleton-manager.service';
import { SheetSkeletonManagerService } from '../services/sheet-skeleton-manager.service';
diff --git a/packages/sheets-ui/src/controllers/clipboard/clipboard.controller.ts b/packages/sheets-ui/src/controllers/clipboard/clipboard.controller.ts
index 9d3ddb66cf..aad50a77bc 100644
--- a/packages/sheets-ui/src/controllers/clipboard/clipboard.controller.ts
+++ b/packages/sheets-ui/src/controllers/clipboard/clipboard.controller.ts
@@ -36,15 +36,15 @@ import {
ICommandService,
IConfigService,
IContextService,
+ Inject,
+ Injector,
isFormulaString,
IUniverInstanceService,
LifecycleStages,
LocaleService,
ObjectMatrix,
OnLifecycle,
- RxDisposable,
- UniverInstanceType,
-} from '@univerjs/core';
+ Optional, RxDisposable, UniverInstanceType } from '@univerjs/core';
import { MessageType } from '@univerjs/design';
import type {
IInsertColMutationParams,
@@ -63,7 +63,6 @@ import {
SetWorksheetRowHeightMutation,
} from '@univerjs/sheets';
import { IMessageService, textTrim } from '@univerjs/ui';
-import { Inject, Injector, Optional } from '@wendellhu/redi';
import { IRenderManagerService, ITextSelectionRenderManager, ptToPx } from '@univerjs/engine-render';
import { takeUntil } from 'rxjs';
diff --git a/packages/sheets-ui/src/controllers/clipboard/utils.ts b/packages/sheets-ui/src/controllers/clipboard/utils.ts
index f76e4725a6..bce27049f3 100644
--- a/packages/sheets-ui/src/controllers/clipboard/utils.ts
+++ b/packages/sheets-ui/src/controllers/clipboard/utils.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICellData, IDocumentBody, IMutationInfo, IParagraph, IRange, Nullable } from '@univerjs/core';
+import type { IAccessor, ICellData, IDocumentBody, IMutationInfo, IParagraph, IRange, Nullable } from '@univerjs/core';
import { cellToRange, DEFAULT_STYLES, IUniverInstanceService, ObjectMatrix, Range, Rectangle, Tools } from '@univerjs/core';
import type {
IAddWorksheetMergeMutationParams,
@@ -36,7 +36,6 @@ import {
SetSelectionsOperation,
SheetInterceptorService,
} from '@univerjs/sheets';
-import type { IAccessor } from '@wendellhu/redi';
import { numfmt } from '@univerjs/engine-numfmt';
import { DEFAULT_PADDING_DATA } from '@univerjs/engine-render';
diff --git a/packages/sheets-ui/src/controllers/defined-name/defined-name.controller.ts b/packages/sheets-ui/src/controllers/defined-name/defined-name.controller.ts
index 9a12dffe44..5b7adb96b3 100644
--- a/packages/sheets-ui/src/controllers/defined-name/defined-name.controller.ts
+++ b/packages/sheets-ui/src/controllers/defined-name/defined-name.controller.ts
@@ -15,11 +15,10 @@
*/
import type { Workbook } from '@univerjs/core';
-import { Disposable, ICommandService, IUniverInstanceService, LifecycleStages, OnLifecycle, ThemeService, UniverInstanceType } from '@univerjs/core';
+import { Disposable, ICommandService, Inject, IUniverInstanceService, LifecycleStages, OnLifecycle, ThemeService, UniverInstanceType } from '@univerjs/core';
import { deserializeRangeWithSheet, IDefinedNamesService, isReferenceStrings, operatorToken } from '@univerjs/engine-formula';
import type { ISelectionWithStyle } from '@univerjs/sheets';
import { getNormalSelectionStyle, getPrimaryForRange, ScrollToCellOperation, SetWorksheetActivateCommand, SheetsSelectionsService } from '@univerjs/sheets';
-import { Inject } from '@wendellhu/redi';
import { filter, merge } from 'rxjs';
@OnLifecycle(LifecycleStages.Rendered, SheetsDefinedNameController)
diff --git a/packages/sheets-ui/src/controllers/drag-render.controller.ts b/packages/sheets-ui/src/controllers/drag-render.controller.ts
index 963776d753..fbd137abe5 100644
--- a/packages/sheets-ui/src/controllers/drag-render.controller.ts
+++ b/packages/sheets-ui/src/controllers/drag-render.controller.ts
@@ -15,10 +15,9 @@
*/
import type { Nullable, Workbook } from '@univerjs/core';
-import { Disposable, DisposableCollection } from '@univerjs/core';
+import { Disposable, DisposableCollection, Inject } from '@univerjs/core';
import type { IRenderContext, IRenderModule } from '@univerjs/engine-render';
import { IRenderManagerService } from '@univerjs/engine-render';
-import { Inject } from '@wendellhu/redi';
import { DragManagerService } from '../services/drag-manager.service';
import { type ISheetSkeletonManagerParam, SheetSkeletonManagerService } from '../services/sheet-skeleton-manager.service';
diff --git a/packages/sheets-ui/src/controllers/editor/__tests__/create-test-bed.ts b/packages/sheets-ui/src/controllers/editor/__tests__/create-test-bed.ts
index c56a1508a6..e3a6dbe45b 100644
--- a/packages/sheets-ui/src/controllers/editor/__tests__/create-test-bed.ts
+++ b/packages/sheets-ui/src/controllers/editor/__tests__/create-test-bed.ts
@@ -14,11 +14,9 @@
* limitations under the License.
*/
-import type { IWorkbookData, Workbook } from '@univerjs/core';
-import { ILogService, IUniverInstanceService, LocaleType, LogLevel, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
+import type { Dependency, IWorkbookData, Workbook } from '@univerjs/core';
+import { ILogService, Inject, Injector, IUniverInstanceService, LocaleType, LogLevel, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
import { SheetInterceptorService, SheetsSelectionsService } from '@univerjs/sheets';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
function getTestWorkbookDataDemo(): IWorkbookData {
return {
diff --git a/packages/sheets-ui/src/controllers/editor/__tests__/end-edit.controller.spec.ts b/packages/sheets-ui/src/controllers/editor/__tests__/end-edit.controller.spec.ts
index c1eda5d8d0..7d081f9884 100644
--- a/packages/sheets-ui/src/controllers/editor/__tests__/end-edit.controller.spec.ts
+++ b/packages/sheets-ui/src/controllers/editor/__tests__/end-edit.controller.spec.ts
@@ -14,11 +14,10 @@
* limitations under the License.
*/
-import type { ICellData, IDocumentData, Univer, Workbook } from '@univerjs/core';
+import type { ICellData, IDocumentData, Injector, Univer, Workbook } from '@univerjs/core';
import { CellValueType, IContextService, IResourceLoaderService, LocaleService } from '@univerjs/core';
import { LexerTreeBuilder } from '@univerjs/engine-formula';
import { SpreadsheetSkeleton } from '@univerjs/engine-render';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { getCellDataByInput } from '../editing.render-controller';
import { createTestBed } from './create-test-bed';
diff --git a/packages/sheets-ui/src/controllers/editor/editing.render-controller.ts b/packages/sheets-ui/src/controllers/editor/editing.render-controller.ts
index 1a0f1f068e..0c8eb2c088 100644
--- a/packages/sheets-ui/src/controllers/editor/editing.render-controller.ts
+++ b/packages/sheets-ui/src/controllers/editor/editing.render-controller.ts
@@ -16,7 +16,7 @@
/* eslint-disable max-lines-per-function */
-import type { DocumentDataModel, ICellData, ICommandInfo, IDocumentBody, IDocumentData, IPosition, Nullable, Workbook } from '@univerjs/core';
+import type { DocumentDataModel, ICellData, ICommandInfo, IDisposable, IDocumentBody, IDocumentData, IPosition, Nullable, Workbook } from '@univerjs/core';
import {
CellValueType, DEFAULT_EMPTY_DOCUMENT_VALUE, Direction, Disposable, DisposableCollection, DOCS_FORMULA_BAR_EDITOR_UNIT_ID_KEY, EDITOR_ACTIVATED,
FOCUSING_EDITOR_BUT_HIDDEN,
@@ -28,6 +28,7 @@ import {
HorizontalAlign,
ICommandService,
IContextService,
+ Inject,
IResourceLoaderService,
isFormulaString,
IUndoRedoService,
@@ -61,8 +62,6 @@ import {
ScrollBar,
} from '@univerjs/engine-render';
import { IEditorService, KeyCode, SetEditorResizeOperation } from '@univerjs/ui';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject } from '@wendellhu/redi';
import type { WorkbookSelections } from '@univerjs/sheets';
import { ClearSelectionFormatCommand, SetRangeValuesCommand, SetSelectionsOperation, SetWorksheetActivateCommand, SheetsSelectionsService } from '@univerjs/sheets';
import { distinctUntilChanged, filter } from 'rxjs';
diff --git a/packages/sheets-ui/src/controllers/editor/formula-editor.controller.ts b/packages/sheets-ui/src/controllers/editor/formula-editor.controller.ts
index f9cb309d28..96b81ab6cc 100644
--- a/packages/sheets-ui/src/controllers/editor/formula-editor.controller.ts
+++ b/packages/sheets-ui/src/controllers/editor/formula-editor.controller.ts
@@ -25,6 +25,7 @@ import {
HorizontalAlign,
ICommandService,
IContextService,
+ Inject,
IUndoRedoService,
IUniverInstanceService,
LifecycleStages,
@@ -45,7 +46,6 @@ import type { DocumentViewModel, RenderComponentType } from '@univerjs/engine-re
import { DeviceInputEventType, IRenderManagerService, ScrollBar } from '@univerjs/engine-render';
import type { IMoveRangeMutationParams, ISetRangeValuesMutationParams } from '@univerjs/sheets';
import { MoveRangeMutation, SetRangeValuesMutation } from '@univerjs/sheets';
-import { Inject } from '@wendellhu/redi';
import { takeUntil } from 'rxjs';
import { SetEditorResizeOperation } from '@univerjs/ui';
diff --git a/packages/sheets-ui/src/controllers/force-string-alert-render.controller.ts b/packages/sheets-ui/src/controllers/force-string-alert-render.controller.ts
index f32b8769b2..686c52d951 100644
--- a/packages/sheets-ui/src/controllers/force-string-alert-render.controller.ts
+++ b/packages/sheets-ui/src/controllers/force-string-alert-render.controller.ts
@@ -15,9 +15,8 @@
*/
import type { Workbook } from '@univerjs/core';
-import { CellValueType, Disposable, isRealNum, LifecycleStages, LocaleService, OnLifecycle } from '@univerjs/core';
+import { CellValueType, Disposable, Inject, isRealNum, LifecycleStages, LocaleService, OnLifecycle } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
import type { IRenderContext, IRenderModule } from '@univerjs/engine-render';
import { HoverManagerService } from '../services/hover-manager.service';
import { CellAlertManagerService, CellAlertType } from '../services/cell-alert-manager.service';
diff --git a/packages/sheets-ui/src/controllers/force-string-render.controller.ts b/packages/sheets-ui/src/controllers/force-string-render.controller.ts
index 6e92c5a88a..4df2242670 100644
--- a/packages/sheets-ui/src/controllers/force-string-render.controller.ts
+++ b/packages/sheets-ui/src/controllers/force-string-render.controller.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { CellValueType, isRealNum, LifecycleStages, OnLifecycle, RxDisposable } from '@univerjs/core';
+import { CellValueType, Inject, isRealNum, LifecycleStages, OnLifecycle, RxDisposable } from '@univerjs/core';
import type { Workbook } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
import { INTERCEPTOR_POINT, SheetInterceptorService } from '@univerjs/sheets';
import type { IRenderContext, IRenderModule } from '@univerjs/engine-render';
import { SheetSkeletonManagerService } from '../services/sheet-skeleton-manager.service';
diff --git a/packages/sheets-ui/src/controllers/format-painter/format-painter.controller.ts b/packages/sheets-ui/src/controllers/format-painter/format-painter.controller.ts
index c5b9dbf66f..a4f34182b7 100644
--- a/packages/sheets-ui/src/controllers/format-painter/format-painter.controller.ts
+++ b/packages/sheets-ui/src/controllers/format-painter/format-painter.controller.ts
@@ -19,6 +19,8 @@ import {
Disposable,
getCellInfoInMergeData,
ICommandService,
+ Inject,
+ Injector,
isICellData,
IUniverInstanceService,
LifecycleStages,
@@ -28,7 +30,6 @@ import {
UniverInstanceType,
} from '@univerjs/core';
-import { Inject, Injector } from '@wendellhu/redi';
import type { IAddWorksheetMergeMutationParams, IRemoveWorksheetMergeMutationParams, ISetRangeValuesMutationParams } from '@univerjs/sheets';
import { AddMergeUndoMutationFactory, AddWorksheetMergeMutation, getAddMergeMutationRangeByType, RemoveMergeUndoMutationFactory, RemoveWorksheetMergeMutation, SetRangeValuesCommand, SetRangeValuesMutation, SetRangeValuesUndoMutationFactory, SheetInterceptorService, SheetsSelectionsService } from '@univerjs/sheets';
import { IRenderManagerService } from '@univerjs/engine-render';
diff --git a/packages/sheets-ui/src/controllers/hover-render.controller.ts b/packages/sheets-ui/src/controllers/hover-render.controller.ts
index 573598bb5d..f56ddcd301 100644
--- a/packages/sheets-ui/src/controllers/hover-render.controller.ts
+++ b/packages/sheets-ui/src/controllers/hover-render.controller.ts
@@ -15,9 +15,8 @@
*/
import type { Nullable, Workbook } from '@univerjs/core';
-import { Disposable, DisposableCollection } from '@univerjs/core';
+import { Disposable, DisposableCollection, Inject } from '@univerjs/core';
import type { IRenderContext, IRenderModule } from '@univerjs/engine-render';
-import { Inject } from '@wendellhu/redi';
import { HoverManagerService } from '../services/hover-manager.service';
import type { ISheetSkeletonManagerParam } from '../services/sheet-skeleton-manager.service';
import { SheetSkeletonManagerService } from '../services/sheet-skeleton-manager.service';
diff --git a/packages/sheets-ui/src/controllers/mark-selection.controller.ts b/packages/sheets-ui/src/controllers/mark-selection.controller.ts
index 513c484706..13317ecad8 100644
--- a/packages/sheets-ui/src/controllers/mark-selection.controller.ts
+++ b/packages/sheets-ui/src/controllers/mark-selection.controller.ts
@@ -15,8 +15,7 @@
*/
import type { ICommandInfo, Workbook } from '@univerjs/core';
-import { Disposable, ICommandService } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { Disposable, ICommandService, Inject } from '@univerjs/core';
import type { IRenderContext, IRenderModule } from '@univerjs/engine-render';
import { SetCellEditVisibleOperation } from '../commands/operations/cell-edit.operation';
diff --git a/packages/sheets-ui/src/controllers/menu/__tests__/create-menu-test-bed.ts b/packages/sheets-ui/src/controllers/menu/__tests__/create-menu-test-bed.ts
index f500a4ce1b..9fe4570b59 100644
--- a/packages/sheets-ui/src/controllers/menu/__tests__/create-menu-test-bed.ts
+++ b/packages/sheets-ui/src/controllers/menu/__tests__/create-menu-test-bed.ts
@@ -15,7 +15,7 @@
*/
import type { IWorkbookData } from '@univerjs/core';
-import { LocaleType, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
+import { Inject, Injector, LocaleType, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
import { RangeProtectionRefRangeService, RangeProtectionRenderModel, RangeProtectionRuleModel, RangeProtectionService, RefRangeService, SheetInterceptorService,
SheetsSelectionsService,
WorkbookPermissionService,
@@ -24,7 +24,6 @@ import { RangeProtectionRefRangeService, RangeProtectionRenderModel, RangeProtec
WorksheetProtectionRuleModel,
} from '@univerjs/sheets';
import { IMenuService, IPlatformService, IShortcutService, MenuService, PlatformService, ShortcutService } from '@univerjs/ui';
-import { Inject, Injector } from '@wendellhu/redi';
import { IRenderManagerService, RenderManagerService } from '@univerjs/engine-render';
const TEST_WORKBOOK_DATA_DEMO: IWorkbookData = {
diff --git a/packages/sheets-ui/src/controllers/menu/__tests__/menu.spec.ts b/packages/sheets-ui/src/controllers/menu/__tests__/menu.spec.ts
index e049f7722f..084e2742e5 100644
--- a/packages/sheets-ui/src/controllers/menu/__tests__/menu.spec.ts
+++ b/packages/sheets-ui/src/controllers/menu/__tests__/menu.spec.ts
@@ -18,15 +18,14 @@ import type { IRange, Univer } from '@univerjs/core';
import {
DisposableCollection,
ICommandService,
- RANGE_TYPE,
-} from '@univerjs/core';
+ Injector,
+ RANGE_TYPE } from '@univerjs/core';
import {
SetBoldCommand,
SetRangeValuesMutation,
SetStyleCommand,
SheetsSelectionsService,
} from '@univerjs/sheets';
-import { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { BoldMenuItemFactory } from '../menu';
diff --git a/packages/sheets-ui/src/controllers/menu/__tests__/row-col.menu.spec.ts b/packages/sheets-ui/src/controllers/menu/__tests__/row-col.menu.spec.ts
index bd27c9c100..9737022c47 100644
--- a/packages/sheets-ui/src/controllers/menu/__tests__/row-col.menu.spec.ts
+++ b/packages/sheets-ui/src/controllers/menu/__tests__/row-col.menu.spec.ts
@@ -18,6 +18,7 @@ import type { Univer, Workbook } from '@univerjs/core';
import {
DisposableCollection,
ICommandService,
+ Injector,
IUniverInstanceService,
RANGE_TYPE,
toDisposable,
@@ -37,7 +38,6 @@ import {
SetSpecificRowsVisibleCommand,
} from '@univerjs/sheets';
import type { ISetSelectionsOperationParams } from '@univerjs/sheets';
-import { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { ShowColMenuItemFactory, ShowRowMenuItemFactory } from '../menu';
diff --git a/packages/sheets-ui/src/controllers/menu/border.menu.ts b/packages/sheets-ui/src/controllers/menu/border.menu.ts
index ddff9e4196..700c8ac1ea 100644
--- a/packages/sheets-ui/src/controllers/menu/border.menu.ts
+++ b/packages/sheets-ui/src/controllers/menu/border.menu.ts
@@ -19,7 +19,7 @@ import type { IBorderInfo } from '@univerjs/sheets';
import { BorderStyleManagerService, RangeProtectionPermissionEditPoint, SetBorderBasicCommand, WorkbookEditablePermission, WorksheetEditPermission, WorksheetSetCellStylePermission } from '@univerjs/sheets';
import type { IMenuSelectorItem } from '@univerjs/ui';
import { getMenuHiddenObservable, MenuGroup, MenuItemType, MenuPosition } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor } from '@univerjs/core';
import { Observable } from 'rxjs';
import { BORDER_LINE_CHILDREN, BORDER_PANEL_COMPONENT } from '../../components/border-panel/interface';
diff --git a/packages/sheets-ui/src/controllers/menu/clear.menu.ts b/packages/sheets-ui/src/controllers/menu/clear.menu.ts
index d5ef4d55e4..a87b3bc42b 100644
--- a/packages/sheets-ui/src/controllers/menu/clear.menu.ts
+++ b/packages/sheets-ui/src/controllers/menu/clear.menu.ts
@@ -18,7 +18,7 @@ import { ClearSelectionAllCommand, ClearSelectionContentCommand, ClearSelectionF
import type { IMenuButtonItem, IMenuSelectorItem } from '@univerjs/ui';
import { getMenuHiddenObservable, MenuGroup, MenuItemType, MenuPosition } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor } from '@univerjs/core';
import { UniverInstanceType } from '@univerjs/core';
import { SheetMenuPosition } from './menu';
import { getCurrentRangeDisable$ } from './menu-util';
diff --git a/packages/sheets-ui/src/controllers/menu/delete.menu.ts b/packages/sheets-ui/src/controllers/menu/delete.menu.ts
index dec8c5e4fa..c135396b79 100644
--- a/packages/sheets-ui/src/controllers/menu/delete.menu.ts
+++ b/packages/sheets-ui/src/controllers/menu/delete.menu.ts
@@ -17,7 +17,7 @@
import type { IMenuButtonItem, IMenuSelectorItem } from '@univerjs/ui';
import { MenuGroup, MenuItemType, MenuPosition } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor } from '@univerjs/core';
import { RangeProtectionPermissionEditPoint, WorkbookEditablePermission, WorksheetDeleteColumnPermission, WorksheetDeleteRowPermission, WorksheetEditPermission } from '@univerjs/sheets';
import { DeleteRangeMoveLeftConfirmCommand } from '../../commands/commands/delete-range-move-left-confirm.command';
import { DeleteRangeMoveUpConfirmCommand } from '../../commands/commands/delete-range-move-up-confirm.command';
diff --git a/packages/sheets-ui/src/controllers/menu/insert.menu.ts b/packages/sheets-ui/src/controllers/menu/insert.menu.ts
index 22b3835095..ecceb30c88 100644
--- a/packages/sheets-ui/src/controllers/menu/insert.menu.ts
+++ b/packages/sheets-ui/src/controllers/menu/insert.menu.ts
@@ -27,7 +27,7 @@ import {
} from '@univerjs/sheets';
import type { IMenuButtonItem, IMenuSelectorItem } from '@univerjs/ui';
import { MenuGroup, MenuItemType, MenuPosition } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor } from '@univerjs/core';
import { InsertRangeMoveDownConfirmCommand } from '../../commands/commands/insert-range-move-down-confirm.command';
import { InsertRangeMoveRightConfirmCommand } from '../../commands/commands/insert-range-move-right-confirm.command';
diff --git a/packages/sheets-ui/src/controllers/menu/menu-util.ts b/packages/sheets-ui/src/controllers/menu/menu-util.ts
index 1435de97ec..202cc7f141 100644
--- a/packages/sheets-ui/src/controllers/menu/menu-util.ts
+++ b/packages/sheets-ui/src/controllers/menu/menu-util.ts
@@ -14,13 +14,12 @@
* limitations under the License.
*/
-import type { ICellDataForSheetInterceptor, IPermissionTypes, IRange, Nullable, Workbook, WorkbookPermissionPointConstructor, Worksheet } from '@univerjs/core';
+import type { IAccessor, ICellDataForSheetInterceptor, IPermissionTypes, IRange, Nullable, Workbook, WorkbookPermissionPointConstructor, Worksheet } from '@univerjs/core';
import { FOCUSING_COMMON_DRAWINGS, IContextService, IPermissionService, IUniverInstanceService, Rectangle, Tools, UniverInstanceType, UserManagerService } from '@univerjs/core';
import { UnitAction } from '@univerjs/protocol';
import type { ICellPermission } from '@univerjs/sheets';
import { RangeProtectionRuleModel, SheetsSelectionsService, WorkbookEditablePermission, WorkbookManageCollaboratorPermission, WorksheetProtectionRuleModel } from '@univerjs/sheets';
-import type { IAccessor } from '@wendellhu/redi';
import type { Observable } from 'rxjs';
import { combineLatest, map, of, startWith, switchMap } from 'rxjs';
diff --git a/packages/sheets-ui/src/controllers/menu/menu.ts b/packages/sheets-ui/src/controllers/menu/menu.ts
index e3102aadeb..d655783049 100644
--- a/packages/sheets-ui/src/controllers/menu/menu.ts
+++ b/packages/sheets-ui/src/controllers/menu/menu.ts
@@ -81,7 +81,7 @@ import {
MenuPosition,
PasteCommand,
} from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor } from '@univerjs/core';
import { combineLatestWith, map, Observable } from 'rxjs';
import {
diff --git a/packages/sheets-ui/src/controllers/menu/merge.menu.ts b/packages/sheets-ui/src/controllers/menu/merge.menu.ts
index 0066eea631..320d97ca44 100644
--- a/packages/sheets-ui/src/controllers/menu/merge.menu.ts
+++ b/packages/sheets-ui/src/controllers/menu/merge.menu.ts
@@ -18,7 +18,7 @@ import { UniverInstanceType } from '@univerjs/core';
import { RangeProtectionPermissionEditPoint, RemoveWorksheetMergeCommand, WorkbookEditablePermission, WorksheetEditPermission, WorksheetSetCellStylePermission, WorksheetSetCellValuePermission } from '@univerjs/sheets';
import type { IMenuButtonItem, IMenuSelectorItem } from '@univerjs/ui';
import { getMenuHiddenObservable, MenuGroup, MenuItemType, MenuPosition } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor } from '@univerjs/core';
import { combineLatestWith, map } from 'rxjs';
import {
diff --git a/packages/sheets-ui/src/controllers/menu/permission-menu-util.ts b/packages/sheets-ui/src/controllers/menu/permission-menu-util.ts
index 2a70cd2c66..d372da168f 100644
--- a/packages/sheets-ui/src/controllers/menu/permission-menu-util.ts
+++ b/packages/sheets-ui/src/controllers/menu/permission-menu-util.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { Workbook } from '@univerjs/core';
+import type { IAccessor, Workbook } from '@univerjs/core';
import { FOCUSING_COMMON_DRAWINGS, IContextService, IPermissionService, IUniverInstanceService, Rectangle, UniverInstanceType, UserManagerService } from '@univerjs/core';
import { RangeProtectionRuleModel, SheetsSelectionsService, WorkbookEditablePermission, WorkbookManageCollaboratorPermission, WorksheetProtectionRuleModel } from '@univerjs/sheets';
-import type { IAccessor } from '@wendellhu/redi';
import { combineLatest, map, merge, of, startWith, switchMap } from 'rxjs';
export function getAddPermissionHidden$(accessor: IAccessor) {
diff --git a/packages/sheets-ui/src/controllers/menu/permission.menu.ts b/packages/sheets-ui/src/controllers/menu/permission.menu.ts
index 0180db9cd3..ae70bcbf15 100644
--- a/packages/sheets-ui/src/controllers/menu/permission.menu.ts
+++ b/packages/sheets-ui/src/controllers/menu/permission.menu.ts
@@ -16,7 +16,7 @@
import type { IMenuButtonItem, IMenuItem, IMenuSelectorItem } from '@univerjs/ui';
import { getMenuHiddenObservable, MenuGroup, MenuItemType, MenuPosition } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor } from '@univerjs/core';
import { UniverInstanceType } from '@univerjs/core';
import { AddRangeProtectionFromContextMenuCommand, AddRangeProtectionFromSheetBarCommand, AddRangeProtectionFromToolbarCommand, DeleteRangeProtectionFromContextMenuCommand, SetRangeProtectionFromContextMenuCommand, ViewSheetPermissionFromContextMenuCommand, ViewSheetPermissionFromSheetBarCommand } from '../../commands/commands/range-protection.command';
diff --git a/packages/sheets-ui/src/controllers/menu/sheet.menu.ts b/packages/sheets-ui/src/controllers/menu/sheet.menu.ts
index 705cf10950..e98bad80f0 100644
--- a/packages/sheets-ui/src/controllers/menu/sheet.menu.ts
+++ b/packages/sheets-ui/src/controllers/menu/sheet.menu.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { Workbook } from '@univerjs/core';
+import type { IAccessor, Workbook } from '@univerjs/core';
import { BooleanNumber, ICommandService, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
import {
CopySheetCommand,
@@ -32,7 +32,6 @@ import {
} from '@univerjs/sheets';
import type { IMenuButtonItem, IMenuSelectorItem } from '@univerjs/ui';
import { getMenuHiddenObservable, MenuItemType } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
import type { Subscriber } from 'rxjs';
import { combineLatest, combineLatestWith, map, Observable } from 'rxjs';
diff --git a/packages/sheets-ui/src/controllers/mobile/mobile-sheet-ui.controller.ts b/packages/sheets-ui/src/controllers/mobile/mobile-sheet-ui.controller.ts
index df8dc41fca..b2e1fb3d5e 100644
--- a/packages/sheets-ui/src/controllers/mobile/mobile-sheet-ui.controller.ts
+++ b/packages/sheets-ui/src/controllers/mobile/mobile-sheet-ui.controller.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import { Disposable, ICommandService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
+import { connectInjector, Disposable, ICommandService, Inject, Injector, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import {
SetBoldCommand,
SetFontFamilyCommand,
@@ -25,9 +25,7 @@ import {
} from '@univerjs/sheets';
import type { IMenuItemFactory, MenuConfig } from '@univerjs/ui';
import { BuiltInUIPart, ComponentManager, ILayoutService, IMenuService, IShortcutService, IUIPartsService } from '@univerjs/ui';
-import { Inject, Injector } from '@wendellhu/redi';
-import { connectInjector } from '@wendellhu/redi/react-bindings';
import {
AddWorksheetMergeAllCommand,
AddWorksheetMergeCommand,
diff --git a/packages/sheets-ui/src/controllers/move-range.controller.ts b/packages/sheets-ui/src/controllers/move-range.controller.ts
index 29ea428e8e..500c64f64e 100644
--- a/packages/sheets-ui/src/controllers/move-range.controller.ts
+++ b/packages/sheets-ui/src/controllers/move-range.controller.ts
@@ -19,11 +19,11 @@ import {
Disposable,
DisposableCollection,
ICommandService,
+ Inject,
toDisposable,
} from '@univerjs/core';
import type { IMoveRangeCommandParams } from '@univerjs/sheets';
import { MoveRangeCommand, SheetsSelectionsService } from '@univerjs/sheets';
-import { Inject } from '@wendellhu/redi';
import type { IRenderContext, IRenderModule } from '@univerjs/engine-render';
import { ISheetSelectionRenderService } from '../services/selection/base-selection-render.service';
diff --git a/packages/sheets-ui/src/controllers/permission/sheet-permission-init.controller.ts b/packages/sheets-ui/src/controllers/permission/sheet-permission-init.controller.ts
index 576ffbeaeb..21ef273c73 100644
--- a/packages/sheets-ui/src/controllers/permission/sheet-permission-init.controller.ts
+++ b/packages/sheets-ui/src/controllers/permission/sheet-permission-init.controller.ts
@@ -15,11 +15,10 @@
*/
import type { Workbook } from '@univerjs/core';
-import { Disposable, IAuthzIoService, IPermissionService, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType, UserManagerService } from '@univerjs/core';
+import { Disposable, IAuthzIoService, Inject, IPermissionService, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType, UserManagerService } from '@univerjs/core';
import type { IRangeProtectionRule, IWorksheetProtectionRenderCellData } from '@univerjs/sheets';
import { defaultWorkbookPermissionPoints, defaultWorksheetPermissionPoint, getAllRangePermissionPoint, getAllWorkbookPermissionPoint, getAllWorksheetPermissionPoint, getAllWorksheetPermissionPointByPointPanel, INTERCEPTOR_POINT, RangeProtectionRenderModel, RangeProtectionRuleModel, SheetInterceptorService, WorksheetEditPermission, WorksheetProtectionPointModel, WorksheetProtectionRuleModel, WorksheetViewPermission } from '@univerjs/sheets';
-import { Inject } from '@wendellhu/redi';
import { IDialogService } from '@univerjs/ui';
import { UnitAction, UnitObject, UniverType } from '@univerjs/protocol';
diff --git a/packages/sheets-ui/src/controllers/permission/sheet-permission-interceptor-base.controller.ts b/packages/sheets-ui/src/controllers/permission/sheet-permission-interceptor-base.controller.ts
index add4f972ed..b72aa6152d 100644
--- a/packages/sheets-ui/src/controllers/permission/sheet-permission-interceptor-base.controller.ts
+++ b/packages/sheets-ui/src/controllers/permission/sheet-permission-interceptor-base.controller.ts
@@ -18,10 +18,9 @@
/* eslint-disable max-lines-per-function */
import type { ICellData, ICellDataForSheetInterceptor, ICommandInfo, IObjectMatrixPrimitiveType, IPermissionTypes, IRange, Nullable, Workbook, WorkbookPermissionPointConstructor, Worksheet } from '@univerjs/core';
-import { Disposable, DisposableCollection, FOCUSING_EDITOR_STANDALONE, ICommandService, IContextService, IPermissionService, isICellData, IUniverInstanceService, LifecycleStages, LocaleService, ObjectMatrix, OnLifecycle, Rectangle, UniverInstanceType } from '@univerjs/core';
+import { Disposable, DisposableCollection, FOCUSING_EDITOR_STANDALONE, ICommandService, IContextService, Inject, IPermissionService, isICellData, IUniverInstanceService, LifecycleStages, LocaleService, ObjectMatrix, OnLifecycle, Rectangle, UniverInstanceType } from '@univerjs/core';
import type { IMoveColsCommandParams, IMoveRangeCommandParams, IMoveRowsCommandParams, ISetRangeValuesCommandParams, ISetSpecificColsVisibleCommandParams, ISetSpecificRowsVisibleCommandParams, ISetWorksheetNameMutationParams } from '@univerjs/sheets';
import { ClearSelectionContentCommand, DeleteRangeMoveLeftCommand, DeleteRangeMoveUpCommand, DeltaColumnWidthCommand, DeltaRowHeightCommand, getSheetCommandTarget, InsertRangeMoveDownCommand, InsertRangeMoveRightCommand, MoveColsCommand, MoveRangeCommand, MoveRowsCommand, RangeProtectionPermissionEditPoint, RangeProtectionPermissionViewPoint, RangeProtectionRuleModel, SetBackgroundColorCommand, SetColWidthCommand, SetRangeValuesCommand, SetRowHeightCommand, SetSelectedColsVisibleCommand, SetSelectedRowsVisibleCommand, SetSpecificColsVisibleCommand, SetSpecificRowsVisibleCommand, SetWorksheetNameCommand, SetWorksheetNameMutation, SetWorksheetOrderCommand, SetWorksheetRowIsAutoHeightCommand, SetWorksheetShowCommand, SheetsSelectionsService, WorkbookCopyPermission, WorkbookEditablePermission, WorkbookHideSheetPermission, WorkbookManageCollaboratorPermission, WorkbookMoveSheetPermission, WorkbookRenameSheetPermission, WorksheetCopyPermission, WorksheetEditPermission, WorksheetProtectionRuleModel, WorksheetSetCellStylePermission, WorksheetSetCellValuePermission, WorksheetSetColumnStylePermission, WorksheetSetRowStylePermission, WorksheetViewPermission } from '@univerjs/sheets';
-import { Inject } from '@wendellhu/redi';
import { IDialogService } from '@univerjs/ui';
import { IMEInputCommand, InsertCommand } from '@univerjs/docs';
import { UnitAction } from '@univerjs/protocol';
diff --git a/packages/sheets-ui/src/controllers/permission/sheet-permission-interceptor-canvas-render.controller.ts b/packages/sheets-ui/src/controllers/permission/sheet-permission-interceptor-canvas-render.controller.ts
index f0092bfb16..255dea062f 100644
--- a/packages/sheets-ui/src/controllers/permission/sheet-permission-interceptor-canvas-render.controller.ts
+++ b/packages/sheets-ui/src/controllers/permission/sheet-permission-interceptor-canvas-render.controller.ts
@@ -16,8 +16,7 @@
import type { ICellDataForSheetInterceptor, IRange, Nullable, Workbook } from '@univerjs/core';
import { getSheetCommandTarget, RangeProtectionRuleModel, SheetsSelectionsService, WorkbookEditablePermission, WorksheetEditPermission, WorksheetSetColumnStylePermission, WorksheetSetRowStylePermission } from '@univerjs/sheets';
-import { Inject, Optional } from '@wendellhu/redi';
-import { DisposableCollection, IPermissionService, IUniverInstanceService, LifecycleStages, OnLifecycle, RANGE_TYPE, Rectangle, RxDisposable, UniverInstanceType } from '@univerjs/core';
+import { DisposableCollection, Inject, IPermissionService, IUniverInstanceService, LifecycleStages, OnLifecycle, Optional, RANGE_TYPE, Rectangle, RxDisposable, UniverInstanceType } from '@univerjs/core';
import type { IRenderContext, IRenderModule, Scene, SpreadsheetSkeleton } from '@univerjs/engine-render';
import { UnitAction } from '@univerjs/protocol';
diff --git a/packages/sheets-ui/src/controllers/permission/sheet-permission-interceptor-clipboard.controller.ts b/packages/sheets-ui/src/controllers/permission/sheet-permission-interceptor-clipboard.controller.ts
index b3fad0d01b..b1da1efb9f 100644
--- a/packages/sheets-ui/src/controllers/permission/sheet-permission-interceptor-clipboard.controller.ts
+++ b/packages/sheets-ui/src/controllers/permission/sheet-permission-interceptor-clipboard.controller.ts
@@ -15,9 +15,8 @@
*/
import type { ICellDataForSheetInterceptor, IRange, Workbook } from '@univerjs/core';
-import { Disposable, DisposableCollection, IUniverInstanceService, LifecycleStages, LocaleService, OnLifecycle, UniverInstanceType } from '@univerjs/core';
+import { Disposable, DisposableCollection, Inject, IUniverInstanceService, LifecycleStages, LocaleService, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import { SheetsSelectionsService } from '@univerjs/sheets';
-import { Inject } from '@wendellhu/redi';
import { UnitAction } from '@univerjs/protocol';
import { ISheetClipboardService } from '../../services/clipboard/clipboard.service';
import { virtualizeDiscreteRanges } from '../utils/range-tools';
diff --git a/packages/sheets-ui/src/controllers/permission/sheet-permission-interceptor-formula-render.controller.ts b/packages/sheets-ui/src/controllers/permission/sheet-permission-interceptor-formula-render.controller.ts
index 5731e26c56..f1105db322 100644
--- a/packages/sheets-ui/src/controllers/permission/sheet-permission-interceptor-formula-render.controller.ts
+++ b/packages/sheets-ui/src/controllers/permission/sheet-permission-interceptor-formula-render.controller.ts
@@ -15,9 +15,8 @@
*/
import type { Workbook } from '@univerjs/core';
-import { DisposableCollection, IPermissionService, IUniverInstanceService, LifecycleStages, OnLifecycle, RxDisposable } from '@univerjs/core';
+import { DisposableCollection, Inject, Injector, IPermissionService, IUniverInstanceService, LifecycleStages, OnLifecycle, RxDisposable } from '@univerjs/core';
import { getSheetCommandTarget, RangeProtectionRenderModel, WorksheetViewPermission } from '@univerjs/sheets';
-import { Inject, Injector } from '@wendellhu/redi';
import type { IRenderContext, IRenderModule } from '@univerjs/engine-render';
import { UnitAction } from '@univerjs/protocol';
import { NullValueObject } from '@univerjs/engine-formula';
diff --git a/packages/sheets-ui/src/controllers/permission/sheet-permission-render.controller.ts b/packages/sheets-ui/src/controllers/permission/sheet-permission-render.controller.ts
index 7ea88204a0..6ff3143e98 100644
--- a/packages/sheets-ui/src/controllers/permission/sheet-permission-render.controller.ts
+++ b/packages/sheets-ui/src/controllers/permission/sheet-permission-render.controller.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { Disposable, IPermissionService, LifecycleStages, OnLifecycle } from '@univerjs/core';
+import { Disposable, Inject, Injector, IPermissionService, LifecycleStages, OnLifecycle } from '@univerjs/core';
import type { MenuConfig } from '@univerjs/ui';
import { ComponentManager, IMenuService } from '@univerjs/ui';
-import { Inject, Injector } from '@wendellhu/redi';
import { CheckMarkSingle, DeleteSingle, LockSingle, ProtectSingle, WriteSingle } from '@univerjs/icons';
import { RangeProtectionRuleModel } from '@univerjs/sheets';
import type { IRenderContext, IRenderModule, Spreadsheet } from '@univerjs/engine-render';
diff --git a/packages/sheets-ui/src/controllers/render-controllers/contextmenu.render-controller.ts b/packages/sheets-ui/src/controllers/render-controllers/contextmenu.render-controller.ts
index 3c1c9d1db4..573bc034e9 100644
--- a/packages/sheets-ui/src/controllers/render-controllers/contextmenu.render-controller.ts
+++ b/packages/sheets-ui/src/controllers/render-controllers/contextmenu.render-controller.ts
@@ -14,16 +14,15 @@
* limitations under the License.
*/
-import type {
- Workbook } from '@univerjs/core';
+import type { Workbook } from '@univerjs/core';
import {
Disposable,
+ Inject,
RANGE_TYPE,
} from '@univerjs/core';
import type { IRenderContext, IRenderModule, Spreadsheet, SpreadsheetColumnHeader, SpreadsheetHeader } from '@univerjs/engine-render';
import { SheetsSelectionsService } from '@univerjs/sheets';
import { IContextMenuService, MenuPosition } from '@univerjs/ui';
-import { Inject } from '@wendellhu/redi';
import { SheetMenuPosition } from '../menu/menu';
import { SHEET_VIEW_KEY } from '../../common/keys';
diff --git a/packages/sheets-ui/src/controllers/render-controllers/editor-bridge.render-controller.ts b/packages/sheets-ui/src/controllers/render-controllers/editor-bridge.render-controller.ts
index 51dc644b20..18cd13bd87 100644
--- a/packages/sheets-ui/src/controllers/render-controllers/editor-bridge.render-controller.ts
+++ b/packages/sheets-ui/src/controllers/render-controllers/editor-bridge.render-controller.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-import type { ICommandInfo, IExecutionOptions, Nullable, Workbook } from '@univerjs/core';
-import { DisposableCollection, ICommandService, IUniverInstanceService, RxDisposable, UniverInstanceType } from '@univerjs/core';
+import type { ICommandInfo, IDisposable, IExecutionOptions, Nullable, Workbook } from '@univerjs/core';
+import { DisposableCollection, ICommandService, Inject, IUniverInstanceService, RxDisposable, UniverInstanceType } from '@univerjs/core';
import type { IRenderContext, IRenderModule } from '@univerjs/engine-render';
import { DeviceInputEventType } from '@univerjs/engine-render';
import type { ISelectionWithStyle } from '@univerjs/sheets';
@@ -24,8 +24,6 @@ import {
SetWorksheetActiveOperation,
SheetsSelectionsService,
} from '@univerjs/sheets';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject } from '@wendellhu/redi';
import { merge } from 'rxjs';
import { IRangeSelectorService } from '@univerjs/ui';
import { SetZoomRatioCommand } from '../../commands/commands/set-zoom-ratio.command';
diff --git a/packages/sheets-ui/src/controllers/render-controllers/freeze.render-controller.ts b/packages/sheets-ui/src/controllers/render-controllers/freeze.render-controller.ts
index 0142cd419a..ea0f74034b 100644
--- a/packages/sheets-ui/src/controllers/render-controllers/freeze.render-controller.ts
+++ b/packages/sheets-ui/src/controllers/render-controllers/freeze.render-controller.ts
@@ -21,6 +21,8 @@ import {
Direction,
Disposable,
ICommandService,
+ Inject,
+ Injector,
InterceptorManager,
RANGE_TYPE,
ThemeService,
@@ -64,7 +66,6 @@ import {
SheetInterceptorService,
SheetsSelectionsService,
} from '@univerjs/sheets';
-import { Inject, Injector } from '@wendellhu/redi';
import { Subscription } from 'rxjs';
import { ScrollCommand } from '../../commands/commands/set-scroll.command';
diff --git a/packages/sheets-ui/src/controllers/render-controllers/header-menu.render-controller.ts b/packages/sheets-ui/src/controllers/render-controllers/header-menu.render-controller.ts
index 4912fb9f1e..d4f6c93867 100644
--- a/packages/sheets-ui/src/controllers/render-controllers/header-menu.render-controller.ts
+++ b/packages/sheets-ui/src/controllers/render-controllers/header-menu.render-controller.ts
@@ -18,6 +18,7 @@ import type { Nullable, Workbook } from '@univerjs/core';
import {
Disposable,
ICommandService,
+ Inject,
RANGE_TYPE,
} from '@univerjs/core';
import type { IMouseEvent, IPointerEvent, IRenderContext, IRenderModule, SpreadsheetColumnHeader, SpreadsheetHeader } from '@univerjs/engine-render';
@@ -25,7 +26,6 @@ import { CURSOR_TYPE, Rect } from '@univerjs/engine-render';
import type { ISetSelectionsOperationParams } from '@univerjs/sheets';
import { SetSelectionsOperation, SheetsSelectionsService } from '@univerjs/sheets';
import { IContextMenuService } from '@univerjs/ui';
-import { Inject } from '@wendellhu/redi';
import { Subscription } from 'rxjs';
import { SHEET_COMPONENT_HEADER_LAYER_INDEX, SHEET_VIEW_KEY } from '../../common/keys';
diff --git a/packages/sheets-ui/src/controllers/render-controllers/header-move.render-controller.ts b/packages/sheets-ui/src/controllers/render-controllers/header-move.render-controller.ts
index c47d43a415..32473b99f1 100644
--- a/packages/sheets-ui/src/controllers/render-controllers/header-move.render-controller.ts
+++ b/packages/sheets-ui/src/controllers/render-controllers/header-move.render-controller.ts
@@ -22,9 +22,9 @@ import type {
} from '@univerjs/core';
import {
createInterceptorKey, Disposable, ICommandService,
+ Inject,
InterceptorManager,
- RANGE_TYPE,
-} from '@univerjs/core';
+ RANGE_TYPE } from '@univerjs/core';
import type { IMouseEvent, IPointerEvent, IRenderContext, IRenderModule, SpreadsheetColumnHeader, SpreadsheetHeader } from '@univerjs/engine-render';
import {
CURSOR_TYPE,
@@ -40,7 +40,6 @@ import {
MoveRowsCommand,
SheetsSelectionsService,
} from '@univerjs/sheets';
-import { Inject } from '@wendellhu/redi';
import { Subscription } from 'rxjs';
import { SHEET_COMPONENT_HEADER_LAYER_INDEX, SHEET_VIEW_KEY } from '../../common/keys';
diff --git a/packages/sheets-ui/src/controllers/render-controllers/header-resize.render-controller.ts b/packages/sheets-ui/src/controllers/render-controllers/header-resize.render-controller.ts
index d5b61c91e3..cbe0c7f309 100644
--- a/packages/sheets-ui/src/controllers/render-controllers/header-resize.render-controller.ts
+++ b/packages/sheets-ui/src/controllers/render-controllers/header-resize.render-controller.ts
@@ -21,6 +21,7 @@ import {
createInterceptorKey,
Disposable,
ICommandService,
+ Inject,
InterceptorManager,
toDisposable,
} from '@univerjs/core';
@@ -32,7 +33,6 @@ import type {
ISetWorksheetRowIsAutoHeightCommandParams,
} from '@univerjs/sheets';
import { DeltaColumnWidthCommand, DeltaRowHeightCommand, SetWorksheetRowIsAutoHeightCommand } from '@univerjs/sheets';
-import { Inject } from '@wendellhu/redi';
import { Subscription } from 'rxjs';
import { SHEET_COMPONENT_HEADER_LAYER_INDEX, SHEET_VIEW_KEY } from '../../common/keys';
diff --git a/packages/sheets-ui/src/controllers/render-controllers/header-unhide.render-controller.ts b/packages/sheets-ui/src/controllers/render-controllers/header-unhide.render-controller.ts
index 3b705ab13f..71e7cc63fa 100644
--- a/packages/sheets-ui/src/controllers/render-controllers/header-unhide.render-controller.ts
+++ b/packages/sheets-ui/src/controllers/render-controllers/header-unhide.render-controller.ts
@@ -17,6 +17,7 @@
import type { Workbook, Worksheet } from '@univerjs/core';
import {
ICommandService,
+ Inject,
RxDisposable,
} from '@univerjs/core';
import type { IRenderContext } from '@univerjs/engine-render';
@@ -37,7 +38,6 @@ import {
SetWorksheetColWidthMutation,
SetWorksheetRowIsAutoHeightMutation,
} from '@univerjs/sheets';
-import { Inject } from '@wendellhu/redi';
import { takeUntil } from 'rxjs';
import { SHEET_COMPONENT_UNHIDE_LAYER_INDEX } from '../../common/keys';
diff --git a/packages/sheets-ui/src/controllers/render-controllers/mobile/mobile-contextmenu.render-controller.ts b/packages/sheets-ui/src/controllers/render-controllers/mobile/mobile-contextmenu.render-controller.ts
index be600d5a38..c1c79733b4 100644
--- a/packages/sheets-ui/src/controllers/render-controllers/mobile/mobile-contextmenu.render-controller.ts
+++ b/packages/sheets-ui/src/controllers/render-controllers/mobile/mobile-contextmenu.render-controller.ts
@@ -15,11 +15,10 @@
*/
import type { Workbook } from '@univerjs/core';
-import { Disposable, RANGE_TYPE, Tools } from '@univerjs/core';
+import { Disposable, Inject, RANGE_TYPE, Tools } from '@univerjs/core';
import { type IPointerEvent, type IRenderContext, type IRenderModule, SHEET_VIEWPORT_KEY } from '@univerjs/engine-render';
import { type ISelectionWithStyle, SheetsSelectionsService } from '@univerjs/sheets';
import { IContextMenuService, ILayoutService, MenuPosition } from '@univerjs/ui';
-import { Inject } from '@wendellhu/redi';
import { ISheetSelectionRenderService } from '../../../services/selection/base-selection-render.service';
/**
diff --git a/packages/sheets-ui/src/controllers/render-controllers/mobile/mobile-scroll.render-controller.ts b/packages/sheets-ui/src/controllers/render-controllers/mobile/mobile-scroll.render-controller.ts
index f4744575cc..141b4d813d 100644
--- a/packages/sheets-ui/src/controllers/render-controllers/mobile/mobile-scroll.render-controller.ts
+++ b/packages/sheets-ui/src/controllers/render-controllers/mobile/mobile-scroll.render-controller.ts
@@ -19,6 +19,7 @@ import {
Direction,
Disposable,
ICommandService,
+ Inject,
IUniverInstanceService,
RANGE_TYPE,
toDisposable,
@@ -27,7 +28,6 @@ import {
import type { IMouseEvent, IPoint, IPointerEvent, IRenderContext, IRenderModule, IScrollObserverParam } from '@univerjs/engine-render';
import { IRenderManagerService, SHEET_VIEWPORT_KEY } from '@univerjs/engine-render';
import { ScrollToCellOperation, SheetsSelectionsService } from '@univerjs/sheets';
-import { Inject } from '@wendellhu/redi';
import { ScrollCommand, SetScrollRelativeCommand } from '../../../commands/commands/set-scroll.command';
import type { IExpandSelectionCommandParams } from '../../../commands/commands/set-selection.command';
diff --git a/packages/sheets-ui/src/controllers/render-controllers/scroll.render-controller.ts b/packages/sheets-ui/src/controllers/render-controllers/scroll.render-controller.ts
index de0c43699b..f76a6f1941 100644
--- a/packages/sheets-ui/src/controllers/render-controllers/scroll.render-controller.ts
+++ b/packages/sheets-ui/src/controllers/render-controllers/scroll.render-controller.ts
@@ -19,14 +19,13 @@ import {
Direction,
Disposable,
ICommandService,
- RANGE_TYPE,
- toDisposable,
-} from '@univerjs/core';
+ Inject,
+ Injector,
+ RANGE_TYPE, toDisposable } from '@univerjs/core';
import type { IRenderContext, IRenderModule, IScrollObserverParam } from '@univerjs/engine-render';
import { IRenderManagerService, SHEET_VIEWPORT_KEY } from '@univerjs/engine-render';
import type { SheetsSelectionsService } from '@univerjs/sheets';
import { getSelectionsService, ScrollToCellOperation } from '@univerjs/sheets';
-import { Inject, Injector } from '@wendellhu/redi';
import { ScrollCommand } from '../../commands/commands/set-scroll.command';
import type { IExpandSelectionCommandParams } from '../../commands/commands/set-selection.command';
diff --git a/packages/sheets-ui/src/controllers/render-controllers/sheet.render-controller.ts b/packages/sheets-ui/src/controllers/render-controllers/sheet.render-controller.ts
index 2369ed4687..711082a088 100644
--- a/packages/sheets-ui/src/controllers/render-controllers/sheet.render-controller.ts
+++ b/packages/sheets-ui/src/controllers/render-controllers/sheet.render-controller.ts
@@ -15,7 +15,7 @@
*/
import type { ICommandInfo, IRange, Workbook, Worksheet } from '@univerjs/core';
-import { CommandType, ICommandService, Rectangle, RxDisposable } from '@univerjs/core';
+import { CommandType, ICommandService, Inject, Rectangle, RxDisposable } from '@univerjs/core';
import type { IRenderContext, IRenderModule, IViewportInfos, IWheelEvent, Scene } from '@univerjs/engine-render';
import {
Layer,
@@ -29,7 +29,6 @@ import {
SpreadsheetRowHeader,
Viewport,
} from '@univerjs/engine-render';
-import { Inject } from '@wendellhu/redi';
import { COMMAND_LISTENER_SKELETON_CHANGE, COMMAND_LISTENER_VALUE_CHANGE, MoveRangeMutation, SetRangeValuesMutation, SetWorksheetActiveOperation } from '@univerjs/sheets';
import { SetScrollRelativeCommand } from '../../commands/commands/set-scroll.command';
diff --git a/packages/sheets-ui/src/controllers/render-controllers/skeleton.render-controller.ts b/packages/sheets-ui/src/controllers/render-controllers/skeleton.render-controller.ts
index c697a2e7a4..50da73fd7e 100644
--- a/packages/sheets-ui/src/controllers/render-controllers/skeleton.render-controller.ts
+++ b/packages/sheets-ui/src/controllers/render-controllers/skeleton.render-controller.ts
@@ -15,8 +15,7 @@
*/
import type { Workbook } from '@univerjs/core';
-import { Disposable, LifecycleStages, OnLifecycle } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { Disposable, Inject, LifecycleStages, OnLifecycle } from '@univerjs/core';
import type { IRenderContext } from '@univerjs/engine-render';
import { SheetSkeletonManagerService } from '../../services/sheet-skeleton-manager.service';
diff --git a/packages/sheets-ui/src/controllers/render-controllers/zoom.render-controller.ts b/packages/sheets-ui/src/controllers/render-controllers/zoom.render-controller.ts
index 4d04ae67c8..d05d2e2172 100644
--- a/packages/sheets-ui/src/controllers/render-controllers/zoom.render-controller.ts
+++ b/packages/sheets-ui/src/controllers/render-controllers/zoom.render-controller.ts
@@ -15,9 +15,8 @@
*/
import type { Workbook } from '@univerjs/core';
-import { Disposable, ICommandService } from '@univerjs/core';
+import { Disposable, ICommandService, Inject } from '@univerjs/core';
import type { IRenderContext, IRenderModule, IWheelEvent } from '@univerjs/engine-render';
-import { Inject } from '@wendellhu/redi';
import { SheetSkeletonManagerService } from '../../services/sheet-skeleton-manager.service';
import { getSheetObject } from '../utils/component-tools';
import { SetZoomRatioCommand } from '../../commands/commands/set-zoom-ratio.command';
diff --git a/packages/sheets-ui/src/controllers/sheet-ui.controller.ts b/packages/sheets-ui/src/controllers/sheet-ui.controller.ts
index db1ac541da..50ae502d2b 100644
--- a/packages/sheets-ui/src/controllers/sheet-ui.controller.ts
+++ b/packages/sheets-ui/src/controllers/sheet-ui.controller.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import { Disposable, ICommandService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
+import { connectInjector, Disposable, ICommandService, Inject, Injector, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import {
SetBoldCommand,
SetFontFamilyCommand,
@@ -25,8 +25,6 @@ import {
} from '@univerjs/sheets';
import type { IMenuItemFactory, MenuConfig } from '@univerjs/ui';
import { BuiltInUIPart, ComponentManager, ILayoutService, IMenuService, IShortcutService, IUIPartsService } from '@univerjs/ui';
-import { Inject, Injector } from '@wendellhu/redi';
-import { connectInjector } from '@wendellhu/redi/react-bindings';
import { ITextSelectionRenderManager } from '@univerjs/engine-render';
import {
diff --git a/packages/sheets-ui/src/controllers/status-bar.controller.ts b/packages/sheets-ui/src/controllers/status-bar.controller.ts
index ad0e6ff21f..7cf55ed5fe 100644
--- a/packages/sheets-ui/src/controllers/status-bar.controller.ts
+++ b/packages/sheets-ui/src/controllers/status-bar.controller.ts
@@ -20,6 +20,7 @@ import {
debounce,
Disposable,
ICommandService,
+ Inject,
InterceptorManager,
IUniverInstanceService,
LifecycleStages,
@@ -43,7 +44,6 @@ import {
SetRangeValuesMutation,
SheetsSelectionsService,
} from '@univerjs/sheets';
-import { Inject } from '@wendellhu/redi';
import type { IStatusBarServiceStatus } from '../services/status-bar.service';
import { IStatusBarService } from '../services/status-bar.service';
diff --git a/packages/sheets-ui/src/controllers/utils/range-tools.ts b/packages/sheets-ui/src/controllers/utils/range-tools.ts
index 535fbc5404..83a5749d45 100644
--- a/packages/sheets-ui/src/controllers/utils/range-tools.ts
+++ b/packages/sheets-ui/src/controllers/utils/range-tools.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import type { IAccessor } from '@wendellhu/redi';
-import type { ICellData, IObjectMatrixPrimitiveType, IRange, Workbook } from '@univerjs/core';
+import type { IAccessor, ICellData, IObjectMatrixPrimitiveType, IRange, Workbook } from '@univerjs/core';
import { IUniverInstanceService, ObjectMatrix, UniverInstanceType } from '@univerjs/core';
export interface IDiscreteRange {
diff --git a/packages/sheets-ui/src/controllers/utils/selections-tools.ts b/packages/sheets-ui/src/controllers/utils/selections-tools.ts
index 87facb1499..09b119a20d 100644
--- a/packages/sheets-ui/src/controllers/utils/selections-tools.ts
+++ b/packages/sheets-ui/src/controllers/utils/selections-tools.ts
@@ -14,11 +14,10 @@
* limitations under the License.
*/
-import type { Workbook } from '@univerjs/core';
+import type { IAccessor, Workbook } from '@univerjs/core';
import { IUniverInstanceService, RANGE_TYPE, Rectangle, UniverInstanceType } from '@univerjs/core';
import type { ISelectionWithStyle } from '@univerjs/sheets';
import { RangeProtectionRuleModel, SheetsSelectionsService } from '@univerjs/sheets';
-import type { IAccessor } from '@wendellhu/redi';
import { combineLatest, map } from 'rxjs';
export function getSheetSelectionsDisabled$(accessor: IAccessor) {
diff --git a/packages/sheets-ui/src/hooks/useHighlightRange.ts b/packages/sheets-ui/src/hooks/useHighlightRange.ts
index a36dc03226..bbcac24e46 100644
--- a/packages/sheets-ui/src/hooks/useHighlightRange.ts
+++ b/packages/sheets-ui/src/hooks/useHighlightRange.ts
@@ -16,7 +16,7 @@
import { useEffect } from 'react';
import type { IRange } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { useDependency } from '@univerjs/core';
import { IMarkSelectionService } from '../services/mark-selection/mark-selection.service';
export const useHighlightRange = (ranges: IRange[] = []) => {
diff --git a/packages/sheets-ui/src/mobile-sheets-ui-plugin.ts b/packages/sheets-ui/src/mobile-sheets-ui-plugin.ts
index 2a2593c380..7c30b4662e 100644
--- a/packages/sheets-ui/src/mobile-sheets-ui-plugin.ts
+++ b/packages/sheets-ui/src/mobile-sheets-ui-plugin.ts
@@ -14,10 +14,8 @@
* limitations under the License.
*/
-import type { Workbook } from '@univerjs/core';
-import { DependentOn, IUniverInstanceService, Plugin, Tools, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import type { Dependency, Workbook } from '@univerjs/core';
+import { DependentOn, Inject, Injector, IUniverInstanceService, Plugin, Tools, UniverInstanceType } from '@univerjs/core';
import { filter } from 'rxjs/operators';
import { IRenderManagerService } from '@univerjs/engine-render';
diff --git a/packages/sheets-ui/src/services/auto-fill/auto-fill.service.ts b/packages/sheets-ui/src/services/auto-fill/auto-fill.service.ts
index 8dbc57bc49..ccf3377207 100644
--- a/packages/sheets-ui/src/services/auto-fill/auto-fill.service.ts
+++ b/packages/sheets-ui/src/services/auto-fill/auto-fill.service.ts
@@ -14,11 +14,13 @@
* limitations under the License.
*/
-import type { IMutationInfo, Nullable, Workbook } from '@univerjs/core';
+import type { IDisposable, IMutationInfo, Nullable, Workbook } from '@univerjs/core';
import {
+ createIdentifier,
Direction,
Disposable,
ICommandService,
+ Inject,
IUndoRedoService,
IUniverInstanceService,
LifecycleStages,
@@ -29,8 +31,6 @@ import {
UniverInstanceType,
} from '@univerjs/core';
import { SetSelectionsOperation, SheetsSelectionsService } from '@univerjs/sheets';
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier, Inject } from '@wendellhu/redi';
import type { Observable } from 'rxjs';
import { BehaviorSubject } from 'rxjs';
diff --git a/packages/sheets-ui/src/services/auto-fill/type.ts b/packages/sheets-ui/src/services/auto-fill/type.ts
index 99616cce8f..6ecf914a59 100644
--- a/packages/sheets-ui/src/services/auto-fill/type.ts
+++ b/packages/sheets-ui/src/services/auto-fill/type.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import type { Direction, ICellData, IMutationInfo, Nullable } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
+import type { Direction, IAccessor, ICellData, IMutationInfo, Nullable } from '@univerjs/core';
import type { IDiscreteRange } from '../../controllers/utils/range-tools';
export enum AutoFillHookType {
diff --git a/packages/sheets-ui/src/services/canvas-pop-manager.service.ts b/packages/sheets-ui/src/services/canvas-pop-manager.service.ts
index 9545243dd3..15385dd6d3 100644
--- a/packages/sheets-ui/src/services/canvas-pop-manager.service.ts
+++ b/packages/sheets-ui/src/services/canvas-pop-manager.service.ts
@@ -14,14 +14,12 @@
* limitations under the License.
*/
-import type { IRange, Nullable, Workbook, Worksheet } from '@univerjs/core';
-import { Disposable, DisposableCollection, ICommandService, IUniverInstanceService, toDisposable, UniverInstanceType } from '@univerjs/core';
+import type { IDisposable, IRange, Nullable, Workbook, Worksheet } from '@univerjs/core';
+import { Disposable, DisposableCollection, ICommandService, Inject, IUniverInstanceService, toDisposable, UniverInstanceType } from '@univerjs/core';
import { IRenderManagerService } from '@univerjs/engine-render';
import type { BaseObject, IBoundRectNoAngle, IRender, SpreadsheetSkeleton, Viewport } from '@univerjs/engine-render';
import type { IPopup } from '@univerjs/ui';
import { ICanvasPopupService } from '@univerjs/ui';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject } from '@wendellhu/redi';
import { BehaviorSubject } from 'rxjs';
import type { ISetWorksheetRowAutoHeightMutationParams } from '@univerjs/sheets';
import { COMMAND_LISTENER_SKELETON_CHANGE, RefRangeService, SetWorksheetRowAutoHeightMutation } from '@univerjs/sheets';
diff --git a/packages/sheets-ui/src/services/cell-alert-manager.service.ts b/packages/sheets-ui/src/services/cell-alert-manager.service.ts
index 1fecc82ba3..476fa68e6a 100644
--- a/packages/sheets-ui/src/services/cell-alert-manager.service.ts
+++ b/packages/sheets-ui/src/services/cell-alert-manager.service.ts
@@ -15,8 +15,8 @@
*/
import { Subject } from 'rxjs';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject } from '@wendellhu/redi';
+import type { IDisposable } from '@univerjs/core';
+import { Inject } from '@univerjs/core';
import type { ISheetLocation } from '@univerjs/sheets';
import { IRenderManagerService } from '@univerjs/engine-render';
import { CELL_ALERT_KEY } from '../views/cell-alert';
diff --git a/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-alignment.spec.ts b/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-alignment.spec.ts
index 7193f8ff75..d1d543f735 100644
--- a/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-alignment.spec.ts
+++ b/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-alignment.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICellData, IStyleData, Nullable, Univer } from '@univerjs/core';
+import type { ICellData, Injector, IStyleData, Nullable, Univer } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, LocaleType, RANGE_TYPE } from '@univerjs/core';
import {
AddWorksheetMergeMutation,
@@ -25,7 +25,6 @@ import {
SetWorksheetRowHeightMutation,
SheetsSelectionsService,
} from '@univerjs/sheets';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { ISheetClipboardService } from '../clipboard.service';
diff --git a/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-border.spec.ts b/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-border.spec.ts
index 4010340b52..6874ad1448 100644
--- a/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-border.spec.ts
+++ b/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-border.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { IBorderData, ICellData, IStyleData, Nullable, Univer } from '@univerjs/core';
+import type { IBorderData, ICellData, Injector, IStyleData, Nullable, Univer } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, LocaleType, RANGE_TYPE } from '@univerjs/core';
import {
AddWorksheetMergeMutation,
@@ -25,7 +25,6 @@ import {
SetWorksheetRowHeightMutation,
SheetsSelectionsService,
} from '@univerjs/sheets';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { ISheetClipboardService } from '../clipboard.service';
diff --git a/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-font.spec.ts b/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-font.spec.ts
index 8893b25132..41f46a5cd3 100644
--- a/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-font.spec.ts
+++ b/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-font.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICellData, IStyleData, Nullable, Univer } from '@univerjs/core';
+import type { ICellData, Injector, IStyleData, Nullable, Univer } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, LocaleType, RANGE_TYPE } from '@univerjs/core';
import {
AddWorksheetMergeMutation,
@@ -25,7 +25,6 @@ import {
SetWorksheetRowHeightMutation,
SheetsSelectionsService,
} from '@univerjs/sheets';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { ISheetClipboardService } from '../clipboard.service';
diff --git a/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-form-excel.spec.ts b/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-form-excel.spec.ts
index 52485a41a1..48d2bb2168 100644
--- a/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-form-excel.spec.ts
+++ b/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-form-excel.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICellData, IStyleData, Nullable, Univer } from '@univerjs/core';
+import type { ICellData, Injector, IStyleData, Nullable, Univer } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, LocaleType, RANGE_TYPE } from '@univerjs/core';
import {
AddWorksheetMergeMutation,
@@ -26,7 +26,6 @@ import {
SetWorksheetRowHeightMutation,
SheetsSelectionsService,
} from '@univerjs/sheets';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { ISheetClipboardService } from '../clipboard.service';
diff --git a/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-from-google.spec.ts b/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-from-google.spec.ts
index d05f89ccf1..1944dc8429 100644
--- a/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-from-google.spec.ts
+++ b/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-from-google.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICellData, IStyleData, Nullable, Univer } from '@univerjs/core';
+import type { ICellData, Injector, IStyleData, Nullable, Univer } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, LocaleType, RANGE_TYPE } from '@univerjs/core';
import {
AddWorksheetMergeMutation,
@@ -26,7 +26,6 @@ import {
SetWorksheetRowHeightMutation,
SheetsSelectionsService,
} from '@univerjs/sheets';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { ISheetClipboardService } from '../clipboard.service';
diff --git a/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-from-notepad.spec.ts b/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-from-notepad.spec.ts
index 5a557a4a9e..7b94193b9e 100644
--- a/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-from-notepad.spec.ts
+++ b/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-from-notepad.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICellData, Nullable, Univer } from '@univerjs/core';
+import type { ICellData, Injector, Nullable, Univer } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, LocaleType, RANGE_TYPE } from '@univerjs/core';
import {
AddWorksheetMergeMutation,
@@ -26,7 +26,6 @@ import {
SetWorksheetRowHeightMutation,
SheetsSelectionsService,
} from '@univerjs/sheets';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { ISheetClipboardService } from '../clipboard.service';
diff --git a/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-rotate.spec.ts b/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-rotate.spec.ts
index 9c7f092ac1..501c8d4bb3 100644
--- a/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-rotate.spec.ts
+++ b/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-paste-rotate.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICellData, IStyleData, Nullable, Univer } from '@univerjs/core';
+import type { ICellData, Injector, IStyleData, Nullable, Univer } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, LocaleType, RANGE_TYPE } from '@univerjs/core';
import {
AddWorksheetMergeMutation,
@@ -25,7 +25,6 @@ import {
SetWorksheetRowHeightMutation,
SheetsSelectionsService,
} from '@univerjs/sheets';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { ISheetClipboardService } from '../clipboard.service';
diff --git a/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-service.spec.ts b/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-service.spec.ts
index 48290704f8..6341a1f095 100644
--- a/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-service.spec.ts
+++ b/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-service.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICellData, IRange, IStyleData, Nullable, Univer } from '@univerjs/core';
+import type { ICellData, Injector, IRange, IStyleData, Nullable, Univer } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, RANGE_TYPE, Rectangle, RedoCommand, UndoCommand } from '@univerjs/core';
import {
AddWorksheetMergeMutation,
@@ -26,7 +26,6 @@ import {
SetWorksheetRowHeightMutation,
SheetsSelectionsService,
} from '@univerjs/sheets';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { ISheetClipboardService, PREDEFINED_HOOK_NAME } from '../clipboard.service';
diff --git a/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-test-bed.ts b/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-test-bed.ts
index 6dab0bfee6..f629541ad9 100644
--- a/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-test-bed.ts
+++ b/packages/sheets-ui/src/services/clipboard/__tests__/clipboard-test-bed.ts
@@ -16,8 +16,8 @@
/* eslint-disable ts/no-explicit-any */
-import type { IWorkbookData } from '@univerjs/core';
-import { DisposableCollection, ILogService, IUniverInstanceService, LocaleService, LocaleType, LogLevel, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
+import type { Dependency, IDisposable, IWorkbookData } from '@univerjs/core';
+import { DisposableCollection, ILogService, Inject, Injector, IUniverInstanceService, LocaleService, LocaleType, LogLevel, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
import { IRenderManagerService, RenderManagerService } from '@univerjs/engine-render';
import { SheetInterceptorService, SheetsSelectionsService } from '@univerjs/sheets';
import {
@@ -28,8 +28,6 @@ import {
INotificationService,
IPlatformService,
} from '@univerjs/ui';
-import type { Dependency, IDisposable } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
import { CalculateFormulaService, DefinedNamesService, FormulaCurrentConfigService, FormulaDataModel, FormulaRuntimeService, IDefinedNamesService, IFormulaCurrentConfigService, IFormulaRuntimeService, LexerTreeBuilder } from '@univerjs/engine-formula';
import { SheetClipboardController } from '../../../controllers/clipboard/clipboard.controller';
diff --git a/packages/sheets-ui/src/services/clipboard/clipboard.service.ts b/packages/sheets-ui/src/services/clipboard/clipboard.service.ts
index 7a688cbae0..435f158280 100644
--- a/packages/sheets-ui/src/services/clipboard/clipboard.service.ts
+++ b/packages/sheets-ui/src/services/clipboard/clipboard.service.ts
@@ -14,22 +14,22 @@
* limitations under the License.
*/
-import type { ICellData, IMutationInfo, IRange, Nullable, Workbook, Worksheet } from '@univerjs/core';
+import type { ICellData, IDisposable, IMutationInfo, IRange, Nullable, Workbook, Worksheet } from '@univerjs/core';
import {
+ createIdentifier,
Disposable,
ErrorService,
extractPureTextFromCell,
ICommandService,
ILogService,
+ Inject,
+ Injector,
IUndoRedoService,
IUniverInstanceService,
LocaleService,
ObjectMatrix,
ThemeService,
- toDisposable,
- Tools,
- UniverInstanceType,
-} from '@univerjs/core';
+ toDisposable, Tools, UniverInstanceType } from '@univerjs/core';
import type { ISetSelectionsOperationParams } from '@univerjs/sheets';
import {
getPrimaryForRange,
@@ -37,8 +37,6 @@ import {
SheetsSelectionsService,
} from '@univerjs/sheets';
import { HTML_CLIPBOARD_MIME_TYPE, IClipboardInterfaceService, INotificationService, IPlatformService, PLAIN_TEXT_CLIPBOARD_MIME_TYPE } from '@univerjs/ui';
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier, Inject, Injector } from '@wendellhu/redi';
import { BehaviorSubject } from 'rxjs';
import { PastePluginLark, PastePluginUniver, PastePluginWord } from '@univerjs/docs-ui';
diff --git a/packages/sheets-ui/src/services/editor-bridge.service.ts b/packages/sheets-ui/src/services/editor-bridge.service.ts
index 923b60950b..771a97087a 100644
--- a/packages/sheets-ui/src/services/editor-bridge.service.ts
+++ b/packages/sheets-ui/src/services/editor-bridge.service.ts
@@ -14,15 +14,17 @@
* limitations under the License.
*/
-import type { ICellDataForSheetInterceptor, IPosition, ISelectionCell, Nullable, Workbook } from '@univerjs/core';
+import type { ICellDataForSheetInterceptor, IDisposable, IPosition, ISelectionCell, Nullable, Workbook } from '@univerjs/core';
import {
CellValueType,
+ createIdentifier,
createInterceptorKey,
Disposable,
DOCS_NORMAL_EDITOR_UNIT_ID_KEY,
FOCUSING_EDITOR_STANDALONE,
FOCUSING_UNIVER_EDITOR_STANDALONE_SINGLE_MODE,
IContextService,
+ Inject,
InterceptorManager,
IUniverInstanceService,
makeCellToSelection,
@@ -36,8 +38,6 @@ import type { ISheetLocation, SheetsSelectionsService } from '@univerjs/sheets';
import { IRefSelectionsService } from '@univerjs/sheets';
import { IEditorService } from '@univerjs/ui';
import type { KeyCode } from '@univerjs/ui';
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier, Inject } from '@wendellhu/redi';
import type { Observable } from 'rxjs';
import { BehaviorSubject } from 'rxjs';
diff --git a/packages/sheets-ui/src/services/editor/cell-editor-manager.service.ts b/packages/sheets-ui/src/services/editor/cell-editor-manager.service.ts
index f17616504c..3cf30bd681 100644
--- a/packages/sheets-ui/src/services/editor/cell-editor-manager.service.ts
+++ b/packages/sheets-ui/src/services/editor/cell-editor-manager.service.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IPosition, Nullable } from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier } from '@wendellhu/redi';
+import type { IDisposable, IPosition, Nullable } from '@univerjs/core';
+import { createIdentifier } from '@univerjs/core';
import type { Observable } from 'rxjs';
import { BehaviorSubject } from 'rxjs';
diff --git a/packages/sheets-ui/src/services/editor/formula-editor-manager.service.ts b/packages/sheets-ui/src/services/editor/formula-editor-manager.service.ts
index bfa7df5586..d5a0dad3e1 100644
--- a/packages/sheets-ui/src/services/editor/formula-editor-manager.service.ts
+++ b/packages/sheets-ui/src/services/editor/formula-editor-manager.service.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { Nullable } from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier } from '@wendellhu/redi';
+import type { IDisposable, Nullable } from '@univerjs/core';
+import { createIdentifier } from '@univerjs/core';
import type { Observable } from 'rxjs';
import { BehaviorSubject, Subject } from 'rxjs';
diff --git a/packages/sheets-ui/src/services/format-painter/format-painter.service.ts b/packages/sheets-ui/src/services/format-painter/format-painter.service.ts
index 599b59ac6f..d5789f0cdb 100644
--- a/packages/sheets-ui/src/services/format-painter/format-painter.service.ts
+++ b/packages/sheets-ui/src/services/format-painter/format-painter.service.ts
@@ -15,9 +15,8 @@
*/
import type { IMutationInfo, IRange, IStyleData } from '@univerjs/core';
-import { Disposable, ICommandService, ILogService, IUndoRedoService, ObjectMatrix, ThemeService } from '@univerjs/core';
+import { createIdentifier, Disposable, ICommandService, ILogService, Inject, IUndoRedoService, ObjectMatrix, ThemeService } from '@univerjs/core';
import { SetRangeValuesMutation, SheetsSelectionsService } from '@univerjs/sheets';
-import { createIdentifier, Inject } from '@wendellhu/redi';
import type { Observable } from 'rxjs';
import { BehaviorSubject } from 'rxjs';
diff --git a/packages/sheets-ui/src/services/mark-selection/mark-selection.service.ts b/packages/sheets-ui/src/services/mark-selection/mark-selection.service.ts
index af067ce91d..242d0d376f 100644
--- a/packages/sheets-ui/src/services/mark-selection/mark-selection.service.ts
+++ b/packages/sheets-ui/src/services/mark-selection/mark-selection.service.ts
@@ -15,10 +15,9 @@
*/
import type { Workbook } from '@univerjs/core';
-import { Disposable, IUniverInstanceService, ThemeService, Tools, UniverInstanceType } from '@univerjs/core';
+import { createIdentifier, Disposable, Inject, IUniverInstanceService, ThemeService, Tools, UniverInstanceType } from '@univerjs/core';
import { IRenderManagerService } from '@univerjs/engine-render';
import type { ISelectionWithStyle } from '@univerjs/sheets';
-import { createIdentifier, Inject } from '@wendellhu/redi';
// import { ISheetSelectionRenderService } from '../selection/base-selection-render.service';
import { SelectionControl } from '../selection/selection-shape';
diff --git a/packages/sheets-ui/src/services/permission/worksheet-permission-render.service.ts b/packages/sheets-ui/src/services/permission/worksheet-permission-render.service.ts
index 92c6f4dfc0..9da6c4cfca 100644
--- a/packages/sheets-ui/src/services/permission/worksheet-permission-render.service.ts
+++ b/packages/sheets-ui/src/services/permission/worksheet-permission-render.service.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { Inject } from '@wendellhu/redi';
+import { Disposable, Inject, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import { IRenderManagerService } from '@univerjs/engine-render';
import type { Spreadsheet } from '@univerjs/engine-render';
-import { Disposable, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import { worksheetProtectionKey, WorksheetProtectionRenderExtension } from '../../views/permission/extensions/worksheet-permission.render';
@OnLifecycle(LifecycleStages.Ready, WorksheetProtectionRenderService)
diff --git a/packages/sheets-ui/src/services/scroll-manager.service.ts b/packages/sheets-ui/src/services/scroll-manager.service.ts
index f8ae44602f..af68f54a77 100644
--- a/packages/sheets-ui/src/services/scroll-manager.service.ts
+++ b/packages/sheets-ui/src/services/scroll-manager.service.ts
@@ -17,7 +17,7 @@
import type { Nullable, Workbook } from '@univerjs/core';
import { BehaviorSubject } from 'rxjs';
import type { IRenderContext, IRenderModule } from '@univerjs/engine-render';
-import { Inject } from '@wendellhu/redi';
+import { Inject } from '@univerjs/core';
import { SheetSkeletonManagerService } from './sheet-skeleton-manager.service';
export interface IViewportScrollState {
diff --git a/packages/sheets-ui/src/services/selection/base-selection-render.service.ts b/packages/sheets-ui/src/services/selection/base-selection-render.service.ts
index 19de6815cf..e343ed80c8 100644
--- a/packages/sheets-ui/src/services/selection/base-selection-render.service.ts
+++ b/packages/sheets-ui/src/services/selection/base-selection-render.service.ts
@@ -16,6 +16,7 @@
import type {
IInterceptor,
+ Injector,
IRange,
IRangeWithCoord,
ISelectionCell,
@@ -24,13 +25,13 @@ import type {
Nullable,
ThemeService,
} from '@univerjs/core';
-import { Disposable, InterceptorManager, makeCellToSelection, RANGE_TYPE, UniverInstanceType } from '@univerjs/core';
+import {
+ createIdentifier, Disposable, InterceptorManager, makeCellToSelection, RANGE_TYPE, UniverInstanceType } from '@univerjs/core';
import type { IMouseEvent, IPointerEvent, IRenderManagerService, IRenderModule, Scene, SpreadsheetSkeleton, Viewport } from '@univerjs/engine-render';
import { ScrollTimer, ScrollTimerType, SHEET_VIEWPORT_KEY, Vector2 } from '@univerjs/engine-render';
import type { ISelectionStyle, ISelectionWithCoordAndStyle, ISelectionWithStyle } from '@univerjs/sheets';
import { getNormalSelectionStyle, transformCellDataToSelectionData } from '@univerjs/sheets';
import type { IShortcutService } from '@univerjs/ui';
-import { createIdentifier, type Injector } from '@wendellhu/redi';
import type { Observable, Subscription } from 'rxjs';
import { BehaviorSubject, Subject } from 'rxjs';
diff --git a/packages/sheets-ui/src/services/selection/mobile-selection-render.service.ts b/packages/sheets-ui/src/services/selection/mobile-selection-render.service.ts
index 7b6fa7eba3..c67ac422a7 100644
--- a/packages/sheets-ui/src/services/selection/mobile-selection-render.service.ts
+++ b/packages/sheets-ui/src/services/selection/mobile-selection-render.service.ts
@@ -18,6 +18,7 @@
/* eslint-disable max-lines-per-function */
import type {
EventState,
+ IDisposable,
IRange,
IRangeWithCoord,
ISelectionCellWithMergeInfo,
@@ -27,7 +28,11 @@ import type {
import {
ICommandService,
IContextService,
- ILogService, RANGE_TYPE, ThemeService,
+ ILogService,
+ Inject,
+ Injector,
+ RANGE_TYPE,
+ ThemeService,
toDisposable,
} from '@univerjs/core';
import type { IMouseEvent, IPointerEvent, IRenderContext, IRenderModule, Scene, Viewport } from '@univerjs/engine-render';
@@ -35,8 +40,6 @@ import { IRenderManagerService, ScrollTimer, ScrollTimerType, SHEET_VIEWPORT_KEY
import type { ISelectionWithCoordAndStyle, ISetSelectionsOperationParams, WorkbookSelections } from '@univerjs/sheets';
import { convertSelectionDataToRange, DISABLE_NORMAL_SELECTIONS, SelectionMoveType, SetSelectionsOperation, SheetsSelectionsService } from '@univerjs/sheets';
import { IShortcutService } from '@univerjs/ui';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
import { distinctUntilChanged, startWith } from 'rxjs';
import type { ISheetObjectParam } from '../../controllers/utils/component-tools';
import { getCoordByOffset, getSheetObject } from '../../controllers/utils/component-tools';
diff --git a/packages/sheets-ui/src/services/selection/selection-render.service.ts b/packages/sheets-ui/src/services/selection/selection-render.service.ts
index 5f282183c2..c28e4cd5ad 100644
--- a/packages/sheets-ui/src/services/selection/selection-render.service.ts
+++ b/packages/sheets-ui/src/services/selection/selection-render.service.ts
@@ -14,15 +14,13 @@
* limitations under the License.
*/
-import type { Nullable, Workbook } from '@univerjs/core';
-import { ICommandService, IContextService, ILogService, RANGE_TYPE, ThemeService, toDisposable } from '@univerjs/core';
+import type { IDisposable, Nullable, Workbook } from '@univerjs/core';
+import { ICommandService, IContextService, ILogService, Inject, Injector, RANGE_TYPE, ThemeService, toDisposable } from '@univerjs/core';
import type { IMouseEvent, IPointerEvent, IRenderContext, IRenderModule } from '@univerjs/engine-render';
import { IRenderManagerService, ScrollTimerType, SHEET_VIEWPORT_KEY, Vector2 } from '@univerjs/engine-render';
import type { ISelectionWithCoordAndStyle, ISelectionWithStyle, ISetSelectionsOperationParams, WorkbookSelections } from '@univerjs/sheets';
import { convertSelectionDataToRange, DISABLE_NORMAL_SELECTIONS, getNormalSelectionStyle, SelectionMoveType, SetSelectionsOperation, SheetsSelectionsService } from '@univerjs/sheets';
import { IShortcutService } from '@univerjs/ui';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
import { distinctUntilChanged, startWith } from 'rxjs';
import { SheetSkeletonManagerService } from '../sheet-skeleton-manager.service';
import type { ISheetObjectParam } from '../../controllers/utils/component-tools';
diff --git a/packages/sheets-ui/src/services/selection/selection-shape-extension.ts b/packages/sheets-ui/src/services/selection/selection-shape-extension.ts
index 7f354ade4f..ab8b67ec9c 100644
--- a/packages/sheets-ui/src/services/selection/selection-shape-extension.ts
+++ b/packages/sheets-ui/src/services/selection/selection-shape-extension.ts
@@ -15,12 +15,11 @@
*/
/* eslint-disable max-lines-per-function */
-import type { IFreeze, IRangeWithCoord, Nullable, ThemeService } from '@univerjs/core';
-import { ColorKit, UniverInstanceType } from '@univerjs/core';
+import type { IFreeze, Injector, IRangeWithCoord, Nullable, ThemeService } from '@univerjs/core';
+import { ColorKit, Quantity, UniverInstanceType } from '@univerjs/core';
import type { IMouseEvent, IPointerEvent, Scene, SpreadsheetSkeleton, Viewport } from '@univerjs/engine-render';
import { CURSOR_TYPE, IRenderManagerService, isRectIntersect, Rect, ScrollTimer, ScrollTimerType, SHEET_VIEWPORT_KEY, Vector2 } from '@univerjs/engine-render';
import { getNormalSelectionStyle, SELECTION_CONTROL_BORDER_BUFFER_WIDTH } from '@univerjs/sheets';
-import { type Injector, Quantity } from '@wendellhu/redi';
import type { Subscription } from 'rxjs';
import { SheetSkeletonManagerService } from '../sheet-skeleton-manager.service';
diff --git a/packages/sheets-ui/src/services/sheet-bar/sheet-bar.service.ts b/packages/sheets-ui/src/services/sheet-bar/sheet-bar.service.ts
index 82650ac859..b13ebbec1f 100644
--- a/packages/sheets-ui/src/services/sheet-bar/sheet-bar.service.ts
+++ b/packages/sheets-ui/src/services/sheet-bar/sheet-bar.service.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { Disposable, toDisposable } from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier, Disposable, toDisposable } from '@univerjs/core';
+import type { IDisposable } from '@univerjs/core';
import type { Observable } from 'rxjs';
import { Subject } from 'rxjs';
diff --git a/packages/sheets-ui/src/services/sheet-skeleton-manager.service.ts b/packages/sheets-ui/src/services/sheet-skeleton-manager.service.ts
index 98f3ef97b8..1c15af3bcc 100644
--- a/packages/sheets-ui/src/services/sheet-skeleton-manager.service.ts
+++ b/packages/sheets-ui/src/services/sheet-skeleton-manager.service.ts
@@ -15,10 +15,9 @@
*/
import type { IRange, IRangeWithCoord, Nullable, Workbook, Worksheet } from '@univerjs/core';
-import { Disposable } from '@univerjs/core';
+import { Disposable, Inject, Injector } from '@univerjs/core';
import type { IRenderContext, IRenderModule } from '@univerjs/engine-render';
import { SpreadsheetSkeleton } from '@univerjs/engine-render';
-import { Inject, Injector } from '@wendellhu/redi';
import { BehaviorSubject } from 'rxjs';
export interface ISheetSkeletonManagerParam {
diff --git a/packages/sheets-ui/src/services/sheets-render.service.ts b/packages/sheets-ui/src/services/sheets-render.service.ts
index 4adbbbb181..0e18fe2678 100644
--- a/packages/sheets-ui/src/services/sheets-render.service.ts
+++ b/packages/sheets-ui/src/services/sheets-render.service.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { Workbook } from '@univerjs/core';
+import type { IDisposable, Workbook } from '@univerjs/core';
import {
IContextService,
IUniverInstanceService,
@@ -25,7 +25,6 @@ import {
UniverInstanceType,
} from '@univerjs/core';
import { IRenderManagerService, RENDER_RAW_FORMULA_KEY, Spreadsheet } from '@univerjs/engine-render';
-import type { IDisposable } from '@wendellhu/redi';
import { distinctUntilChanged, takeUntil } from 'rxjs';
/**
diff --git a/packages/sheets-ui/src/services/shortcut-experience.service.ts b/packages/sheets-ui/src/services/shortcut-experience.service.ts
index 3f32a302d7..a5222c4f7d 100644
--- a/packages/sheets-ui/src/services/shortcut-experience.service.ts
+++ b/packages/sheets-ui/src/services/shortcut-experience.service.ts
@@ -14,11 +14,9 @@
* limitations under the License.
*/
-import type { ISelection, ITextRangeParam, Nullable } from '@univerjs/core';
-import { IUniverInstanceService, LocaleService } from '@univerjs/core';
+import type { IDisposable, ISelection, ITextRangeParam, Nullable } from '@univerjs/core';
+import { Inject, IUniverInstanceService, LocaleService } from '@univerjs/core';
import type { KeyCode } from '@univerjs/ui';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject } from '@wendellhu/redi';
export interface IShortcutExperienceSearch {
unitId: string;
diff --git a/packages/sheets-ui/src/services/status-bar.service.ts b/packages/sheets-ui/src/services/status-bar.service.ts
index ca88bdb762..ed3bab052e 100644
--- a/packages/sheets-ui/src/services/status-bar.service.ts
+++ b/packages/sheets-ui/src/services/status-bar.service.ts
@@ -14,11 +14,10 @@
* limitations under the License.
*/
-import type { Nullable } from '@univerjs/core';
+import type { IDisposable, Nullable } from '@univerjs/core';
import type { IFunctionNames } from '@univerjs/engine-formula';
import { FUNCTION_NAMES_MATH, FUNCTION_NAMES_STATISTICAL } from '@univerjs/engine-formula';
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier } from '@univerjs/core';
import type { Observable } from 'rxjs';
import { BehaviorSubject } from 'rxjs';
diff --git a/packages/sheets-ui/src/sheets-ui-plugin.ts b/packages/sheets-ui/src/sheets-ui-plugin.ts
index 8a7ce618eb..9ddbb6acf2 100644
--- a/packages/sheets-ui/src/sheets-ui-plugin.ts
+++ b/packages/sheets-ui/src/sheets-ui-plugin.ts
@@ -14,10 +14,8 @@
* limitations under the License.
*/
-import type { Workbook } from '@univerjs/core';
-import { DependentOn, IUniverInstanceService, Plugin, Tools, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import type { Dependency, Workbook } from '@univerjs/core';
+import { DependentOn, Inject, Injector, IUniverInstanceService, Plugin, Tools, UniverInstanceType } from '@univerjs/core';
import { filter } from 'rxjs/operators';
import { IRenderManagerService } from '@univerjs/engine-render';
diff --git a/packages/sheets-ui/src/views/count-bar/ZoomSlider.tsx b/packages/sheets-ui/src/views/count-bar/ZoomSlider.tsx
index 8b4dc318e1..0f491b22f3 100644
--- a/packages/sheets-ui/src/views/count-bar/ZoomSlider.tsx
+++ b/packages/sheets-ui/src/views/count-bar/ZoomSlider.tsx
@@ -19,10 +19,10 @@ import {
ICommandService,
IUniverInstanceService,
UniverInstanceType,
+ useDependency,
} from '@univerjs/core';
import { Slider } from '@univerjs/design';
import { SetWorksheetActiveOperation } from '@univerjs/sheets';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import React, { useCallback, useEffect, useState } from 'react';
import { SetZoomRatioCommand } from '../../commands/commands/set-zoom-ratio.command';
diff --git a/packages/sheets-ui/src/views/defined-name/DefinedName.tsx b/packages/sheets-ui/src/views/defined-name/DefinedName.tsx
index 17df487f7c..8d2d7e6380 100644
--- a/packages/sheets-ui/src/views/defined-name/DefinedName.tsx
+++ b/packages/sheets-ui/src/views/defined-name/DefinedName.tsx
@@ -18,7 +18,7 @@ import React, { useEffect } from 'react';
import { Dropdown, Input } from '@univerjs/design';
import { MoreDownSingle } from '@univerjs/icons';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { useDependency } from '@univerjs/core';
import { IDefinedNamesService } from '@univerjs/engine-formula';
import clsx from 'clsx';
import styles from './index.module.less';
diff --git a/packages/sheets-ui/src/views/defined-name/DefinedNameContainer.tsx b/packages/sheets-ui/src/views/defined-name/DefinedNameContainer.tsx
index 13e87a9655..9e73e1f15b 100644
--- a/packages/sheets-ui/src/views/defined-name/DefinedNameContainer.tsx
+++ b/packages/sheets-ui/src/views/defined-name/DefinedNameContainer.tsx
@@ -17,8 +17,7 @@
import React, { useEffect, useState } from 'react';
import type { Nullable, Workbook } from '@univerjs/core';
-import { ICommandService, IUniverInstanceService, LocaleService, Tools, UniverInstanceType } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { ICommandService, IUniverInstanceService, LocaleService, Tools, UniverInstanceType, useDependency } from '@univerjs/core';
import { CheckMarkSingle, DeleteSingle, IncreaseSingle } from '@univerjs/icons';
import type { IDefinedNamesServiceParam } from '@univerjs/engine-formula';
import { IDefinedNamesService, serializeRangeWithSheet } from '@univerjs/engine-formula';
diff --git a/packages/sheets-ui/src/views/defined-name/DefinedNameInput.tsx b/packages/sheets-ui/src/views/defined-name/DefinedNameInput.tsx
index a77a30e4f4..80e78daf45 100644
--- a/packages/sheets-ui/src/views/defined-name/DefinedNameInput.tsx
+++ b/packages/sheets-ui/src/views/defined-name/DefinedNameInput.tsx
@@ -18,8 +18,7 @@ import React, { useEffect, useState } from 'react';
import { RangeSelector, TextEditor } from '@univerjs/ui';
import type { IUnitRange, Nullable, Workbook } from '@univerjs/core';
-import { AbsoluteRefType, createInternalEditorID, IUniverInstanceService, LocaleService, Tools, UniverInstanceType } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { AbsoluteRefType, createInternalEditorID, IUniverInstanceService, LocaleService, Tools, UniverInstanceType, useDependency } from '@univerjs/core';
import { Button, Input, Radio, RadioGroup, Select } from '@univerjs/design';
import { IDefinedNamesService, type IDefinedNamesServiceParam, IFunctionService, isReferenceStrings, isReferenceStringWithEffectiveColumn, LexerTreeBuilder, operatorToken, serializeRangeToRefString } from '@univerjs/engine-formula';
import { ErrorSingle } from '@univerjs/icons';
diff --git a/packages/sheets-ui/src/views/defined-name/DefinedNameOverlay.tsx b/packages/sheets-ui/src/views/defined-name/DefinedNameOverlay.tsx
index 61f237c1a2..85feb6513f 100644
--- a/packages/sheets-ui/src/views/defined-name/DefinedNameOverlay.tsx
+++ b/packages/sheets-ui/src/views/defined-name/DefinedNameOverlay.tsx
@@ -17,8 +17,7 @@
import React, { useEffect, useState } from 'react';
import type { Workbook } from '@univerjs/core';
-import { ICommandService, IUniverInstanceService, LocaleService, UniverInstanceType } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { ICommandService, IUniverInstanceService, LocaleService, UniverInstanceType, useDependency } from '@univerjs/core';
import type { IDefinedNamesServiceParam } from '@univerjs/engine-formula';
import { IDefinedNamesService } from '@univerjs/engine-formula';
import { SidebarDefinedNameOperation } from '../../commands/operations/sidebar-defined-name.operation';
diff --git a/packages/sheets-ui/src/views/editor-container/EditorContainer.tsx b/packages/sheets-ui/src/views/editor-container/EditorContainer.tsx
index f15573f6ee..3fad2f1dd1 100644
--- a/packages/sheets-ui/src/views/editor-container/EditorContainer.tsx
+++ b/packages/sheets-ui/src/views/editor-container/EditorContainer.tsx
@@ -15,8 +15,7 @@
*/
import type { IDocumentData } from '@univerjs/core';
-import { DEFAULT_EMPTY_DOCUMENT_VALUE, DOCS_NORMAL_EDITOR_UNIT_ID_KEY, DocumentFlavor, IContextService } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { DEFAULT_EMPTY_DOCUMENT_VALUE, DOCS_NORMAL_EDITOR_UNIT_ID_KEY, DocumentFlavor, IContextService, useDependency } from '@univerjs/core';
import React, { useEffect, useState } from 'react';
import { FIX_ONE_PIXEL_BLUR_OFFSET } from '@univerjs/engine-render';
diff --git a/packages/sheets-ui/src/views/formula-bar/FormulaBar.tsx b/packages/sheets-ui/src/views/formula-bar/FormulaBar.tsx
index 4c81cd1feb..5b8cc886be 100644
--- a/packages/sheets-ui/src/views/formula-bar/FormulaBar.tsx
+++ b/packages/sheets-ui/src/views/formula-bar/FormulaBar.tsx
@@ -15,11 +15,10 @@
*/
import type { Nullable, Workbook } from '@univerjs/core';
-import { BooleanNumber, DEFAULT_EMPTY_DOCUMENT_VALUE, DOCS_FORMULA_BAR_EDITOR_UNIT_ID_KEY, DocumentFlavor, HorizontalAlign, IPermissionService, IUniverInstanceService, Rectangle, ThemeService, UniverInstanceType, VerticalAlign, WrapStrategy } from '@univerjs/core';
+import { BooleanNumber, DEFAULT_EMPTY_DOCUMENT_VALUE, DOCS_FORMULA_BAR_EDITOR_UNIT_ID_KEY, DocumentFlavor, HorizontalAlign, IPermissionService, IUniverInstanceService, Rectangle, ThemeService, UniverInstanceType, useDependency, VerticalAlign, WrapStrategy } from '@univerjs/core';
import { DeviceInputEventType } from '@univerjs/engine-render';
import { CheckMarkSingle, CloseSingle, DropdownSingle, FxSingle } from '@univerjs/icons';
import { KeyCode, ProgressBar, TextEditor } from '@univerjs/ui';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import clsx from 'clsx';
import React, { useEffect, useLayoutEffect, useState } from 'react';
diff --git a/packages/sheets-ui/src/views/mobile/sheet-bar/MobileSheetBar.tsx b/packages/sheets-ui/src/views/mobile/sheet-bar/MobileSheetBar.tsx
index 5ea2702140..bf01e84fd6 100644
--- a/packages/sheets-ui/src/views/mobile/sheet-bar/MobileSheetBar.tsx
+++ b/packages/sheets-ui/src/views/mobile/sheet-bar/MobileSheetBar.tsx
@@ -16,9 +16,8 @@
import React, { useCallback, useEffect, useState } from 'react';
import clsx from 'clsx';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { ICommandService, useDependency } from '@univerjs/core';
import type { ICommandInfo, Workbook } from '@univerjs/core';
-import { ICommandService } from '@univerjs/core';
import type { ISetWorksheetActiveOperationParams } from '@univerjs/sheets';
import {
InsertSheetMutation,
diff --git a/packages/sheets-ui/src/views/operate-container/AutoFillPopupMenu.tsx b/packages/sheets-ui/src/views/operate-container/AutoFillPopupMenu.tsx
index 979a27191c..16f520fd4d 100644
--- a/packages/sheets-ui/src/views/operate-container/AutoFillPopupMenu.tsx
+++ b/packages/sheets-ui/src/views/operate-container/AutoFillPopupMenu.tsx
@@ -15,11 +15,10 @@
*/
import type { ICommandInfo, IExecutionOptions } from '@univerjs/core';
-import { ICommandService, IUniverInstanceService, LocaleService, toDisposable } from '@univerjs/core';
+import { ICommandService, IUniverInstanceService, LocaleService, toDisposable, useDependency } from '@univerjs/core';
import { Dropdown } from '@univerjs/design';
import { IRenderManagerService } from '@univerjs/engine-render';
import { Autofill, CheckMarkSingle, MoreDownSingle } from '@univerjs/icons';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import clsx from 'clsx';
import React, { useCallback, useEffect, useMemo, useState } from 'react';
diff --git a/packages/sheets-ui/src/views/permission/error-msg-dialog/index.tsx b/packages/sheets-ui/src/views/permission/error-msg-dialog/index.tsx
index 17bfd0de88..f7c85f93c2 100644
--- a/packages/sheets-ui/src/views/permission/error-msg-dialog/index.tsx
+++ b/packages/sheets-ui/src/views/permission/error-msg-dialog/index.tsx
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { LocaleService } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { LocaleService, useDependency } from '@univerjs/core';
import React from 'react';
import { Button } from '@univerjs/design';
import { IDialogService } from '@univerjs/ui';
diff --git a/packages/sheets-ui/src/views/permission/footer/permission-detail-footer.tsx b/packages/sheets-ui/src/views/permission/footer/permission-detail-footer.tsx
index 89d08355ec..7904e95f49 100644
--- a/packages/sheets-ui/src/views/permission/footer/permission-detail-footer.tsx
+++ b/packages/sheets-ui/src/views/permission/footer/permission-detail-footer.tsx
@@ -15,10 +15,9 @@
*/
import { Button } from '@univerjs/design';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { IAuthzIoService, ICommandService, LocaleService, useDependency } from '@univerjs/core';
import React from 'react';
import { ISidebarService, useObservable } from '@univerjs/ui';
-import { IAuthzIoService, ICommandService, LocaleService } from '@univerjs/core';
import { CreateRequest_WorkSheetObjectScope, UnitAction, UnitObject, UnitRole } from '@univerjs/protocol';
import { AddRangeProtectionCommand } from '@univerjs/sheets';
import { SheetPermissionPanelModel, viewState } from '../../../services/permission/sheet-permission-panel.model';
diff --git a/packages/sheets-ui/src/views/permission/footer/permission-list-footer.tsx b/packages/sheets-ui/src/views/permission/footer/permission-list-footer.tsx
index c4bc01dcbd..8b6b183b85 100644
--- a/packages/sheets-ui/src/views/permission/footer/permission-list-footer.tsx
+++ b/packages/sheets-ui/src/views/permission/footer/permission-list-footer.tsx
@@ -15,11 +15,10 @@
*/
import { Button } from '@univerjs/design';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { IPermissionService, IUniverInstanceService, LocaleService, UniverInstanceType, useDependency } from '@univerjs/core';
import React from 'react';
import { ISidebarService, useObservable } from '@univerjs/ui';
import type { Workbook } from '@univerjs/core';
-import { IPermissionService, IUniverInstanceService, LocaleService, UniverInstanceType } from '@univerjs/core';
import { WorkbookEditablePermission, WorkbookManageCollaboratorPermission, WorksheetProtectionRuleModel } from '@univerjs/sheets';
import { SheetPermissionPanelModel } from '../../../services/permission/sheet-permission-panel.model';
import { UNIVER_SHEET_PERMISSION_PANEL, UNIVER_SHEET_PERMISSION_PANEL_FOOTER } from '../../../basics/const/permission';
diff --git a/packages/sheets-ui/src/views/permission/panel-detail/index.tsx b/packages/sheets-ui/src/views/permission/panel-detail/index.tsx
index c81c5b1ef6..9af2c30a8d 100644
--- a/packages/sheets-ui/src/views/permission/panel-detail/index.tsx
+++ b/packages/sheets-ui/src/views/permission/panel-detail/index.tsx
@@ -16,9 +16,8 @@
import React, { useEffect, useState } from 'react';
import { Avatar, FormLayout, Input, Radio, RadioGroup, Select } from '@univerjs/design';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { createInternalEditorID, IAuthzIoService, isValidRange, IUniverInstanceService, LocaleService, RANGE_TYPE, Rectangle, UniverInstanceType, useDependency, UserManagerService } from '@univerjs/core';
import type { IRange, Workbook } from '@univerjs/core';
-import { createInternalEditorID, IAuthzIoService, isValidRange, IUniverInstanceService, LocaleService, RANGE_TYPE, Rectangle, UniverInstanceType, UserManagerService } from '@univerjs/core';
import { IDialogService, ISidebarService, RangeSelector, useObservable } from '@univerjs/ui';
import { RangeProtectionRuleModel, setEndForRange, SheetsSelectionsService, WorksheetProtectionRuleModel } from '@univerjs/sheets';
import { serializeRange } from '@univerjs/engine-formula';
diff --git a/packages/sheets-ui/src/views/permission/panel-list/index.tsx b/packages/sheets-ui/src/views/permission/panel-list/index.tsx
index 70a5c4f4d0..c5d3b4d3b2 100644
--- a/packages/sheets-ui/src/views/permission/panel-list/index.tsx
+++ b/packages/sheets-ui/src/views/permission/panel-list/index.tsx
@@ -17,9 +17,8 @@
import React, { useCallback, useEffect, useState } from 'react';
import clsx from 'clsx';
import { Avatar, Tooltip } from '@univerjs/design';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { IAuthzIoService, ICommandService, IPermissionService, IUniverInstanceService, LocaleService, UniverInstanceType, useDependency, UserManagerService } from '@univerjs/core';
import type { IRange, Workbook } from '@univerjs/core';
-import { IAuthzIoService, ICommandService, IPermissionService, IUniverInstanceService, LocaleService, UniverInstanceType, UserManagerService } from '@univerjs/core';
import type { IRangeProtectionRule, IWorksheetProtectionRule } from '@univerjs/sheets';
import { DeleteRangeProtectionCommand, RangeProtectionRuleModel, SetWorksheetActiveOperation, WorkbookManageCollaboratorPermission, WorksheetProtectionRuleModel } from '@univerjs/sheets';
import { ISidebarService, useObservable } from '@univerjs/ui';
diff --git a/packages/sheets-ui/src/views/permission/permission-dialog/index.tsx b/packages/sheets-ui/src/views/permission/permission-dialog/index.tsx
index 0bd445e5ea..e6c9ff2cb1 100644
--- a/packages/sheets-ui/src/views/permission/permission-dialog/index.tsx
+++ b/packages/sheets-ui/src/views/permission/permission-dialog/index.tsx
@@ -18,9 +18,8 @@ import React, { useEffect, useState } from 'react';
import { Button, Switch } from '@univerjs/design';
import clsx from 'clsx';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { IAuthzIoService, ICommandService, IPermissionService, IUniverInstanceService, LocaleService, UniverInstanceType, useDependency } from '@univerjs/core';
import type { Workbook } from '@univerjs/core';
-import { IAuthzIoService, ICommandService, IPermissionService, IUniverInstanceService, LocaleService, UniverInstanceType } from '@univerjs/core';
import { IDialogService } from '@univerjs/ui';
import { getAllWorksheetPermissionPoint, SetWorksheetPermissionPointsCommand, WorksheetProtectionPointModel } from '@univerjs/sheets';
import type { ICollaborator, UnitAction } from '@univerjs/protocol';
diff --git a/packages/sheets-ui/src/views/permission/user-dialog/index.tsx b/packages/sheets-ui/src/views/permission/user-dialog/index.tsx
index bdf2cc9ecf..5e05e1db7c 100644
--- a/packages/sheets-ui/src/views/permission/user-dialog/index.tsx
+++ b/packages/sheets-ui/src/views/permission/user-dialog/index.tsx
@@ -17,8 +17,7 @@
import React, { useState } from 'react';
import { Avatar, Button, Input } from '@univerjs/design';
import clsx from 'clsx';
-import { useDependency } from '@wendellhu/redi/react-bindings';
-import { LocaleService } from '@univerjs/core';
+import { LocaleService, useDependency } from '@univerjs/core';
import { IDialogService } from '@univerjs/ui';
import { type ICollaborator, UnitRole } from '@univerjs/protocol';
import { CheckMarkSingle } from '@univerjs/icons';
diff --git a/packages/sheets-ui/src/views/sheet-bar/SheetBar.tsx b/packages/sheets-ui/src/views/sheet-bar/SheetBar.tsx
index e5beb1137d..3b5d3e5765 100644
--- a/packages/sheets-ui/src/views/sheet-bar/SheetBar.tsx
+++ b/packages/sheets-ui/src/views/sheet-bar/SheetBar.tsx
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { ICommandService, IPermissionService } from '@univerjs/core';
+import { ICommandService, IPermissionService, useDependency } from '@univerjs/core';
import { IncreaseSingle, MoreSingle } from '@univerjs/icons';
import { InsertSheetCommand, WorkbookCreateSheetPermission, WorkbookEditablePermission } from '@univerjs/sheets';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import React, { useEffect, useState } from 'react';
import { useObservable } from '@univerjs/ui';
diff --git a/packages/sheets-ui/src/views/sheet-bar/sheet-bar-menu/SheetBarMenu.tsx b/packages/sheets-ui/src/views/sheet-bar/sheet-bar-menu/SheetBarMenu.tsx
index 84d9a91812..2d9d0a411b 100644
--- a/packages/sheets-ui/src/views/sheet-bar/sheet-bar-menu/SheetBarMenu.tsx
+++ b/packages/sheets-ui/src/views/sheet-bar/sheet-bar-menu/SheetBarMenu.tsx
@@ -15,7 +15,7 @@
*/
import type { ICommandInfo, Workbook } from '@univerjs/core';
-import { BooleanNumber, DisposableCollection, ICommandService, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
+import { BooleanNumber, DisposableCollection, ICommandService, IUniverInstanceService, UniverInstanceType, useDependency } from '@univerjs/core';
import { Dropdown } from '@univerjs/design';
import { CheckMarkSingle, ConvertSingle, EyelashSingle } from '@univerjs/icons';
import {
@@ -29,7 +29,6 @@ import {
SetWorksheetShowCommand,
WorksheetProtectionRuleModel,
} from '@univerjs/sheets';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import React, { useCallback, useEffect, useState } from 'react';
import { useObservable } from '@univerjs/ui';
diff --git a/packages/sheets-ui/src/views/sheet-bar/sheet-bar-tabs/SheetBarItem.tsx b/packages/sheets-ui/src/views/sheet-bar/sheet-bar-tabs/SheetBarItem.tsx
index 459177f80d..a7a5831d15 100644
--- a/packages/sheets-ui/src/views/sheet-bar/sheet-bar-tabs/SheetBarItem.tsx
+++ b/packages/sheets-ui/src/views/sheet-bar/sheet-bar-tabs/SheetBarItem.tsx
@@ -15,8 +15,7 @@
*/
import type { BooleanNumber } from '@univerjs/core';
-import { ColorKit, ThemeService } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { ColorKit, ThemeService, useDependency } from '@univerjs/core';
import React, { useEffect, useState } from 'react';
import styles from './index.module.less';
diff --git a/packages/sheets-ui/src/views/sheet-bar/sheet-bar-tabs/SheetBarTabs.tsx b/packages/sheets-ui/src/views/sheet-bar/sheet-bar-tabs/SheetBarTabs.tsx
index caacfe48ed..10498854a3 100644
--- a/packages/sheets-ui/src/views/sheet-bar/sheet-bar-tabs/SheetBarTabs.tsx
+++ b/packages/sheets-ui/src/views/sheet-bar/sheet-bar-tabs/SheetBarTabs.tsx
@@ -15,7 +15,7 @@
*/
import type { ICommandInfo } from '@univerjs/core';
-import { ICommandService, IPermissionService, LocaleService, nameCharacterCheck } from '@univerjs/core';
+import { ICommandService, IPermissionService, LocaleService, nameCharacterCheck, Quantity, useDependency } from '@univerjs/core';
import { Dropdown } from '@univerjs/design';
import {
InsertSheetMutation,
@@ -33,12 +33,10 @@ import {
WorksheetProtectionRuleModel,
} from '@univerjs/sheets';
import { IConfirmService, Menu, useObservable } from '@univerjs/ui';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import React, { useCallback, useEffect, useRef, useState } from 'react';
import { LockSingle } from '@univerjs/icons';
import { merge } from 'rxjs';
-import { Quantity } from '@wendellhu/redi';
import { SheetMenuPosition } from '../../../controllers/menu/menu';
import { ISheetBarService } from '../../../services/sheet-bar/sheet-bar.service';
import { IEditorBridgeService } from '../../../services/editor-bridge.service';
diff --git a/packages/sheets-ui/src/views/sheet-container/SheetContainer.tsx b/packages/sheets-ui/src/views/sheet-container/SheetContainer.tsx
index c7b86d60db..387e6a98af 100644
--- a/packages/sheets-ui/src/views/sheet-container/SheetContainer.tsx
+++ b/packages/sheets-ui/src/views/sheet-container/SheetContainer.tsx
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { IUniverInstanceService, UniverInstanceType, useDependency } from '@univerjs/core';
import type { Workbook } from '@univerjs/core';
-import { IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
import React from 'react';
import { useObservable } from '@univerjs/ui';
diff --git a/packages/sheets-ui/src/views/status-bar/CopyableStatisticItem.tsx b/packages/sheets-ui/src/views/status-bar/CopyableStatisticItem.tsx
index 5484990825..5a3ffa52bf 100644
--- a/packages/sheets-ui/src/views/status-bar/CopyableStatisticItem.tsx
+++ b/packages/sheets-ui/src/views/status-bar/CopyableStatisticItem.tsx
@@ -14,13 +14,12 @@
* limitations under the License.
*/
-import { LocaleService } from '@univerjs/core';
+import { LocaleService, useDependency } from '@univerjs/core';
import { MessageType, Tooltip } from '@univerjs/design';
import type { IFunctionNames } from '@univerjs/engine-formula';
import { FUNCTION_NAMES_MATH, FUNCTION_NAMES_STATISTICAL, FUNCTION_NAMES_TEXT } from '@univerjs/engine-formula';
import { numfmt } from '@univerjs/engine-numfmt';
import { IClipboardInterfaceService, IMessageService } from '@univerjs/ui';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import React from 'react';
import styles from './index.module.less';
diff --git a/packages/sheets-ui/src/views/status-bar/StatusBar.tsx b/packages/sheets-ui/src/views/status-bar/StatusBar.tsx
index a563316412..c06b77f234 100644
--- a/packages/sheets-ui/src/views/status-bar/StatusBar.tsx
+++ b/packages/sheets-ui/src/views/status-bar/StatusBar.tsx
@@ -14,11 +14,10 @@
* limitations under the License.
*/
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { debounce, useDependency } from '@univerjs/core';
import clsx from 'clsx';
import React, { useEffect, useState } from 'react';
-import { debounce } from '@univerjs/core';
import { IStatusBarService } from '../../services/status-bar.service';
import type { IStatisticItem } from './CopyableStatisticItem';
import { CopyableStatisticItem } from './CopyableStatisticItem';
diff --git a/packages/sheets-zen-editor/package.json b/packages/sheets-zen-editor/package.json
index b2fa97fe41..ac79e1da02 100644
--- a/packages/sheets-zen-editor/package.json
+++ b/packages/sheets-zen-editor/package.json
@@ -71,7 +71,6 @@
"@univerjs/sheets": "workspace:*",
"@univerjs/sheets-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": ">=2.0.0",
"react": "^16.9.0 || ^17.0.0 || ^18.0.0",
"rxjs": ">=7.0.0"
@@ -89,7 +88,6 @@
"@univerjs/sheets": "workspace:*",
"@univerjs/sheets-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": "^2.1.1",
"less": "^4.2.0",
"react": "18.3.1",
diff --git a/packages/sheets-zen-editor/src/controllers/zen-editor-ui.controller.ts b/packages/sheets-zen-editor/src/controllers/zen-editor-ui.controller.ts
index 4070bf4945..709790ce73 100644
--- a/packages/sheets-zen-editor/src/controllers/zen-editor-ui.controller.ts
+++ b/packages/sheets-zen-editor/src/controllers/zen-editor-ui.controller.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { Disposable, ICommandService, LifecycleStages, OnLifecycle } from '@univerjs/core';
+import { Disposable, ICommandService, Inject, Injector, LifecycleStages, OnLifecycle } from '@univerjs/core';
import type { IMenuItemFactory, MenuConfig } from '@univerjs/ui';
import { IMenuService, IShortcutService, IZenZoneService } from '@univerjs/ui';
-import { Inject, Injector } from '@wendellhu/redi';
import { CancelZenEditCommand, ConfirmZenEditCommand } from '../commands/commands/zen-editor.command';
import { OpenZenEditorOperation } from '../commands/operations/zen-editor.operation';
diff --git a/packages/sheets-zen-editor/src/controllers/zen-editor.controller.ts b/packages/sheets-zen-editor/src/controllers/zen-editor.controller.ts
index 69a6b604df..6981523072 100644
--- a/packages/sheets-zen-editor/src/controllers/zen-editor.controller.ts
+++ b/packages/sheets-zen-editor/src/controllers/zen-editor.controller.ts
@@ -21,6 +21,7 @@ import {
DOCS_NORMAL_EDITOR_UNIT_ID_KEY,
DocumentFlavor,
ICommandService,
+ Inject,
IUndoRedoService,
IUniverInstanceService,
LifecycleStages,
@@ -41,7 +42,6 @@ import { DeviceInputEventType, IRenderManagerService } from '@univerjs/engine-re
import type { IEditorBridgeServiceParam } from '@univerjs/sheets-ui';
import { getEditorObject, IEditorBridgeService } from '@univerjs/sheets-ui';
import { IZenZoneService } from '@univerjs/ui';
-import { Inject } from '@wendellhu/redi';
import { takeUntil } from 'rxjs';
import { OpenZenEditorOperation } from '../commands/operations/zen-editor.operation';
diff --git a/packages/sheets-zen-editor/src/plugin.ts b/packages/sheets-zen-editor/src/plugin.ts
index 2b3117db2d..041f6a02d3 100644
--- a/packages/sheets-zen-editor/src/plugin.ts
+++ b/packages/sheets-zen-editor/src/plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { LocaleService, Plugin, Tools, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { Inject, Injector, LocaleService, Plugin, Tools, UniverInstanceType } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
import { ZenEditorController } from './controllers/zen-editor.controller';
import type { IUniverSheetsZenEditorUIConfig } from './controllers/zen-editor-ui.controller';
diff --git a/packages/sheets-zen-editor/src/services/zen-editor.service.ts b/packages/sheets-zen-editor/src/services/zen-editor.service.ts
index 9e0fcbb622..40a76dd4b0 100644
--- a/packages/sheets-zen-editor/src/services/zen-editor.service.ts
+++ b/packages/sheets-zen-editor/src/services/zen-editor.service.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { Nullable } from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier } from '@wendellhu/redi';
+import type { IDisposable, Nullable } from '@univerjs/core';
+import { createIdentifier } from '@univerjs/core';
import type { Observable } from 'rxjs';
import { BehaviorSubject } from 'rxjs';
diff --git a/packages/sheets-zen-editor/src/views/menu.ts b/packages/sheets-zen-editor/src/views/menu.ts
index 56385c6478..f30497b001 100644
--- a/packages/sheets-zen-editor/src/views/menu.ts
+++ b/packages/sheets-zen-editor/src/views/menu.ts
@@ -17,7 +17,7 @@
import { type IMenuButtonItem, MenuGroup, MenuItemType, MenuPosition } from '@univerjs/ui';
import { getCurrentRangeDisable$ } from '@univerjs/sheets-ui';
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor } from '@univerjs/core';
import { RangeProtectionPermissionEditPoint, WorkbookEditablePermission, WorksheetEditPermission, WorksheetSetCellStylePermission, WorksheetSetCellValuePermission } from '@univerjs/sheets';
import { OpenZenEditorOperation } from '../commands/operations/zen-editor.operation';
diff --git a/packages/sheets-zen-editor/src/views/zen-editor/ZenEditor.tsx b/packages/sheets-zen-editor/src/views/zen-editor/ZenEditor.tsx
index a3effdb374..2efa7dd33b 100644
--- a/packages/sheets-zen-editor/src/views/zen-editor/ZenEditor.tsx
+++ b/packages/sheets-zen-editor/src/views/zen-editor/ZenEditor.tsx
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { ICommandService } from '@univerjs/core';
+import { ICommandService, useDependency } from '@univerjs/core';
import { IRenderManagerService } from '@univerjs/engine-render';
import { CheckMarkSingle, CloseSingle } from '@univerjs/icons';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import clsx from 'clsx';
import React, { useEffect, useRef } from 'react';
diff --git a/packages/sheets/package.json b/packages/sheets/package.json
index 59233db9fe..f8be40d880 100644
--- a/packages/sheets/package.json
+++ b/packages/sheets/package.json
@@ -66,7 +66,6 @@
"@univerjs/engine-formula": "workspace:*",
"@univerjs/engine-numfmt": "workspace:*",
"@univerjs/rpc": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": ">=7.0.0"
},
"dependencies": {
@@ -78,7 +77,6 @@
"@univerjs/engine-numfmt": "workspace:*",
"@univerjs/rpc": "workspace:*",
"@univerjs/shared": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": "^7.8.1",
"typescript": "^5.5.3",
"vite": "^5.3.4",
diff --git a/packages/sheets/src/commands/commands/__tests__/clear-selection.command.spec.ts b/packages/sheets/src/commands/commands/__tests__/clear-selection.command.spec.ts
index 30746987fa..d49cf48829 100644
--- a/packages/sheets/src/commands/commands/__tests__/clear-selection.command.spec.ts
+++ b/packages/sheets/src/commands/commands/__tests__/clear-selection.command.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICellData, IRange, IStyleData, Nullable, Univer } from '@univerjs/core';
+import type { ICellData, Injector, IRange, IStyleData, Nullable, Univer } from '@univerjs/core';
import {
CellValueType,
ICommandService,
@@ -23,7 +23,6 @@ import {
RedoCommand,
UndoCommand,
} from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { MergeCellController } from '../../../controllers/merge-cell.controller';
diff --git a/packages/sheets/src/commands/commands/__tests__/copy-worksheet.command.spec.ts b/packages/sheets/src/commands/commands/__tests__/copy-worksheet.command.spec.ts
index efdbe80c96..cc3f9a7f52 100644
--- a/packages/sheets/src/commands/commands/__tests__/copy-worksheet.command.spec.ts
+++ b/packages/sheets/src/commands/commands/__tests__/copy-worksheet.command.spec.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { Univer, Workbook, Worksheet } from '@univerjs/core';
+import type { Injector, Univer, Workbook, Worksheet } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, LocaleService, LocaleType, RedoCommand, UndoCommand, UniverInstanceType } from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import enUS from '../../../locale/en-US';
diff --git a/packages/sheets/src/commands/commands/__tests__/create-command-test-bed.ts b/packages/sheets/src/commands/commands/__tests__/create-command-test-bed.ts
index 4e3fcf1379..7bf692af5f 100644
--- a/packages/sheets/src/commands/commands/__tests__/create-command-test-bed.ts
+++ b/packages/sheets/src/commands/commands/__tests__/create-command-test-bed.ts
@@ -14,10 +14,12 @@
* limitations under the License.
*/
-import type { IWorkbookData, Workbook } from '@univerjs/core';
+import type { Dependency, IWorkbookData, Workbook } from '@univerjs/core';
import {
BooleanNumber,
ILogService,
+ Inject,
+ Injector,
IUniverInstanceService,
LocaleService,
LocaleType,
@@ -27,8 +29,6 @@ import {
Univer,
UniverInstanceType,
} from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
import { WorkbookPermissionService } from '../../../services/permission/workbook-permission/workbook-permission.service';
import { WorksheetPermissionService } from '../../../services/permission/worksheet-permission/worksheet-permission.service';
import enUS from '../../../locale/en-US';
diff --git a/packages/sheets/src/commands/commands/__tests__/delete-range.command.spec.ts b/packages/sheets/src/commands/commands/__tests__/delete-range.command.spec.ts
index 2b003c3f8c..e9f60ab0ff 100644
--- a/packages/sheets/src/commands/commands/__tests__/delete-range.command.spec.ts
+++ b/packages/sheets/src/commands/commands/__tests__/delete-range.command.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICellData, IRange, IStyleData, IWorkbookData, Nullable, Univer } from '@univerjs/core';
+import type { ICellData, Injector, IRange, IStyleData, IWorkbookData, Nullable, Univer } from '@univerjs/core';
import {
ICommandService,
IUniverInstanceService,
@@ -24,7 +24,6 @@ import {
RedoCommand,
UndoCommand,
} from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { SheetsSelectionsService } from '../../../services/selections/selection-manager.service';
diff --git a/packages/sheets/src/commands/commands/__tests__/insert-range.command.spec.ts b/packages/sheets/src/commands/commands/__tests__/insert-range.command.spec.ts
index 6bf2a08f52..78670158c2 100644
--- a/packages/sheets/src/commands/commands/__tests__/insert-range.command.spec.ts
+++ b/packages/sheets/src/commands/commands/__tests__/insert-range.command.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICellData, IRange, IStyleData, IWorkbookData, Nullable, Univer } from '@univerjs/core';
+import type { ICellData, Injector, IRange, IStyleData, IWorkbookData, Nullable, Univer } from '@univerjs/core';
import {
ICommandService,
IUniverInstanceService,
@@ -25,7 +25,6 @@ import {
Tools,
UndoCommand,
} from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { MergeCellController } from '../../../controllers/merge-cell.controller';
diff --git a/packages/sheets/src/commands/commands/__tests__/insert-remove-rows-cols.command.spec.ts b/packages/sheets/src/commands/commands/__tests__/insert-remove-rows-cols.command.spec.ts
index 34aacc2e28..c73d0a7800 100644
--- a/packages/sheets/src/commands/commands/__tests__/insert-remove-rows-cols.command.spec.ts
+++ b/packages/sheets/src/commands/commands/__tests__/insert-remove-rows-cols.command.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICellData, IRange, IStyleData, IWorkbookData, Nullable, Univer, Workbook } from '@univerjs/core';
+import type { ICellData, Injector, IRange, IStyleData, IWorkbookData, Nullable, Univer, Workbook } from '@univerjs/core';
import {
ICommandService,
IUniverInstanceService,
@@ -25,7 +25,6 @@ import {
UndoCommand,
UniverInstanceType,
} from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { MergeCellController } from '../../../controllers/merge-cell.controller';
diff --git a/packages/sheets/src/commands/commands/__tests__/move-range-commands.spec.ts b/packages/sheets/src/commands/commands/__tests__/move-range-commands.spec.ts
index 920fa8cfb1..f4b732a6ba 100644
--- a/packages/sheets/src/commands/commands/__tests__/move-range-commands.spec.ts
+++ b/packages/sheets/src/commands/commands/__tests__/move-range-commands.spec.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IRange, IWorkbookData, Nullable, Univer, Workbook } from '@univerjs/core';
+import type { Injector, IRange, IWorkbookData, Nullable, Univer, Workbook } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, LocaleType, Tools, UniverInstanceType } from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { MergeCellController } from '../../../controllers/merge-cell.controller';
diff --git a/packages/sheets/src/commands/commands/__tests__/move-rows-cols.command.spec.ts b/packages/sheets/src/commands/commands/__tests__/move-rows-cols.command.spec.ts
index ce25cc09e4..807826ef9c 100644
--- a/packages/sheets/src/commands/commands/__tests__/move-rows-cols.command.spec.ts
+++ b/packages/sheets/src/commands/commands/__tests__/move-rows-cols.command.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICellData, IRange, IWorkbookData, Nullable, Univer, Workbook } from '@univerjs/core';
+import type { ICellData, Injector, IRange, IWorkbookData, Nullable, Univer, Workbook } from '@univerjs/core';
import {
cellToRange,
ICommandService,
@@ -26,7 +26,6 @@ import {
UndoCommand,
UniverInstanceType,
} from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { beforeEach, describe, expect, it } from 'vitest';
import { MergeCellController } from '../../../controllers/merge-cell.controller';
diff --git a/packages/sheets/src/commands/commands/__tests__/remove-rows-cols.command.spec.ts b/packages/sheets/src/commands/commands/__tests__/remove-rows-cols.command.spec.ts
index e84c40ab8f..f09c1e8fd7 100644
--- a/packages/sheets/src/commands/commands/__tests__/remove-rows-cols.command.spec.ts
+++ b/packages/sheets/src/commands/commands/__tests__/remove-rows-cols.command.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICellData, IWorkbookData, Nullable, Univer, Workbook } from '@univerjs/core';
+import type { ICellData, Injector, IWorkbookData, Nullable, Univer, Workbook } from '@univerjs/core';
import {
ICommandService,
IUniverInstanceService,
@@ -25,7 +25,6 @@ import {
UndoCommand,
UniverInstanceType,
} from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { beforeEach, describe, expect, it } from 'vitest';
import { MergeCellController } from '../../../controllers/merge-cell.controller';
diff --git a/packages/sheets/src/commands/commands/__tests__/remove-sheet.command.spec.ts b/packages/sheets/src/commands/commands/__tests__/remove-sheet.command.spec.ts
index 4664b9420d..43ead69ae1 100644
--- a/packages/sheets/src/commands/commands/__tests__/remove-sheet.command.spec.ts
+++ b/packages/sheets/src/commands/commands/__tests__/remove-sheet.command.spec.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { Univer, Workbook } from '@univerjs/core';
+import type { Injector, Univer, Workbook } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, RedoCommand, UndoCommand, UniverInstanceType } from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { InsertSheetMutation } from '../../mutations/insert-sheet.mutation';
diff --git a/packages/sheets/src/commands/commands/__tests__/set-border.command.spec.ts b/packages/sheets/src/commands/commands/__tests__/set-border.command.spec.ts
index ebe9988aa6..a4fdce093d 100644
--- a/packages/sheets/src/commands/commands/__tests__/set-border.command.spec.ts
+++ b/packages/sheets/src/commands/commands/__tests__/set-border.command.spec.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IBorderData, IRange, Univer } from '@univerjs/core';
+import type { IBorderData, Injector, IRange, Univer } from '@univerjs/core';
import { BorderStyleTypes, BorderType, ICommandService, IUniverInstanceService, RANGE_TYPE } from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { SheetsSelectionsService } from '../../../services/selections/selection-manager.service';
diff --git a/packages/sheets/src/commands/commands/__tests__/set-col-width.command.spec.ts b/packages/sheets/src/commands/commands/__tests__/set-col-width.command.spec.ts
index 528f8f3130..73ae804cf6 100644
--- a/packages/sheets/src/commands/commands/__tests__/set-col-width.command.spec.ts
+++ b/packages/sheets/src/commands/commands/__tests__/set-col-width.command.spec.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { Univer, Workbook } from '@univerjs/core';
+import type { Injector, Univer, Workbook } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, RANGE_TYPE, RedoCommand, UndoCommand, UniverInstanceType } from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { SheetsSelectionsService } from '../../../services/selections/selection-manager.service';
diff --git a/packages/sheets/src/commands/commands/__tests__/set-frozen.command.spec.ts b/packages/sheets/src/commands/commands/__tests__/set-frozen.command.spec.ts
index f2fa637711..394877425e 100644
--- a/packages/sheets/src/commands/commands/__tests__/set-frozen.command.spec.ts
+++ b/packages/sheets/src/commands/commands/__tests__/set-frozen.command.spec.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IWorkbookData, Univer, Workbook } from '@univerjs/core';
+import type { Injector, IWorkbookData, Univer, Workbook } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, LocaleType, RedoCommand, UndoCommand, UniverInstanceType } from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { SetFrozenMutation } from '../../mutations/set-frozen.mutation';
diff --git a/packages/sheets/src/commands/commands/__tests__/set-range-values.command.spec.ts b/packages/sheets/src/commands/commands/__tests__/set-range-values.command.spec.ts
index 164bcf271a..dfd371e4ca 100644
--- a/packages/sheets/src/commands/commands/__tests__/set-range-values.command.spec.ts
+++ b/packages/sheets/src/commands/commands/__tests__/set-range-values.command.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICellData, IDocumentData, IStyleData, IWorkbookData, Nullable, Univer, Workbook } from '@univerjs/core';
+import type { ICellData, IDocumentData, Injector, IStyleData, IWorkbookData, Nullable, Univer, Workbook } from '@univerjs/core';
import {
BooleanNumber,
CellValueType,
@@ -27,7 +27,6 @@ import {
UndoCommand,
UniverInstanceType,
} from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { DEFAULT_TEXT_FORMAT } from '@univerjs/engine-numfmt';
diff --git a/packages/sheets/src/commands/commands/__tests__/set-row-col-visible.command.spec.ts b/packages/sheets/src/commands/commands/__tests__/set-row-col-visible.command.spec.ts
index 6793c14a0c..80d7b6c57c 100644
--- a/packages/sheets/src/commands/commands/__tests__/set-row-col-visible.command.spec.ts
+++ b/packages/sheets/src/commands/commands/__tests__/set-row-col-visible.command.spec.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { Univer, Workbook } from '@univerjs/core';
+import type { Injector, Univer, Workbook } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, RANGE_TYPE, RedoCommand, UndoCommand, UniverInstanceType } from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { SheetsSelectionsService } from '../../../services/selections/selection-manager.service';
diff --git a/packages/sheets/src/commands/commands/__tests__/set-row-height.command.spec.ts b/packages/sheets/src/commands/commands/__tests__/set-row-height.command.spec.ts
index a3cf73b3c7..95656c5ffd 100644
--- a/packages/sheets/src/commands/commands/__tests__/set-row-height.command.spec.ts
+++ b/packages/sheets/src/commands/commands/__tests__/set-row-height.command.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { Nullable, Univer, Workbook } from '@univerjs/core';
+import type { Injector, Nullable, Univer, Workbook } from '@univerjs/core';
import {
BooleanNumber,
ICommandService,
@@ -24,7 +24,6 @@ import {
UndoCommand,
UniverInstanceType,
} from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { SheetsSelectionsService } from '../../../services/selections/selection-manager.service';
diff --git a/packages/sheets/src/commands/commands/__tests__/set-style.command.spec.ts b/packages/sheets/src/commands/commands/__tests__/set-style.command.spec.ts
index 11c6be6a36..f91374f785 100644
--- a/packages/sheets/src/commands/commands/__tests__/set-style.command.spec.ts
+++ b/packages/sheets/src/commands/commands/__tests__/set-style.command.spec.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { IColorStyle, ITextDecoration, ITextRotation, Univer } from '@univerjs/core';
+import type { IColorStyle, Injector, ITextDecoration, ITextRotation, Univer } from '@univerjs/core';
import {
BooleanNumber,
FontItalic,
@@ -28,7 +28,6 @@ import {
VerticalAlign,
WrapStrategy,
} from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { SheetsSelectionsService } from '../../../services/selections/selection-manager.service';
diff --git a/packages/sheets/src/commands/commands/__tests__/set-tab-color.command.spec.ts b/packages/sheets/src/commands/commands/__tests__/set-tab-color.command.spec.ts
index 04ff180e75..c97262fabe 100644
--- a/packages/sheets/src/commands/commands/__tests__/set-tab-color.command.spec.ts
+++ b/packages/sheets/src/commands/commands/__tests__/set-tab-color.command.spec.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { Univer } from '@univerjs/core';
+import type { Injector, Univer } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, RedoCommand, UndoCommand } from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { SetTabColorCommand } from '../set-tab-color.command';
diff --git a/packages/sheets/src/commands/commands/__tests__/set-worksheet-hide.command.spec.ts b/packages/sheets/src/commands/commands/__tests__/set-worksheet-hide.command.spec.ts
index 4f5d8c5b3a..4917cf9a8c 100644
--- a/packages/sheets/src/commands/commands/__tests__/set-worksheet-hide.command.spec.ts
+++ b/packages/sheets/src/commands/commands/__tests__/set-worksheet-hide.command.spec.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { Univer, Workbook } from '@univerjs/core';
+import type { Injector, Univer, Workbook } from '@univerjs/core';
import { BooleanNumber, ICommandService, IUniverInstanceService, RedoCommand, UndoCommand, UniverInstanceType } from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { InsertSheetMutation } from '../../mutations/insert-sheet.mutation';
diff --git a/packages/sheets/src/commands/commands/__tests__/set-worksheet-name.command.spec.ts b/packages/sheets/src/commands/commands/__tests__/set-worksheet-name.command.spec.ts
index 09cb01d774..d693fd584b 100644
--- a/packages/sheets/src/commands/commands/__tests__/set-worksheet-name.command.spec.ts
+++ b/packages/sheets/src/commands/commands/__tests__/set-worksheet-name.command.spec.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { Univer, Workbook } from '@univerjs/core';
+import type { Injector, Univer, Workbook } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, RedoCommand, UndoCommand, UniverInstanceType } from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { SetWorksheetNameMutation } from '../../mutations/set-worksheet-name.mutation';
diff --git a/packages/sheets/src/commands/commands/__tests__/set-worksheet-order.command.spec.ts b/packages/sheets/src/commands/commands/__tests__/set-worksheet-order.command.spec.ts
index 20db10416f..bfa252a0c0 100644
--- a/packages/sheets/src/commands/commands/__tests__/set-worksheet-order.command.spec.ts
+++ b/packages/sheets/src/commands/commands/__tests__/set-worksheet-order.command.spec.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { Univer, Workbook } from '@univerjs/core';
+import type { Injector, Univer, Workbook } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, RedoCommand, UndoCommand, UniverInstanceType } from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { InsertSheetMutation } from '../../mutations/insert-sheet.mutation';
diff --git a/packages/sheets/src/commands/commands/__tests__/set-worksheet-show.command.spec.ts b/packages/sheets/src/commands/commands/__tests__/set-worksheet-show.command.spec.ts
index 6b21a3b346..048f060db9 100644
--- a/packages/sheets/src/commands/commands/__tests__/set-worksheet-show.command.spec.ts
+++ b/packages/sheets/src/commands/commands/__tests__/set-worksheet-show.command.spec.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { Univer, Workbook } from '@univerjs/core';
+import type { Injector, Univer, Workbook } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, RedoCommand, UndoCommand, UniverInstanceType } from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { InsertSheetMutation } from '../../mutations/insert-sheet.mutation';
diff --git a/packages/sheets/src/commands/commands/add-worksheet-merge.command.ts b/packages/sheets/src/commands/commands/add-worksheet-merge.command.ts
index d0dd62758a..b1db54bb17 100644
--- a/packages/sheets/src/commands/commands/add-worksheet-merge.command.ts
+++ b/packages/sheets/src/commands/commands/add-worksheet-merge.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICellData, ICommand, IMutationInfo, IRange, Nullable, Workbook, Worksheet } from '@univerjs/core';
+import type { IAccessor, ICellData, ICommand, IMutationInfo, IRange, Nullable, Workbook, Worksheet } from '@univerjs/core';
import {
CommandType,
Dimension,
@@ -25,7 +25,6 @@ import {
sequenceExecute,
UniverInstanceType,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type {
IAddWorksheetMergeMutationParams,
diff --git a/packages/sheets/src/commands/commands/clear-selection-all.command.ts b/packages/sheets/src/commands/commands/clear-selection-all.command.ts
index 7a082a34b6..bd160d4a03 100644
--- a/packages/sheets/src/commands/commands/clear-selection-all.command.ts
+++ b/packages/sheets/src/commands/commands/clear-selection-all.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICommand, IMutationInfo, Workbook } from '@univerjs/core';
+import type { IAccessor, ICommand, IMutationInfo, Workbook } from '@univerjs/core';
import {
CommandType,
ICommandService,
@@ -23,7 +23,6 @@ import {
sequenceExecute,
UniverInstanceType,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { SheetsSelectionsService } from '../../services/selections/selection-manager.service';
import { SheetInterceptorService } from '../../services/sheet-interceptor/sheet-interceptor.service';
diff --git a/packages/sheets/src/commands/commands/clear-selection-content.command.ts b/packages/sheets/src/commands/commands/clear-selection-content.command.ts
index 42e079857d..3f199a6be1 100644
--- a/packages/sheets/src/commands/commands/clear-selection-content.command.ts
+++ b/packages/sheets/src/commands/commands/clear-selection-content.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICommand, Workbook } from '@univerjs/core';
+import type { IAccessor, ICommand, Workbook } from '@univerjs/core';
import {
CommandType,
ICommandService,
@@ -23,7 +23,6 @@ import {
sequenceExecute,
UniverInstanceType,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { SheetsSelectionsService } from '../../services/selections/selection-manager.service';
import { SheetInterceptorService } from '../../services/sheet-interceptor/sheet-interceptor.service';
diff --git a/packages/sheets/src/commands/commands/clear-selection-format.command.ts b/packages/sheets/src/commands/commands/clear-selection-format.command.ts
index f56e1156ef..42a33d7521 100644
--- a/packages/sheets/src/commands/commands/clear-selection-format.command.ts
+++ b/packages/sheets/src/commands/commands/clear-selection-format.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICommand, IMutationInfo, Workbook } from '@univerjs/core';
+import type { IAccessor, ICommand, IMutationInfo, Workbook } from '@univerjs/core';
import {
CommandType,
ICommandService,
@@ -23,7 +23,6 @@ import {
sequenceExecute,
UniverInstanceType,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { SheetsSelectionsService } from '../../services/selections/selection-manager.service';
import { SheetInterceptorService } from '../../services/sheet-interceptor/sheet-interceptor.service';
diff --git a/packages/sheets/src/commands/commands/copy-worksheet.command.ts b/packages/sheets/src/commands/commands/copy-worksheet.command.ts
index 7c863658e2..77002f70c2 100644
--- a/packages/sheets/src/commands/commands/copy-worksheet.command.ts
+++ b/packages/sheets/src/commands/commands/copy-worksheet.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICommand, Workbook } from '@univerjs/core';
+import type { IAccessor, ICommand, Workbook } from '@univerjs/core';
import {
CommandType,
ICommandService,
@@ -23,7 +23,6 @@ import {
LocaleService,
Tools,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type {
IInsertSheetMutationParams,
diff --git a/packages/sheets/src/commands/commands/delete-range-move-left.command.ts b/packages/sheets/src/commands/commands/delete-range-move-left.command.ts
index 906a1f2fa7..8dc4eb1ec5 100644
--- a/packages/sheets/src/commands/commands/delete-range-move-left.command.ts
+++ b/packages/sheets/src/commands/commands/delete-range-move-left.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICommand, IMutationInfo, IRange } from '@univerjs/core';
+import type { IAccessor, ICommand, IMutationInfo, IRange } from '@univerjs/core';
import {
CommandType,
Dimension,
@@ -23,7 +23,6 @@ import {
IUniverInstanceService,
sequenceExecute,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { IDeleteRangeMutationParams } from '../../basics/interfaces/mutation-interface';
import { SheetsSelectionsService } from '../../services/selections/selection-manager.service';
diff --git a/packages/sheets/src/commands/commands/delete-range-move-up.command.ts b/packages/sheets/src/commands/commands/delete-range-move-up.command.ts
index 5e7bc15688..fb5d939094 100644
--- a/packages/sheets/src/commands/commands/delete-range-move-up.command.ts
+++ b/packages/sheets/src/commands/commands/delete-range-move-up.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICommand, IMutationInfo, IRange } from '@univerjs/core';
+import type { IAccessor, ICommand, IMutationInfo, IRange } from '@univerjs/core';
import {
CommandType,
Dimension,
@@ -23,7 +23,6 @@ import {
IUniverInstanceService,
sequenceExecute,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { IDeleteRangeMutationParams } from '../../basics/interfaces/mutation-interface';
import { SheetsSelectionsService } from '../../services/selections/selection-manager.service';
diff --git a/packages/sheets/src/commands/commands/insert-defined-name.command.ts b/packages/sheets/src/commands/commands/insert-defined-name.command.ts
index 4b83a7630b..5c6b7bd67a 100644
--- a/packages/sheets/src/commands/commands/insert-defined-name.command.ts
+++ b/packages/sheets/src/commands/commands/insert-defined-name.command.ts
@@ -14,13 +14,12 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import {
CommandType,
ICommandService,
IUndoRedoService,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { type ISetDefinedNameMutationParam, RemoveDefinedNameMutation, SetDefinedNameMutation } from '@univerjs/engine-formula';
/**
diff --git a/packages/sheets/src/commands/commands/insert-range-move-down.command.ts b/packages/sheets/src/commands/commands/insert-range-move-down.command.ts
index ba44cfe4cb..7413bcd171 100644
--- a/packages/sheets/src/commands/commands/insert-range-move-down.command.ts
+++ b/packages/sheets/src/commands/commands/insert-range-move-down.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICellData, ICommand, IMutationInfo, IObjectMatrixPrimitiveType, IRange } from '@univerjs/core';
+import type { IAccessor, ICellData, ICommand, IMutationInfo, IObjectMatrixPrimitiveType, IRange } from '@univerjs/core';
import {
BooleanNumber,
CommandType,
@@ -27,7 +27,6 @@ import {
Range,
sequenceExecute,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type {
IInsertRangeMutationParams,
diff --git a/packages/sheets/src/commands/commands/insert-range-move-right.command.ts b/packages/sheets/src/commands/commands/insert-range-move-right.command.ts
index 03fda011b3..4aa4359d72 100644
--- a/packages/sheets/src/commands/commands/insert-range-move-right.command.ts
+++ b/packages/sheets/src/commands/commands/insert-range-move-right.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICellData, ICommand, IMutationInfo, IObjectMatrixPrimitiveType, IRange } from '@univerjs/core';
+import type { IAccessor, ICellData, ICommand, IMutationInfo, IObjectMatrixPrimitiveType, IRange } from '@univerjs/core';
import {
BooleanNumber,
CommandType,
@@ -27,7 +27,6 @@ import {
Range,
sequenceExecute,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type {
IInsertColMutationParams,
diff --git a/packages/sheets/src/commands/commands/insert-row-col.command.ts b/packages/sheets/src/commands/commands/insert-row-col.command.ts
index dba4e1ee5e..47bca83c0a 100644
--- a/packages/sheets/src/commands/commands/insert-row-col.command.ts
+++ b/packages/sheets/src/commands/commands/insert-row-col.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICellData, ICommand, IMutationInfo, IObjectMatrixPrimitiveType, IRange, Workbook } from '@univerjs/core';
+import type { IAccessor, ICellData, ICommand, IMutationInfo, IObjectMatrixPrimitiveType, IRange, Workbook } from '@univerjs/core';
import {
BooleanNumber,
CommandType,
@@ -27,7 +27,6 @@ import {
sequenceExecute,
UniverInstanceType,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type {
IInsertColMutationParams,
diff --git a/packages/sheets/src/commands/commands/insert-sheet.command.ts b/packages/sheets/src/commands/commands/insert-sheet.command.ts
index 8128d15776..38d6c63beb 100644
--- a/packages/sheets/src/commands/commands/insert-sheet.command.ts
+++ b/packages/sheets/src/commands/commands/insert-sheet.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICommand, IWorksheetData } from '@univerjs/core';
+import type { IAccessor, ICommand, IWorksheetData } from '@univerjs/core';
import {
CommandType,
ICommandService,
@@ -24,7 +24,6 @@ import {
mergeWorksheetSnapshotWithDefault,
Tools,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type {
IInsertSheetMutationParams,
diff --git a/packages/sheets/src/commands/commands/move-range.command.ts b/packages/sheets/src/commands/commands/move-range.command.ts
index c1fc149049..a0c3831bf2 100644
--- a/packages/sheets/src/commands/commands/move-range.command.ts
+++ b/packages/sheets/src/commands/commands/move-range.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICellData, ICommand, IMutationInfo, IRange, Nullable } from '@univerjs/core';
+import type { IAccessor, ICellData, ICommand, IMutationInfo, IRange, Nullable } from '@univerjs/core';
import {
cellToRange,
CommandType,
@@ -28,7 +28,6 @@ import {
Rectangle,
sequenceExecute,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { SheetInterceptorService } from '../../services/sheet-interceptor/sheet-interceptor.service';
import type { IMoveRangeMutationParams } from '../mutations/move-range.mutation';
diff --git a/packages/sheets/src/commands/commands/move-rows-cols.command.ts b/packages/sheets/src/commands/commands/move-rows-cols.command.ts
index 3aa23c52d7..e732403c8c 100644
--- a/packages/sheets/src/commands/commands/move-rows-cols.command.ts
+++ b/packages/sheets/src/commands/commands/move-rows-cols.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICommand, IRange, Workbook } from '@univerjs/core';
+import type { IAccessor, ICommand, IRange, Workbook } from '@univerjs/core';
import {
CommandType,
ErrorService,
@@ -27,7 +27,6 @@ import {
sequenceExecute,
UniverInstanceType,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { SheetsSelectionsService } from '../../services/selections/selection-manager.service';
import { SheetInterceptorService } from '../../services/sheet-interceptor/sheet-interceptor.service';
diff --git a/packages/sheets/src/commands/commands/remove-defined-name.command.ts b/packages/sheets/src/commands/commands/remove-defined-name.command.ts
index 4b0f1ab7c4..1ebabfcbba 100644
--- a/packages/sheets/src/commands/commands/remove-defined-name.command.ts
+++ b/packages/sheets/src/commands/commands/remove-defined-name.command.ts
@@ -14,13 +14,12 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import {
CommandType,
ICommandService,
IUndoRedoService,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { type ISetDefinedNameMutationParam, RemoveDefinedNameMutation, SetDefinedNameMutation } from '@univerjs/engine-formula';
/**
diff --git a/packages/sheets/src/commands/commands/remove-row-col.command.ts b/packages/sheets/src/commands/commands/remove-row-col.command.ts
index 7012def57d..744f013e67 100644
--- a/packages/sheets/src/commands/commands/remove-row-col.command.ts
+++ b/packages/sheets/src/commands/commands/remove-row-col.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICommand, IMutationInfo, IRange } from '@univerjs/core';
+import type { IAccessor, ICommand, IMutationInfo, IRange } from '@univerjs/core';
import {
CommandType,
ICommandService,
@@ -22,7 +22,6 @@ import {
IUniverInstanceService,
sequenceExecute,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type {
IInsertColMutationParams,
diff --git a/packages/sheets/src/commands/commands/remove-sheet.command.ts b/packages/sheets/src/commands/commands/remove-sheet.command.ts
index 53c0b2daba..bef0cc1813 100644
--- a/packages/sheets/src/commands/commands/remove-sheet.command.ts
+++ b/packages/sheets/src/commands/commands/remove-sheet.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import {
CommandType,
ICommandService,
@@ -22,7 +22,6 @@ import {
IUniverInstanceService,
sequenceExecute,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type {
IInsertSheetMutationParams,
diff --git a/packages/sheets/src/commands/commands/remove-worksheet-merge.command.ts b/packages/sheets/src/commands/commands/remove-worksheet-merge.command.ts
index 8c0539e44c..e151ced9f7 100644
--- a/packages/sheets/src/commands/commands/remove-worksheet-merge.command.ts
+++ b/packages/sheets/src/commands/commands/remove-worksheet-merge.command.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICellData, ICommand, IMutationInfo, IRange, Nullable, Worksheet } from '@univerjs/core';
+import type { IAccessor, ICellData, ICommand, IMutationInfo, IRange, Nullable, Worksheet } from '@univerjs/core';
import { CommandType, ICommandService, IUndoRedoService, IUniverInstanceService, ObjectMatrix, Rectangle, sequenceExecute, Tools } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type {
IAddWorksheetMergeMutationParams,
diff --git a/packages/sheets/src/commands/commands/reorder-range.command.ts b/packages/sheets/src/commands/commands/reorder-range.command.ts
index a43c82499c..14ca59028c 100644
--- a/packages/sheets/src/commands/commands/reorder-range.command.ts
+++ b/packages/sheets/src/commands/commands/reorder-range.command.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICommand, IRange } from '@univerjs/core';
+import type { IAccessor, ICommand, IRange } from '@univerjs/core';
import { CommandType, ICommandService, IUndoRedoService, sequenceExecute } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { ISheetCommandSharedParams } from '../utils/interface';
import type { IReorderRangeMutationParams } from '../mutations/reorder-range.mutation';
import { ReorderRangeMutation, ReorderRangeUndoMutationFactory } from '../mutations/reorder-range.mutation';
diff --git a/packages/sheets/src/commands/commands/set-border-command.ts b/packages/sheets/src/commands/commands/set-border-command.ts
index af130d7a1e..d7f58aded7 100644
--- a/packages/sheets/src/commands/commands/set-border-command.ts
+++ b/packages/sheets/src/commands/commands/set-border-command.ts
@@ -16,6 +16,7 @@
import type {
BorderStyleTypes,
+ IAccessor,
IBorderData,
IBorderStyleData,
ICellData,
@@ -33,7 +34,6 @@ import {
Rectangle,
Tools,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { BorderStyleManagerService, type IBorderInfo } from '../../services/border-style-manager.service';
import { SheetsSelectionsService } from '../../services/selections/selection-manager.service';
diff --git a/packages/sheets/src/commands/commands/set-col-visible.command.ts b/packages/sheets/src/commands/commands/set-col-visible.command.ts
index 3633cbdcb5..b6dd96c021 100644
--- a/packages/sheets/src/commands/commands/set-col-visible.command.ts
+++ b/packages/sheets/src/commands/commands/set-col-visible.command.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import type { ICommand, IRange, Nullable,
- Worksheet } from '@univerjs/core';
+import type { IAccessor, ICommand, IRange, Nullable, Worksheet } from '@univerjs/core';
import {
CommandType,
ICommandService,
@@ -24,7 +23,6 @@ import {
RANGE_TYPE,
sequenceExecute,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { ISetColHiddenMutationParams, ISetColVisibleMutationParams } from '../mutations/set-col-visible.mutation';
import {
diff --git a/packages/sheets/src/commands/commands/set-defined-name.command.ts b/packages/sheets/src/commands/commands/set-defined-name.command.ts
index 4c47452071..bceab2ec00 100644
--- a/packages/sheets/src/commands/commands/set-defined-name.command.ts
+++ b/packages/sheets/src/commands/commands/set-defined-name.command.ts
@@ -14,13 +14,12 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import {
CommandType,
ICommandService,
IUndoRedoService,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { type ISetDefinedNameMutationParam, SetDefinedNameMutation } from '@univerjs/engine-formula';
export interface ISetDefinedNameCommandParams {
diff --git a/packages/sheets/src/commands/commands/set-frozen-cancel.command.ts b/packages/sheets/src/commands/commands/set-frozen-cancel.command.ts
index 9e7fbf8a83..9c22408453 100644
--- a/packages/sheets/src/commands/commands/set-frozen-cancel.command.ts
+++ b/packages/sheets/src/commands/commands/set-frozen-cancel.command.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType, ICommandService, IUndoRedoService, IUniverInstanceService } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { ISetFrozenMutationParams } from '../mutations/set-frozen.mutation';
import { SetFrozenMutation, SetFrozenMutationFactory } from '../mutations/set-frozen.mutation';
diff --git a/packages/sheets/src/commands/commands/set-frozen.command.ts b/packages/sheets/src/commands/commands/set-frozen.command.ts
index 8fc325dfb6..00e2a90b3a 100644
--- a/packages/sheets/src/commands/commands/set-frozen.command.ts
+++ b/packages/sheets/src/commands/commands/set-frozen.command.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType, ICommandService, IUndoRedoService, IUniverInstanceService } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { ISetFrozenMutationParams } from '../mutations/set-frozen.mutation';
import { SetFrozenMutation, SetFrozenMutationFactory } from '../mutations/set-frozen.mutation';
diff --git a/packages/sheets/src/commands/commands/set-hide-gridlines.command.ts b/packages/sheets/src/commands/commands/set-hide-gridlines.command.ts
index 6801888e71..3fb6c2f9d4 100644
--- a/packages/sheets/src/commands/commands/set-hide-gridlines.command.ts
+++ b/packages/sheets/src/commands/commands/set-hide-gridlines.command.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { BooleanNumber, CommandType, ICommandService, IUndoRedoService, IUniverInstanceService } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { ISetHideGridlinesMutationParams } from '../mutations/set-hide-gridlines.mutatiom';
import {
diff --git a/packages/sheets/src/commands/commands/set-range-values.command.ts b/packages/sheets/src/commands/commands/set-range-values.command.ts
index 387b0bcab1..c6f72a4805 100644
--- a/packages/sheets/src/commands/commands/set-range-values.command.ts
+++ b/packages/sheets/src/commands/commands/set-range-values.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICellData, ICommand, IObjectMatrixPrimitiveType, IRange } from '@univerjs/core';
+import type { IAccessor, ICellData, ICommand, IObjectMatrixPrimitiveType, IRange } from '@univerjs/core';
import {
CommandType,
ICommandService,
@@ -26,7 +26,6 @@ import {
sequenceExecute,
Tools,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { SheetsSelectionsService } from '../../services/selections/selection-manager.service';
import { SheetInterceptorService } from '../../services/sheet-interceptor/sheet-interceptor.service';
diff --git a/packages/sheets/src/commands/commands/set-row-visible.command.ts b/packages/sheets/src/commands/commands/set-row-visible.command.ts
index d61010c5fc..885f8f967e 100644
--- a/packages/sheets/src/commands/commands/set-row-visible.command.ts
+++ b/packages/sheets/src/commands/commands/set-row-visible.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICommand, IRange, Nullable, Worksheet } from '@univerjs/core';
+import type { IAccessor, ICommand, IRange, Nullable, Worksheet } from '@univerjs/core';
import {
CommandType,
ICommandService,
@@ -23,7 +23,6 @@ import {
RANGE_TYPE,
sequenceExecute,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { SheetsSelectionsService } from '../../services/selections/selection-manager.service';
import type { ISetRowHiddenMutationParams, ISetRowVisibleMutationParams } from '../mutations/set-row-visible.mutation';
diff --git a/packages/sheets/src/commands/commands/set-style.command.ts b/packages/sheets/src/commands/commands/set-style.command.ts
index 84a01eeb9e..dfaa59a254 100644
--- a/packages/sheets/src/commands/commands/set-style.command.ts
+++ b/packages/sheets/src/commands/commands/set-style.command.ts
@@ -16,6 +16,7 @@
import type {
HorizontalAlign,
+ IAccessor,
ICellData,
IColorStyle,
ICommand,
@@ -37,7 +38,6 @@ import {
sequenceExecute,
Tools,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { SheetsSelectionsService } from '../../services/selections/selection-manager.service';
import { SheetInterceptorService } from '../../services/sheet-interceptor/sheet-interceptor.service';
diff --git a/packages/sheets/src/commands/commands/set-tab-color.command.ts b/packages/sheets/src/commands/commands/set-tab-color.command.ts
index d7a4ee9a16..d65dd562be 100644
--- a/packages/sheets/src/commands/commands/set-tab-color.command.ts
+++ b/packages/sheets/src/commands/commands/set-tab-color.command.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType, ICommandService, IUndoRedoService, IUniverInstanceService } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { ISetTabColorMutationParams } from '../mutations/set-tab-color.mutation';
import { SetTabColorMutation, SetTabColorUndoMutationFactory } from '../mutations/set-tab-color.mutation';
diff --git a/packages/sheets/src/commands/commands/set-workbook-name.command.ts b/packages/sheets/src/commands/commands/set-workbook-name.command.ts
index f336b22fab..3d04c07250 100644
--- a/packages/sheets/src/commands/commands/set-workbook-name.command.ts
+++ b/packages/sheets/src/commands/commands/set-workbook-name.command.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-import { CommandType, type ICommand, ICommandService, IUniverInstanceService, sequenceExecute, UniverInstanceType } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor, ICommand } from '@univerjs/core';
+import { CommandType, ICommandService, IUniverInstanceService, sequenceExecute, UniverInstanceType } from '@univerjs/core';
import { SheetInterceptorService } from '../../services/sheet-interceptor/sheet-interceptor.service';
import type { ISetWorkbookNameMutationParams } from '../mutations/set-workbook-name.mutation';
import { SetWorkbookNameMutation } from '../mutations/set-workbook-name.mutation';
diff --git a/packages/sheets/src/commands/commands/set-worksheet-activate.command.ts b/packages/sheets/src/commands/commands/set-worksheet-activate.command.ts
index 41e6ff4c79..66cb5f9a78 100644
--- a/packages/sheets/src/commands/commands/set-worksheet-activate.command.ts
+++ b/packages/sheets/src/commands/commands/set-worksheet-activate.command.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICommand, IExecutionOptions } from '@univerjs/core';
+import type { IAccessor, ICommand, IExecutionOptions } from '@univerjs/core';
import { CommandType, ICommandService, IUniverInstanceService } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { ISetWorksheetActiveOperationParams } from '../operations/set-worksheet-active.operation';
import { SetWorksheetActiveOperation } from '../operations/set-worksheet-active.operation';
diff --git a/packages/sheets/src/commands/commands/set-worksheet-col-width.command.ts b/packages/sheets/src/commands/commands/set-worksheet-col-width.command.ts
index de6d93094b..40288a3396 100644
--- a/packages/sheets/src/commands/commands/set-worksheet-col-width.command.ts
+++ b/packages/sheets/src/commands/commands/set-worksheet-col-width.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICommand, IRange } from '@univerjs/core';
+import type { IAccessor, ICommand, IRange } from '@univerjs/core';
import {
CommandType,
ICommandService,
@@ -24,7 +24,6 @@ import {
Rectangle,
sequenceExecute,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { SheetsSelectionsService } from '../../services/selections/selection-manager.service';
import { SheetInterceptorService } from '../../services/sheet-interceptor/sheet-interceptor.service';
diff --git a/packages/sheets/src/commands/commands/set-worksheet-hide.command.ts b/packages/sheets/src/commands/commands/set-worksheet-hide.command.ts
index 945302ed6e..e2e7745419 100644
--- a/packages/sheets/src/commands/commands/set-worksheet-hide.command.ts
+++ b/packages/sheets/src/commands/commands/set-worksheet-hide.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import {
BooleanNumber,
CommandType,
@@ -24,7 +24,6 @@ import {
IUniverInstanceService,
LocaleService,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { ISetWorksheetHideMutationParams } from '../mutations/set-worksheet-hide.mutation';
import { SetWorksheetHideMutation, SetWorksheetHideMutationFactory } from '../mutations/set-worksheet-hide.mutation';
diff --git a/packages/sheets/src/commands/commands/set-worksheet-name.command.ts b/packages/sheets/src/commands/commands/set-worksheet-name.command.ts
index aeb217a3e3..b3229f2ab6 100644
--- a/packages/sheets/src/commands/commands/set-worksheet-name.command.ts
+++ b/packages/sheets/src/commands/commands/set-worksheet-name.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import {
CommandType,
ICommandService,
@@ -22,7 +22,6 @@ import {
IUniverInstanceService,
sequenceExecute,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { SheetInterceptorService } from '../../services/sheet-interceptor/sheet-interceptor.service';
import type { ISetWorksheetNameMutationParams } from '../mutations/set-worksheet-name.mutation';
diff --git a/packages/sheets/src/commands/commands/set-worksheet-order.command.ts b/packages/sheets/src/commands/commands/set-worksheet-order.command.ts
index 0aadde3bd5..35b3fc9c00 100644
--- a/packages/sheets/src/commands/commands/set-worksheet-order.command.ts
+++ b/packages/sheets/src/commands/commands/set-worksheet-order.command.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType, ICommandService, IUndoRedoService, IUniverInstanceService } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { ISetWorksheetOrderMutationParams } from '../mutations/set-worksheet-order.mutation';
import {
diff --git a/packages/sheets/src/commands/commands/set-worksheet-right-to-left.command.ts b/packages/sheets/src/commands/commands/set-worksheet-right-to-left.command.ts
index cfeecad362..a20d629a6b 100644
--- a/packages/sheets/src/commands/commands/set-worksheet-right-to-left.command.ts
+++ b/packages/sheets/src/commands/commands/set-worksheet-right-to-left.command.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { BooleanNumber, CommandType, ICommandService, IUndoRedoService, IUniverInstanceService } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { ISetWorksheetRightToLeftMutationParams } from '../mutations/set-worksheet-right-to-left.mutation';
import {
diff --git a/packages/sheets/src/commands/commands/set-worksheet-row-height.command.ts b/packages/sheets/src/commands/commands/set-worksheet-row-height.command.ts
index bbc3be5797..57ae5ce03f 100644
--- a/packages/sheets/src/commands/commands/set-worksheet-row-height.command.ts
+++ b/packages/sheets/src/commands/commands/set-worksheet-row-height.command.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { ICommand, IRange } from '@univerjs/core';
+import type { IAccessor, ICommand, IRange } from '@univerjs/core';
import {
BooleanNumber,
CommandType,
@@ -25,7 +25,6 @@ import {
Rectangle,
sequenceExecute,
} from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { SheetsSelectionsService } from '../../services/selections/selection-manager.service';
import { SheetInterceptorService } from '../../services/sheet-interceptor/sheet-interceptor.service';
diff --git a/packages/sheets/src/commands/commands/set-worksheet-show.command.ts b/packages/sheets/src/commands/commands/set-worksheet-show.command.ts
index 8d68239e0d..8d9b6a52e6 100644
--- a/packages/sheets/src/commands/commands/set-worksheet-show.command.ts
+++ b/packages/sheets/src/commands/commands/set-worksheet-show.command.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICommand, Workbook } from '@univerjs/core';
+import type { IAccessor, ICommand, Workbook } from '@univerjs/core';
import { BooleanNumber, CommandType, ICommandService, IUndoRedoService, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type { ISetWorksheetHideMutationParams } from '../mutations/set-worksheet-hide.mutation';
import { SetWorksheetHideMutation, SetWorksheetHideMutationFactory } from '../mutations/set-worksheet-hide.mutation';
diff --git a/packages/sheets/src/commands/mutations/__tests__/create-command-test-bed.ts b/packages/sheets/src/commands/mutations/__tests__/create-command-test-bed.ts
index b09327ebc7..fae2ef8438 100644
--- a/packages/sheets/src/commands/mutations/__tests__/create-command-test-bed.ts
+++ b/packages/sheets/src/commands/mutations/__tests__/create-command-test-bed.ts
@@ -14,18 +14,18 @@
* limitations under the License.
*/
-import type { IWorkbookData, Workbook } from '@univerjs/core';
+import type { Dependency, IWorkbookData, Workbook } from '@univerjs/core';
import {
BooleanNumber,
ILogService,
+ Inject,
+ Injector,
IUniverInstanceService,
LogLevel,
Plugin,
Univer,
UniverInstanceType,
} from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
const TEST_WORKBOOK_DATA_DEMO: () => IWorkbookData = () => ({
id: 'workbook-01',
diff --git a/packages/sheets/src/commands/mutations/__tests__/remove-row-col.mutation.spec.ts b/packages/sheets/src/commands/mutations/__tests__/remove-row-col.mutation.spec.ts
index 3763d76611..f13874b01a 100644
--- a/packages/sheets/src/commands/mutations/__tests__/remove-row-col.mutation.spec.ts
+++ b/packages/sheets/src/commands/mutations/__tests__/remove-row-col.mutation.spec.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { Workbook } from '@univerjs/core';
+import type { Injector, Workbook } from '@univerjs/core';
import { BooleanNumber, ICommandService, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { beforeEach, describe, expect, it } from 'vitest';
import type {
diff --git a/packages/sheets/src/commands/mutations/add-worksheet-merge.mutation.ts b/packages/sheets/src/commands/mutations/add-worksheet-merge.mutation.ts
index 6031736bc0..3c9e24f387 100644
--- a/packages/sheets/src/commands/mutations/add-worksheet-merge.mutation.ts
+++ b/packages/sheets/src/commands/mutations/add-worksheet-merge.mutation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IMutation } from '@univerjs/core';
+import type { IAccessor, IMutation } from '@univerjs/core';
import { CommandType, IUniverInstanceService } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type {
IAddWorksheetMergeMutationParams,
diff --git a/packages/sheets/src/commands/mutations/delete-range-protection.mutation.ts b/packages/sheets/src/commands/mutations/delete-range-protection.mutation.ts
index 9ad41ab8b9..6514849e06 100644
--- a/packages/sheets/src/commands/mutations/delete-range-protection.mutation.ts
+++ b/packages/sheets/src/commands/mutations/delete-range-protection.mutation.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import type { IAccessor } from '@wendellhu/redi';
-import type { IMutation, IMutationInfo } from '@univerjs/core';
+import type { IAccessor, IMutation, IMutationInfo } from '@univerjs/core';
import { CommandType } from '@univerjs/core';
import type { IRangeProtectionRule } from '../../model/range-protection-rule.model';
diff --git a/packages/sheets/src/commands/mutations/insert-row-col.mutation.ts b/packages/sheets/src/commands/mutations/insert-row-col.mutation.ts
index ac3f21d86f..67bdd173d9 100644
--- a/packages/sheets/src/commands/mutations/insert-row-col.mutation.ts
+++ b/packages/sheets/src/commands/mutations/insert-row-col.mutation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IMutation } from '@univerjs/core';
+import type { IAccessor, IMutation } from '@univerjs/core';
import { CommandType, insertMatrixArray, IUniverInstanceService } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type {
IInsertColMutationParams,
diff --git a/packages/sheets/src/commands/mutations/insert-sheet.mutation.ts b/packages/sheets/src/commands/mutations/insert-sheet.mutation.ts
index da0eaa4602..78e9e8e027 100644
--- a/packages/sheets/src/commands/mutations/insert-sheet.mutation.ts
+++ b/packages/sheets/src/commands/mutations/insert-sheet.mutation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IMutation } from '@univerjs/core';
+import type { IAccessor, IMutation } from '@univerjs/core';
import { CommandType, IUniverInstanceService } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type {
IInsertSheetMutationParams,
diff --git a/packages/sheets/src/commands/mutations/move-rows-cols.mutation.ts b/packages/sheets/src/commands/mutations/move-rows-cols.mutation.ts
index b3b148d46b..b20e742c4d 100644
--- a/packages/sheets/src/commands/mutations/move-rows-cols.mutation.ts
+++ b/packages/sheets/src/commands/mutations/move-rows-cols.mutation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IMutation, IRange } from '@univerjs/core';
+import type { IAccessor, IMutation, IRange } from '@univerjs/core';
import { CommandType, IUniverInstanceService, moveMatrixArray, Rectangle } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
export interface IMoveRowsMutationParams {
unitId: string;
diff --git a/packages/sheets/src/commands/mutations/numfmt-mutation.ts b/packages/sheets/src/commands/mutations/numfmt-mutation.ts
index 17729c2579..b9cb72d851 100644
--- a/packages/sheets/src/commands/mutations/numfmt-mutation.ts
+++ b/packages/sheets/src/commands/mutations/numfmt-mutation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICommand, IMutationInfo, IRange } from '@univerjs/core';
+import type { IAccessor, ICommand, IMutationInfo, IRange } from '@univerjs/core';
import { cellToRange, CommandType, Range } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { rangeMerge } from '../../basics/rangeMerge';
import { createUniqueKey, groupByKey } from '../../basics/utils';
diff --git a/packages/sheets/src/commands/mutations/remove-row-col.mutation.ts b/packages/sheets/src/commands/mutations/remove-row-col.mutation.ts
index 0fcf873634..1d2324c3cd 100644
--- a/packages/sheets/src/commands/mutations/remove-row-col.mutation.ts
+++ b/packages/sheets/src/commands/mutations/remove-row-col.mutation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IColumnData, IMutation, IObjectArrayPrimitiveType, IRowData, Worksheet } from '@univerjs/core';
+import type { IAccessor, IColumnData, IMutation, IObjectArrayPrimitiveType, IRowData, Worksheet } from '@univerjs/core';
import { CommandType, concatMatrixArray, IUniverInstanceService, sliceMatrixArray, spliceArray } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type {
IInsertColMutationParams,
diff --git a/packages/sheets/src/commands/mutations/remove-sheet.mutation.ts b/packages/sheets/src/commands/mutations/remove-sheet.mutation.ts
index 11f1a43f89..9bc6321b33 100644
--- a/packages/sheets/src/commands/mutations/remove-sheet.mutation.ts
+++ b/packages/sheets/src/commands/mutations/remove-sheet.mutation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IMutation } from '@univerjs/core';
+import type { IAccessor, IMutation } from '@univerjs/core';
import { CommandType, IUniverInstanceService } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type {
IInsertSheetMutationParams,
diff --git a/packages/sheets/src/commands/mutations/remove-worksheet-merge.mutation.ts b/packages/sheets/src/commands/mutations/remove-worksheet-merge.mutation.ts
index be1aa47774..3026682bdd 100644
--- a/packages/sheets/src/commands/mutations/remove-worksheet-merge.mutation.ts
+++ b/packages/sheets/src/commands/mutations/remove-worksheet-merge.mutation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IMutation } from '@univerjs/core';
+import type { IAccessor, IMutation } from '@univerjs/core';
import { CommandType, IUniverInstanceService, Rectangle } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type {
IAddWorksheetMergeMutationParams,
diff --git a/packages/sheets/src/commands/mutations/set-col-visible.mutation.ts b/packages/sheets/src/commands/mutations/set-col-visible.mutation.ts
index 974a8c1d58..3af99452dc 100644
--- a/packages/sheets/src/commands/mutations/set-col-visible.mutation.ts
+++ b/packages/sheets/src/commands/mutations/set-col-visible.mutation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IMutation, IRange } from '@univerjs/core';
+import type { IAccessor, IMutation, IRange } from '@univerjs/core';
import { BooleanNumber, CommandType, IUniverInstanceService } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
export interface ISetColHiddenMutationParams {
unitId: string;
diff --git a/packages/sheets/src/commands/mutations/set-frozen.mutation.ts b/packages/sheets/src/commands/mutations/set-frozen.mutation.ts
index 7eb09f192d..17ab6abc07 100644
--- a/packages/sheets/src/commands/mutations/set-frozen.mutation.ts
+++ b/packages/sheets/src/commands/mutations/set-frozen.mutation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IMutation } from '@univerjs/core';
+import type { IAccessor, IMutation } from '@univerjs/core';
import { CommandType, IUniverInstanceService } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
export interface ISetFrozenMutationParams {
unitId: string;
diff --git a/packages/sheets/src/commands/mutations/set-hide-gridlines.mutatiom.ts b/packages/sheets/src/commands/mutations/set-hide-gridlines.mutatiom.ts
index bcd9a8af18..5f2d2e66cc 100644
--- a/packages/sheets/src/commands/mutations/set-hide-gridlines.mutatiom.ts
+++ b/packages/sheets/src/commands/mutations/set-hide-gridlines.mutatiom.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { BooleanNumber, IMutation } from '@univerjs/core';
+import type { BooleanNumber, IAccessor, IMutation } from '@univerjs/core';
import { CommandType, IUniverInstanceService, Tools } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
export interface ISetHideGridlinesMutationParams {
hideGridlines: BooleanNumber;
diff --git a/packages/sheets/src/commands/mutations/set-range-protection.mutation.ts b/packages/sheets/src/commands/mutations/set-range-protection.mutation.ts
index ff579022e1..644de96b5b 100644
--- a/packages/sheets/src/commands/mutations/set-range-protection.mutation.ts
+++ b/packages/sheets/src/commands/mutations/set-range-protection.mutation.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import type { IAccessor } from '@wendellhu/redi';
-import type { IMutation, IMutationInfo } from '@univerjs/core';
+import type { IAccessor, IMutation, IMutationInfo } from '@univerjs/core';
import { CommandType } from '@univerjs/core';
import type { IRangeProtectionRule } from '../../model/range-protection-rule.model';
diff --git a/packages/sheets/src/commands/mutations/set-range-values.mutation.ts b/packages/sheets/src/commands/mutations/set-range-values.mutation.ts
index 12d8b40d8c..ef891afba1 100644
--- a/packages/sheets/src/commands/mutations/set-range-values.mutation.ts
+++ b/packages/sheets/src/commands/mutations/set-range-values.mutation.ts
@@ -15,6 +15,7 @@
*/
import type {
+ IAccessor,
ICellData,
ICopyToOptionsData,
IMutation,
@@ -25,7 +26,6 @@ import type {
Workbook,
} from '@univerjs/core';
import { CommandType, IUniverInstanceService, ObjectMatrix, Tools } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { handleStyle, transformStyle } from '../../basics/cell-style';
import { getCellValue, setNull } from '../../basics/cell-value';
import { getCellType } from '../../basics/cell-type';
diff --git a/packages/sheets/src/commands/mutations/set-row-visible.mutation.ts b/packages/sheets/src/commands/mutations/set-row-visible.mutation.ts
index 76caa69a1d..c1285302ab 100644
--- a/packages/sheets/src/commands/mutations/set-row-visible.mutation.ts
+++ b/packages/sheets/src/commands/mutations/set-row-visible.mutation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IMutation, IRange } from '@univerjs/core';
+import type { IAccessor, IMutation, IRange } from '@univerjs/core';
import { CommandType, IUniverInstanceService } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
export interface ISetRowVisibleMutationParams {
unitId: string;
diff --git a/packages/sheets/src/commands/mutations/set-tab-color.mutation.ts b/packages/sheets/src/commands/mutations/set-tab-color.mutation.ts
index bbd3df4065..564fd97c33 100644
--- a/packages/sheets/src/commands/mutations/set-tab-color.mutation.ts
+++ b/packages/sheets/src/commands/mutations/set-tab-color.mutation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IMutation } from '@univerjs/core';
+import type { IAccessor, IMutation } from '@univerjs/core';
import { CommandType, IUniverInstanceService, Tools } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
export interface ISetTabColorMutationParams {
color: string;
diff --git a/packages/sheets/src/commands/mutations/set-worksheet-col-width.mutation.ts b/packages/sheets/src/commands/mutations/set-worksheet-col-width.mutation.ts
index 56de8bafcd..ae21393e2c 100644
--- a/packages/sheets/src/commands/mutations/set-worksheet-col-width.mutation.ts
+++ b/packages/sheets/src/commands/mutations/set-worksheet-col-width.mutation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IMutation, IObjectArrayPrimitiveType, IRange, Nullable } from '@univerjs/core';
+import type { IAccessor, IMutation, IObjectArrayPrimitiveType, IRange, Nullable } from '@univerjs/core';
import { CommandType, IUniverInstanceService } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
export interface ISetWorksheetColWidthMutationParams {
unitId: string;
diff --git a/packages/sheets/src/commands/mutations/set-worksheet-hide.mutation.ts b/packages/sheets/src/commands/mutations/set-worksheet-hide.mutation.ts
index 64fe17b697..cf053fcef8 100644
--- a/packages/sheets/src/commands/mutations/set-worksheet-hide.mutation.ts
+++ b/packages/sheets/src/commands/mutations/set-worksheet-hide.mutation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { BooleanNumber, IMutation } from '@univerjs/core';
+import type { BooleanNumber, IAccessor, IMutation } from '@univerjs/core';
import { CommandType, IUniverInstanceService } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { getSheetMutationTarget } from '../commands/utils/target-util';
export interface ISetWorksheetHideMutationParams {
diff --git a/packages/sheets/src/commands/mutations/set-worksheet-name.mutation.ts b/packages/sheets/src/commands/mutations/set-worksheet-name.mutation.ts
index 5f562cae5f..66ce38692c 100644
--- a/packages/sheets/src/commands/mutations/set-worksheet-name.mutation.ts
+++ b/packages/sheets/src/commands/mutations/set-worksheet-name.mutation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IMutation } from '@univerjs/core';
+import type { IAccessor, IMutation } from '@univerjs/core';
import { CommandType, IUniverInstanceService } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { getSheetMutationTarget } from '../commands/utils/target-util';
export interface ISetWorksheetNameMutationParams {
diff --git a/packages/sheets/src/commands/mutations/set-worksheet-order.mutation.ts b/packages/sheets/src/commands/mutations/set-worksheet-order.mutation.ts
index b2c00e756c..e9cc19bee4 100644
--- a/packages/sheets/src/commands/mutations/set-worksheet-order.mutation.ts
+++ b/packages/sheets/src/commands/mutations/set-worksheet-order.mutation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IMutation } from '@univerjs/core';
+import type { IAccessor, IMutation } from '@univerjs/core';
import { CommandType, IUniverInstanceService, Tools } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
export interface ISetWorksheetOrderMutationParams {
fromOrder: number;
diff --git a/packages/sheets/src/commands/mutations/set-worksheet-right-to-left.mutation.ts b/packages/sheets/src/commands/mutations/set-worksheet-right-to-left.mutation.ts
index d264197106..ea897ed1d9 100644
--- a/packages/sheets/src/commands/mutations/set-worksheet-right-to-left.mutation.ts
+++ b/packages/sheets/src/commands/mutations/set-worksheet-right-to-left.mutation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { BooleanNumber, IMutation } from '@univerjs/core';
+import type { BooleanNumber, IAccessor, IMutation } from '@univerjs/core';
import { CommandType, IUniverInstanceService, Tools } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
export interface ISetWorksheetRightToLeftMutationParams {
rightToLeft: BooleanNumber;
diff --git a/packages/sheets/src/commands/mutations/set-worksheet-row-height.mutation.ts b/packages/sheets/src/commands/mutations/set-worksheet-row-height.mutation.ts
index 8e0cd000b2..adc634f4aa 100644
--- a/packages/sheets/src/commands/mutations/set-worksheet-row-height.mutation.ts
+++ b/packages/sheets/src/commands/mutations/set-worksheet-row-height.mutation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { BooleanNumber, IMutation, IObjectArrayPrimitiveType, IRange, IRowAutoHeightInfo, Nullable, Workbook } from '@univerjs/core';
+import type { BooleanNumber, IAccessor, IMutation, IObjectArrayPrimitiveType, IRange, IRowAutoHeightInfo, Nullable, Workbook } from '@univerjs/core';
import { CommandType, IUniverInstanceService } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
const MAXIMUM_ROW_HEIGHT = 2000;
diff --git a/packages/sheets/src/commands/utils/handle-merge-operation.ts b/packages/sheets/src/commands/utils/handle-merge-operation.ts
index 116c9f07d6..786e182d3c 100644
--- a/packages/sheets/src/commands/utils/handle-merge-operation.ts
+++ b/packages/sheets/src/commands/utils/handle-merge-operation.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import type { IAccessor } from '@wendellhu/redi';
-import type { IRange } from '@univerjs/core';
+import type { IAccessor, IRange } from '@univerjs/core';
import { Dimension } from '@univerjs/core';
import type { IAddMergeCommandParams } from '../commands/add-worksheet-merge.command';
import { SheetsSelectionsService } from '../../services/selections/selection-manager.service';
diff --git a/packages/sheets/src/commands/utils/handle-range-mutation.ts b/packages/sheets/src/commands/utils/handle-range-mutation.ts
index d13cd58dfc..b33de4c6cd 100644
--- a/packages/sheets/src/commands/utils/handle-range-mutation.ts
+++ b/packages/sheets/src/commands/utils/handle-range-mutation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICellData, IMutationInfo, IObjectMatrixPrimitiveType, IRange, Nullable } from '@univerjs/core';
+import type { IAccessor, ICellData, IMutationInfo, IObjectMatrixPrimitiveType, IRange, Nullable } from '@univerjs/core';
import { Dimension, getArrayLength, IUniverInstanceService, ObjectMatrix, Tools } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import type {
IDeleteRangeMutationParams,
diff --git a/packages/sheets/src/commands/utils/selection-command-util.ts b/packages/sheets/src/commands/utils/selection-command-util.ts
index b7ff564f5b..9dc93509c2 100644
--- a/packages/sheets/src/commands/utils/selection-command-util.ts
+++ b/packages/sheets/src/commands/utils/selection-command-util.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor } from '@univerjs/core';
import { IContextService } from '@univerjs/core';
import { DISABLE_NORMAL_SELECTIONS, SheetsSelectionsService } from '../../services/selections/selection-manager.service';
import { IRefSelectionsService } from '../../services/selections/ref-selections.service';
diff --git a/packages/sheets/src/controllers/__tests__/util.ts b/packages/sheets/src/controllers/__tests__/util.ts
index c45ddebd9f..ede5599331 100644
--- a/packages/sheets/src/controllers/__tests__/util.ts
+++ b/packages/sheets/src/controllers/__tests__/util.ts
@@ -14,10 +14,8 @@
* limitations under the License.
*/
-import type { IWorkbookData } from '@univerjs/core';
-import { ILogService, IUniverInstanceService, LocaleType, LogLevel, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import type { Dependency, IWorkbookData } from '@univerjs/core';
+import { ILogService, Inject, Injector, IUniverInstanceService, LocaleType, LogLevel, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
const TEST_WORKBOOK_DATA_DEMO: IWorkbookData = {
id: 'test',
diff --git a/packages/sheets/src/controllers/basic-worksheet.controller.ts b/packages/sheets/src/controllers/basic-worksheet.controller.ts
index a08d305ef9..45fe922dd1 100644
--- a/packages/sheets/src/controllers/basic-worksheet.controller.ts
+++ b/packages/sheets/src/controllers/basic-worksheet.controller.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IMutation, IStyleData } from '@univerjs/core';
-import { Disposable, ICommandService, IConfigService, LifecycleStages, OnLifecycle } from '@univerjs/core';
-import { type IDisposable, Optional } from '@wendellhu/redi';
+import type { IDisposable, IMutation, IStyleData } from '@univerjs/core';
+import { Disposable, ICommandService, IConfigService, LifecycleStages, OnLifecycle, Optional } from '@univerjs/core';
import { DataSyncPrimaryController } from '@univerjs/rpc';
import { ClearSelectionAllCommand } from '../commands/commands/clear-selection-all.command';
diff --git a/packages/sheets/src/controllers/calculate-result-apply.controller.ts b/packages/sheets/src/controllers/calculate-result-apply.controller.ts
index 29094ce222..186935d069 100644
--- a/packages/sheets/src/controllers/calculate-result-apply.controller.ts
+++ b/packages/sheets/src/controllers/calculate-result-apply.controller.ts
@@ -15,11 +15,10 @@
*/
import type { ICellData, ICommandInfo, IObjectMatrixPrimitiveType, Nullable } from '@univerjs/core';
-import { Disposable, ICommandService, IUniverInstanceService, LifecycleStages, ObjectMatrix, OnLifecycle } from '@univerjs/core';
+import { Disposable, ICommandService, Inject, IUniverInstanceService, LifecycleStages, ObjectMatrix, OnLifecycle } from '@univerjs/core';
import type { ISetFormulaCalculationResultMutation } from '@univerjs/engine-formula';
import { handleNumfmtInCell, SetFormulaCalculationResultMutation } from '@univerjs/engine-formula';
-import { Inject } from '@wendellhu/redi';
import { SetRangeValuesMutation } from '../commands/mutations/set-range-values.mutation';
@OnLifecycle(LifecycleStages.Ready, CalculateResultApplyController)
diff --git a/packages/sheets/src/controllers/defined-name-data.controller.ts b/packages/sheets/src/controllers/defined-name-data.controller.ts
index 44a1e25d2c..e94690a54a 100644
--- a/packages/sheets/src/controllers/defined-name-data.controller.ts
+++ b/packages/sheets/src/controllers/defined-name-data.controller.ts
@@ -19,7 +19,8 @@ import {
IResourceManagerService,
LifecycleStages,
OnLifecycle,
- UniverInstanceType } from '@univerjs/core';
+ UniverInstanceType,
+} from '@univerjs/core';
import type { IDefinedNameMapItem } from '@univerjs/engine-formula';
import { IDefinedNamesService } from '@univerjs/engine-formula';
diff --git a/packages/sheets/src/controllers/merge-cell.controller.ts b/packages/sheets/src/controllers/merge-cell.controller.ts
index 134d8c261a..33eb5c14a8 100644
--- a/packages/sheets/src/controllers/merge-cell.controller.ts
+++ b/packages/sheets/src/controllers/merge-cell.controller.ts
@@ -20,6 +20,8 @@ import {
Disposable,
DisposableCollection,
ICommandService,
+ Inject,
+ Injector,
IUniverInstanceService,
LifecycleStages,
OnLifecycle,
@@ -27,7 +29,6 @@ import {
Tools,
UniverInstanceType,
} from '@univerjs/core';
-import { Inject, Injector } from '@wendellhu/redi';
import type {
IAddWorksheetMergeMutationParams,
diff --git a/packages/sheets/src/controllers/number-cell.controller.ts b/packages/sheets/src/controllers/number-cell.controller.ts
index 09f69e23df..f93f9f30db 100644
--- a/packages/sheets/src/controllers/number-cell.controller.ts
+++ b/packages/sheets/src/controllers/number-cell.controller.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { CellValueType, Disposable, LifecycleStages, OnLifecycle } from '@univerjs/core';
+import { CellValueType, Disposable, Inject, LifecycleStages, OnLifecycle } from '@univerjs/core';
import { stripErrorMargin } from '@univerjs/engine-formula';
-import { Inject } from '@wendellhu/redi';
import { SheetInterceptorService } from '../services/sheet-interceptor/sheet-interceptor.service';
import { INTERCEPTOR_POINT } from '../services/sheet-interceptor/interceptor-const';
diff --git a/packages/sheets/src/model/range-protection-render.model.ts b/packages/sheets/src/model/range-protection-render.model.ts
index 884bb2c815..e0417ca160 100644
--- a/packages/sheets/src/model/range-protection-render.model.ts
+++ b/packages/sheets/src/model/range-protection-render.model.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { Inject } from '@wendellhu/redi';
+import { Inject, IPermissionService, LifecycleStages, LRUMap, OnLifecycle, Range } from '@univerjs/core';
import { filter, map } from 'rxjs/operators';
-import { IPermissionService, LifecycleStages, LRUMap, OnLifecycle, Range } from '@univerjs/core';
import type { UnitAction } from '@univerjs/protocol';
import { UnitObject } from '@univerjs/protocol';
diff --git a/packages/sheets/src/services/__tests__/numfmt.service.test.ts b/packages/sheets/src/services/__tests__/numfmt.service.test.ts
index 38eea230b7..6bd546a6bc 100644
--- a/packages/sheets/src/services/__tests__/numfmt.service.test.ts
+++ b/packages/sheets/src/services/__tests__/numfmt.service.test.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { Styles, Univer, Workbook, Worksheet } from '@univerjs/core';
+import type { Injector, Styles, Univer, Workbook, Worksheet } from '@univerjs/core';
import { cellToRange, CellValueType, ICommandService, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
import type { IRemoveNumfmtMutationParams, ISetNumfmtMutationParams } from '@univerjs/sheets';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { DEFAULT_TEXT_FORMAT } from '@univerjs/engine-numfmt';
diff --git a/packages/sheets/src/services/__tests__/ref-range.setvice.spec.ts b/packages/sheets/src/services/__tests__/ref-range.setvice.spec.ts
index 6fd94fb53b..42e93ff11b 100644
--- a/packages/sheets/src/services/__tests__/ref-range.setvice.spec.ts
+++ b/packages/sheets/src/services/__tests__/ref-range.setvice.spec.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IRange, Univer, Workbook, Worksheet } from '@univerjs/core';
+import type { Injector, IRange, Univer, Workbook, Worksheet } from '@univerjs/core';
import { ICommandService, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest';
import type { IMoveRangeCommandParams } from '../../commands/commands/move-range.command';
diff --git a/packages/sheets/src/services/__tests__/util.ts b/packages/sheets/src/services/__tests__/util.ts
index 8dda30c3e8..36332a5ab3 100644
--- a/packages/sheets/src/services/__tests__/util.ts
+++ b/packages/sheets/src/services/__tests__/util.ts
@@ -14,11 +14,9 @@
* limitations under the License.
*/
-import type { IWorkbookData } from '@univerjs/core';
-import { CellValueType, ILogService, IUniverInstanceService, LocaleType, LogLevel, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
+import type { Dependency, IWorkbookData } from '@univerjs/core';
+import { CellValueType, ILogService, Inject, Injector, IUniverInstanceService, LocaleType, LogLevel, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
import { DEFAULT_TEXT_FORMAT } from '@univerjs/engine-numfmt';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
export const TEST_WORKBOOK_DATA_DEMO: IWorkbookData = {
id: 'test',
diff --git a/packages/sheets/src/services/border-style-manager.service.ts b/packages/sheets/src/services/border-style-manager.service.ts
index 37475deebb..247bc2245e 100644
--- a/packages/sheets/src/services/border-style-manager.service.ts
+++ b/packages/sheets/src/services/border-style-manager.service.ts
@@ -15,7 +15,7 @@
*/
import { BorderStyleTypes, BorderType } from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
+import type { IDisposable } from '@univerjs/core';
import { BehaviorSubject } from 'rxjs';
export interface IBorderInfo {
diff --git a/packages/sheets/src/services/numfmt/type.ts b/packages/sheets/src/services/numfmt/type.ts
index 2f4687b1f6..39719b696b 100644
--- a/packages/sheets/src/services/numfmt/type.ts
+++ b/packages/sheets/src/services/numfmt/type.ts
@@ -15,8 +15,7 @@
*/
import type { ICellData, IRange, Nullable, ObjectMatrix } from '@univerjs/core';
-import { LifecycleStages, runOnLifecycle } from '@univerjs/core';
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier, LifecycleStages, runOnLifecycle } from '@univerjs/core';
// eslint-disable-next-line ts/consistent-type-definitions
export type INumfmtItem = {
diff --git a/packages/sheets/src/services/permission/range-permission/range-protection.ref-range.ts b/packages/sheets/src/services/permission/range-permission/range-protection.ref-range.ts
index 092525d778..b26b8bafe2 100644
--- a/packages/sheets/src/services/permission/range-permission/range-protection.ref-range.ts
+++ b/packages/sheets/src/services/permission/range-permission/range-protection.ref-range.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { Inject } from '@wendellhu/redi';
+import { Disposable, DisposableCollection, ICommandService, Inject, IUniverInstanceService, LifecycleStages, OnLifecycle, Rectangle, Tools, UniverInstanceType } from '@univerjs/core';
import type { ICommandInfo, IRange, Workbook } from '@univerjs/core';
-import { Disposable, DisposableCollection, ICommandService, IUniverInstanceService, LifecycleStages, OnLifecycle, Rectangle, Tools, UniverInstanceType } from '@univerjs/core';
import { AddRangeProtectionCommand } from '../../../commands/commands/add-range-protection.command';
import { SetRangeProtectionCommand } from '../../../commands/commands/set-range-protection.command';
import type { IRangeProtectionRule } from '../../../model/range-protection-rule.model';
diff --git a/packages/sheets/src/services/permission/range-permission/range-protection.service.ts b/packages/sheets/src/services/permission/range-permission/range-protection.service.ts
index b3fbe796fa..df4185d67e 100644
--- a/packages/sheets/src/services/permission/range-permission/range-protection.service.ts
+++ b/packages/sheets/src/services/permission/range-permission/range-protection.service.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { Disposable, IPermissionService, IResourceManagerService, LifecycleStages, OnLifecycle } from '@univerjs/core';
+import { Disposable, Inject, IPermissionService, IResourceManagerService, LifecycleStages, OnLifecycle } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
import { UnitAction, UnitObject, UniverType } from '@univerjs/protocol';
import type { IObjectModel } from '../../../model/range-protection-rule.model';
import { RangeProtectionRuleModel } from '../../../model/range-protection-rule.model';
diff --git a/packages/sheets/src/services/permission/workbook-permission/workbook-permission.service.ts b/packages/sheets/src/services/permission/workbook-permission/workbook-permission.service.ts
index d3c4136874..c84d22b304 100644
--- a/packages/sheets/src/services/permission/workbook-permission/workbook-permission.service.ts
+++ b/packages/sheets/src/services/permission/workbook-permission/workbook-permission.service.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { Inject } from '@wendellhu/redi';
+import { Disposable, Inject, IPermissionService, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import type { Workbook } from '@univerjs/core';
-import { Disposable, IPermissionService, IUniverInstanceService, LifecycleStages, OnLifecycle, UniverInstanceType } from '@univerjs/core';
import { getAllWorksheetPermissionPoint, getAllWorksheetPermissionPointByPointPanel } from '../worksheet-permission/utils';
import { RangeProtectionRuleModel } from '../../../model/range-protection-rule.model';
diff --git a/packages/sheets/src/services/permission/worksheet-permission/worksheet-permission.service.ts b/packages/sheets/src/services/permission/worksheet-permission/worksheet-permission.service.ts
index 818fe10f53..6d56ade2b7 100644
--- a/packages/sheets/src/services/permission/worksheet-permission/worksheet-permission.service.ts
+++ b/packages/sheets/src/services/permission/worksheet-permission/worksheet-permission.service.ts
@@ -15,8 +15,7 @@
*/
import type { Workbook, Worksheet } from '@univerjs/core';
-import { IPermissionService, IResourceManagerService, IUniverInstanceService, LifecycleStages, OnLifecycle, RxDisposable, UniverInstanceType } from '@univerjs/core';
-import { Inject, Injector } from '@wendellhu/redi';
+import { Inject, Injector, IPermissionService, IResourceManagerService, IUniverInstanceService, LifecycleStages, OnLifecycle, RxDisposable, UniverInstanceType } from '@univerjs/core';
import { takeUntil } from 'rxjs/operators';
import { UniverType } from '@univerjs/protocol';
diff --git a/packages/sheets/src/services/ref-range/__tests__/__testing__.ts b/packages/sheets/src/services/ref-range/__tests__/__testing__.ts
index cb1ed3e5e6..983dafd612 100644
--- a/packages/sheets/src/services/ref-range/__tests__/__testing__.ts
+++ b/packages/sheets/src/services/ref-range/__tests__/__testing__.ts
@@ -14,10 +14,8 @@
* limitations under the License.
*/
-import type { IWorkbookData } from '@univerjs/core';
-import { ILogService, IUniverInstanceService, LocaleType, LogLevel, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import type { Dependency, IWorkbookData } from '@univerjs/core';
+import { ILogService, Inject, Injector, IUniverInstanceService, LocaleType, LogLevel, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
export const TEST_WORKBOOK_DATA_DEMO: IWorkbookData = {
id: 'test',
diff --git a/packages/sheets/src/services/ref-range/__tests__/ref-range.service.spec.ts b/packages/sheets/src/services/ref-range/__tests__/ref-range.service.spec.ts
index 4727584392..43a210180a 100644
--- a/packages/sheets/src/services/ref-range/__tests__/ref-range.service.spec.ts
+++ b/packages/sheets/src/services/ref-range/__tests__/ref-range.service.spec.ts
@@ -15,10 +15,8 @@
*/
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
-import type { ICommand, IRange, IWorkbookData, Nullable } from '@univerjs/core';
-import { ICommandService, ILogService, IUniverInstanceService, LocaleType, LogLevel, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import type { Dependency, ICommand, IRange, IWorkbookData, Nullable } from '@univerjs/core';
+import { ICommandService, ILogService, Inject, Injector, IUniverInstanceService, LocaleType, LogLevel, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
import { RefRangeService } from '../ref-range.service';
import { SheetsSelectionsService } from '../../selections/selection-manager.service';
diff --git a/packages/sheets/src/services/ref-range/ref-range.service.ts b/packages/sheets/src/services/ref-range/ref-range.service.ts
index 429e4f7b13..93f286045f 100644
--- a/packages/sheets/src/services/ref-range/ref-range.service.ts
+++ b/packages/sheets/src/services/ref-range/ref-range.service.ts
@@ -14,12 +14,13 @@
* limitations under the License.
*/
-import type { IMutationInfo, IRange, Nullable, Workbook } from '@univerjs/core';
+import type { IDisposable, IMutationInfo, IRange, Nullable, Workbook } from '@univerjs/core';
import {
CommandType,
createInterceptorKey,
Disposable,
ICommandService,
+ Inject,
InterceptorManager,
IUniverInstanceService,
LifecycleStages,
@@ -29,8 +30,6 @@ import {
toDisposable,
UniverInstanceType,
} from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject } from '@wendellhu/redi';
import { SheetsSelectionsService } from '../selections/selection-manager.service';
import { SheetInterceptorService } from '../sheet-interceptor/sheet-interceptor.service';
diff --git a/packages/sheets/src/services/selections/ref-selections.service.ts b/packages/sheets/src/services/selections/ref-selections.service.ts
index b0ebcbc8be..b545c78c33 100644
--- a/packages/sheets/src/services/selections/ref-selections.service.ts
+++ b/packages/sheets/src/services/selections/ref-selections.service.ts
@@ -15,8 +15,7 @@
*/
import type { Workbook } from '@univerjs/core';
-import { IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
import type { Observable } from 'rxjs';
import { BehaviorSubject, map, merge, switchMap, takeUntil } from 'rxjs';
import type { WorkbookSelections } from './selection-manager.service';
diff --git a/packages/sheets/src/services/sheet-interceptor/__tests__/create-core-test-bed.ts b/packages/sheets/src/services/sheet-interceptor/__tests__/create-core-test-bed.ts
index 24b31a840d..80d2e89e4c 100644
--- a/packages/sheets/src/services/sheet-interceptor/__tests__/create-core-test-bed.ts
+++ b/packages/sheets/src/services/sheet-interceptor/__tests__/create-core-test-bed.ts
@@ -14,10 +14,8 @@
* limitations under the License.
*/
-import type { IWorkbookData } from '@univerjs/core';
-import { ILogService, IUniverInstanceService, LocaleType, LogLevel, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import type { Dependency, IWorkbookData } from '@univerjs/core';
+import { ILogService, Inject, Injector, IUniverInstanceService, LocaleType, LogLevel, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
const TEST_WORKBOOK_DATA: IWorkbookData = {
id: 'test',
diff --git a/packages/sheets/src/services/sheet-interceptor/__tests__/sheet-interceptor.service.spec.ts b/packages/sheets/src/services/sheet-interceptor/__tests__/sheet-interceptor.service.spec.ts
index 778b2beda6..e245d43c60 100644
--- a/packages/sheets/src/services/sheet-interceptor/__tests__/sheet-interceptor.service.spec.ts
+++ b/packages/sheets/src/services/sheet-interceptor/__tests__/sheet-interceptor.service.spec.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ICellData, Nullable, Univer, Workbook } from '@univerjs/core';
+import type { ICellData, Injector, Nullable, Univer, Workbook } from '@univerjs/core';
import { createInterceptorKey, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
-import type { Injector } from '@wendellhu/redi';
import { afterEach, beforeEach, describe, expect, it } from 'vitest';
import { INTERCEPTOR_POINT } from '../interceptor-const';
diff --git a/packages/sheets/src/services/sheet-interceptor/sheet-interceptor.service.ts b/packages/sheets/src/services/sheet-interceptor/sheet-interceptor.service.ts
index c350b01a63..806ef16cef 100644
--- a/packages/sheets/src/services/sheet-interceptor/sheet-interceptor.service.ts
+++ b/packages/sheets/src/services/sheet-interceptor/sheet-interceptor.service.ts
@@ -17,6 +17,7 @@
import type {
ICellData,
ICommandInfo,
+ IDisposable,
IInterceptor,
IUndoRedoCommandInfosByInterceptor,
Nullable,
@@ -34,7 +35,6 @@ import {
toDisposable,
UniverInstanceType,
} from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
import { INTERCEPTOR_POINT } from './interceptor-const';
diff --git a/packages/sheets/src/sheets-plugin.ts b/packages/sheets/src/sheets-plugin.ts
index bf9310fd44..f2b6b6c494 100644
--- a/packages/sheets/src/sheets-plugin.ts
+++ b/packages/sheets/src/sheets-plugin.ts
@@ -14,10 +14,8 @@
* limitations under the License.
*/
-import type { DependencyOverride } from '@univerjs/core';
-import { DependentOn, ICommandService, IConfigService, LocaleService, mergeOverrideWithDependencies, Plugin, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import type { Dependency, DependencyOverride } from '@univerjs/core';
+import { DependentOn, ICommandService, IConfigService, Inject, Injector, LocaleService, mergeOverrideWithDependencies, Plugin, UniverInstanceType } from '@univerjs/core';
import { UniverFormulaEnginePlugin } from '@univerjs/engine-formula';
import { BasicWorksheetController } from './controllers/basic-worksheet.controller';
diff --git a/packages/slides-ui/package.json b/packages/slides-ui/package.json
index 0531ed1789..e1e2d8126a 100644
--- a/packages/slides-ui/package.json
+++ b/packages/slides-ui/package.json
@@ -70,7 +70,6 @@
"@univerjs/engine-render": "workspace:*",
"@univerjs/slides": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": ">=2.0.0",
"react": "^16.9.0 || ^17.0.0 || ^18.0.0"
},
@@ -82,7 +81,6 @@
"@univerjs/shared": "workspace:*",
"@univerjs/slides": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": "^2.1.1",
"less": "^4.2.0",
"react": "18.3.1",
diff --git a/packages/slides-ui/src/commands/operations/activate.operation.ts b/packages/slides-ui/src/commands/operations/activate.operation.ts
index 4427e1d7e9..1310952936 100644
--- a/packages/slides-ui/src/commands/operations/activate.operation.ts
+++ b/packages/slides-ui/src/commands/operations/activate.operation.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { IOperation } from '@univerjs/core';
+import type { IAccessor, IOperation } from '@univerjs/core';
import { CommandType } from '@univerjs/core';
import { CanvasView } from '@univerjs/slides';
-import type { IAccessor } from '@wendellhu/redi';
export interface IActiveSlidePageOperationParams {
id: string;
diff --git a/packages/slides-ui/src/commands/operations/set-thumb.operation.ts b/packages/slides-ui/src/commands/operations/set-thumb.operation.ts
index fb751c25f7..216429616e 100644
--- a/packages/slides-ui/src/commands/operations/set-thumb.operation.ts
+++ b/packages/slides-ui/src/commands/operations/set-thumb.operation.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { IOperation } from '@univerjs/core';
+import type { IAccessor, IOperation } from '@univerjs/core';
import { CommandType } from '@univerjs/core';
import { CanvasView } from '@univerjs/slides';
-import type { IAccessor } from '@wendellhu/redi';
export const SetSlidePageThumbOperation: IOperation = {
id: 'slide.operation.set-slide-page-thumb',
diff --git a/packages/slides-ui/src/controllers/slide-ui.controller.ts b/packages/slides-ui/src/controllers/slide-ui.controller.ts
index de1912dcaf..cdd66d7a9c 100644
--- a/packages/slides-ui/src/controllers/slide-ui.controller.ts
+++ b/packages/slides-ui/src/controllers/slide-ui.controller.ts
@@ -14,10 +14,8 @@
* limitations under the License.
*/
-import { Disposable, ICommandService, LifecycleStages, OnLifecycle } from '@univerjs/core';
+import { connectInjector, Disposable, ICommandService, Inject, Injector, LifecycleStages, OnLifecycle } from '@univerjs/core';
import { BuiltInUIPart, IUIPartsService } from '@univerjs/ui';
-import { Inject, Injector } from '@wendellhu/redi';
-import { connectInjector } from '@wendellhu/redi/react-bindings';
import { SlideSideBar } from '../views/slide-bar/SlideBar';
import { ActivateSlidePageOperation } from '../commands/operations/activate.operation';
import { SetSlidePageThumbOperation } from '../commands/operations/set-thumb.operation';
diff --git a/packages/slides-ui/src/slides-ui-plugin.ts b/packages/slides-ui/src/slides-ui-plugin.ts
index e0633b72b0..fc4e1d9759 100644
--- a/packages/slides-ui/src/slides-ui-plugin.ts
+++ b/packages/slides-ui/src/slides-ui-plugin.ts
@@ -14,10 +14,8 @@
* limitations under the License.
*/
-import type { SlideDataModel } from '@univerjs/core';
-import { IUniverInstanceService, Plugin, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import type { Dependency, SlideDataModel } from '@univerjs/core';
+import { Inject, Injector, IUniverInstanceService, Plugin, UniverInstanceType } from '@univerjs/core';
import { SlideUIController } from './controllers/slide-ui.controller';
diff --git a/packages/slides-ui/src/views/slide-bar/SlideBar.tsx b/packages/slides-ui/src/views/slide-bar/SlideBar.tsx
index e554863289..be02142095 100644
--- a/packages/slides-ui/src/views/slide-bar/SlideBar.tsx
+++ b/packages/slides-ui/src/views/slide-bar/SlideBar.tsx
@@ -16,11 +16,10 @@
import type { SlideDataModel } from '@univerjs/core';
import clsx from 'clsx';
-import { ICommandService, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
+import { ICommandService, IUniverInstanceService, UniverInstanceType, useDependency } from '@univerjs/core';
import { Scrollbar } from '@univerjs/design';
import type { RefObject } from 'react';
import React, { useCallback, useEffect, useRef, useState } from 'react';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import { useObservable } from '@univerjs/ui';
import { IRenderManagerService } from '@univerjs/engine-render';
import { CanvasView } from '@univerjs/slides';
@@ -59,7 +58,7 @@ export function SlideSideBar() {
useEffect(() => {
setDivRefs(slideList.map((_) => React.createRef()));
- }, [slideList]);
+ }, [slideList.length]);
useEffect(() => {
canvasView.activePageId$.subscribe((id) => {
diff --git a/packages/slides/package.json b/packages/slides/package.json
index 9680370a92..ff23afc5ae 100644
--- a/packages/slides/package.json
+++ b/packages/slides/package.json
@@ -64,14 +64,12 @@
"peerDependencies": {
"@univerjs/core": "workspace:*",
"@univerjs/engine-render": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": ">=7.0.0"
},
"devDependencies": {
"@univerjs/core": "workspace:*",
"@univerjs/engine-render": "workspace:*",
"@univerjs/shared": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": "^7.8.1",
"typescript": "^5.5.3",
"vite": "^5.3.4",
diff --git a/packages/slides/src/slides-plugin.ts b/packages/slides/src/slides-plugin.ts
index 6532a22a89..f05fc605e0 100644
--- a/packages/slides/src/slides-plugin.ts
+++ b/packages/slides/src/slides-plugin.ts
@@ -14,11 +14,10 @@
* limitations under the License.
*/
-import { Plugin, UniverInstanceType } from '@univerjs/core';
+import { Inject, Injector, Plugin, UniverInstanceType } from '@univerjs/core';
import type { Engine } from '@univerjs/engine-render';
import { IRenderingEngine } from '@univerjs/engine-render';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import type { Dependency } from '@univerjs/core';
import { CanvasView } from './views/render';
diff --git a/packages/slides/src/views/render/adaptor.ts b/packages/slides/src/views/render/adaptor.ts
index b1e6e53a02..7e04460ca8 100644
--- a/packages/slides/src/views/render/adaptor.ts
+++ b/packages/slides/src/views/render/adaptor.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { IPageElement, PageElementType } from '@univerjs/core';
+import type { Injector, IPageElement, PageElementType } from '@univerjs/core';
import { Registry } from '@univerjs/core';
import type { Scene } from '@univerjs/engine-render';
-import type { Injector } from '@wendellhu/redi';
export abstract class ObjectAdaptor {
zIndex = 0;
diff --git a/packages/slides/src/views/render/adaptors/docs-adaptor.ts b/packages/slides/src/views/render/adaptors/docs-adaptor.ts
index c9feb8ee06..b48669239e 100644
--- a/packages/slides/src/views/render/adaptors/docs-adaptor.ts
+++ b/packages/slides/src/views/render/adaptors/docs-adaptor.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-import type { EventState, IPageElement } from '@univerjs/core';
-import { DocumentDataModel, LocaleService, PageElementType } from '@univerjs/core';
+import type { EventState, Injector, IPageElement } from '@univerjs/core';
+import { DocumentDataModel, Inject, LocaleService, PageElementType } from '@univerjs/core';
import type { BaseObject, IDocumentSkeletonDrawing, IPageRenderConfig, IWheelEvent } from '@univerjs/engine-render';
import {
Documents,
@@ -30,8 +30,6 @@ import {
ScrollBar,
Viewport,
} from '@univerjs/engine-render';
-import type { Injector } from '@wendellhu/redi';
-import { Inject } from '@wendellhu/redi';
import { CanvasObjectProviderRegistry, ObjectAdaptor } from '../adaptor';
diff --git a/packages/slides/src/views/render/adaptors/image-adaptor.ts b/packages/slides/src/views/render/adaptors/image-adaptor.ts
index 7f1e83d6c0..527ab310c2 100644
--- a/packages/slides/src/views/render/adaptors/image-adaptor.ts
+++ b/packages/slides/src/views/render/adaptors/image-adaptor.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { IPageElement } from '@univerjs/core';
+import type { Injector, IPageElement } from '@univerjs/core';
import { PageElementType } from '@univerjs/core';
import { Image } from '@univerjs/engine-render';
-import type { Injector } from '@wendellhu/redi';
import { CanvasObjectProviderRegistry, ObjectAdaptor } from '../adaptor';
diff --git a/packages/slides/src/views/render/adaptors/rich-text-adaptor.ts b/packages/slides/src/views/render/adaptors/rich-text-adaptor.ts
index f39dc21201..2eb8d0434b 100644
--- a/packages/slides/src/views/render/adaptors/rich-text-adaptor.ts
+++ b/packages/slides/src/views/render/adaptors/rich-text-adaptor.ts
@@ -14,12 +14,10 @@
* limitations under the License.
*/
-import type { IPageElement } from '@univerjs/core';
-import { LocaleService, PageElementType } from '@univerjs/core';
+import type { Injector, IPageElement } from '@univerjs/core';
+import { Inject, LocaleService, PageElementType } from '@univerjs/core';
import type { IRichTextProps, Scene } from '@univerjs/engine-render';
import { RichText } from '@univerjs/engine-render';
-import type { Injector } from '@wendellhu/redi';
-import { Inject } from '@wendellhu/redi';
import { CanvasObjectProviderRegistry, ObjectAdaptor } from '../adaptor';
diff --git a/packages/slides/src/views/render/adaptors/shape-adaptor.ts b/packages/slides/src/views/render/adaptors/shape-adaptor.ts
index a7768e7ffa..6189ce6bd0 100644
--- a/packages/slides/src/views/render/adaptors/shape-adaptor.ts
+++ b/packages/slides/src/views/render/adaptors/shape-adaptor.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { IPageElement } from '@univerjs/core';
+import type { Injector, IPageElement } from '@univerjs/core';
import { BasicShapes, getColorStyle, PageElementType } from '@univerjs/core';
import { Rect } from '@univerjs/engine-render';
-import type { Injector } from '@wendellhu/redi';
import { CanvasObjectProviderRegistry, ObjectAdaptor } from '../adaptor';
diff --git a/packages/slides/src/views/render/adaptors/slide-adaptor.ts b/packages/slides/src/views/render/adaptors/slide-adaptor.ts
index ccd9d3837d..36d6354f01 100644
--- a/packages/slides/src/views/render/adaptors/slide-adaptor.ts
+++ b/packages/slides/src/views/render/adaptors/slide-adaptor.ts
@@ -15,10 +15,9 @@
*/
import type { IColorStyle, IPageElement, ISlidePage } from '@univerjs/core';
-import { getColorStyle, PageElementType, SlideDataModel } from '@univerjs/core';
+import { getColorStyle, Inject, Injector, PageElementType, SlideDataModel } from '@univerjs/core';
import type { Engine } from '@univerjs/engine-render';
import { Rect, Scene, Slide, Viewport } from '@univerjs/engine-render';
-import { Inject, Injector } from '@wendellhu/redi';
import { CanvasObjectProviderRegistry, ObjectAdaptor } from '../adaptor';
import { ObjectProvider } from '../object-provider';
diff --git a/packages/slides/src/views/render/adaptors/spreadsheet-adaptor.ts b/packages/slides/src/views/render/adaptors/spreadsheet-adaptor.ts
index 4168d0914d..7dc49b043b 100644
--- a/packages/slides/src/views/render/adaptors/spreadsheet-adaptor.ts
+++ b/packages/slides/src/views/render/adaptors/spreadsheet-adaptor.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-import type { EventState, ICellData, IPageElement } from '@univerjs/core';
-import { IContextService, LocaleService, ObjectMatrix, PageElementType, Styles, Worksheet } from '@univerjs/core';
+import type { EventState, ICellData, Injector, IPageElement } from '@univerjs/core';
+import { IContextService, Inject, LocaleService, ObjectMatrix, PageElementType, Styles, Worksheet } from '@univerjs/core';
import type { IScrollObserverParam, IWheelEvent } from '@univerjs/engine-render';
import {
getColor,
@@ -29,8 +29,6 @@ import {
SpreadsheetSkeleton,
Viewport,
} from '@univerjs/engine-render';
-import type { Injector } from '@wendellhu/redi';
-import { Inject } from '@wendellhu/redi';
import { CanvasObjectProviderRegistry, ObjectAdaptor } from '../adaptor';
diff --git a/packages/slides/src/views/render/canvas-view.ts b/packages/slides/src/views/render/canvas-view.ts
index 401da2bd5f..e96fa3eafe 100644
--- a/packages/slides/src/views/render/canvas-view.ts
+++ b/packages/slides/src/views/render/canvas-view.ts
@@ -15,7 +15,7 @@
*/
import type { EventState, IColorStyle, ISlidePage, Nullable, SlideDataModel } from '@univerjs/core';
-import { debounce, getColorStyle, IUniverInstanceService, LifecycleStages, OnLifecycle, RxDisposable, UniverInstanceType } from '@univerjs/core';
+import { debounce, getColorStyle, Inject, Injector, IUniverInstanceService, LifecycleStages, OnLifecycle, RxDisposable, UniverInstanceType } from '@univerjs/core';
import type { IWheelEvent } from '@univerjs/engine-render';
import {
IRenderManagerService,
@@ -25,7 +25,6 @@ import {
Slide,
Viewport,
} from '@univerjs/engine-render';
-import { Inject, Injector } from '@wendellhu/redi';
import { Subject, takeUntil } from 'rxjs';
import { ObjectProvider } from './object-provider';
diff --git a/packages/slides/src/views/render/object-provider.ts b/packages/slides/src/views/render/object-provider.ts
index eebf570b99..3abb14699e 100644
--- a/packages/slides/src/views/render/object-provider.ts
+++ b/packages/slides/src/views/render/object-provider.ts
@@ -17,9 +17,8 @@
import './adaptors';
import type { IPageElement } from '@univerjs/core';
-import { sortRules } from '@univerjs/core';
+import { Inject, Injector, sortRules } from '@univerjs/core';
import type { BaseObject, Scene } from '@univerjs/engine-render';
-import { Inject, Injector } from '@wendellhu/redi';
import type { ObjectAdaptor } from './adaptor';
import { CanvasObjectProviderRegistry } from './adaptor';
diff --git a/packages/thread-comment-ui/package.json b/packages/thread-comment-ui/package.json
index 1f5ecfef48..b5105458ef 100644
--- a/packages/thread-comment-ui/package.json
+++ b/packages/thread-comment-ui/package.json
@@ -69,7 +69,6 @@
"@univerjs/engine-render": "workspace:*",
"@univerjs/thread-comment": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": ">=2.0.0",
"dayjs": ">=1.11.0",
"react": "^16.9.0 || ^17.0.0 || ^18.0.0",
@@ -87,7 +86,6 @@
"@univerjs/shared": "workspace:*",
"@univerjs/thread-comment": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": "^2.1.1",
"dayjs": "^1.11.11",
"less": "^4.2.0",
diff --git a/packages/thread-comment-ui/src/commands/operations/comment.operations.ts b/packages/thread-comment-ui/src/commands/operations/comment.operations.ts
index 4d1a1873b5..31b9f26ad8 100644
--- a/packages/thread-comment-ui/src/commands/operations/comment.operations.ts
+++ b/packages/thread-comment-ui/src/commands/operations/comment.operations.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { ICommand } from '@univerjs/core';
+import type { IAccessor, ICommand } from '@univerjs/core';
import { CommandType } from '@univerjs/core';
import { ISidebarService } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
import { ThreadCommentPanelService } from '../../services/thread-comment-panel.service';
import { THREAD_COMMENT_PANEL } from '../../types/const';
diff --git a/packages/thread-comment-ui/src/controllers/thread-comment-ui.controller.ts b/packages/thread-comment-ui/src/controllers/thread-comment-ui.controller.ts
index e10c31ceb2..918b4d8cf7 100644
--- a/packages/thread-comment-ui/src/controllers/thread-comment-ui.controller.ts
+++ b/packages/thread-comment-ui/src/controllers/thread-comment-ui.controller.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { Disposable, LifecycleStages, LocaleService, OnLifecycle } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { Disposable, Inject, LifecycleStages, LocaleService, OnLifecycle } from '@univerjs/core';
@OnLifecycle(LifecycleStages.Starting, ThreadCommentUIController)
export class ThreadCommentUIController extends Disposable {
diff --git a/packages/thread-comment-ui/src/plugin.ts b/packages/thread-comment-ui/src/plugin.ts
index 4d13dec1f9..d4226fdae7 100644
--- a/packages/thread-comment-ui/src/plugin.ts
+++ b/packages/thread-comment-ui/src/plugin.ts
@@ -15,10 +15,8 @@
*/
import { UniverThreadCommentPlugin } from '@univerjs/thread-comment';
-import type { DependencyOverride } from '@univerjs/core';
-import { DependentOn, ICommandService, mergeOverrideWithDependencies, Plugin, UniverInstanceType } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import type { Dependency, DependencyOverride } from '@univerjs/core';
+import { DependentOn, ICommandService, Inject, Injector, mergeOverrideWithDependencies, Plugin, UniverInstanceType } from '@univerjs/core';
import { PLUGIN_NAME } from './types/const';
import { ThreadCommentPanelService } from './services/thread-comment-panel.service';
import { SetActiveCommentOperation, ToggleSheetCommentPanelOperation } from './commands/operations/comment.operations';
diff --git a/packages/thread-comment-ui/src/services/thread-comment-mention-data.service.ts b/packages/thread-comment-ui/src/services/thread-comment-mention-data.service.ts
index 1886b14c38..668312059b 100644
--- a/packages/thread-comment-ui/src/services/thread-comment-mention-data.service.ts
+++ b/packages/thread-comment-ui/src/services/thread-comment-mention-data.service.ts
@@ -17,7 +17,7 @@
import type { Nullable } from '@univerjs/core';
import type { MentionProps } from '@univerjs/design';
import type { IThreadCommentMention } from '@univerjs/thread-comment';
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier } from '@univerjs/core';
export interface IThreadCommentMentionDataSource {
getMentions(search: string, unitId: string, subUnitId: string): Promise<IThreadCommentMention[]>;
diff --git a/packages/thread-comment-ui/src/services/thread-comment-panel.service.ts b/packages/thread-comment-ui/src/services/thread-comment-panel.service.ts
index 11ac812543..0aaa5ba0d4 100644
--- a/packages/thread-comment-ui/src/services/thread-comment-panel.service.ts
+++ b/packages/thread-comment-ui/src/services/thread-comment-panel.service.ts
@@ -15,9 +15,8 @@
*/
import type { Nullable } from '@univerjs/core';
-import { Disposable, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
+import { Disposable, Inject, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
import { ISidebarService } from '@univerjs/ui';
-import { Inject } from '@wendellhu/redi';
import { BehaviorSubject, filter } from 'rxjs';
export type ActiveCommentInfo = Nullable<{ unitId: string; subUnitId: string; commentId: string; trigger?: string }>;
diff --git a/packages/thread-comment-ui/src/views/thread-comment-editor/index.tsx b/packages/thread-comment-ui/src/views/thread-comment-editor/index.tsx
index 12b50d826b..277fe6ef54 100644
--- a/packages/thread-comment-ui/src/views/thread-comment-editor/index.tsx
+++ b/packages/thread-comment-ui/src/views/thread-comment-editor/index.tsx
@@ -18,9 +18,8 @@ import type { IThreadComment } from '@univerjs/thread-comment';
import type { MentionProps } from '@univerjs/design';
import { Button, Mention, Mentions } from '@univerjs/design';
import React, { forwardRef, useImperativeHandle, useRef, useState } from 'react';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { ICommandService, LocaleService, useDependency } from '@univerjs/core';
import type { IDocumentBody } from '@univerjs/core';
-import { ICommandService, LocaleService } from '@univerjs/core';
import { ITextSelectionRenderManager } from '@univerjs/engine-render';
import { TextSelectionManagerService } from '@univerjs/docs';
import { IThreadCommentMentionDataService } from '../../services/thread-comment-mention-data.service';
diff --git a/packages/thread-comment-ui/src/views/thread-comment-panel/index.tsx b/packages/thread-comment-ui/src/views/thread-comment-panel/index.tsx
index 663408f1b7..8343020eec 100644
--- a/packages/thread-comment-ui/src/views/thread-comment-panel/index.tsx
+++ b/packages/thread-comment-ui/src/views/thread-comment-panel/index.tsx
@@ -15,11 +15,10 @@
*/
import React, { useEffect, useMemo, useRef, useState } from 'react';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { ICommandService, LocaleService, UniverInstanceType, useDependency, UserManagerService } from '@univerjs/core';
import type { IThreadComment } from '@univerjs/thread-comment';
import { ThreadCommentModel } from '@univerjs/thread-comment';
import type { Nullable } from '@univerjs/core';
-import { ICommandService, LocaleService, UniverInstanceType, UserManagerService } from '@univerjs/core';
import { useObservable } from '@univerjs/ui';
import { Button, Select } from '@univerjs/design';
import { IncreaseSingle } from '@univerjs/icons';
diff --git a/packages/thread-comment-ui/src/views/thread-comment-tree/index.tsx b/packages/thread-comment-ui/src/views/thread-comment-tree/index.tsx
index 765fbee8ec..4be7503a6f 100644
--- a/packages/thread-comment-ui/src/views/thread-comment-tree/index.tsx
+++ b/packages/thread-comment-ui/src/views/thread-comment-tree/index.tsx
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { useDependency } from '@univerjs/core';
import type { IAddCommentCommandParams, IThreadComment, IUpdateCommentCommandParams } from '@univerjs/thread-comment';
import { AddCommentCommand, DeleteCommentCommand, DeleteCommentTreeCommand, ResolveCommentCommand, ThreadCommentModel, UpdateCommentCommand } from '@univerjs/thread-comment';
import React, { useEffect, useRef, useState } from 'react';
diff --git a/packages/thread-comment/package.json b/packages/thread-comment/package.json
index 975c69c514..d68efaf86b 100644
--- a/packages/thread-comment/package.json
+++ b/packages/thread-comment/package.json
@@ -62,7 +62,6 @@
},
"peerDependencies": {
"@univerjs/core": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": ">=7.0.0"
},
"dependencies": {
@@ -71,7 +70,6 @@
"devDependencies": {
"@univerjs/core": "workspace:*",
"@univerjs/shared": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"rxjs": "^7.8.1",
"typescript": "^5.5.3",
"vite": "^5.3.4",
diff --git a/packages/thread-comment/src/controllers/tc-resource.controller.ts b/packages/thread-comment/src/controllers/tc-resource.controller.ts
index 5c60faf73b..470d4a872c 100644
--- a/packages/thread-comment/src/controllers/tc-resource.controller.ts
+++ b/packages/thread-comment/src/controllers/tc-resource.controller.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { Disposable, IResourceManagerService, LifecycleStages, OnLifecycle } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { Disposable, Inject, IResourceManagerService, LifecycleStages, OnLifecycle } from '@univerjs/core';
import { UniverType } from '@univerjs/protocol';
import { ThreadCommentModel } from '../models/thread-comment.model';
import { TC_PLUGIN_NAME } from '../types/const';
diff --git a/packages/thread-comment/src/models/thread-comment.model.ts b/packages/thread-comment/src/models/thread-comment.model.ts
index 4ea34aba6e..12f180baa3 100644
--- a/packages/thread-comment/src/models/thread-comment.model.ts
+++ b/packages/thread-comment/src/models/thread-comment.model.ts
@@ -15,8 +15,7 @@
*/
import { BehaviorSubject, map, Subject } from 'rxjs';
-import { CustomRangeType, Disposable, ICommandService } from '@univerjs/core';
-import { Inject } from '@wendellhu/redi';
+import { CustomRangeType, Disposable, ICommandService, Inject } from '@univerjs/core';
import type { IBaseComment, IThreadComment } from '../types/interfaces/i-thread-comment';
import type { IUpdateCommentPayload, IUpdateCommentRefPayload } from '../commands/mutations/comment.mutation';
import { IThreadCommentDataSourceService } from '../services/tc-datasource.service';
diff --git a/packages/thread-comment/src/plugin.ts b/packages/thread-comment/src/plugin.ts
index 25faf140e0..64abe42cc7 100644
--- a/packages/thread-comment/src/plugin.ts
+++ b/packages/thread-comment/src/plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { DependencyOverride } from '@univerjs/core';
-import { ICommandService, mergeOverrideWithDependencies, Plugin, UniverInstanceType } from '@univerjs/core';
-import { type Dependency, Inject, Injector } from '@wendellhu/redi';
+import type { Dependency, DependencyOverride } from '@univerjs/core';
+import { ICommandService, Inject, Injector, mergeOverrideWithDependencies, Plugin, UniverInstanceType } from '@univerjs/core';
import { ThreadCommentModel } from './models/thread-comment.model';
import { ThreadCommentResourceController } from './controllers/tc-resource.controller';
import { TC_PLUGIN_NAME } from './types/const';
diff --git a/packages/thread-comment/src/services/tc-datasource.service.ts b/packages/thread-comment/src/services/tc-datasource.service.ts
index 5187b052c9..d81ee2505f 100644
--- a/packages/thread-comment/src/services/tc-datasource.service.ts
+++ b/packages/thread-comment/src/services/tc-datasource.service.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier, Disposable } from '@univerjs/core';
import type { Nullable } from '@univerjs/core';
-import { Disposable } from '@univerjs/core';
import type { IBaseComment, IThreadComment } from '../types/interfaces/i-thread-comment';
export type ThreadCommentJSON = {
diff --git a/packages/ui/package.json b/packages/ui/package.json
index 86caad612d..21fe7561ed 100644
--- a/packages/ui/package.json
+++ b/packages/ui/package.json
@@ -70,7 +70,6 @@
"@univerjs/engine-formula": "workspace:*",
"@univerjs/engine-render": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": ">=2.0.0",
"react": "^16.9.0 || ^17.0.0 || ^18.0.0",
"react-dom": "^16.9.0 || ^17.0.0 || ^18.0.0",
@@ -96,7 +95,6 @@
"@univerjs/engine-formula": "workspace:*",
"@univerjs/engine-render": "workspace:*",
"@univerjs/shared": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": "^2.1.1",
"less": "^4.2.0",
"react": "18.3.1",
diff --git a/packages/ui/src/commands/operations/toggle-shortcut-panel.operation.ts b/packages/ui/src/commands/operations/toggle-shortcut-panel.operation.ts
index d6d2f4dc94..6fcc304b85 100644
--- a/packages/ui/src/commands/operations/toggle-shortcut-panel.operation.ts
+++ b/packages/ui/src/commands/operations/toggle-shortcut-panel.operation.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { IOperation } from '@univerjs/core';
+import type { IAccessor, IOperation } from '@univerjs/core';
import { CommandType } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { ShortcutPanelService } from '../../services/shortcut/shortcut-panel.service';
import { ISidebarService } from '../../services/sidebar/sidebar.service';
diff --git a/packages/ui/src/common/component-manager.ts b/packages/ui/src/common/component-manager.ts
index 9ea8008af5..8b9247157a 100644
--- a/packages/ui/src/common/component-manager.ts
+++ b/packages/ui/src/common/component-manager.ts
@@ -113,7 +113,7 @@ import {
VerticalIntegrationSingle,
VerticalTextSingle,
} from '@univerjs/icons';
-import type { IDisposable } from '@wendellhu/redi';
+import type { IDisposable } from '@univerjs/core';
import type { defineComponent } from 'vue';
import type React from 'react';
diff --git a/packages/ui/src/common/lifecycle.ts b/packages/ui/src/common/lifecycle.ts
index 6dd7134cd5..04aa1395f0 100644
--- a/packages/ui/src/common/lifecycle.ts
+++ b/packages/ui/src/common/lifecycle.ts
@@ -15,7 +15,7 @@
*/
import { toDisposable } from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
+import type { IDisposable } from '@univerjs/core';
export function fromGlobalEvent<K extends keyof WindowEventMap>(
type: K,
diff --git a/packages/ui/src/common/menu-hidden-observable.ts b/packages/ui/src/common/menu-hidden-observable.ts
index d84fb022a0..d82f0ceceb 100644
--- a/packages/ui/src/common/menu-hidden-observable.ts
+++ b/packages/ui/src/common/menu-hidden-observable.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { UniverInstanceType } from '@univerjs/core';
+import type { IAccessor, UniverInstanceType } from '@univerjs/core';
import { DocumentFlavor, IUniverInstanceService } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
import { Observable } from 'rxjs';
export function getMenuHiddenObservable(
diff --git a/packages/ui/src/components/custom-label/CustomLabel.tsx b/packages/ui/src/components/custom-label/CustomLabel.tsx
index 74c9102a32..b693ae465d 100644
--- a/packages/ui/src/components/custom-label/CustomLabel.tsx
+++ b/packages/ui/src/components/custom-label/CustomLabel.tsx
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { ColorKit, LocaleService } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { ColorKit, LocaleService, useDependency } from '@univerjs/core';
import React from 'react';
import type { Observable } from 'rxjs';
import { isObservable } from 'rxjs';
diff --git a/packages/ui/src/components/editor/TextEditor.tsx b/packages/ui/src/components/editor/TextEditor.tsx
index 4eb3a59e5f..99931cb372 100644
--- a/packages/ui/src/components/editor/TextEditor.tsx
+++ b/packages/ui/src/components/editor/TextEditor.tsx
@@ -15,8 +15,7 @@
*/
import type { IDocumentData, Nullable } from '@univerjs/core';
-import { debounce, isInternalEditorID, LocaleService } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { debounce, isInternalEditorID, LocaleService, useDependency } from '@univerjs/core';
import React, { useEffect, useRef, useState } from 'react';
import type { Editor, IEditorCanvasStyle } from '../../services/editor/editor.service';
import { IEditorService } from '../../services/editor/editor.service';
diff --git a/packages/ui/src/components/font-family/FontFamily.tsx b/packages/ui/src/components/font-family/FontFamily.tsx
index f7857455e0..dc9e2d6dda 100644
--- a/packages/ui/src/components/font-family/FontFamily.tsx
+++ b/packages/ui/src/components/font-family/FontFamily.tsx
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { LocaleService } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { LocaleService, useDependency } from '@univerjs/core';
import React, { useMemo } from 'react';
import styles from './index.module.less';
diff --git a/packages/ui/src/components/font-family/FontFamilyItem.tsx b/packages/ui/src/components/font-family/FontFamilyItem.tsx
index a90ccdcc4d..f20f6f2e49 100644
--- a/packages/ui/src/components/font-family/FontFamilyItem.tsx
+++ b/packages/ui/src/components/font-family/FontFamilyItem.tsx
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { LocaleService } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { LocaleService, useDependency } from '@univerjs/core';
import React from 'react';
import styles from './index.module.less';
diff --git a/packages/ui/src/components/hooks/locale.ts b/packages/ui/src/components/hooks/locale.ts
index 37f140b6b3..d03c456f85 100644
--- a/packages/ui/src/components/hooks/locale.ts
+++ b/packages/ui/src/components/hooks/locale.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { LocaleService } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { LocaleService, useDependency } from '@univerjs/core';
export function useLocaleService() {
return useDependency(LocaleService);
diff --git a/packages/ui/src/components/menu/common/hook.ts b/packages/ui/src/components/menu/common/hook.ts
index 9edee02f9e..489b75e5af 100644
--- a/packages/ui/src/components/menu/common/hook.ts
+++ b/packages/ui/src/components/menu/common/hook.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import { useObservable } from '@wendellhu/redi/react-bindings';
+import { useObservable } from '@univerjs/core';
import type { IDisplayMenuItem, IMenuItem } from '../../../services/menu/menu';
export function useMenuItemState(
diff --git a/packages/ui/src/components/menu/desktop/Menu.tsx b/packages/ui/src/components/menu/desktop/Menu.tsx
index 1efe0676cd..e23c55620f 100644
--- a/packages/ui/src/components/menu/desktop/Menu.tsx
+++ b/packages/ui/src/components/menu/desktop/Menu.tsx
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import { isRealNum } from '@univerjs/core';
+import { isRealNum, useDependency } from '@univerjs/core';
import {
Menu as DesignMenu,
@@ -23,7 +23,6 @@ import {
SubMenu as DesignSubMenu,
} from '@univerjs/design';
import { CheckMarkSingle, MoreSingle } from '@univerjs/icons';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import clsx from 'clsx';
import React, { useState } from 'react';
import { isObservable } from 'rxjs';
diff --git a/packages/ui/src/components/menu/mobile/MobileMenu.stories.tsx b/packages/ui/src/components/menu/mobile/MobileMenu.stories.tsx
index 42eddcdf35..fb0e0df2a5 100644
--- a/packages/ui/src/components/menu/mobile/MobileMenu.stories.tsx
+++ b/packages/ui/src/components/menu/mobile/MobileMenu.stories.tsx
@@ -16,10 +16,8 @@
import type { Meta } from '@storybook/react';
import React, { useState } from 'react';
-import { LocaleType, Plugin, Univer, UniverInstanceType } from '@univerjs/core';
-import { RediContext } from '@wendellhu/redi/react-bindings';
-import type { IAccessor } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { Inject, Injector, LocaleType, Plugin, RediContext, Univer, UniverInstanceType } from '@univerjs/core';
+import type { IAccessor } from '@univerjs/core';
import { of } from 'rxjs';
import { IMenuService, MenuService } from '../../../services/menu/menu.service';
import { IShortcutService, ShortcutService } from '../../../services/shortcut/shortcut.service';
diff --git a/packages/ui/src/components/menu/mobile/MobileMenu.tsx b/packages/ui/src/components/menu/mobile/MobileMenu.tsx
index 064db9e4aa..55b6bffae4 100644
--- a/packages/ui/src/components/menu/mobile/MobileMenu.tsx
+++ b/packages/ui/src/components/menu/mobile/MobileMenu.tsx
@@ -15,8 +15,7 @@
*/
import React from 'react';
-import { useDependency, useObservable } from '@wendellhu/redi/react-bindings';
-import { makeArray } from '@univerjs/core';
+import { makeArray, useDependency, useObservable } from '@univerjs/core';
import { clsx } from 'clsx';
import type { IBaseMenuProps } from '../desktop/Menu';
import { IMenuService } from '../../../services/menu/menu.service';
diff --git a/packages/ui/src/components/progress-bar/ProgressBar.tsx b/packages/ui/src/components/progress-bar/ProgressBar.tsx
index 7e5ffcf91f..76c5d38474 100644
--- a/packages/ui/src/components/progress-bar/ProgressBar.tsx
+++ b/packages/ui/src/components/progress-bar/ProgressBar.tsx
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { useDependency } from '@univerjs/core';
import React, { useEffect, useRef, useState } from 'react';
import { CloseSingle } from '@univerjs/icons';
import type { IProgressStep } from '../../services/progress/progress.service';
diff --git a/packages/ui/src/components/range-selector/RangeSelector.tsx b/packages/ui/src/components/range-selector/RangeSelector.tsx
index 9d17932ad7..1c61b712b7 100644
--- a/packages/ui/src/components/range-selector/RangeSelector.tsx
+++ b/packages/ui/src/components/range-selector/RangeSelector.tsx
@@ -15,10 +15,9 @@
*/
import type { IUnitRangeWithName, Nullable, Workbook } from '@univerjs/core';
-import { IUniverInstanceService, LocaleService, UniverInstanceType } from '@univerjs/core';
+import { IUniverInstanceService, LocaleService, UniverInstanceType, useDependency } from '@univerjs/core';
import { Button, Dialog, Input, Tooltip } from '@univerjs/design';
import { CloseSingle, DeleteSingle, IncreaseSingle, SelectRangeSingle } from '@univerjs/icons';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import React, { useEffect, useRef, useState } from 'react';
import { getRangeWithRefsString, isReferenceStringWithEffectiveColumn, serializeRange, serializeRangeWithSheet, serializeRangeWithSpreadsheet } from '@univerjs/engine-formula';
diff --git a/packages/ui/src/controllers/error/error.controller.ts b/packages/ui/src/controllers/error/error.controller.ts
index c0ee0e35a7..12b628e84e 100644
--- a/packages/ui/src/controllers/error/error.controller.ts
+++ b/packages/ui/src/controllers/error/error.controller.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { Disposable, ErrorService, LifecycleStages, OnLifecycle, toDisposable } from '@univerjs/core';
+import { Disposable, ErrorService, Inject, LifecycleStages, OnLifecycle, toDisposable } from '@univerjs/core';
import { MessageType } from '@univerjs/design';
-import { Inject } from '@wendellhu/redi';
import { IMessageService } from '../../services/message/message.service';
diff --git a/packages/ui/src/controllers/menus/menus.ts b/packages/ui/src/controllers/menus/menus.ts
index b17fe1ad77..b9412962fd 100644
--- a/packages/ui/src/controllers/menus/menus.ts
+++ b/packages/ui/src/controllers/menus/menus.ts
@@ -15,7 +15,7 @@
*/
import { IUndoRedoService, RedoCommand, UndoCommand } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor } from '@univerjs/core';
import { map } from 'rxjs/operators';
import type { IMenuButtonItem } from '../../services/menu/menu';
diff --git a/packages/ui/src/controllers/shared-shortcut.controller.ts b/packages/ui/src/controllers/shared-shortcut.controller.ts
index 52a4f6d524..660fad27c6 100644
--- a/packages/ui/src/controllers/shared-shortcut.controller.ts
+++ b/packages/ui/src/controllers/shared-shortcut.controller.ts
@@ -15,8 +15,7 @@
*/
import type { IContextService } from '@univerjs/core';
-import { Disposable, FOCUSING_UNIVER_EDITOR, ICommandService, LifecycleStages, OnLifecycle, RedoCommand, UndoCommand } from '@univerjs/core';
-import { Inject, Injector } from '@wendellhu/redi';
+import { Disposable, FOCUSING_UNIVER_EDITOR, ICommandService, Inject, Injector, LifecycleStages, OnLifecycle, RedoCommand, UndoCommand } from '@univerjs/core';
import { CopyCommand, CutCommand, PasteCommand } from '../services/clipboard/clipboard.command';
import { IMenuService } from '../services/menu/menu.service';
diff --git a/packages/ui/src/controllers/shortcut-display/menu.ts b/packages/ui/src/controllers/shortcut-display/menu.ts
index 162f5c0158..6c731bf1a1 100644
--- a/packages/ui/src/controllers/shortcut-display/menu.ts
+++ b/packages/ui/src/controllers/shortcut-display/menu.ts
@@ -15,7 +15,7 @@
*/
import { UniverInstanceType } from '@univerjs/core';
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor } from '@univerjs/core';
import { ToggleShortcutPanelOperation } from '../../commands/operations/toggle-shortcut-panel.operation';
import { getMenuHiddenObservable } from '../../common/menu-hidden-observable';
diff --git a/packages/ui/src/controllers/shortcut-display/shortcut-panel.controller.ts b/packages/ui/src/controllers/shortcut-display/shortcut-panel.controller.ts
index 315cd28cae..39f940a193 100644
--- a/packages/ui/src/controllers/shortcut-display/shortcut-panel.controller.ts
+++ b/packages/ui/src/controllers/shortcut-display/shortcut-panel.controller.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { Disposable, ICommandService, LifecycleStages, OnLifecycle } from '@univerjs/core';
-import { Inject, Injector } from '@wendellhu/redi';
+import { Disposable, ICommandService, Inject, Injector, LifecycleStages, OnLifecycle } from '@univerjs/core';
import {
ShortcutPanelComponentName,
diff --git a/packages/ui/src/controllers/ui/ui-desktop.controller.tsx b/packages/ui/src/controllers/ui/ui-desktop.controller.tsx
index d2f43bccf8..ef8139366b 100644
--- a/packages/ui/src/controllers/ui/ui-desktop.controller.tsx
+++ b/packages/ui/src/controllers/ui/ui-desktop.controller.tsx
@@ -14,12 +14,10 @@
* limitations under the License.
*/
-import { Disposable, IConfigService, isInternalEditorID, LifecycleService, LifecycleStages, OnLifecycle, toDisposable } from '@univerjs/core';
+import { connectInjector, Disposable, IConfigService, Inject, Injector, isInternalEditorID, LifecycleService, LifecycleStages, OnLifecycle, Optional, toDisposable } from '@univerjs/core';
import type { RenderUnit } from '@univerjs/engine-render';
import { IRenderManagerService } from '@univerjs/engine-render';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject, Injector, Optional } from '@wendellhu/redi';
-import { connectInjector } from '@wendellhu/redi/react-bindings';
+import type { IDisposable } from '@univerjs/core';
import { render as createRoot, unmount } from 'rc-util/lib/React/render';
import React from 'react';
diff --git a/packages/ui/src/controllers/ui/ui-mobile.controller.tsx b/packages/ui/src/controllers/ui/ui-mobile.controller.tsx
index 7715c8daa0..9fcd0b5c42 100644
--- a/packages/ui/src/controllers/ui/ui-mobile.controller.tsx
+++ b/packages/ui/src/controllers/ui/ui-mobile.controller.tsx
@@ -14,11 +14,9 @@
* limitations under the License.
*/
-import { Disposable, IUniverInstanceService, LifecycleService, LifecycleStages, toDisposable, UniverInstanceType } from '@univerjs/core';
+import { connectInjector, Disposable, Inject, Injector, IUniverInstanceService, LifecycleService, LifecycleStages, Optional, toDisposable, UniverInstanceType } from '@univerjs/core';
import { IRenderManagerService } from '@univerjs/engine-render';
-import type { IDisposable } from '@wendellhu/redi';
-import { Inject, Injector, Optional } from '@wendellhu/redi';
-import { connectInjector } from '@wendellhu/redi/react-bindings';
+import type { IDisposable } from '@univerjs/core';
import { render as createRoot, unmount } from 'rc-util/lib/React/render';
import React from 'react';
diff --git a/packages/ui/src/controllers/ui/ui.controller.ts b/packages/ui/src/controllers/ui/ui.controller.ts
index 2f9490dc7c..1bb53fd3b7 100644
--- a/packages/ui/src/controllers/ui/ui.controller.ts
+++ b/packages/ui/src/controllers/ui/ui.controller.ts
@@ -15,7 +15,7 @@
*/
import { type DependencyOverride, LifecycleStages, runOnLifecycle } from '@univerjs/core';
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier } from '@univerjs/core';
import type { MenuConfig } from '../../services/menu/menu';
export interface IWorkbenchOptions {
diff --git a/packages/ui/src/mobile-ui-plugin.ts b/packages/ui/src/mobile-ui-plugin.ts
index 59de254207..ba620dda56 100644
--- a/packages/ui/src/mobile-ui-plugin.ts
+++ b/packages/ui/src/mobile-ui-plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { DependentOn, ILocalStorageService, mergeOverrideWithDependencies, Plugin } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { DependentOn, ILocalStorageService, Inject, Injector, mergeOverrideWithDependencies, Plugin } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
import { UniverRenderEnginePlugin } from '@univerjs/engine-render';
import { CanvasPopupService, ICanvasPopupService } from './services/popup/canvas-popup.service';
import { DesktopGlobalZoneService } from './services/global-zone/desktop-global-zone.service';
diff --git a/packages/ui/src/services/before-close/before-close.service.ts b/packages/ui/src/services/before-close/before-close.service.ts
index 1c6162c487..e29f6e3e90 100644
--- a/packages/ui/src/services/before-close/before-close.service.ts
+++ b/packages/ui/src/services/before-close/before-close.service.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier } from '@wendellhu/redi';
+import type { IDisposable } from '@univerjs/core';
+import { createIdentifier } from '@univerjs/core';
import { INotificationService } from '../notification/notification.service';
diff --git a/packages/ui/src/services/clipboard/clipboard-interface.service.ts b/packages/ui/src/services/clipboard/clipboard-interface.service.ts
index 13c736184e..3c6f448a68 100644
--- a/packages/ui/src/services/clipboard/clipboard-interface.service.ts
+++ b/packages/ui/src/services/clipboard/clipboard-interface.service.ts
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { Disposable, ILogService, LocaleService } from '@univerjs/core';
-import { createIdentifier, Inject, Optional } from '@wendellhu/redi';
+import { createIdentifier, Disposable, ILogService, Inject, LocaleService, Optional } from '@univerjs/core';
import { INotificationService } from '../notification/notification.service';
import { supportClipboardAPI } from './clipboard-utils';
diff --git a/packages/ui/src/services/confirm/confirm.service.ts b/packages/ui/src/services/confirm/confirm.service.ts
index 6933f23454..80715f78a6 100644
--- a/packages/ui/src/services/confirm/confirm.service.ts
+++ b/packages/ui/src/services/confirm/confirm.service.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier } from '@wendellhu/redi';
+import type { IDisposable } from '@univerjs/core';
+import { createIdentifier } from '@univerjs/core';
import type { Subject } from 'rxjs';
import type { IConfirmPartMethodOptions } from '../../views/components/confirm-part/interface';
diff --git a/packages/ui/src/services/confirm/desktop-confirm.service.ts b/packages/ui/src/services/confirm/desktop-confirm.service.ts
index de5b6f4814..35d41c36c8 100644
--- a/packages/ui/src/services/confirm/desktop-confirm.service.ts
+++ b/packages/ui/src/services/confirm/desktop-confirm.service.ts
@@ -14,11 +14,10 @@
* limitations under the License.
*/
-import { Disposable, toDisposable } from '@univerjs/core';
-import { type IDisposable, Inject, Injector } from '@wendellhu/redi';
+import { connectInjector, Disposable, toDisposable } from '@univerjs/core';
+import { type IDisposable, Inject, Injector } from '@univerjs/core';
import { Subject } from 'rxjs';
-import { connectInjector } from '@wendellhu/redi/react-bindings';
import type { IConfirmPartMethodOptions } from '../../views/components/confirm-part/interface';
import { BuiltInUIPart, IUIPartsService } from '../parts/parts.service';
import { ConfirmPart } from '../../views/components/confirm-part/ConfirmPart';
diff --git a/packages/ui/src/services/contextmenu/contextmenu.service.ts b/packages/ui/src/services/contextmenu/contextmenu.service.ts
index 50791df3fc..68d9ecb5f2 100644
--- a/packages/ui/src/services/contextmenu/contextmenu.service.ts
+++ b/packages/ui/src/services/contextmenu/contextmenu.service.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { Disposable, toDisposable } from '@univerjs/core';
+import { createIdentifier, Disposable, toDisposable } from '@univerjs/core';
import type { IMouseEvent, IPointerEvent } from '@univerjs/engine-render';
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier } from '@wendellhu/redi';
+import type { IDisposable } from '@univerjs/core';
export interface IContextMenuHandler {
/** A callback to open context menu with given position and menu type. */
diff --git a/packages/ui/src/services/dialog/desktop-dialog.service.ts b/packages/ui/src/services/dialog/desktop-dialog.service.ts
index 930a82c93f..a36d3e37c8 100644
--- a/packages/ui/src/services/dialog/desktop-dialog.service.ts
+++ b/packages/ui/src/services/dialog/desktop-dialog.service.ts
@@ -14,11 +14,10 @@
* limitations under the License.
*/
-import { Disposable, toDisposable } from '@univerjs/core';
-import { type IDisposable, Inject, Injector } from '@wendellhu/redi';
+import { connectInjector, Disposable, toDisposable } from '@univerjs/core';
+import { type IDisposable, Inject, Injector } from '@univerjs/core';
import { Subject } from 'rxjs';
-import { connectInjector } from '@wendellhu/redi/react-bindings';
import type { IDialogPartMethodOptions } from '../../views/components/dialog-part/interface';
import { BuiltInUIPart, IUIPartsService } from '../parts/parts.service';
import { DialogPart } from '../../views/components/dialog-part/DialogPart';
diff --git a/packages/ui/src/services/dialog/dialog.service.ts b/packages/ui/src/services/dialog/dialog.service.ts
index 8e4d06ec08..6ce4641d15 100644
--- a/packages/ui/src/services/dialog/dialog.service.ts
+++ b/packages/ui/src/services/dialog/dialog.service.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier } from '@wendellhu/redi';
+import type { IDisposable } from '@univerjs/core';
+import { createIdentifier } from '@univerjs/core';
import type { Observable } from 'rxjs';
import type { IDialogPartMethodOptions } from '../../views/components/dialog-part/interface';
diff --git a/packages/ui/src/services/editor/editor.service.ts b/packages/ui/src/services/editor/editor.service.ts
index d666829580..debf58b6f2 100644
--- a/packages/ui/src/services/editor/editor.service.ts
+++ b/packages/ui/src/services/editor/editor.service.ts
@@ -14,10 +14,8 @@
* limitations under the License.
*/
-import type { DocumentDataModel, IDocumentBody, IDocumentData, IDocumentStyle, IPosition, Nullable, Workbook } from '@univerjs/core';
-import { DEFAULT_EMPTY_DOCUMENT_VALUE, DEFAULT_STYLES, Disposable, EDITOR_ACTIVATED, FOCUSING_EDITOR_INPUT_FORMULA, FOCUSING_EDITOR_STANDALONE, FOCUSING_UNIVER_EDITOR_STANDALONE_SINGLE_MODE, HorizontalAlign, IContextService, IUniverInstanceService, toDisposable, UniverInstanceType, VerticalAlign } from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier, Inject } from '@wendellhu/redi';
+import type { DocumentDataModel, IDisposable, IDocumentBody, IDocumentData, IDocumentStyle, IPosition, Nullable, Workbook } from '@univerjs/core';
+import { createIdentifier, DEFAULT_EMPTY_DOCUMENT_VALUE, DEFAULT_STYLES, Disposable, EDITOR_ACTIVATED, FOCUSING_EDITOR_INPUT_FORMULA, FOCUSING_EDITOR_STANDALONE, FOCUSING_UNIVER_EDITOR_STANDALONE_SINGLE_MODE, HorizontalAlign, IContextService, Inject, IUniverInstanceService, toDisposable, UniverInstanceType, VerticalAlign } from '@univerjs/core';
import type { Observable } from 'rxjs';
import { Subject } from 'rxjs';
import type { IRender, ISuccinctTextRangeParam, Scene } from '@univerjs/engine-render';
diff --git a/packages/ui/src/services/global-zone/desktop-global-zone.service.ts b/packages/ui/src/services/global-zone/desktop-global-zone.service.ts
index 28bb812762..8e54241633 100644
--- a/packages/ui/src/services/global-zone/desktop-global-zone.service.ts
+++ b/packages/ui/src/services/global-zone/desktop-global-zone.service.ts
@@ -15,7 +15,7 @@
*/
import { toDisposable } from '@univerjs/core';
-import { type IDisposable, Inject } from '@wendellhu/redi';
+import { type IDisposable, Inject } from '@univerjs/core';
import type { ForwardRefExoticComponent } from 'react';
import { Subject } from 'rxjs';
diff --git a/packages/ui/src/services/global-zone/global-zone.service.ts b/packages/ui/src/services/global-zone/global-zone.service.ts
index 9e630825e6..3ae292ae42 100644
--- a/packages/ui/src/services/global-zone/global-zone.service.ts
+++ b/packages/ui/src/services/global-zone/global-zone.service.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier } from '@wendellhu/redi';
+import type { IDisposable } from '@univerjs/core';
+import { createIdentifier } from '@univerjs/core';
import type { Subject } from 'rxjs';
export const IGlobalZoneService = createIdentifier<IGlobalZoneService>('univer.global-zone-service');
diff --git a/packages/ui/src/services/layout/layout.service.ts b/packages/ui/src/services/layout/layout.service.ts
index 911b999b2d..8bd6c6c03b 100644
--- a/packages/ui/src/services/layout/layout.service.ts
+++ b/packages/ui/src/services/layout/layout.service.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import type { ContextService, Nullable } from '@univerjs/core';
-import { Disposable, DocumentDataModel, FOCUSING_UNIVER_EDITOR, IContextService, IUniverInstanceService, LifecycleStages, OnLifecycle, remove, SlideDataModel, toDisposable, UniverInstanceType, Workbook } from '@univerjs/core';
-import { createIdentifier, type IDisposable } from '@wendellhu/redi';
+import type { ContextService, IDisposable, Nullable } from '@univerjs/core';
+import { createIdentifier, Disposable, DocumentDataModel, FOCUSING_UNIVER_EDITOR, IContextService, IUniverInstanceService, LifecycleStages, OnLifecycle, remove, SlideDataModel, toDisposable, UniverInstanceType, Workbook } from '@univerjs/core';
import { fromEvent } from 'rxjs';
import { IEditorService } from '../editor/editor.service';
diff --git a/packages/ui/src/services/menu/menu.service.ts b/packages/ui/src/services/menu/menu.service.ts
index 595a4739a7..dfabb41bba 100644
--- a/packages/ui/src/services/menu/menu.service.ts
+++ b/packages/ui/src/services/menu/menu.service.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { Disposable, toDisposable } from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier, Disposable, toDisposable } from '@univerjs/core';
+import type { IDisposable } from '@univerjs/core';
import type { Observable } from 'rxjs';
import { BehaviorSubject } from 'rxjs';
diff --git a/packages/ui/src/services/menu/menu.ts b/packages/ui/src/services/menu/menu.ts
index 66ed4d68c1..88d9bd422c 100644
--- a/packages/ui/src/services/menu/menu.ts
+++ b/packages/ui/src/services/menu/menu.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor } from '@univerjs/core';
import type { Observable } from 'rxjs';
export type OneOrMany<T> = T | T[];
diff --git a/packages/ui/src/services/message/__testing__/mock-message.service.ts b/packages/ui/src/services/message/__testing__/mock-message.service.ts
index b26fb29a17..9a2408e30d 100644
--- a/packages/ui/src/services/message/__testing__/mock-message.service.ts
+++ b/packages/ui/src/services/message/__testing__/mock-message.service.ts
@@ -15,7 +15,7 @@
*/
import type { IMessageOptions, IMessageProps } from '@univerjs/design';
-import type { IDisposable } from '@wendellhu/redi';
+import type { IDisposable } from '@univerjs/core';
import { toDisposable } from '@univerjs/core';
import type { IMessageService } from '../message.service';
diff --git a/packages/ui/src/services/message/desktop-message.service.ts b/packages/ui/src/services/message/desktop-message.service.ts
index d4a8d48da2..f31a10cdbd 100644
--- a/packages/ui/src/services/message/desktop-message.service.ts
+++ b/packages/ui/src/services/message/desktop-message.service.ts
@@ -16,7 +16,7 @@
import type { IMessageOptions, IMessageProps } from '@univerjs/design';
import { Message } from '@univerjs/design';
-import type { IDisposable } from '@wendellhu/redi';
+import type { IDisposable } from '@univerjs/core';
import canUseDom from 'rc-util/lib/Dom/canUseDom';
import type { IMessageService } from './message.service';
diff --git a/packages/ui/src/services/message/message.service.ts b/packages/ui/src/services/message/message.service.ts
index ee00eff105..931580373f 100644
--- a/packages/ui/src/services/message/message.service.ts
+++ b/packages/ui/src/services/message/message.service.ts
@@ -15,8 +15,8 @@
*/
import type { IMessageOptions } from '@univerjs/design';
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier } from '@wendellhu/redi';
+import type { IDisposable } from '@univerjs/core';
+import { createIdentifier } from '@univerjs/core';
export const IMessageService = createIdentifier<IMessageService>('ui.message.service');
diff --git a/packages/ui/src/services/notification/desktop-notification.service.ts b/packages/ui/src/services/notification/desktop-notification.service.ts
index 4a9741909b..6038f9607c 100644
--- a/packages/ui/src/services/notification/desktop-notification.service.ts
+++ b/packages/ui/src/services/notification/desktop-notification.service.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { Disposable, toDisposable } from '@univerjs/core';
-import { type IDisposable, Inject, Injector } from '@wendellhu/redi';
+import { connectInjector, Disposable, toDisposable } from '@univerjs/core';
+import { type IDisposable, Inject, Injector } from '@univerjs/core';
-import { connectInjector } from '@wendellhu/redi/react-bindings';
import type { INotificationOptions } from '../../components/notification/Notification';
import { notification, Notification } from '../../components/notification/Notification';
import { BuiltInUIPart, IUIPartsService } from '../parts/parts.service';
diff --git a/packages/ui/src/services/notification/notification.service.ts b/packages/ui/src/services/notification/notification.service.ts
index d7ccb68e29..e46316453f 100644
--- a/packages/ui/src/services/notification/notification.service.ts
+++ b/packages/ui/src/services/notification/notification.service.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier } from '@wendellhu/redi';
+import type { IDisposable } from '@univerjs/core';
+import { createIdentifier } from '@univerjs/core';
import type { INotificationOptions } from '../../components/notification/Notification';
diff --git a/packages/ui/src/services/parts/parts.service.ts b/packages/ui/src/services/parts/parts.service.ts
index e1d1f2473a..100ab149fc 100644
--- a/packages/ui/src/services/parts/parts.service.ts
+++ b/packages/ui/src/services/parts/parts.service.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier } from '@wendellhu/redi';
+import type { IDisposable } from '@univerjs/core';
+import { createIdentifier, Disposable, toDisposable } from '@univerjs/core';
import { type Observable, Subject } from 'rxjs';
-import { Disposable, toDisposable } from '@univerjs/core';
import type { ComponentType } from '../../common/component-manager';
diff --git a/packages/ui/src/services/platform/platform.service.ts b/packages/ui/src/services/platform/platform.service.ts
index 8b254c7bad..9ab5504e86 100644
--- a/packages/ui/src/services/platform/platform.service.ts
+++ b/packages/ui/src/services/platform/platform.service.ts
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier } from '@univerjs/core';
/**
* A service to provide context info of the host service.
diff --git a/packages/ui/src/services/popup/canvas-popup.service.ts b/packages/ui/src/services/popup/canvas-popup.service.ts
index e038068498..bc80063a92 100644
--- a/packages/ui/src/services/popup/canvas-popup.service.ts
+++ b/packages/ui/src/services/popup/canvas-popup.service.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { Disposable, Tools } from '@univerjs/core';
+import { createIdentifier, Disposable, Tools } from '@univerjs/core';
import type { IRectPopupProps } from '@univerjs/design';
import type { IBoundRectNoAngle } from '@univerjs/engine-render';
-import { createIdentifier } from '@wendellhu/redi';
import type { Observable } from 'rxjs';
import { BehaviorSubject } from 'rxjs';
diff --git a/packages/ui/src/services/progress/progress.service.ts b/packages/ui/src/services/progress/progress.service.ts
index ba56d56275..1ddbfbe373 100644
--- a/packages/ui/src/services/progress/progress.service.ts
+++ b/packages/ui/src/services/progress/progress.service.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { Disposable } from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier } from '@wendellhu/redi';
+import { createIdentifier, Disposable } from '@univerjs/core';
+import type { IDisposable } from '@univerjs/core';
import type { Observable } from 'rxjs';
import { Subject } from 'rxjs';
diff --git a/packages/ui/src/services/range-selector/range-selector.service.ts b/packages/ui/src/services/range-selector/range-selector.service.ts
index a95e33a921..a6940c9f41 100644
--- a/packages/ui/src/services/range-selector/range-selector.service.ts
+++ b/packages/ui/src/services/range-selector/range-selector.service.ts
@@ -14,10 +14,8 @@
* limitations under the License.
*/
-import type { IUnitRange, Nullable } from '@univerjs/core';
-import { Disposable } from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier } from '@wendellhu/redi';
+import type { IDisposable, IUnitRange, Nullable } from '@univerjs/core';
+import { createIdentifier, Disposable } from '@univerjs/core';
import type { Observable } from 'rxjs';
import { Subject } from 'rxjs';
diff --git a/packages/ui/src/services/shortcut/shortcut.service.ts b/packages/ui/src/services/shortcut/shortcut.service.ts
index ef3ab3cc9c..148fd1359d 100644
--- a/packages/ui/src/services/shortcut/shortcut.service.ts
+++ b/packages/ui/src/services/shortcut/shortcut.service.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { Disposable, ICommandService, IContextService, toDisposable } from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier, Optional } from '@wendellhu/redi';
+import { createIdentifier, Disposable, ICommandService, IContextService, Optional, toDisposable } from '@univerjs/core';
+import type { IDisposable } from '@univerjs/core';
import type { Observable } from 'rxjs';
import { Subject } from 'rxjs';
diff --git a/packages/ui/src/services/sidebar/desktop-sidebar.service.ts b/packages/ui/src/services/sidebar/desktop-sidebar.service.ts
index 6fafe6e316..57e7e7e6b8 100644
--- a/packages/ui/src/services/sidebar/desktop-sidebar.service.ts
+++ b/packages/ui/src/services/sidebar/desktop-sidebar.service.ts
@@ -15,7 +15,7 @@
*/
import { toDisposable } from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
+import type { IDisposable } from '@univerjs/core';
import { Subject } from 'rxjs';
import type { ISidebarMethodOptions } from '../../views/components/sidebar/interface';
diff --git a/packages/ui/src/services/sidebar/sidebar.service.ts b/packages/ui/src/services/sidebar/sidebar.service.ts
index 6fb05b6d4e..1aaa8dc786 100644
--- a/packages/ui/src/services/sidebar/sidebar.service.ts
+++ b/packages/ui/src/services/sidebar/sidebar.service.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier } from '@wendellhu/redi';
+import type { IDisposable } from '@univerjs/core';
+import { createIdentifier } from '@univerjs/core';
import type { Subject } from 'rxjs';
import type { ISidebarMethodOptions } from '../../views/components/sidebar/interface';
diff --git a/packages/ui/src/services/zen-zone/desktop-zen-zone.service.ts b/packages/ui/src/services/zen-zone/desktop-zen-zone.service.ts
index a12c9c1570..c104053a74 100644
--- a/packages/ui/src/services/zen-zone/desktop-zen-zone.service.ts
+++ b/packages/ui/src/services/zen-zone/desktop-zen-zone.service.ts
@@ -15,7 +15,7 @@
*/
import { toDisposable } from '@univerjs/core';
-import { type IDisposable, Inject } from '@wendellhu/redi';
+import { type IDisposable, Inject } from '@univerjs/core';
import type { ForwardRefExoticComponent } from 'react';
import { Subject } from 'rxjs';
diff --git a/packages/ui/src/services/zen-zone/zen-zone.service.ts b/packages/ui/src/services/zen-zone/zen-zone.service.ts
index f6a1c6e791..550c0d57af 100644
--- a/packages/ui/src/services/zen-zone/zen-zone.service.ts
+++ b/packages/ui/src/services/zen-zone/zen-zone.service.ts
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-import type { IDisposable } from '@wendellhu/redi';
-import { createIdentifier } from '@wendellhu/redi';
+import type { IDisposable } from '@univerjs/core';
+import { createIdentifier } from '@univerjs/core';
import type { Subject } from 'rxjs';
export const IZenZoneService = createIdentifier<IZenZoneService>('univer.zen-zone-service');
diff --git a/packages/ui/src/ui-plugin.ts b/packages/ui/src/ui-plugin.ts
index c13506c6f7..c593c60155 100644
--- a/packages/ui/src/ui-plugin.ts
+++ b/packages/ui/src/ui-plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { DependentOn, IContextService, ILocalStorageService, mergeOverrideWithDependencies, Plugin, Tools } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { DependentOn, IContextService, ILocalStorageService, Inject, Injector, mergeOverrideWithDependencies, Plugin, Tools } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
import { UniverRenderEnginePlugin } from '@univerjs/engine-render';
import { CanvasPopupService, ICanvasPopupService } from './services/popup/canvas-popup.service';
diff --git a/packages/ui/src/views/MobileApp.tsx b/packages/ui/src/views/MobileApp.tsx
index 7b0777b7d9..89514c672b 100644
--- a/packages/ui/src/views/MobileApp.tsx
+++ b/packages/ui/src/views/MobileApp.tsx
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { LocaleService, ThemeService } from '@univerjs/core';
+import { LocaleService, ThemeService, useDependency } from '@univerjs/core';
import type { ILocale } from '@univerjs/design';
import { ConfigProvider, defaultTheme, themeInstance } from '@univerjs/design';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import React, { useEffect, useMemo, useRef, useState } from 'react';
import type { IWorkbenchOptions } from '../controllers/ui/ui.controller';
import { IMessageService } from '../services/message/message.service';
diff --git a/packages/ui/src/views/components/ComponentContainer.tsx b/packages/ui/src/views/components/ComponentContainer.tsx
index 0ba1716543..56fa444476 100644
--- a/packages/ui/src/views/components/ComponentContainer.tsx
+++ b/packages/ui/src/views/components/ComponentContainer.tsx
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { useDependency } from '@univerjs/core';
import type { ComponentType } from 'react';
import React, { useMemo, useRef } from 'react';
import { filter, map, startWith } from 'rxjs';
-import type { Injector } from '@wendellhu/redi';
+import type { Injector } from '@univerjs/core';
import { useObservable } from '../../components/hooks/observable';
import { IUIPartsService } from '../../services/parts/parts.service';
diff --git a/packages/ui/src/views/components/confirm-part/ConfirmPart.tsx b/packages/ui/src/views/components/confirm-part/ConfirmPart.tsx
index f21f6fc6dd..750c206d3b 100644
--- a/packages/ui/src/views/components/confirm-part/ConfirmPart.tsx
+++ b/packages/ui/src/views/components/confirm-part/ConfirmPart.tsx
@@ -16,7 +16,7 @@
import type { IConfirmProps } from '@univerjs/design';
import { Confirm } from '@univerjs/design';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { useDependency } from '@univerjs/core';
import React, { useEffect, useState } from 'react';
import { CustomLabel } from '../../../components/custom-label/CustomLabel';
diff --git a/packages/ui/src/views/components/context-menu/ContextMenu.tsx b/packages/ui/src/views/components/context-menu/ContextMenu.tsx
index f3409a739a..8ac7df28c3 100644
--- a/packages/ui/src/views/components/context-menu/ContextMenu.tsx
+++ b/packages/ui/src/views/components/context-menu/ContextMenu.tsx
@@ -14,11 +14,10 @@
* limitations under the License.
*/
-import { ICommandService } from '@univerjs/core';
+import { ICommandService, useDependency, useInjector } from '@univerjs/core';
import { Popup } from '@univerjs/design';
import type { IMouseEvent } from '@univerjs/engine-render';
import { ITextSelectionRenderManager } from '@univerjs/engine-render';
-import { useDependency, useInjector } from '@wendellhu/redi/react-bindings';
import React, { useEffect, useRef, useState } from 'react';
import { Menu } from '../../../components/menu/desktop/Menu';
diff --git a/packages/ui/src/views/components/context-menu/MobileContextMenu.tsx b/packages/ui/src/views/components/context-menu/MobileContextMenu.tsx
index 920d801a6c..b13c7f594f 100644
--- a/packages/ui/src/views/components/context-menu/MobileContextMenu.tsx
+++ b/packages/ui/src/views/components/context-menu/MobileContextMenu.tsx
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { ICommandService } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { ICommandService, useDependency } from '@univerjs/core';
import React, { useEffect, useState } from 'react';
import { Popup } from '@univerjs/design';
import type { IMouseEvent } from '@univerjs/engine-render';
diff --git a/packages/ui/src/views/components/dialog-part/DialogPart.tsx b/packages/ui/src/views/components/dialog-part/DialogPart.tsx
index 24ca5b7de7..c36a54a419 100644
--- a/packages/ui/src/views/components/dialog-part/DialogPart.tsx
+++ b/packages/ui/src/views/components/dialog-part/DialogPart.tsx
@@ -16,7 +16,7 @@
import type { IDialogProps } from '@univerjs/design';
import { Dialog } from '@univerjs/design';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { useDependency } from '@univerjs/core';
import React, { useEffect, useState } from 'react';
import { CustomLabel } from '../../../components/custom-label/CustomLabel';
diff --git a/packages/ui/src/views/components/doc-bars/Toolbar.tsx b/packages/ui/src/views/components/doc-bars/Toolbar.tsx
index 725521fc6a..534c264296 100644
--- a/packages/ui/src/views/components/doc-bars/Toolbar.tsx
+++ b/packages/ui/src/views/components/doc-bars/Toolbar.tsx
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { LocaleService } from '@univerjs/core';
+import { LocaleService, useDependency } from '@univerjs/core';
import { Dropdown, Tooltip } from '@univerjs/design';
import { MoreFunctionSingle } from '@univerjs/icons';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import clsx from 'clsx';
import type { ComponentType } from 'react';
import React, { useMemo } from 'react';
diff --git a/packages/ui/src/views/components/doc-bars/ToolbarItem.tsx b/packages/ui/src/views/components/doc-bars/ToolbarItem.tsx
index 860b000113..2d0a3e4807 100644
--- a/packages/ui/src/views/components/doc-bars/ToolbarItem.tsx
+++ b/packages/ui/src/views/components/doc-bars/ToolbarItem.tsx
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { ICommandService, LocaleService } from '@univerjs/core';
+import { ICommandService, LocaleService, useDependency } from '@univerjs/core';
import { Dropdown, Tooltip } from '@univerjs/design';
import { MoreDownSingle } from '@univerjs/icons';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import type { Ref } from 'react';
import React, { forwardRef, useMemo, useState } from 'react';
import { isObservable, Observable } from 'rxjs';
diff --git a/packages/ui/src/views/components/doc-bars/hook.ts b/packages/ui/src/views/components/doc-bars/hook.ts
index 59c6491891..40e0f4f3a7 100644
--- a/packages/ui/src/views/components/doc-bars/hook.ts
+++ b/packages/ui/src/views/components/doc-bars/hook.ts
@@ -17,7 +17,7 @@
import { useEffect, useMemo, useRef, useState } from 'react';
import type { Subscription } from 'rxjs';
import { combineLatest, map, Observable } from 'rxjs';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { useDependency } from '@univerjs/core';
import { type IDisplayMenuItem, type IMenuItem, MenuGroup, MenuPosition } from '../../../services/menu/menu';
import { IMenuService } from '../../../services/menu/menu.service';
diff --git a/packages/ui/src/views/components/dom/FloatDom.tsx b/packages/ui/src/views/components/dom/FloatDom.tsx
index 9ca8238185..c12451dd4b 100644
--- a/packages/ui/src/views/components/dom/FloatDom.tsx
+++ b/packages/ui/src/views/components/dom/FloatDom.tsx
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { useDependency } from '@univerjs/core';
import React, { memo } from 'react';
import type { IFloatDom } from '../../../services/dom/canvas-dom-layer.service';
import { CanvasFloatDomService } from '../../../services/dom/canvas-dom-layer.service';
diff --git a/packages/ui/src/views/components/global-zone/GlobalZone.tsx b/packages/ui/src/views/components/global-zone/GlobalZone.tsx
index cb95d45365..4f818309c5 100644
--- a/packages/ui/src/views/components/global-zone/GlobalZone.tsx
+++ b/packages/ui/src/views/components/global-zone/GlobalZone.tsx
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { useDependency } from '@univerjs/core';
import clsx from 'clsx';
import React, { useEffect, useMemo, useState } from 'react';
import { ComponentManager } from '../../../common/component-manager';
diff --git a/packages/ui/src/views/components/popup/CanvasPopup.tsx b/packages/ui/src/views/components/popup/CanvasPopup.tsx
index aefe835f7e..47acb3c644 100644
--- a/packages/ui/src/views/components/popup/CanvasPopup.tsx
+++ b/packages/ui/src/views/components/popup/CanvasPopup.tsx
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { useDependency } from '@univerjs/core';
import React, { useMemo } from 'react';
import { RectPopup } from '@univerjs/design';
import type { IBoundRectNoAngle } from '@univerjs/engine-render';
diff --git a/packages/ui/src/views/components/shortcut-panel/ShortcutPanel.tsx b/packages/ui/src/views/components/shortcut-panel/ShortcutPanel.tsx
index 36741e4bb4..edc0b75c16 100644
--- a/packages/ui/src/views/components/shortcut-panel/ShortcutPanel.tsx
+++ b/packages/ui/src/views/components/shortcut-panel/ShortcutPanel.tsx
@@ -14,8 +14,7 @@
* limitations under the License.
*/
-import { LocaleService } from '@univerjs/core';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { LocaleService, useDependency } from '@univerjs/core';
import { useObservable } from '@univerjs/ui';
import React, { useCallback, useEffect } from 'react';
diff --git a/packages/ui/src/views/components/sidebar/Sidebar.tsx b/packages/ui/src/views/components/sidebar/Sidebar.tsx
index 6005bf8d48..6d5cd263f3 100644
--- a/packages/ui/src/views/components/sidebar/Sidebar.tsx
+++ b/packages/ui/src/views/components/sidebar/Sidebar.tsx
@@ -15,7 +15,7 @@
*/
import { CloseSingle } from '@univerjs/icons';
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { useDependency } from '@univerjs/core';
import clsx from 'clsx';
import React, { useEffect, useMemo, useRef } from 'react';
import { CustomLabel } from '../../../components/custom-label/CustomLabel';
diff --git a/packages/ui/src/views/components/zen-zone/ZenZone.tsx b/packages/ui/src/views/components/zen-zone/ZenZone.tsx
index e4a3390a4c..d9c317ebf3 100644
--- a/packages/ui/src/views/components/zen-zone/ZenZone.tsx
+++ b/packages/ui/src/views/components/zen-zone/ZenZone.tsx
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-import { useDependency } from '@wendellhu/redi/react-bindings';
+import { useDependency } from '@univerjs/core';
import clsx from 'clsx';
import React, { useEffect, useMemo, useState } from 'react';
diff --git a/packages/ui/src/views/workbench/Workbench.tsx b/packages/ui/src/views/workbench/Workbench.tsx
index e08558d331..008cb32571 100644
--- a/packages/ui/src/views/workbench/Workbench.tsx
+++ b/packages/ui/src/views/workbench/Workbench.tsx
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { LocaleService, ThemeService } from '@univerjs/core';
+import { LocaleService, ThemeService, useDependency } from '@univerjs/core';
import type { ILocale } from '@univerjs/design';
import { ConfigContext, ConfigProvider, defaultTheme, themeInstance } from '@univerjs/design';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import React, { useContext, useEffect, useMemo, useRef, useState } from 'react';
import { createPortal } from 'react-dom';
diff --git a/packages/umd/package.json b/packages/umd/package.json
index 32efbf35b9..cf8deae9d8 100644
--- a/packages/umd/package.json
+++ b/packages/umd/package.json
@@ -83,7 +83,6 @@
"@univerjs/thread-comment-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
"@univerjs/uniscript": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"clsx": "^2.1.1",
"dayjs": "^1.11.11",
"lodash": "^4.17.21",
diff --git a/packages/umd/scripts/index.mjs b/packages/umd/scripts/index.mjs
index 0e35bf863c..f811294e32 100644
--- a/packages/umd/scripts/index.mjs
+++ b/packages/umd/scripts/index.mjs
@@ -163,8 +163,6 @@ function buildExternalLib({ react, rxjs }) {
const libs = [
'clsx/dist/clsx.min.js',
'dayjs/dayjs.min.js',
- '@wendellhu/redi/dist/redi.js',
- '@wendellhu/redi/dist/react-bindings.js',
];
if (react) {
libs.unshift(
diff --git a/packages/uniscript/package.json b/packages/uniscript/package.json
index bb6fdb2c78..955c3e0721 100644
--- a/packages/uniscript/package.json
+++ b/packages/uniscript/package.json
@@ -71,7 +71,6 @@
"@univerjs/sheets": "workspace:*",
"@univerjs/sheets-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"monaco-editor": ">=0.44.0",
"react": "^16.9.0 || ^17.0.0 || ^18.0.0",
"rxjs": ">=7.0.0"
@@ -88,7 +87,6 @@
"@univerjs/sheets": "workspace:*",
"@univerjs/sheets-ui": "workspace:*",
"@univerjs/ui": "workspace:*",
- "@wendellhu/redi": "0.16.0",
"less": "^4.2.0",
"monaco-editor": "0.50.0",
"rxjs": "^7.8.1",
diff --git a/packages/uniscript/src/commands/operations/panel.operation.ts b/packages/uniscript/src/commands/operations/panel.operation.ts
index 38d9eb519d..97ce0f4d13 100644
--- a/packages/uniscript/src/commands/operations/panel.operation.ts
+++ b/packages/uniscript/src/commands/operations/panel.operation.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import type { IOperation } from '@univerjs/core';
+import type { IAccessor, IOperation } from '@univerjs/core';
import { CommandType } from '@univerjs/core';
import { ISidebarService } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
import { ScriptPanelService } from '../../services/script-panel.service';
diff --git a/packages/uniscript/src/controllers/menu.ts b/packages/uniscript/src/controllers/menu.ts
index b48d2b3fe8..766077a7b2 100644
--- a/packages/uniscript/src/controllers/menu.ts
+++ b/packages/uniscript/src/controllers/menu.ts
@@ -16,7 +16,7 @@
import type { IMenuButtonItem } from '@univerjs/ui';
import { getMenuHiddenObservable, MenuItemType, MenuPosition } from '@univerjs/ui';
-import type { IAccessor } from '@wendellhu/redi';
+import type { IAccessor } from '@univerjs/core';
import { UniverInstanceType } from '@univerjs/core';
import { getCurrentRangeDisable$ } from '@univerjs/sheets-ui';
diff --git a/packages/uniscript/src/controllers/uniscript.controller.ts b/packages/uniscript/src/controllers/uniscript.controller.ts
index 0d08e38124..c6589f2ac4 100644
--- a/packages/uniscript/src/controllers/uniscript.controller.ts
+++ b/packages/uniscript/src/controllers/uniscript.controller.ts
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-import { Disposable, ICommandService, LifecycleStages, OnLifecycle } from '@univerjs/core';
+import { Disposable, ICommandService, Inject, Injector, LifecycleStages, OnLifecycle } from '@univerjs/core';
import type { MenuConfig } from '@univerjs/ui';
import { ComponentManager, IMenuService } from '@univerjs/ui';
-import { Inject, Injector } from '@wendellhu/redi';
import { ScriptPanelComponentName, ToggleScriptPanelOperation } from '../commands/operations/panel.operation';
import { ScriptEditorPanel } from '../views/components/ScriptEditorPanel';
diff --git a/packages/uniscript/src/plugin.ts b/packages/uniscript/src/plugin.ts
index 1eb567b75c..ebd22f0658 100644
--- a/packages/uniscript/src/plugin.ts
+++ b/packages/uniscript/src/plugin.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { LocaleService, Plugin, Tools } from '@univerjs/core';
-import type { Dependency } from '@wendellhu/redi';
-import { Inject, Injector } from '@wendellhu/redi';
+import { Inject, Injector, LocaleService, Plugin, Tools } from '@univerjs/core';
+import type { Dependency } from '@univerjs/core';
import type { IUniverUniscriptConfig } from './controllers/uniscript.controller';
import { DefaultUniscriptConfig, UniscriptController } from './controllers/uniscript.controller';
diff --git a/packages/uniscript/src/services/script-editor.service.ts b/packages/uniscript/src/services/script-editor.service.ts
index 249606b9c5..5b8636b1d4 100644
--- a/packages/uniscript/src/services/script-editor.service.ts
+++ b/packages/uniscript/src/services/script-editor.service.ts
@@ -15,7 +15,7 @@
*/
import { Disposable, toDisposable } from '@univerjs/core';
-import type { IDisposable } from '@wendellhu/redi';
+import type { IDisposable } from '@univerjs/core';
import type { editor } from 'monaco-editor';
import type { IUniverUniscriptConfig } from '../controllers/uniscript.controller';
diff --git a/packages/uniscript/src/services/script-execution.service.ts b/packages/uniscript/src/services/script-execution.service.ts
index 198c4372ed..c6c93eb8cd 100644
--- a/packages/uniscript/src/services/script-execution.service.ts
+++ b/packages/uniscript/src/services/script-execution.service.ts
@@ -14,9 +14,8 @@
* limitations under the License.
*/
-import { Disposable, ILogService } from '@univerjs/core';
+import { createIdentifier, Disposable, ILogService, Inject, Injector } from '@univerjs/core';
import { FUniver } from '@univerjs/facade';
-import { createIdentifier, Inject, Injector } from '@wendellhu/redi';
export const IUniscriptExecutionService = createIdentifier<IUniscriptExecutionService>('univer.uniscript.execution-service');
diff --git a/packages/uniscript/src/views/components/ScriptEditorPanel.tsx b/packages/uniscript/src/views/components/ScriptEditorPanel.tsx
index 175a66c9fa..c141b3b4a1 100644
--- a/packages/uniscript/src/views/components/ScriptEditorPanel.tsx
+++ b/packages/uniscript/src/views/components/ScriptEditorPanel.tsx
@@ -14,12 +14,10 @@
* limitations under the License.
*/
-import type { Nullable } from '@univerjs/core';
-import { DisposableCollection, LocaleService, toDisposable } from '@univerjs/core';
+import type { IDisposable, Nullable } from '@univerjs/core';
+import { DisposableCollection, LocaleService, toDisposable, useDependency } from '@univerjs/core';
import { Button, MessageType } from '@univerjs/design';
import { IMessageService, IShortcutService } from '@univerjs/ui';
-import type { IDisposable } from '@wendellhu/redi';
-import { useDependency } from '@wendellhu/redi/react-bindings';
import { editor } from 'monaco-editor';
import React, { useCallback, useEffect, useRef } from 'react';
diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml
index 78299b9928..693a2ca6bb 100644
--- a/pnpm-lock.yaml
+++ b/pnpm-lock.yaml
@@ -170,9 +170,6 @@ importers:
'@univerjs/ui':
specifier: workspace:*
version: link:../../packages/ui
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
css-loader:
specifier: ^6.10.0
@@ -342,9 +339,6 @@ importers:
'@univerjs/uniui':
specifier: workspace:*
version: link:../packages-experimental/uniui
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
clsx:
specifier: ^2.1.1
version: 2.1.1
@@ -428,9 +422,6 @@ importers:
'@univerjs/ui':
specifier: workspace:*
version: link:../../packages/ui
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
clsx:
specifier: ^2.1.1
version: 2.1.1
@@ -458,9 +449,6 @@ importers:
'@univerjs/uni-formula':
specifier: workspace:*
version: link:../uni-formula
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
rxjs:
specifier: ^7.8.1
version: 7.8.1
@@ -504,9 +492,6 @@ importers:
'@univerjs/ui':
specifier: workspace:*
version: link:../../packages/ui
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
clsx:
specifier: ^2.1.1
version: 2.1.1
@@ -537,6 +522,9 @@ importers:
'@univerjs/protocol':
specifier: 0.1.38-alpha.23
version: 0.1.38-alpha.23(@grpc/[email protected])([email protected])
+ '@wendellhu/redi':
+ specifier: 0.16.0
+ version: 0.16.0
nanoid:
specifier: 5.0.7
version: 5.0.7
@@ -546,6 +534,9 @@ importers:
ot-json1:
specifier: ^1.0.2
version: 1.0.2
+ react:
+ specifier: ^16.9.0 || ^17.0.0 || ^18.0.0
+ version: 18.3.1
devDependencies:
'@types/numeral':
specifier: ^2.0.5
@@ -553,9 +544,6 @@ importers:
'@univerjs/shared':
specifier: workspace:*
version: link:../../common/shared
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
rxjs:
specifier: ^7.8.1
version: 7.8.1
@@ -584,9 +572,6 @@ importers:
'@univerjs/sheets':
specifier: workspace:*
version: link:../sheets
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
rxjs:
specifier: ^7.8.1
version: 7.8.1
@@ -637,9 +622,6 @@ importers:
'@vitejs/plugin-vue':
specifier: ^5.0.4
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
rxjs:
specifier: ^7.8.1
version: 7.8.1
@@ -767,9 +749,6 @@ importers:
'@univerjs/shared':
specifier: workspace:*
version: link:../../common/shared
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
rxjs:
specifier: ^7.8.1
version: 7.8.1
@@ -804,9 +783,6 @@ importers:
'@univerjs/shared':
specifier: workspace:*
version: link:../../common/shared
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
typescript:
specifier: ^5.5.3
version: 5.5.3
@@ -853,9 +829,6 @@ importers:
'@univerjs/ui':
specifier: workspace:*
version: link:../ui
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
clsx:
specifier: ^2.1.1
version: 2.1.1
@@ -895,9 +868,6 @@ importers:
'@univerjs/shared':
specifier: workspace:*
version: link:../../common/shared
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
rxjs:
specifier: ^7.8.1
version: 7.8.1
@@ -941,9 +911,6 @@ importers:
'@univerjs/ui':
specifier: workspace:*
version: link:../ui
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
clsx:
specifier: ^2.1.1
version: 2.1.1
@@ -980,9 +947,6 @@ importers:
'@univerjs/shared':
specifier: workspace:*
version: link:../../common/shared
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
rxjs:
specifier: ^7.8.1
version: 7.8.1
@@ -1025,9 +989,6 @@ importers:
'@univerjs/ui':
specifier: workspace:*
version: link:../ui
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
clsx:
specifier: ^2.1.1
version: 2.1.1
@@ -1086,9 +1047,6 @@ importers:
'@univerjs/ui':
specifier: workspace:*
version: link:../ui
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
clsx:
specifier: ^2.1.1
version: 2.1.1
@@ -1131,9 +1089,6 @@ importers:
'@univerjs/ui':
specifier: workspace:*
version: link:../ui
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
clsx:
specifier: ^2.1.1
version: 2.1.1
@@ -1171,9 +1126,6 @@ importers:
'@univerjs/shared':
specifier: workspace:*
version: link:../../common/shared
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
less:
specifier: ^4.2.0
version: 4.2.0
@@ -1214,9 +1166,6 @@ importers:
'@univerjs/ui':
specifier: workspace:*
version: link:../ui
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
clsx:
specifier: ^2.1.1
version: 2.1.1
@@ -1260,9 +1209,6 @@ importers:
'@univerjs/shared':
specifier: workspace:*
version: link:../../common/shared
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
rxjs:
specifier: ^7.8.1
version: 7.8.1
@@ -1322,9 +1268,6 @@ importers:
'@univerjs/shared':
specifier: workspace:*
version: link:../../common/shared
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
rxjs:
specifier: ^7.8.1
version: 7.8.1
@@ -1379,9 +1322,6 @@ importers:
'@univerjs/ui':
specifier: workspace:*
version: link:../ui
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
jest-canvas-mock:
specifier: ^2.5.2
version: 2.5.2
@@ -1428,9 +1368,6 @@ importers:
'@univerjs/ui':
specifier: workspace:*
version: link:../ui
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
less:
specifier: ^4.2.0
version: 4.2.0
@@ -1458,9 +1395,6 @@ importers:
'@univerjs/shared':
specifier: workspace:*
version: link:../../common/shared
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
rxjs:
specifier: ^7.8.1
version: 7.8.1
@@ -1482,9 +1416,6 @@ importers:
'@univerjs/shared':
specifier: workspace:*
version: link:../../common/shared
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
rxjs:
specifier: ^7.8.1
version: 7.8.1
@@ -1519,9 +1450,6 @@ importers:
'@univerjs/shared':
specifier: workspace:*
version: link:../../common/shared
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
rxjs:
specifier: ^7.8.1
version: 7.8.1
@@ -1559,9 +1487,6 @@ importers:
'@univerjs/sheets':
specifier: workspace:*
version: link:../sheets
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
dayjs:
specifier: ^1.11.11
version: 1.11.11
@@ -1644,9 +1569,6 @@ importers:
'@univerjs/ui':
specifier: workspace:*
version: link:../ui
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
clsx:
specifier: ^2.1.1
version: 2.1.1
@@ -1711,9 +1633,6 @@ importers:
'@univerjs/ui':
specifier: workspace:*
version: link:../ui
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
clsx:
specifier: ^2.1.1
version: 2.1.1
@@ -1757,9 +1676,6 @@ importers:
'@univerjs/sheets':
specifier: workspace:*
version: link:../sheets
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
typescript:
specifier: ^5.5.3
version: 5.5.3
@@ -1806,9 +1722,6 @@ importers:
'@univerjs/ui':
specifier: workspace:*
version: link:../ui
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
clsx:
specifier: ^2.1.1
version: 2.1.1
@@ -1842,9 +1755,6 @@ importers:
'@univerjs/sheets':
specifier: workspace:*
version: link:../sheets
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
rxjs:
specifier: ^7.8.1
version: 7.8.1
@@ -1897,9 +1807,6 @@ importers:
'@univerjs/ui':
specifier: workspace:*
version: link:../ui
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
clsx:
specifier: ^2.1.1
version: 2.1.1
@@ -1949,9 +1856,6 @@ importers:
'@univerjs/sheets-ui':
specifier: workspace:*
version: link:../sheets-ui
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
rxjs:
specifier: ^7.8.1
version: 7.8.1
@@ -2010,9 +1914,6 @@ importers:
'@vitejs/plugin-react':
specifier: ^4.3.1
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
less:
specifier: ^4.2.0
version: 4.2.0
@@ -2053,9 +1954,6 @@ importers:
'@univerjs/sheets':
specifier: workspace:*
version: link:../sheets
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
rxjs:
specifier: ^7.8.1
version: 7.8.1
@@ -2111,9 +2009,6 @@ importers:
'@univerjs/ui':
specifier: workspace:*
version: link:../ui
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
clsx:
specifier: ^2.1.1
version: 2.1.1
@@ -2166,9 +2061,6 @@ importers:
'@univerjs/ui':
specifier: workspace:*
version: link:../ui
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
less:
specifier: ^4.2.0
version: 4.2.0
@@ -2202,9 +2094,6 @@ importers:
'@univerjs/sheets':
specifier: workspace:*
version: link:../sheets
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
rxjs:
specifier: ^7.8.1
version: 7.8.1
@@ -2254,9 +2143,6 @@ importers:
'@univerjs/ui':
specifier: workspace:*
version: link:../ui
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
clsx:
specifier: ^2.1.1
version: 2.1.1
@@ -2318,9 +2204,6 @@ importers:
'@univerjs/ui':
specifier: workspace:*
version: link:../ui
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
clsx:
specifier: ^2.1.1
version: 2.1.1
@@ -2364,9 +2247,6 @@ importers:
'@univerjs/ui':
specifier: workspace:*
version: link:../ui
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
react:
specifier: 18.3.1
version: 18.3.1
@@ -2425,9 +2305,6 @@ importers:
'@univerjs/ui':
specifier: workspace:*
version: link:../ui
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
clsx:
specifier: ^2.1.1
version: 2.1.1
@@ -2480,9 +2357,6 @@ importers:
'@univerjs/ui':
specifier: workspace:*
version: link:../ui
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
clsx:
specifier: ^2.1.1
version: 2.1.1
@@ -2516,9 +2390,6 @@ importers:
'@univerjs/shared':
specifier: workspace:*
version: link:../../common/shared
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
rxjs:
specifier: ^7.8.1
version: 7.8.1
@@ -2555,9 +2426,6 @@ importers:
'@univerjs/ui':
specifier: workspace:*
version: link:../ui
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
clsx:
specifier: ^2.1.1
version: 2.1.1
@@ -2592,9 +2460,6 @@ importers:
'@univerjs/shared':
specifier: workspace:*
version: link:../../common/shared
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
rxjs:
specifier: ^7.8.1
version: 7.8.1
@@ -2638,9 +2503,6 @@ importers:
'@univerjs/ui':
specifier: workspace:*
version: link:../ui
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
clsx:
specifier: ^2.1.1
version: 2.1.1
@@ -2718,9 +2580,6 @@ importers:
'@univerjs/shared':
specifier: workspace:*
version: link:../../common/shared
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
clsx:
specifier: ^2.1.1
version: 2.1.1
@@ -2883,9 +2742,6 @@ importers:
'@univerjs/uniscript':
specifier: workspace:*
version: link:../uniscript
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
clsx:
specifier: ^2.1.1
version: 2.1.1
@@ -2941,9 +2797,6 @@ importers:
'@univerjs/ui':
specifier: workspace:*
version: link:../ui
- '@wendellhu/redi':
- specifier: 0.16.0
- version: 0.16.0
less:
specifier: ^4.2.0
version: 4.2.0