angular2-grid icon indicating copy to clipboard operation
angular2-grid copied to clipboard

Margin affect the col-widt/row-height

Open ghost opened this issue 9 years ago • 1 comments

Hi,

either im configuring wrong or understanding something wrong. my configuration: image image this is ok but by increasing the margin to one the with increases by 3: image

some ideas?

ghost avatar Oct 11 '16 13:10 ghost

Yeah, that's correct. For every width 1 row that you have, adding a margin of 1 makes the total row width 1. That's because the smallest row would be 1px wide with a 1px margin either side. So when the item width gets calculated it's (width * rowCount) + ((marginLeft + marginRight) * (rowCount - 1)). Does that make sense?

BTMorton avatar Nov 27 '16 13:11 BTMorton