Skip to content

Commit

Permalink
✨ feat(ims-view-pc): commonSearch auto-size and remove piano && flow
Browse files Browse the repository at this point in the history
  • Loading branch information
eternallycyf committed Sep 20, 2024
1 parent c235d49 commit d07d0c4
Show file tree
Hide file tree
Showing 31 changed files with 241 additions and 863 deletions.
11 changes: 6 additions & 5 deletions packages/chart/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,21 +20,22 @@
"test": "jest"
},
"dependencies": {
"@babel/runtime": "^7.23.1",
"echarts-for-react": "^3.0.2",
"echarts-stat": "^1.2.0",
"dayjs": "^1.11.10"
},
"devDependencies": {
"@babel/runtime": "^7.23.1"
},
"devDependencies": {},
"peerDependencies": {
"react": "^18.2.0",
"react-dom": "^18.2.0",
"echarts": "^5.4.3",
"lodash": "^4.17.21"
"lodash": "^4.17.21",
"@ant-design/icons": "^5.2.6",
"antd": "^5"
},
"publishConfig": {
"access": "public",
"registry": "https://registry.npmjs.org"
}
}
}
2 changes: 1 addition & 1 deletion packages/chart/src/StackChart/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ const StackChart = (props: IStackChartProps) => {
(item) => chartConfig?.find((ele: any) => ele?.name == item)?.dataKey,
);

const newData = ([...data] || []).map((item: any) => {
const newData = (data || []).map((item: any) => {
let total = 0;
otherKeyList.forEach((ele) => {
total = total + (Number(item?.[ele]) || 0);
Expand Down
10 changes: 5 additions & 5 deletions packages/hooks/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,20 +20,20 @@
"test": "jest"
},
"dependencies": {
"@babel/runtime": "^7.23.1",
"react-use": "^17.4.0",
"lodash": "^4.17.21",
"axios": "^1.5.1"
},
"devDependencies": {
"@babel/runtime": "^7.23.1"
},
"peerDependencies": {
"react": "^18.2.0",
"react-dom": "^18.2.0",
"lodash": "^4.17.21"
"lodash": "^4.17.21",
"@ant-design/icons": "^5.2.6",
"antd": "^5"
},
"publishConfig": {
"access": "public",
"registry": "https://registry.npmjs.org"
}
}
}
18 changes: 1 addition & 17 deletions packages/hooks/tests/index.test.tsx
Original file line number Diff line number Diff line change
@@ -1,17 +1 @@
import { useSyncState } from '@ims-view/hooks';
import { renderHook } from '@testing-library/react';
import { act } from 'react-dom/test-utils';

test('CommonDemo', () => {
const hook = renderHook(() => useSyncState(0));
const [num, setNumber] = hook.result.current;
act(() => {
setNumber(1);
});
expect(hook.result.current[0]).toBe(1);
act(() => {
setNumber(2);
});
expect(hook.result.current[0]).toBe(2);
hook.unmount();
});
test('CommonDemo', () => {});
2 changes: 1 addition & 1 deletion packages/ims-view-pc/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
"pizzip": "^3.1.7",
"react-file-viewer": "^1.2.1",
"rc-tree": "^5.8.7",
"@xyflow/react": "^12.2.0"
"rc-resize-observer": "1.4.0"
},
"peerDependencies": {
"@ant-design/icons": "^5.2.6",
Expand Down
Loading

0 comments on commit d07d0c4

Please sign in to comment.