Fast interactive hall layout on canvas

Fast interactive hall layout on canvas  
We are developing a library for displaying large interactive schemes of halls on canvas without frameworks and making it work well in ie and mobile devices. Along the way, we understand the peculiarities of canvas.
demo , so it will be clearer than what it's about.
In the article I will insert only small parts of the code, the rest can be viewed at
Remember that canvas is essentially a picture with api, so handling hoverers and clicks on our conscience: you need to count the coordinates yourself, taking into account the scale and scroll, to search for objects by their coordinates...