added inside logics & ui improvement