fixed bug of closing node, and expanding canvas