User:Ohconfucius/script/formatgeneral.js: Difference between revisions

Content deleted Content added
fix bug in INRconvert
disabled the space removal following request BY User:Mike Christie
Line 296:
regex(/(\w)[‘’′](s|t)\b/gi, '$1\'$2'); // in-word replacement of various single quotes and prime symbol with straight apostrophe
// regex(/(.)[‘`´’](.)/gi, '$1\'$2'); // straight apostrophe (won't touch prime symbol here)
// regex(/([\w;,\]\)>] ) +([\[(]|[a-z\d])/gi, '$1$2'); //rem multiple spaces except when preceded by full stop; tweaked to not remove dbl spaces where preceded by new sentence (caps) //disabled the space removal following request
regex(/(^\.U\.)[ ]+((?:S|K)\.)/gi, '$1$2'); //U. S. and U. K. to U.S. and U.K.
regex(/(<\/?ref(?: name=[^<>\/]*?|)>)[ ,\.]*(<ref)/gi, '$1$2'); // remove punctuation between ref tags