Dunno if the condition would actually arise, but best to always protect against division by zero. e.g. do: 
`100/(rect.height || 1)`