Fixed issue #1 & #2

[#1] reset style when modal reopens + getting default value from input
[#2]type ahead implementation, can be further optimized to neglect
missed spaces.