Skip to content

Commit

Permalink
Allow HTML elements in popover title
Browse files Browse the repository at this point in the history
This is important as ordinals may have <sup>, like in French.

Also added the adjudicator's name as the title for their record popover.

Fixes #1691
  • Loading branch information
tienne-B committed Dec 21, 2020
1 parent 45c14d2 commit fc5c6cf
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion tabbycat/templates/tables/Popover.vue
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
<div class="popover bs-popover-bottom" role="tooltip" ref="popover"
v-show="showingPopOver" @mouseenter="hoveringPopOver = true" @mouseleave="hidePopOver">
<div class="popover-header d-flex">
<h6 class="flex-grow-1" v-if="cellData.title">{{ cellData.title }}</h6>
<h6 class="flex-grow-1" v-if="cellData.title" v-html="cellData.title"></h6>
<div class="popover-close" v-on:click="hidePopOver(true)" v-on:tap="hidePopOver(true)">
<i data-feather="x" class="hoverable text-danger"></i>
</div>
Expand Down
2 changes: 1 addition & 1 deletion tabbycat/utils/tables.py
Original file line number Diff line number Diff line change
Expand Up @@ -487,7 +487,7 @@ def add_adjudicator_columns(self, adjudicators, show_institutions=True,
else:
cell = {'text': adj.name}
if self._show_record_links:
cell['popover'] = {'content': [self._adjudicator_record_link(adj)]}
cell['popover'] = {'title': adj.name, 'content': [self._adjudicator_record_link(adj)]}
if subtext == 'institution' and adj.institution is not None:
cell['subtext'] = adj.institution.code
adj_data.append(cell)
Expand Down

0 comments on commit fc5c6cf

Please sign in to comment.