fix layout/js bug