Skip to content

Commit

Permalink
test: remove default _disableColumnAndRowSizeRound config
Browse files Browse the repository at this point in the history
  • Loading branch information
Rui-Sun committed May 13, 2024
1 parent f1ca7cd commit 3ccc017
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions packages/vtable/src/core/BaseTable.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1011,7 +1011,7 @@ export abstract class BaseTable extends EventTarget implements BaseTableAPI {
// : this.internalProps.defaultRowHeight)
// );
if (isValid(this.rowHeightsMap.get(row))) {
if (this.options._disableColumnAndRowSizeRound ?? true) {
if (this.options._disableColumnAndRowSizeRound) {
const height = this.rowHeightsMap.get(row);
let heightRange;
if (row < this.frozenRowCount) {
Expand Down Expand Up @@ -1129,7 +1129,7 @@ export abstract class BaseTable extends EventTarget implements BaseTableAPI {
h += this.getRowHeight(i);
}
} else {
if (this.options._disableColumnAndRowSizeRound ?? true) {
if (this.options._disableColumnAndRowSizeRound) {
// for (let i = startRow; i <= endRow; i++) {
// h += this.getRowHeight(i);
// }
Expand Down Expand Up @@ -1263,7 +1263,8 @@ export abstract class BaseTable extends EventTarget implements BaseTableAPI {
_setColWidth(col: number, width: string | number, clearCache?: boolean, skipCheckFrozen?: boolean): void {
this.colWidthsMap.put(
col,
typeof width === 'number' ? (this.options._disableColumnAndRowSizeRound ? width : Math.round(width)) : width
// typeof width === 'number' ? (this.options._disableColumnAndRowSizeRound ? width : Math.round(width)) : width
typeof width === 'number' ? Math.round(width) : width
);
// 清楚影响缓存
if (clearCache) {
Expand Down

0 comments on commit 3ccc017

Please sign in to comment.