I have an app for scheduling for out homeschooling. I use floating divs to represent various events in a column for each child and for each day. I found that I can set the height of each div such that one hour is 5.55% of the total height of the containing div.
style="height:5.55%;"
So I thought to represent the time between events using margin-top. So 30 minutes of free time could be represented this way:
style="height:5.55%;margin-top:2.78%"
But margin-top is calculated based on the width of the element. I was surprised by this inconsistency. The logic which determines that an element's height should be calculated based on the height of the containing element should also be applied to margin-top.
Does this make sense?
And how would one propose a change to the calculation of margin-top based on percent?
Can it even be changed?