venus-design 0.2.1 → 0.2.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -260,11 +260,11 @@ export var getUmi = function getUmi() {
260
260
  var umiData;
261
261
  try {
262
262
  // 尝试从 @umijs/max 中引入 history
263
- //umiData = require('@umijs/max');
263
+ umiData = require('@umijs/max');
264
264
  } catch (e) {
265
265
  try {
266
266
  // 如果失败,尝试从 umi 中引入 history
267
- //umiData = require('umi');
267
+ umiData = require('umi');
268
268
  } catch (e) {
269
269
  // 如果都失败,可以考虑使用其他方式创建 history 或抛出错误
270
270
  console.warn('无法找到 umi 模块。请确保你的项目中安装了 @umijs/max 或 umi。');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "venus-design",
3
- "version": "0.2.1",
3
+ "version": "0.2.2",
4
4
  "description": "venus all compoments",
5
5
  "module": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -50,6 +50,10 @@
50
50
  "publishConfig": {
51
51
  "access": "public"
52
52
  },
53
+ "optionalDependencies": {
54
+ "@umijs/max": "^4.4.4",
55
+ "umi": "^3.5.0"
56
+ },
53
57
  "peerDependencies": {
54
58
  "@ant-design/icons": "^4.8.3 ||^5.6.1",
55
59
  "@ant-design/cssinjs": "^1.5.6",
@@ -90,6 +94,7 @@
90
94
  "@types/react-loadable": "^5.5.11",
91
95
  "@types/react-resizable": "^3.0.3",
92
96
  "@umijs/lint": "^4.0.0",
97
+ "@umijs/max": "^4.4.4",
93
98
  "antd": "^4.6.4 || ^5.23.4",
94
99
  "babel-plugin-import": "^1.13.8",
95
100
  "classnames": "^2.2.6",