Skip to content

Commit 9efee19

Browse files
committed
🐛 Fixed previous commit
1 parent a91ab17 commit 9efee19

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@ This fork added/fixed:
1919
- Fixed input loses focus
2020
- Added debounce
2121
- Fixed dispatch
22-
- Added `align` prop
23-
- Added `headerAlign` prop to override default header cell 'center' text-align
22+
- Added `align` col config
23+
- Added `headerAlign` col config to override default header cell 'center' text-align
2424
- Lighter border colors
2525
- Added `onCellUpdate` and `onHeaderUpdate` (see usage below)
2626

src/index.svelte

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1015,6 +1015,7 @@
10151015
left: {getCellLeft({ i, columnWidths, __affixedColumnIndices, __scrollLeft })}px;
10161016
height: {rowHeight}px; line-height: {rowHeight}px;
10171017
width: {(i===columnWidths.length-1 ? lastColWidth+1 : columnWidths[i])+'px'};
1018+
text-align: {column.headerAlign || 'center'};
10181019
{allowColumnReordering ? 'cursor:pointer;' : ''}"
10191020
title={column.display || ''}
10201021
role="columnheader">
@@ -1079,8 +1080,7 @@
10791080
__affixedColumnIndices,
10801081
__scrollLeft
10811082
}) - Math.floor(__columnHeaderResizeCaptureWidth / 2)}px;
1082-
width: {__columnHeaderResizeCaptureWidth}px;
1083-
text-align: {column.headerAlign || 'center'};"
1083+
width: {__columnHeaderResizeCaptureWidth}px;"
10841084
on:mousedown={event => onColumnResizeStart(event, i)} />
10851085
{/if}
10861086
{/each}

0 commit comments

Comments
 (0)