r102706 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r102705‎ | r102706 | r102707 >
Date:22:29, 10 November 2011
Author:yaron
Status:deferred
Tags:
Comment:
Removed bolding of search term within combobox - unnecessary, since the term already gets bolded by the standard autocompletion handling
Modified paths:
  • /trunk/extensions/SemanticForms/libs/SemanticForms.js (modified) (history)

Diff [purge]

Index: trunk/extensions/SemanticForms/libs/SemanticForms.js
@@ -29,8 +29,8 @@
3030 }
3131 }
3232
33 - /* extending jQuery functions for custom highlighting */
34 - jQuery.ui.autocomplete.prototype._renderItem = function( ul, item) {
 33+ /* extending jQuery functions for custom highlighting */
 34+ jQuery.ui.autocomplete.prototype._renderItem = function( ul, item) {
3535
3636 var re = new RegExp("(?![^&;]+;)(?!<[^<>]*)(" + this.term.replace(/([\^\$\(\)\[\]\{\}\*\.\+\?\|\\])/gi, "\\$1") + ")(?![^<>]*>)(?![^&;]+;)", "gi");
3737 var loc = item.label.search(re);
@@ -883,7 +883,7 @@
884884 if (this.value && (!request.term || matcher.test(text))) {
885885 return {
886886 id: this.value,
887 - label: text.replace(new RegExp("(?![^&;]+;)(?!<[^<>]*)(" + jQuery.ui.autocomplete.escapeRegex(request.term) + ")(?![^<>]*>)(?![^&;]+;)", "gi"), "<strong>$1</strong>"),
 887+ label: text,
888888 value: text
889889 };
890890 }