(js) Improve autocomplete of attendees editor

This commit is contained in:
Francis Lachapelle committed 2015-06-12 12:05:07 -04:00
1 parent a95ed0f8e6
commit 290264262c
4 files changed
+49 -7

No files matched your search

+5
View File
@@ -149,6 +149,11 @@ Date.prototype.daysUpTo = function(otherDate) {
return days;
};
String.prototype.isValidEmail = function() {
var emailRE = /^([\w\!\#$\%\&\'\*\+\-\/\=\?\^\`{\|\}\~]+\.)*[\w\!\#$\%\&\'\*\+\-\/\=\?\^\`{\|\}\~]+@((((([a-z0-9]{1}[a-z0-9\-]{0,62}[a-z0-9]{1})|[a-z])\.)+[a-z]{2,})|(\d{1,3}\.){3}\d{1,3}(\:\d{1,5})?)$/i;
return emailRE.test(this);
};
String.prototype.asCSSIdentifier = function() {
var characters = [ '_' , '\\.', '#' , '@' , '\\*', ':' , ',' , ' '
, "'", '&', '\\+' ];