update style and js logic