-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcheck-table-width.html
More file actions
39 lines (35 loc) · 1.41 KB
/
check-table-width.html
File metadata and controls
39 lines (35 loc) · 1.41 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
<!DOCTYPE html>
<html>
<head>
<title>检查表格宽度</title>
<script>
// 在浏览器控制台运行这些命令来检查问题
console.log('=== 检查表格容器 ===');
// 1. 检查 dynamic-table 容器
const dynamicTable = document.querySelector('.dynamic-table');
console.log('dynamic-table:', {
width: dynamicTable?.offsetWidth,
scrollWidth: dynamicTable?.scrollWidth,
overflow: getComputedStyle(dynamicTable).overflow
});
// 2. 检查 arco-table-container
const tableContainer = document.querySelector('.arco-table-container');
console.log('arco-table-container:', {
width: tableContainer?.offsetWidth,
scrollWidth: tableContainer?.scrollWidth,
overflowX: getComputedStyle(tableContainer).overflowX
});
// 3. 检查表格本身
const table = document.querySelector('.arco-table');
console.log('arco-table:', {
width: table?.offsetWidth,
scrollWidth: table?.scrollWidth
});
// 4. 检查滚动配置
console.log('表格是否应该滚动:', tableContainer?.scrollWidth > tableContainer?.offsetWidth);
</script>
</head>
<body>
<p>请在浏览器中打开开发者工具(F12),然后在列表页面的控制台中粘贴上面的代码运行</p>
</body>
</html>