@apify/ui-library 1.157.3 → 1.158.0
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.
- package/dist/components/table/table.styled.d.ts.map +1 -1
- package/dist/components/table/table.styled.js +4 -2
- package/dist/components/table/table_loading_row.d.ts.map +1 -1
- package/dist/components/table/table_loading_row.js +8 -2
- package/dist/files_hash_at_build.txt +1 -1
- package/dist/src/components/table/table.styled.d.ts.map +1 -1
- package/dist/src/components/table/table.styled.js +4 -2
- package/dist/src/components/table/table.styled.js.map +1 -1
- package/dist/src/components/table/table_loading_row.d.ts.map +1 -1
- package/dist/src/components/table/table_loading_row.js +8 -2
- package/dist/src/components/table/table_loading_row.js.map +1 -1
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +2 -2
- package/src/components/table/table.styled.ts +4 -2
- package/src/components/table/table_loading_row.tsx +9 -2
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@apify/ui-library",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.158.0",
|
|
4
4
|
"description": "React UI library used by apify.com",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"type": "module",
|
|
@@ -95,5 +95,5 @@
|
|
|
95
95
|
"src",
|
|
96
96
|
"style"
|
|
97
97
|
],
|
|
98
|
-
"gitHead": "
|
|
98
|
+
"gitHead": "a95d2c32be1c155877006b808c4cf292d4c64806"
|
|
99
99
|
}
|
|
@@ -75,6 +75,8 @@ export const StyledTable = styled.table`
|
|
|
75
75
|
background-color: ${theme.color.neutral.backgroundMuted};
|
|
76
76
|
border-bottom: solid 1px ${theme.color.neutral.separatorSubtle};
|
|
77
77
|
color: ${theme.color.neutral.textMuted};
|
|
78
|
+
/* Same size the SortLabel button sets for itself, so plain and sortable headers match. */
|
|
79
|
+
${theme.typography.shared.desktop.bodyS};
|
|
78
80
|
}
|
|
79
81
|
|
|
80
82
|
/* Body styling */
|
|
@@ -144,10 +146,10 @@ export const StyledTable = styled.table`
|
|
|
144
146
|
}
|
|
145
147
|
}
|
|
146
148
|
|
|
147
|
-
/* Empty row
|
|
149
|
+
/* Empty row. Keeps the padding every other cell has; the content (spinner, empty state) brings
|
|
150
|
+
its own vertical space, the same way the old table did. */
|
|
148
151
|
.${tableClassNames.ROW_EMPTY_CELL} {
|
|
149
152
|
text-align: center;
|
|
150
|
-
padding: ${theme.space.space16};
|
|
151
153
|
}
|
|
152
154
|
`;
|
|
153
155
|
|
|
@@ -1,13 +1,20 @@
|
|
|
1
1
|
import type { FC, ReactNode } from 'react';
|
|
2
|
+
import styled from 'styled-components';
|
|
2
3
|
|
|
3
|
-
import {
|
|
4
|
+
import { theme } from '../../design_system/theme';
|
|
5
|
+
import { BlockSpinner } from '../spinner';
|
|
4
6
|
import { tableClassNames } from './table.styled';
|
|
5
7
|
import { tableTestIds } from './table.test_ids';
|
|
6
8
|
|
|
9
|
+
/** `BlockSpinner` defaults to an 8rem box, which is taller than a table row needs. */
|
|
10
|
+
const RowSpinner = styled(BlockSpinner)`
|
|
11
|
+
min-height: ${theme.space.space40};
|
|
12
|
+
`;
|
|
13
|
+
|
|
7
14
|
export const TableLoadingRow: FC<{ colSpan: number; children?: ReactNode }> = ({ colSpan, children }) => (
|
|
8
15
|
<tr data-test={tableTestIds.LOADING_ROW} className={tableClassNames.ROW_EMPTY}>
|
|
9
16
|
<td colSpan={colSpan} className={tableClassNames.ROW_EMPTY_CELL}>
|
|
10
|
-
{children ?? <
|
|
17
|
+
{children ?? <RowSpinner small />}
|
|
11
18
|
</td>
|
|
12
19
|
</tr>
|
|
13
20
|
);
|