Skip to content

Commit 011f20e

Browse files
committed
Sticky column feature
1 parent 5dd9b3b commit 011f20e

File tree

4 files changed

+4
-2
lines changed

4 files changed

+4
-2
lines changed

dist/index.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -373,7 +373,7 @@
373373
this.columnCount = rows[0] && rows[0].props.children.length || 0;
374374

375375
if (rows.length) {
376-
if (this.stickyColumnCount > 0) {
376+
if (this.stickyColumnCount > 0 && this.stickyHeaderCount > 0) {
377377
stickyCorner = this.getStickyCorner(rows);
378378
}
379379
if (this.stickyColumnCount > 0) {

dist/react-sticky-table.css

+1
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
top: 0;
2020
z-index: 3;
2121
border-right: 2px solid #e5e5e5;
22+
border-bottom: 2px solid #e5e5e5;
2223
}
2324
.sticky-table .sticky-header {
2425
position: absolute;

src/index.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -329,7 +329,7 @@ class StickyTable extends Component {
329329
this.columnCount = (rows[0] && rows[0].props.children.length) || 0;
330330

331331
if (rows.length) {
332-
if (this.stickyColumnCount > 0) {
332+
if (this.stickyColumnCount > 0 && this.stickyHeaderCount > 0) {
333333
stickyCorner = this.getStickyCorner(rows);
334334
}
335335
if (this.stickyColumnCount > 0) {

src/sticky-table.css

+1
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
top: 0;
1111
z-index: 3;
1212
border-right: 2px solid #e5e5e5;
13+
border-bottom: 2px solid #e5e5e5;
1314
}
1415
.sticky-table .sticky-header {
1516
position: absolute;

0 commit comments

Comments
 (0)