Skip to content

Commit

Permalink
Increased specificity on annotate.show()/hide() to prevent hiding
Browse files Browse the repository at this point in the history
the HeadingsPlugin summary levels
  • Loading branch information
jdan committed Sep 7, 2015
1 parent 2214484 commit 2f6d9d6
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
4 changes: 2 additions & 2 deletions plugins/shared/annotate/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -169,11 +169,11 @@ module.exports = (namespace) => {
},

hide() {
$(".tota11y-label").hide();
$(".tota11y.tota11y-label").hide();
},

show() {
$(".tota11y-label").show();
$(".tota11y.tota11y-label").show();
},

removeAll() {
Expand Down
4 changes: 1 addition & 3 deletions plugins/shared/info-panel/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -194,13 +194,11 @@ class InfoPanel {
$activeTab = this._addTab("Summary", this.summary);
}

// Wire annotation toggling.
// Wire annotation toggling
this.$el.find(".toggle-annotation").click((e) => {
if ($(e.target).prop("checked")) {
// Showing annotations.
annotate.show();
} else {
// Hiding annotations.
annotate.hide();
}
});
Expand Down

0 comments on commit 2f6d9d6

Please sign in to comment.