a bug when switch to record state if the inputed text is more than 2 lines