perf : code converted into set of functions and more readable code added
perf : code converted into set of functions and more readable code added

ritz078/ngEmoticons,ritz078/ngEmbed,ritz078/ngEmoticons,ritz078/ngEmbed,ritz078/ng-embed