Skip to content

Commit

Permalink
fix: resizable box overflow(unset) lead to table overflow
Browse files Browse the repository at this point in the history
  • Loading branch information
hemengke1997 committed Jan 4, 2023
1 parent 619bc25 commit 523a7fc
Show file tree
Hide file tree
Showing 21 changed files with 5,164 additions and 6,247 deletions.
1 change: 0 additions & 1 deletion .eslintignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
node_modules/
/dist
*.min.js
/example
/vite.config.ts
1 change: 0 additions & 1 deletion .prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,3 @@ LICENSE
.eslintcache
*.lock
yarn-error.log
/example
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
## 预览

![preview](./image/new_preview.gif)
![preview](./screenshots/new_preview.gif)

## 在线地址

Expand Down Expand Up @@ -70,13 +70,13 @@ function App() {

return (
<>
<Table columns={resizableColumns} components={components} dataSource={data} scroll={{ x: tableWidth }}></Table>
<Table columns={resizableColumns} components={components} dataSource={data} scroll={{ x: tableWidth }} />
<ProTable
columns={resizableColumns}
components={components}
dataSource={data}
scroll={{ x: tableWidth }}
></ProTable>
/>
<Button onClick={() => resetColumns()}>重置宽度</Button>
</>
)
Expand Down Expand Up @@ -290,7 +290,7 @@ function App() {
title: genEllipsis(item.title as string, false, true),
}))

return <ProTable columns={cols} components={components} scroll={{ x: tableWidth }} dataSource={dataSource}></ProTable>
return <ProTable columns={cols} components={components} scroll={{ x: tableWidth }} dataSource={dataSource} />
}
```

Expand Down
21 changes: 11 additions & 10 deletions example/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,21 +3,22 @@
"scripts": {
"dev": "vite",
"build": "tsc && vite build",
"serve": "vite preview"
"serve": "vite preview",
"upgrade:deps": "pnpm up -i --latest"
},
"dependencies": {
"@ant-design/pro-table": "^2.61.9",
"@ant-design/pro-table": "^3.2.9",
"@minko-fe/use-antd-resizable-header": "link:..",
"antd": "4.17.4",
"react": "^17.0.0",
"react-dom": "^17.0.0"
"antd": "5.1.2",
"react": "^18.2.0",
"react-dom": "^18.2.0"
},
"devDependencies": {
"@types/react": "^17.0.0",
"@types/react-dom": "^17.0.0",
"@vitejs/plugin-react-refresh": "^1.3.1",
"@types/react": "^18.0.26",
"@types/react-dom": "^18.0.10",
"@vitejs/plugin-react": "^3.0.0",
"less": "^4.1.1",
"typescript": "^4.3.2",
"vite": "^2.4.0"
"typescript": "^4.9.4",
"vite": "^4.0.4"
}
}
Loading

0 comments on commit 523a7fc

Please sign in to comment.