add is_empty js method and made some change to make table editable cell more flexible