Skip to content

Commit

Permalink
chore: small code refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
ghiscoding committed Mar 15, 2021
1 parent 2fa8ba5 commit 9624426
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/vanilla-bundle/src/services/resizer.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -67,11 +67,11 @@ export class ResizerService {
this._grid = grid;
const fixedGridDimensions = (this.gridOptions?.gridHeight || this.gridOptions?.gridWidth) ? { height: this.gridOptions?.gridHeight, width: this.gridOptions?.gridWidth } : undefined;
const autoResizeOptions = this.gridOptions?.autoResize ?? { bottomPadding: 0 };
if (autoResizeOptions && autoResizeOptions.bottomPadding !== undefined && this.gridOptions.showCustomFooter) {
if (autoResizeOptions?.bottomPadding !== undefined && this.gridOptions.showCustomFooter) {
const footerHeight: string | number = this.gridOptions?.customFooterOptions?.footerHeight ?? DATAGRID_FOOTER_HEIGHT;
autoResizeOptions.bottomPadding += parseInt(`${footerHeight}`, 10);
}
if (autoResizeOptions && autoResizeOptions.bottomPadding !== undefined && this.gridOptions.enablePagination) {
if (autoResizeOptions?.bottomPadding !== undefined && this.gridOptions.enablePagination) {
autoResizeOptions.bottomPadding += DATAGRID_PAGINATION_HEIGHT;
}
if (fixedGridDimensions?.width && gridParentContainerElm?.style) {
Expand Down

0 comments on commit 9624426

Please sign in to comment.