@alfalab/core-components-table 2.2.5 → 2.2.7
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/component.js +12 -14
- package/components/index.js +13 -15
- package/components/pagination/Component.js +8 -15
- package/components/pagination/index.css +8 -8
- package/components/pagination/index.js +4 -6
- package/components/pagination/select-field/index.css +4 -4
- package/components/pagination/select-field/index.js +4 -11
- package/components/table/Component.js +6 -13
- package/components/table/index.css +7 -7
- package/components/table/index.js +3 -5
- package/components/table/utils.js +4 -10
- package/components/table-context/index.js +1 -7
- package/components/tbody/Component.js +3 -10
- package/components/tbody/index.css +2 -2
- package/components/tbody/index.js +2 -4
- package/components/tcell/Component.js +3 -10
- package/components/tcell/index.css +6 -6
- package/components/tcell/index.js +2 -4
- package/components/texpandable-row/Component.js +5 -12
- package/components/texpandable-row/index.css +5 -5
- package/components/texpandable-row/index.js +2 -4
- package/components/thead/Component.js +4 -11
- package/components/thead/index.css +6 -6
- package/components/thead/index.js +2 -4
- package/components/thead-cell/Component.js +3 -10
- package/components/thead-cell/index.css +8 -8
- package/components/thead-cell/index.js +2 -4
- package/components/trow/Component.js +4 -11
- package/components/trow/index.css +8 -8
- package/components/trow/index.js +2 -4
- package/components/tsortable-head-cell/Component.js +6 -13
- package/components/tsortable-head-cell/index.css +9 -9
- package/components/tsortable-head-cell/index.js +3 -5
- package/components/tsortable-head-cell/sort-icon-asc.js +3 -9
- package/components/tsortable-head-cell/sort-icon-desc.js +3 -9
- package/components/tsortable-head-cell/sort-icon-unset.js +3 -9
- package/cssm/component.js +13 -15
- package/cssm/components/index.js +13 -15
- package/cssm/components/pagination/Component.js +8 -16
- package/cssm/components/pagination/index.js +4 -6
- package/cssm/components/pagination/select-field/index.js +3 -11
- package/cssm/components/table/Component.js +10 -18
- package/cssm/components/table/index.js +4 -6
- package/cssm/components/table/utils.js +5 -11
- package/cssm/components/table-context/index.js +1 -7
- package/cssm/components/tbody/Component.js +2 -10
- package/cssm/components/tbody/index.js +2 -4
- package/cssm/components/tcell/Component.js +2 -10
- package/cssm/components/tcell/index.js +2 -4
- package/cssm/components/texpandable-row/Component.js +7 -15
- package/cssm/components/texpandable-row/index.js +3 -5
- package/cssm/components/thead/Component.js +3 -11
- package/cssm/components/thead/index.js +2 -4
- package/cssm/components/thead-cell/Component.js +3 -11
- package/cssm/components/thead-cell/index.js +2 -4
- package/cssm/components/trow/Component.js +6 -14
- package/cssm/components/trow/index.js +2 -4
- package/cssm/components/tsortable-head-cell/Component.js +7 -15
- package/cssm/components/tsortable-head-cell/index.js +3 -5
- package/cssm/components/tsortable-head-cell/sort-icon-asc.js +3 -9
- package/cssm/components/tsortable-head-cell/sort-icon-desc.js +3 -9
- package/cssm/components/tsortable-head-cell/sort-icon-unset.js +3 -9
- package/cssm/index.js +13 -15
- package/cssm/{tslib.es6-9682e485.d.ts → tslib.es6-bbd6cd2a.d.ts} +0 -0
- package/cssm/{tslib.es6-9682e485.js → tslib.es6-bbd6cd2a.js} +0 -0
- package/cssm/utils.js +1 -7
- package/esm/component.js +12 -12
- package/esm/components/index.js +12 -12
- package/esm/components/pagination/Component.js +5 -5
- package/esm/components/pagination/index.css +8 -8
- package/esm/components/pagination/index.js +4 -4
- package/esm/components/pagination/select-field/index.css +4 -4
- package/esm/components/pagination/select-field/index.js +2 -2
- package/esm/components/table/Component.js +3 -3
- package/esm/components/table/index.css +7 -7
- package/esm/components/table/index.js +3 -3
- package/esm/components/table/utils.js +2 -2
- package/esm/components/tbody/Component.js +2 -2
- package/esm/components/tbody/index.css +2 -2
- package/esm/components/tbody/index.js +2 -2
- package/esm/components/tcell/Component.js +2 -2
- package/esm/components/tcell/index.css +6 -6
- package/esm/components/tcell/index.js +2 -2
- package/esm/components/texpandable-row/Component.js +2 -2
- package/esm/components/texpandable-row/index.css +5 -5
- package/esm/components/texpandable-row/index.js +2 -2
- package/esm/components/thead/Component.js +2 -2
- package/esm/components/thead/index.css +6 -6
- package/esm/components/thead/index.js +2 -2
- package/esm/components/thead-cell/Component.js +2 -2
- package/esm/components/thead-cell/index.css +8 -8
- package/esm/components/thead-cell/index.js +2 -2
- package/esm/components/trow/Component.js +2 -2
- package/esm/components/trow/index.css +8 -8
- package/esm/components/trow/index.js +2 -2
- package/esm/components/tsortable-head-cell/Component.js +3 -3
- package/esm/components/tsortable-head-cell/index.css +9 -9
- package/esm/components/tsortable-head-cell/index.js +3 -3
- package/esm/components/tsortable-head-cell/sort-icon-asc.js +1 -1
- package/esm/components/tsortable-head-cell/sort-icon-desc.js +1 -1
- package/esm/components/tsortable-head-cell/sort-icon-unset.js +1 -1
- package/esm/index.js +7 -7
- package/esm/{tslib.es6-eb63d7de.d.ts → tslib.es6-c7b61e8d.d.ts} +0 -0
- package/esm/{tslib.es6-eb63d7de.js → tslib.es6-c7b61e8d.js} +0 -0
- package/index.js +7 -9
- package/modern/component.js +11 -11
- package/modern/components/index.js +11 -11
- package/modern/components/pagination/Component.js +3 -3
- package/modern/components/pagination/index.css +8 -8
- package/modern/components/pagination/index.js +3 -3
- package/modern/components/pagination/select-field/index.css +4 -4
- package/modern/components/pagination/select-field/index.js +1 -1
- package/modern/components/table/Component.js +2 -2
- package/modern/components/table/index.css +7 -7
- package/modern/components/table/index.js +2 -2
- package/modern/components/table/utils.js +1 -1
- package/modern/components/tbody/Component.js +1 -1
- package/modern/components/tbody/index.css +2 -2
- package/modern/components/tbody/index.js +1 -1
- package/modern/components/tcell/Component.js +1 -1
- package/modern/components/tcell/index.css +6 -6
- package/modern/components/tcell/index.js +1 -1
- package/modern/components/texpandable-row/Component.js +1 -1
- package/modern/components/texpandable-row/index.css +5 -5
- package/modern/components/texpandable-row/index.js +1 -1
- package/modern/components/thead/Component.js +1 -1
- package/modern/components/thead/index.css +6 -6
- package/modern/components/thead/index.js +1 -1
- package/modern/components/thead-cell/Component.js +1 -1
- package/modern/components/thead-cell/index.css +8 -8
- package/modern/components/thead-cell/index.js +1 -1
- package/modern/components/trow/Component.js +1 -1
- package/modern/components/trow/index.css +8 -8
- package/modern/components/trow/index.js +1 -1
- package/modern/components/tsortable-head-cell/Component.js +2 -2
- package/modern/components/tsortable-head-cell/index.css +9 -9
- package/modern/components/tsortable-head-cell/index.js +2 -2
- package/modern/index.js +6 -6
- package/package.json +2 -2
- package/{tslib.es6-04e02981.d.ts → tslib.es6-73285132.d.ts} +0 -0
- package/{tslib.es6-04e02981.js → tslib.es6-73285132.js} +0 -0
- package/utils.js +1 -7
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: wsrqa */
|
|
2
2
|
:root {
|
|
3
3
|
--color-light-graphic-quaternary: #dbdee1;
|
|
4
4
|
}
|
|
@@ -13,12 +13,12 @@
|
|
|
13
13
|
:root {
|
|
14
14
|
--gap-xs: 8px;
|
|
15
15
|
}
|
|
16
|
-
.
|
|
16
|
+
.table__component_6t5yu {
|
|
17
17
|
position: relative;
|
|
18
18
|
width: 100%;
|
|
19
19
|
box-sizing: border-box
|
|
20
20
|
}
|
|
21
|
-
.
|
|
21
|
+
.table__component_6t5yu th:not(:last-child):not(:empty):after {
|
|
22
22
|
transition: opacity 0.2s;
|
|
23
23
|
position: absolute;
|
|
24
24
|
content: '';
|
|
@@ -30,12 +30,12 @@
|
|
|
30
30
|
bottom: var(--gap-xs);
|
|
31
31
|
background-color: var(--color-light-graphic-quaternary);
|
|
32
32
|
}
|
|
33
|
-
.
|
|
33
|
+
.table__component_6t5yu th:after {
|
|
34
34
|
opacity: 0;
|
|
35
35
|
}
|
|
36
|
-
.
|
|
36
|
+
.table__component_6t5yu:hover th:after {
|
|
37
37
|
opacity: 1;
|
|
38
38
|
}
|
|
39
|
-
.
|
|
39
|
+
.table__row_6t5yu {
|
|
40
40
|
height: 72px;
|
|
41
41
|
}
|
|
@@ -2,7 +2,7 @@ import React, { useContext } from 'react';
|
|
|
2
2
|
import cn from 'classnames';
|
|
3
3
|
import { TableContext } from '../table-context/index.js';
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
const styles = {"component":"table__component_1hrvb","sortable":"table__sortable_1hrvb","sorted":"table__sorted_1hrvb","stickyHeader":"table__stickyHeader_1hrvb","compactHorizontal":"table__compactHorizontal_1hrvb"};
|
|
6
6
|
require('./index.css')
|
|
7
7
|
|
|
8
8
|
const THeadCell = ({ children, className, dataTestId, style, width, textAlign, hidden, ...restProps }) => {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: r4ivk */
|
|
2
2
|
:root {
|
|
3
3
|
--color-light-bg-primary: #fff;
|
|
4
4
|
--color-light-border-primary: #dbdee1;
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
--gap-m: 16px;
|
|
19
19
|
--gap-2xl: 32px;
|
|
20
20
|
}
|
|
21
|
-
.
|
|
21
|
+
.table__component_1hrvb {
|
|
22
22
|
font-size: 12px;
|
|
23
23
|
line-height: 16px;
|
|
24
24
|
font-weight: 500;
|
|
@@ -35,26 +35,26 @@
|
|
|
35
35
|
vertical-align: top;
|
|
36
36
|
box-sizing: border-box
|
|
37
37
|
}
|
|
38
|
-
.
|
|
38
|
+
.table__component_1hrvb:first-child {
|
|
39
39
|
padding-left: var(--gap-m);
|
|
40
40
|
}
|
|
41
|
-
.
|
|
41
|
+
.table__component_1hrvb:last-child {
|
|
42
42
|
padding-right: var(--gap-m);
|
|
43
43
|
}
|
|
44
|
-
.
|
|
44
|
+
.table__sortable_1hrvb {
|
|
45
45
|
cursor: pointer;
|
|
46
46
|
}
|
|
47
|
-
.
|
|
47
|
+
.table__sorted_1hrvb {
|
|
48
48
|
color: var(--color-light-text-primary);
|
|
49
49
|
}
|
|
50
|
-
.
|
|
50
|
+
.table__stickyHeader_1hrvb {
|
|
51
51
|
top: 0;
|
|
52
52
|
position: sticky;
|
|
53
53
|
box-shadow: inset 0 -1px 0 0 rgba(11, 31, 53, 0.16);
|
|
54
54
|
border: none;
|
|
55
55
|
z-index: 1;
|
|
56
56
|
}
|
|
57
|
-
.
|
|
57
|
+
.table__compactHorizontal_1hrvb {
|
|
58
58
|
padding-left: 6px;
|
|
59
59
|
padding-right: 6px;
|
|
60
60
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import cn from 'classnames';
|
|
3
3
|
|
|
4
|
-
|
|
4
|
+
const styles = {"component":"table__component_10faw","withoutBorder":"table__withoutBorder_10faw","clickable":"table__clickable_10faw","selected":"table__selected_10faw"};
|
|
5
5
|
require('./index.css')
|
|
6
6
|
|
|
7
7
|
const TRow = ({ children, className, selected, withoutBorder, dataTestId, ...restProps }) => (React.createElement("tr", { className: cn(styles.component, className, {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: 1nbx5 */
|
|
2
2
|
:root {
|
|
3
3
|
--color-static-graphic-solitude: #e8f2fe;
|
|
4
4
|
}
|
|
@@ -14,28 +14,28 @@
|
|
|
14
14
|
|
|
15
15
|
/* Hard up */
|
|
16
16
|
}
|
|
17
|
-
.
|
|
17
|
+
.table__component_10faw {
|
|
18
18
|
padding-top: 1px;
|
|
19
19
|
width: 100%;
|
|
20
20
|
transition: background-color 0.2s;
|
|
21
21
|
box-sizing: border-box;
|
|
22
22
|
background: var(--color-light-bg-primary)
|
|
23
23
|
}
|
|
24
|
-
.
|
|
24
|
+
.table__component_10faw:first-child td {
|
|
25
25
|
border-top: 0;
|
|
26
26
|
}
|
|
27
|
-
.
|
|
27
|
+
.table__withoutBorder_10faw td {
|
|
28
28
|
border: none;
|
|
29
29
|
}
|
|
30
|
-
.
|
|
30
|
+
.table__clickable_10faw {
|
|
31
31
|
cursor: pointer
|
|
32
32
|
}
|
|
33
|
-
.
|
|
33
|
+
.table__clickable_10faw:hover {
|
|
34
34
|
background-color: var(--color-light-bg-secondary);
|
|
35
35
|
}
|
|
36
|
-
.
|
|
36
|
+
.table__selected_10faw {
|
|
37
37
|
background-color: #f2f8ff /* нет цвета в палитре */
|
|
38
38
|
}
|
|
39
|
-
.
|
|
39
|
+
.table__selected_10faw:hover {
|
|
40
40
|
background-color: var(--color-static-graphic-solitude);
|
|
41
41
|
}
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import React, { useMemo } from 'react';
|
|
2
2
|
import cn from 'classnames';
|
|
3
|
-
import '../table-context/index.js';
|
|
4
3
|
import { THeadCell } from '../thead-cell/Component.js';
|
|
5
4
|
import { SortIconAsc } from './sort-icon-asc.js';
|
|
6
5
|
import { SortIconDesc } from './sort-icon-desc.js';
|
|
7
6
|
import { SortIconUnset } from './sort-icon-unset.js';
|
|
7
|
+
import '../table-context/index.js';
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
const styles = {"component":"table__component_18935","content":"table__content_18935","icon":"table__icon_18935","reverse":"table__reverse_18935","sorted":"table__sorted_18935"};
|
|
10
10
|
require('./index.css')
|
|
11
11
|
|
|
12
12
|
const TSortableHeadCell = ({ children, className, defaultIsSortedDesc, isSortedDesc, textAlign, onSort, ...restProps }) => {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: rxqky */
|
|
2
2
|
:root {
|
|
3
3
|
--color-light-graphic-link: #007aff;
|
|
4
4
|
--color-light-graphic-primary: #0b1f35;
|
|
@@ -15,14 +15,14 @@
|
|
|
15
15
|
:root {
|
|
16
16
|
--gap-xs: 8px;
|
|
17
17
|
}
|
|
18
|
-
.
|
|
18
|
+
.table__component_18935 {
|
|
19
19
|
position: relative;
|
|
20
20
|
}
|
|
21
|
-
.
|
|
21
|
+
.table__content_18935 {
|
|
22
22
|
display: flex;
|
|
23
23
|
align-items: flex-start;
|
|
24
24
|
}
|
|
25
|
-
.
|
|
25
|
+
.table__icon_18935 {
|
|
26
26
|
cursor: pointer;
|
|
27
27
|
margin-left: var(--gap-xs);
|
|
28
28
|
|
|
@@ -35,19 +35,19 @@
|
|
|
35
35
|
transition: color 0.2s ease;
|
|
36
36
|
flex-shrink: 0
|
|
37
37
|
}
|
|
38
|
-
.
|
|
38
|
+
.table__icon_18935:hover {
|
|
39
39
|
color: var(--color-light-graphic-primary);
|
|
40
40
|
}
|
|
41
|
-
.
|
|
41
|
+
.table__reverse_18935 {
|
|
42
42
|
flex-direction: row-reverse
|
|
43
43
|
}
|
|
44
|
-
.
|
|
44
|
+
.table__reverse_18935 .table__icon_18935 {
|
|
45
45
|
margin-left: 0;
|
|
46
46
|
margin-right: var(--gap-xs);
|
|
47
47
|
}
|
|
48
|
-
.
|
|
48
|
+
.table__sorted_18935 {
|
|
49
49
|
color: var(--color-light-graphic-link)
|
|
50
50
|
}
|
|
51
|
-
.
|
|
51
|
+
.table__sorted_18935:hover {
|
|
52
52
|
color: var(--color-light-graphic-link);
|
|
53
53
|
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
+
export { TSortableHeadCell } from './Component.js';
|
|
1
2
|
import 'react';
|
|
2
3
|
import 'classnames';
|
|
3
|
-
import '../table-context/index.js';
|
|
4
4
|
import '../thead-cell/Component.js';
|
|
5
|
+
import '../table-context/index.js';
|
|
5
6
|
import './sort-icon-asc.js';
|
|
6
7
|
import './sort-icon-desc.js';
|
|
7
8
|
import './sort-icon-unset.js';
|
|
8
|
-
export { TSortableHeadCell } from './Component.js';
|
package/modern/index.js
CHANGED
|
@@ -1,22 +1,22 @@
|
|
|
1
|
+
export { Table } from './component.js';
|
|
2
|
+
import './components/table/Component.js';
|
|
1
3
|
import 'react';
|
|
2
4
|
import 'classnames';
|
|
3
5
|
import './components/table-context/index.js';
|
|
6
|
+
import './components/table/utils.js';
|
|
4
7
|
import './utils.js';
|
|
5
8
|
import './components/thead/Component.js';
|
|
6
|
-
import './components/
|
|
7
|
-
import './components/table/Component.js';
|
|
9
|
+
import './components/pagination/Component.js';
|
|
8
10
|
import '@alfalab/core-components-pagination/modern';
|
|
9
11
|
import '@alfalab/core-components-select/modern';
|
|
10
|
-
import '@alfalab/core-components-button/modern';
|
|
11
12
|
import './components/pagination/select-field/index.js';
|
|
12
|
-
import '
|
|
13
|
+
import '@alfalab/core-components-button/modern';
|
|
13
14
|
import './components/thead-cell/Component.js';
|
|
15
|
+
import './components/tsortable-head-cell/Component.js';
|
|
14
16
|
import './components/tsortable-head-cell/sort-icon-asc.js';
|
|
15
17
|
import './components/tsortable-head-cell/sort-icon-desc.js';
|
|
16
18
|
import './components/tsortable-head-cell/sort-icon-unset.js';
|
|
17
|
-
import './components/tsortable-head-cell/Component.js';
|
|
18
19
|
import './components/tbody/Component.js';
|
|
19
20
|
import './components/tcell/Component.js';
|
|
20
21
|
import './components/trow/Component.js';
|
|
21
22
|
import './components/texpandable-row/Component.js';
|
|
22
|
-
export { Table } from './component.js';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@alfalab/core-components-table",
|
|
3
|
-
"version": "2.2.
|
|
3
|
+
"version": "2.2.7",
|
|
4
4
|
"description": "",
|
|
5
5
|
"keywords": [],
|
|
6
6
|
"license": "MIT",
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
"dependencies": {
|
|
18
18
|
"@alfalab/core-components-button": "^7.0.1",
|
|
19
19
|
"@alfalab/core-components-pagination": "^2.0.7",
|
|
20
|
-
"@alfalab/core-components-select": "^13.2.
|
|
20
|
+
"@alfalab/core-components-select": "^13.2.2",
|
|
21
21
|
"classnames": "^2.3.1"
|
|
22
22
|
}
|
|
23
23
|
}
|
|
File without changes
|
|
File without changes
|
package/utils.js
CHANGED
|
@@ -1,16 +1,10 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
-
|
|
5
3
|
var React = require('react');
|
|
6
4
|
|
|
7
|
-
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
8
|
-
|
|
9
|
-
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
10
|
-
|
|
11
5
|
function isChildInstanceOf(child, Component) {
|
|
12
6
|
// мы не можем полагаться на child.type === Component, см. https://github.com/gaearon/react-hot-loader/issues/304
|
|
13
|
-
return child.type ===
|
|
7
|
+
return child.type === React.createElement(Component).type;
|
|
14
8
|
}
|
|
15
9
|
|
|
16
10
|
exports.isChildInstanceOf = isChildInstanceOf;
|