fix(market-depth): orderbook row height calculation (#3068)
This commit is contained in:
parent
7b8d814724
commit
a65ee358ff
@ -88,9 +88,9 @@ const getRowsToRender = (
|
|||||||
return selectedRows;
|
return selectedRows;
|
||||||
};
|
};
|
||||||
|
|
||||||
// 17px of row height plus 5px gap
|
// 17px of row height plus 4px gap
|
||||||
export const gridGap = 5;
|
export const gridGap = 4;
|
||||||
export const rowHeight = 22;
|
export const rowHeight = 21;
|
||||||
// top padding to make space for header
|
// top padding to make space for header
|
||||||
const headerPadding = 30;
|
const headerPadding = 30;
|
||||||
// bottom padding to make space for footer
|
// bottom padding to make space for footer
|
||||||
@ -393,7 +393,8 @@ export const Orderbook = ({
|
|||||||
numberOfRows * rowHeight +
|
numberOfRows * rowHeight +
|
||||||
headerPadding +
|
headerPadding +
|
||||||
footerPadding +
|
footerPadding +
|
||||||
-viewportHeight
|
-viewportHeight -
|
||||||
|
gridGap
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
if (scrollTopRef.current !== priceCenterScrollOffset) {
|
if (scrollTopRef.current !== priceCenterScrollOffset) {
|
||||||
|
Loading…
Reference in New Issue
Block a user