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.

build(workspace): Remove circular dependencies between plugins

Dushusira7a2fb83eb71
diff --git a/README-zh.md b/README-zh.md
index 633e907a1c..0408f185a0 100644
--- a/README-zh.md
+++ b/README-zh.md
@@ -10,7 +10,7 @@
## Demo
-- [Univer Demo](dream-num.github.io/univer-demo/)
+- [Univer Demo](https://dream-num.github.io/univer-demo/)
## 开发
@@ -33,7 +33,7 @@ pnpm i
启动 sheets
```
-npm run dev
+npm run dev:sheet
```
启动 docs
diff --git a/README.md b/README.md
index adecfcb475..9d9461264f 100644
--- a/README.md
+++ b/README.md
@@ -10,7 +10,7 @@ English | [简体中文](./README-zh.md)
## Demo
-- [Univer Demo](dream-num.github.io/univer-demo/)
+- [Univer Demo](https://dream-num.github.io/univer-demo/)
## Development
@@ -33,7 +33,7 @@ pnpm i
Start sheets
```
-npm run dev
+npm run dev:sheet
```
Start docs
diff --git a/examples/univer-sheet-ts/src/main.tsx b/examples/univer-sheet-ts/src/main.tsx
index f8018eb5e1..c220cdb155 100644
--- a/examples/univer-sheet-ts/src/main.tsx
+++ b/examples/univer-sheet-ts/src/main.tsx
@@ -46,7 +46,7 @@ const uiDefaultConfigDemo = {
// const univerSheetDemo = UniverSheet.newInstance(DEFAULT_WORKBOOK_DATA_DEMO1);
// const univerSheetDemo = UniverSheet.newInstance(DEFAULT_WORKBOOK_DATA_DEMO2);
// const univerSheetDemo = UniverSheet.newInstance(DEFAULT_WORKBOOK_DATA_DEMO3);
-const univerSheetDemo = UniverSheet.newInstance(DEFAULT_WORKBOOK_DATA_DEMO3);
+const univerSheetDemo = UniverSheet.newInstance(DEFAULT_WORKBOOK_DATA_DEMO);
univerSheetDemo.installPlugin(new RenderEngine());
univerSheetDemo.installPlugin(new UniverComponentSheet());
univerSheetDemo.installPlugin(new SheetPlugin(uiDefaultConfigDemo));
diff --git a/package.json b/package.json
index d7a81b8c37..5cdb0be160 100644
--- a/package.json
+++ b/package.json
@@ -8,19 +8,16 @@
"test:ui": "pnpm run --filter @univer/style-universheet test",
"test:e2e": "pnpm run --filter @univer/base-sheets test:play",
"dev": "node scripts/dev",
- "dev:demo": "pnpm run --filter univer-sheet-ts dev",
- "dev:demosheet": "pnpm run --filter univer-sheet-ts dev",
- "dev:demodoc": "pnpm run --filter univer-doc-ts dev",
- "dev:demoslide": "pnpm run --filter univer-slide-ts dev",
- "dev:doc": "pnpm run --filter @univer/base-docs dev",
- "dev:slide": "pnpm run --filter @univer/base-slides dev",
- "d": "pnpm run --filter univer-vanilla-ts dev",
+ "dev:sheet": "pnpm run --filter univer-sheet-ts dev",
+ "dev:doc": "pnpm run --filter univer-doc-ts dev",
+ "dev:slide": "pnpm run --filter univer-slide-ts dev",
+ "dev:all": "pnpm run --filter univer-vanilla-ts dev",
"api": "node scripts/api",
"lighthouse-dev": "start /B node scripts/dev && lighthouse http://127.0.0.1:3103 --output html --output-path ./report.html",
"build": "node scripts/build.js",
- "build:demosheet": "pnpm run --filter univer-sheet-ts build:demo",
- "build:demodoc": "pnpm run --filter univer-doc-ts build:demo",
- "build:demoslide": "pnpm run --filter univer-slide-ts build:demo",
+ "build:sheet": "pnpm run --filter univer-sheet-ts build:demo",
+ "build:doc": "pnpm run --filter univer-doc-ts build:demo",
+ "build:slide": "pnpm run --filter univer-slide-ts build:demo",
"link": "node scripts/link.js",
"build:customd": "cd cli/src/templates/univer-custom-build && npm run build:d",
"clean": "npm cache clean --force && pnpm dlx rimraf node_modules **/node_modules/ package-lock.json yarn.lock pnpm-lock.yaml && pnpm install && pnpm dlx playwright install",
diff --git a/packages/base-docs/package.json b/packages/base-docs/package.json
index 154125126f..d07a01b33c 100644
--- a/packages/base-docs/package.json
+++ b/packages/base-docs/package.json
@@ -54,7 +54,6 @@
"@univer/base-sheets": "workspace:^0.0.1",
"@univer/core": "workspace:^0.0.1",
"@univer/common-plugin-data": "workspace:^0.0.1",
- "@univer/sheets-plugin-filter": "workspace:^0.0.1",
"@univer/style-universheet": "workspace:^0.0.1",
"css-vars-ponyfill": "^2.4.6",
"preact": "^10.5.14"
diff --git a/packages/base-formula-engine/package.json b/packages/base-formula-engine/package.json
index 9a53a12764..45db6d03cf 100644
--- a/packages/base-formula-engine/package.json
+++ b/packages/base-formula-engine/package.json
@@ -50,10 +50,7 @@
"vite": "^2.4.4"
},
"dependencies": {
- "@univer/base-formula-engine": "workspace:^0.0.1",
- "@univer/base-sheets": "workspace:^0.0.1",
"@univer/core": "workspace:^0.0.1",
- "@univer/sheets-plugin-filter": "workspace:^0.0.1",
"@univer/style-universheet": "workspace:^0.0.1",
"nanoid": "4.0.0",
"preact": "^10.5.14"
diff --git a/packages/base-numfmt-engine/package.json b/packages/base-numfmt-engine/package.json
index a133072bfd..c8500e0a42 100644
--- a/packages/base-numfmt-engine/package.json
+++ b/packages/base-numfmt-engine/package.json
@@ -45,10 +45,6 @@
"vite-plugin-external": "1.2.3"
},
"dependencies": {
- "@univer/base-numfmt-engine": "workspace:^0.0.1",
- "@univer/base-sheets": "workspace:^0.0.1",
- "@univer/core": "workspace:^0.0.1",
- "@univer/sheets-plugin-filter": "workspace:^0.0.1",
- "@univer/style-universheet": "workspace:^0.0.1"
+ "@univer/core": "workspace:^0.0.1"
}
}
diff --git a/packages/base-sheets/package.json b/packages/base-sheets/package.json
index c48a6c7c25..436b8902ef 100644
--- a/packages/base-sheets/package.json
+++ b/packages/base-sheets/package.json
@@ -52,8 +52,6 @@
"@univer/base-render": "workspace:^0.0.1",
"@univer/common-plugin-data": "workspace:^0.0.1",
"@univer/core": "workspace:^0.0.1",
- "@univer/sheets-plugin-formula": "workspace:^0.0.1",
- "@univer/sheets-plugin-numfmt": "workspace:^0.0.1",
"@univer/style-universheet": "workspace:^0.0.1",
"css-vars-ponyfill": "^2.4.6",
"nanoid": "4.0.0",
diff --git a/packages/base-sheets/src/main.tsx b/packages/base-sheets/src/main.tsx
index fbb530ab9e..08650c706d 100644
--- a/packages/base-sheets/src/main.tsx
+++ b/packages/base-sheets/src/main.tsx
@@ -1,9 +1,9 @@
import { UniverSheet } from '@univer/core';
import { RenderEngine } from '@univer/base-render';
import { UniverComponentSheet } from '@univer/style-universheet';
-import { NumfmtPlugin } from '@univer/sheets-plugin-numfmt';
+// import { NumfmtPlugin } from '@univer/sheets-plugin-numfmt';
import { DEFAULT_WORKBOOK_DATA } from '@univer/common-plugin-data';
-import { DEFAULT_FORMULA_DATA, FormulaPlugin } from '@univer/sheets-plugin-formula';
+// import { DEFAULT_FORMULA_DATA, FormulaPlugin } from '@univer/sheets-plugin-formula';
import { SheetPlugin } from './SheetPlugin';
const uiDefaultConfigUp = {
@@ -44,8 +44,8 @@ univerSheetUp.installPlugin(new UniverComponentSheet());
let sheetPlugin = new SheetPlugin(uiDefaultConfigUp);
univerSheetUp.installPlugin(sheetPlugin);
-univerSheetUp.installPlugin(new NumfmtPlugin());
-FormulaPlugin.create(DEFAULT_FORMULA_DATA).installTo(univerSheetUp);
+// univerSheetUp.installPlugin(new NumfmtPlugin());
+// FormulaPlugin.create(DEFAULT_FORMULA_DATA).installTo(univerSheetUp);
// univerSheetUp.refreshWorkbook(DEFAULT_WORKBOOK_DATA_DOWN);
diff --git a/packages/base-slides/package.json b/packages/base-slides/package.json
index 87ccd461d6..d8275a3014 100644
--- a/packages/base-slides/package.json
+++ b/packages/base-slides/package.json
@@ -54,7 +54,6 @@
"@univer/base-sheets": "workspace:^0.0.1",
"@univer/common-plugin-data": "workspace:^0.0.1",
"@univer/core": "workspace:^0.0.1",
- "@univer/sheets-plugin-filter": "workspace:^0.0.1",
"@univer/style-universheet": "workspace:^0.0.1",
"css-vars-ponyfill": "^2.4.6",
"preact": "^10.5.14"
diff --git a/packages/sheets-plugin-alternating-colors/package.json b/packages/sheets-plugin-alternating-colors/package.json
index 57ed29629c..9bf09600e2 100644
--- a/packages/sheets-plugin-alternating-colors/package.json
+++ b/packages/sheets-plugin-alternating-colors/package.json
@@ -45,12 +45,11 @@
"vite-plugin-external": "1.2.3"
},
"dependencies": {
+ "@univer/base-component": "workspace:^0.0.1",
"@univer/base-render": "workspace:^0.0.1",
"@univer/base-sheets": "workspace:^0.0.1",
"@univer/common-plugin-data": "workspace:^0.0.1",
"@univer/core": "workspace:^0.0.1",
- "@univer/sheets-plugin-filter": "workspace:^0.0.1",
- "@univer/sheets-plugin-protection": "workspace:^0.0.1",
"@univer/style-universheet": "workspace:^0.0.1",
"preact": "^10.5.14"
}
diff --git a/packages/sheets-plugin-clipboard/package.json b/packages/sheets-plugin-clipboard/package.json
index d6c2a08caa..75ce278ef6 100644
--- a/packages/sheets-plugin-clipboard/package.json
+++ b/packages/sheets-plugin-clipboard/package.json
@@ -46,7 +46,6 @@
"@univer/base-sheets": "workspace:^0.0.1",
"@univer/common-plugin-data": "workspace:^0.0.1",
"@univer/core": "workspace:^0.0.1",
- "@univer/sheets-plugin-conditional-format": "workspace:^0.0.1",
"@univer/style-universheet": "workspace:^0.0.1",
"nanoid": "^4.0.0",
"preact": "^10.5.14"
diff --git a/packages/sheets-plugin-comment/package.json b/packages/sheets-plugin-comment/package.json
index b91a0c0a88..e02a68cf71 100644
--- a/packages/sheets-plugin-comment/package.json
+++ b/packages/sheets-plugin-comment/package.json
@@ -44,11 +44,11 @@
"vite-plugin-external": "1.2.3"
},
"dependencies": {
+ "@univer/base-component": "workspace:^0.0.1",
"@univer/base-render": "workspace:^0.0.1",
"@univer/base-sheets": "workspace:^0.0.1",
"@univer/common-plugin-data": "workspace:^0.0.1",
"@univer/core": "workspace:^0.0.1",
- "@univer/sheets-plugin-filter": "workspace:^0.0.1",
"@univer/style-universheet": "workspace:^0.0.1",
"preact": "^10.5.14"
}
diff --git a/packages/sheets-plugin-conditional-format/package.json b/packages/sheets-plugin-conditional-format/package.json
index 958a09ca66..26cb64e4d0 100644
--- a/packages/sheets-plugin-conditional-format/package.json
+++ b/packages/sheets-plugin-conditional-format/package.json
@@ -45,11 +45,11 @@
"vite-plugin-external": "1.2.3"
},
"dependencies": {
+ "@univer/base-component": "workspace:^0.0.1",
"@univer/base-render": "workspace:^0.0.1",
"@univer/base-sheets": "workspace:^0.0.1",
"@univer/common-plugin-data": "workspace:^0.0.1",
"@univer/core": "workspace:^0.0.1",
- "@univer/sheets-plugin-filter": "workspace:^0.0.1",
"@univer/style-universheet": "workspace:^0.0.1",
"preact": "^10.5.14"
}
diff --git a/packages/sheets-plugin-data-validation/package.json b/packages/sheets-plugin-data-validation/package.json
index 93eade7124..d0c2bf7792 100644
--- a/packages/sheets-plugin-data-validation/package.json
+++ b/packages/sheets-plugin-data-validation/package.json
@@ -45,11 +45,11 @@
"vite-plugin-external": "1.2.3"
},
"dependencies": {
+ "@univer/base-component": "workspace:^0.0.1",
"@univer/base-render": "workspace:^0.0.1",
"@univer/base-sheets": "workspace:^0.0.1",
"@univer/common-plugin-data": "workspace:^0.0.1",
"@univer/core": "workspace:^0.0.1",
- "@univer/sheets-plugin-filter": "workspace:^0.0.1",
"@univer/style-universheet": "workspace:^0.0.1",
"preact": "^10.5.14"
}
diff --git a/packages/sheets-plugin-filter/package.json b/packages/sheets-plugin-filter/package.json
index 4db25732ba..7bf1b1f032 100644
--- a/packages/sheets-plugin-filter/package.json
+++ b/packages/sheets-plugin-filter/package.json
@@ -41,11 +41,11 @@
"vite-plugin-external": "1.2.3"
},
"dependencies": {
+ "@univer/base-component": "workspace:^0.0.1",
"@univer/base-render": "workspace:^0.0.1",
"@univer/base-sheets": "workspace:^0.0.1",
"@univer/common-plugin-data": "workspace:^0.0.1",
"@univer/core": "workspace:^0.0.1",
- "@univer/sheets-plugin-conditional-format": "workspace:^0.0.1",
"@univer/style-universheet": "workspace:^0.0.1",
"nanoid": "^4.0.0",
"preact": "^10.5.14"
diff --git a/packages/sheets-plugin-find/package.json b/packages/sheets-plugin-find/package.json
index b3e549ce4e..6e0461f225 100644
--- a/packages/sheets-plugin-find/package.json
+++ b/packages/sheets-plugin-find/package.json
@@ -45,11 +45,11 @@
"vite-plugin-external": "1.2.3"
},
"dependencies": {
+ "@univer/base-component": "workspace:^0.0.1",
"@univer/base-render": "workspace:^0.0.1",
"@univer/base-sheets": "workspace:^0.0.1",
"@univer/common-plugin-data": "workspace:^0.0.1",
"@univer/core": "workspace:^0.0.1",
- "@univer/sheets-plugin-filter": "workspace:^0.0.1",
"@univer/style-universheet": "workspace:^0.0.1",
"preact": "^10.5.14"
}
diff --git a/packages/sheets-plugin-formula/package.json b/packages/sheets-plugin-formula/package.json
index d5487296cf..7ee10351ee 100644
--- a/packages/sheets-plugin-formula/package.json
+++ b/packages/sheets-plugin-formula/package.json
@@ -51,7 +51,6 @@
"@univer/base-sheets": "workspace:^0.0.1",
"@univer/common-plugin-data": "workspace:^0.0.1",
"@univer/core": "workspace:^0.0.1",
- "@univer/sheets-plugin-filter": "workspace:^0.0.1",
"@univer/style-universheet": "workspace:^0.0.1",
"css-vars-ponyfill": "^2.4.6",
"preact": "^10.5.14",
diff --git a/packages/sheets-plugin-freeze/package.json b/packages/sheets-plugin-freeze/package.json
index cadba6312c..d9fee2850e 100644
--- a/packages/sheets-plugin-freeze/package.json
+++ b/packages/sheets-plugin-freeze/package.json
@@ -44,11 +44,11 @@
"vite-plugin-external": "1.2.3"
},
"dependencies": {
+ "@univer/base-component": "workspace:^0.0.1",
"@univer/base-render": "workspace:^0.0.1",
"@univer/base-sheets": "workspace:^0.0.1",
"@univer/common-plugin-data": "workspace:^0.0.1",
"@univer/core": "workspace:^0.0.1",
- "@univer/sheets-plugin-filter": "workspace:^0.0.1",
"@univer/style-universheet": "workspace:^0.0.1",
"preact": "^10.5.14"
}
diff --git a/packages/sheets-plugin-group/package.json b/packages/sheets-plugin-group/package.json
index 62e4f0a949..ac5f4351bf 100644
--- a/packages/sheets-plugin-group/package.json
+++ b/packages/sheets-plugin-group/package.json
@@ -49,11 +49,11 @@
"vite": "^2.4.4"
},
"dependencies": {
+ "@univer/base-component": "workspace:^0.0.1",
"@univer/base-render": "workspace:^0.0.1",
"@univer/base-sheets": "workspace:^0.0.1",
"@univer/common-plugin-data": "workspace:^0.0.1",
"@univer/core": "workspace:^0.0.1",
- "@univer/sheets-plugin-filter": "workspace:^0.0.1",
"@univer/style-universheet": "workspace:^0.0.1",
"preact": "^10.5.14"
}
diff --git a/packages/sheets-plugin-image/package.json b/packages/sheets-plugin-image/package.json
index 535d8564e3..b829e6a30d 100644
--- a/packages/sheets-plugin-image/package.json
+++ b/packages/sheets-plugin-image/package.json
@@ -45,11 +45,11 @@
"vite-plugin-external": "1.2.3"
},
"dependencies": {
+ "@univer/base-component": "workspace:^0.0.1",
"@univer/base-render": "workspace:^0.0.1",
"@univer/base-sheets": "workspace:^0.0.1",
"@univer/common-plugin-data": "workspace:^0.0.1",
"@univer/core": "workspace:^0.0.1",
- "@univer/sheets-plugin-filter": "workspace:^0.0.1",
"@univer/style-universheet": "workspace:^0.0.1",
"preact": "^10.5.14"
}
diff --git a/packages/sheets-plugin-link/package.json b/packages/sheets-plugin-link/package.json
index 39f3b0627f..a142b56922 100644
--- a/packages/sheets-plugin-link/package.json
+++ b/packages/sheets-plugin-link/package.json
@@ -45,11 +45,11 @@
"vite-plugin-external": "1.2.3"
},
"dependencies": {
+ "@univer/base-component": "workspace:^0.0.1",
"@univer/base-render": "workspace:^0.0.1",
"@univer/base-sheets": "workspace:^0.0.1",
"@univer/common-plugin-data": "workspace:^0.0.1",
"@univer/core": "workspace:^0.0.1",
- "@univer/sheets-plugin-filter": "workspace:^0.0.1",
"@univer/style-universheet": "workspace:^0.0.1",
"preact": "^10.5.14"
}
diff --git a/packages/sheets-plugin-numfmt/package.json b/packages/sheets-plugin-numfmt/package.json
index bc00b5277a..9a52b021cc 100644
--- a/packages/sheets-plugin-numfmt/package.json
+++ b/packages/sheets-plugin-numfmt/package.json
@@ -51,6 +51,7 @@
"@univer/base-sheets": "workspace:^0.0.1",
"@univer/common-plugin-data": "workspace:^0.0.1",
"@univer/core": "workspace:^0.0.1",
+ "@univer/style-universheet": "workspace:^0.0.1",
"preact": "^10.5.14"
}
}
diff --git a/packages/sheets-plugin-pivot-table/package.json b/packages/sheets-plugin-pivot-table/package.json
index 8fb896704c..b7e2070508 100644
--- a/packages/sheets-plugin-pivot-table/package.json
+++ b/packages/sheets-plugin-pivot-table/package.json
@@ -44,11 +44,11 @@
"vite-plugin-external": "1.2.3"
},
"dependencies": {
+ "@univer/base-component": "workspace:^0.0.1",
"@univer/base-render": "workspace:^0.0.1",
"@univer/base-sheets": "workspace:^0.0.1",
"@univer/common-plugin-data": "workspace:^0.0.1",
"@univer/core": "workspace:^0.0.1",
- "@univer/sheets-plugin-filter": "workspace:^0.0.1",
"@univer/style-universheet": "workspace:^0.0.1",
"preact": "^10.5.14"
}
diff --git a/packages/sheets-plugin-print/package.json b/packages/sheets-plugin-print/package.json
index dbc21f55a5..34ae1176ed 100644
--- a/packages/sheets-plugin-print/package.json
+++ b/packages/sheets-plugin-print/package.json
@@ -44,11 +44,11 @@
"vite-plugin-external": "1.2.3"
},
"dependencies": {
+ "@univer/base-component": "workspace:^0.0.1",
"@univer/base-render": "workspace:^0.0.1",
"@univer/base-sheets": "workspace:^0.0.1",
"@univer/common-plugin-data": "workspace:^0.0.1",
"@univer/core": "workspace:^0.0.1",
- "@univer/sheets-plugin-filter": "workspace:^0.0.1",
"@univer/style-universheet": "workspace:^0.0.1",
"preact": "^10.5.14"
}
diff --git a/packages/sheets-plugin-protection/package.json b/packages/sheets-plugin-protection/package.json
index f11bb49da5..6155d97b71 100644
--- a/packages/sheets-plugin-protection/package.json
+++ b/packages/sheets-plugin-protection/package.json
@@ -44,11 +44,11 @@
"vite-plugin-external": "1.2.3"
},
"dependencies": {
+ "@univer/base-component": "workspace:^0.0.1",
"@univer/base-render": "workspace:^0.0.1",
"@univer/base-sheets": "workspace:^0.0.1",
"@univer/common-plugin-data": "workspace:^0.0.1",
"@univer/core": "workspace:^0.0.1",
- "@univer/sheets-plugin-filter": "workspace:^0.0.1",
"@univer/style-universheet": "workspace:^0.0.1",
"preact": "^10.5.14"
}
diff --git a/packages/sheets-plugin-screenshot/package.json b/packages/sheets-plugin-screenshot/package.json
index 37107f13fe..198b176912 100644
--- a/packages/sheets-plugin-screenshot/package.json
+++ b/packages/sheets-plugin-screenshot/package.json
@@ -45,11 +45,11 @@
"vite-plugin-external": "1.2.3"
},
"dependencies": {
+ "@univer/base-component": "workspace:^0.0.1",
"@univer/base-render": "workspace:^0.0.1",
"@univer/base-sheets": "workspace:^0.0.1",
"@univer/common-plugin-data": "workspace:^0.0.1",
"@univer/core": "workspace:^0.0.1",
- "@univer/sheets-plugin-filter": "workspace:^0.0.1",
"@univer/style-universheet": "workspace:^0.0.1",
"preact": "^10.5.14"
}
diff --git a/packages/sheets-plugin-sort/package.json b/packages/sheets-plugin-sort/package.json
index ae82688013..d93f872324 100644
--- a/packages/sheets-plugin-sort/package.json
+++ b/packages/sheets-plugin-sort/package.json
@@ -45,11 +45,11 @@
"vite-plugin-external": "1.2.3"
},
"dependencies": {
+ "@univer/base-component": "workspace:^0.0.1",
"@univer/base-render": "workspace:^0.0.1",
"@univer/base-sheets": "workspace:^0.0.1",
"@univer/common-plugin-data": "workspace:^0.0.1",
"@univer/core": "workspace:^0.0.1",
- "@univer/sheets-plugin-filter": "workspace:^0.0.1",
"@univer/style-universheet": "workspace:^0.0.1",
"preact": "^10.5.14"
}
diff --git a/packages/sheets-plugin-split-column/package.json b/packages/sheets-plugin-split-column/package.json
index 7bf5a904bc..819054c095 100644
--- a/packages/sheets-plugin-split-column/package.json
+++ b/packages/sheets-plugin-split-column/package.json
@@ -45,11 +45,11 @@
"vite-plugin-external": "1.2.3"
},
"dependencies": {
+ "@univer/base-component": "workspace:^0.0.1",
"@univer/base-render": "workspace:^0.0.1",
"@univer/base-sheets": "workspace:^0.0.1",
"@univer/common-plugin-data": "workspace:^0.0.1",
"@univer/core": "workspace:^0.0.1",
- "@univer/sheets-plugin-filter": "workspace:^0.0.1",
"@univer/style-universheet": "workspace:^0.0.1",
"preact": "^10.5.14"
}