Updated JS to use data property for regex matching.
Added regex pattern for Name.