Closured-based HTML editor