[cmd:resize] JavaScript syntax strictly
[cmd:resize] fix preview window problem (synchronize with textbox)