bloodhound-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Anze Staric <>
Subject Re: [REGRESSION] What should be italics is rendered as bold text WAS: svn commit: r1456892 - /incubator/bloodhound/trunk/bloodhound_theme/bhtheme/htdocs/bloodhound.css
Date Fri, 22 Mar 2013 09:24:54 GMT
The change was introduced in r1452190 with match highlighting in
search. The tag <em> was chosen as the tag to mark matches based on
the default choise of Solr (<em> for emphasis -

Css was modified to match the look of the google search results (bold
matches). As it only changes style inside elements marked as
searchable it was not supposed to break anything outside the search
results. I forgot to check whether the css class was used in other
contexts. The following patch replaces the name of the class marking
the search results that need to be highlighted.

--- bloodhound_theme/bhtheme/htdocs/bloodhound.css (revision 1459423)
+++ bloodhound_theme/bhtheme/htdocs/bloodhound.css (working copy)
@@ -476,7 +476,7 @@
  text-decoration: underline;

-.searchable em {
+.highlight_matches em {
  font-style: inherit;
  font-weight: bold;
Index: bloodhound_search/bhsearch/templates/bhsearch.html
--- bloodhound_search/bhsearch/templates/bhsearch.html (revision 1459423)
+++ bloodhound_search/bhsearch/templates/bhsearch.html (working copy)
@@ -126,7 +126,7 @@
                       <tr class="${'odd' if idx % 2 else 'even'}
                         ' added' if 'added' in result else ''}${
                         ' changed' if 'changed' in result else ''}${
-                        ' removed' if 'removed' in result else ''} searchable">
+                        ' removed' if 'removed' in result else ''}
                         <py:for each="idx, header in
enumerate(headers)" py:choose="">
                           <py:with vars="name =; value =
result[name]; hilited_value=result['hilited_' + name]; title = _('View
')+ result['type']">
                             <td py:when="name == 'id'" class="id"><a
href="$result.href" title="${title}"
@@ -154,8 +154,8 @@
                 <!--Rendering results in free form-->
                 <dl id="results">
                   <py:for each="result in results">
-                    <dt><a href="${result.href}"
-                    <dd class="searchable">${result.hilited_content
or result.content}</dd>
+                    <dt><a href="${result.href}"
+                    <dd
class="highlight_matches">${result.hilited_content or
                       <py:if test=""><span
class="author" i18n:msg="author">By
${format_author(}</span> &mdash;</py:if>
                       <span class="date">${}</span>


View raw message