Commit 59336ee0 by Vik Paruchuri

Fix prompt hiding issue in peer grading

parent 48b0e570
...@@ -257,8 +257,6 @@ class @PeerGradingProblem ...@@ -257,8 +257,6 @@ class @PeerGradingProblem
$(window).keydown @keydown_handler $(window).keydown @keydown_handler
$(window).keyup @keyup_handler $(window).keyup @keyup_handler
@collapse_question()
Collapsible.setCollapsibles(@content_panel) Collapsible.setCollapsibles(@content_panel)
# Set up the click event handlers # Set up the click event handlers
...@@ -571,16 +569,17 @@ class @PeerGradingProblem ...@@ -571,16 +569,17 @@ class @PeerGradingProblem
@grading_message.fadeIn() @grading_message.fadeIn()
@grading_message.html("<p>" + msg + "</p>") @grading_message.html("<p>" + msg + "</p>")
collapse_question: () => collapse_question: (event) =>
@prompt_container.slideToggle() @prompt_container.slideToggle()
@prompt_container.toggleClass('open') @prompt_container.toggleClass('open')
if @question_header.text() == "(Hide)" if @question_header.text() == "Hide Prompt"
Logger.log 'peer_grading_hide_question', {location: @location} new_text = "Show Prompt"
new_text = "(Show)" Logger.log 'oe_hide_question', {location: @location}
else else
Logger.log 'peer_grading_show_question', {location: @location} Logger.log 'oe_show_question', {location: @location}
new_text = "(Hide)" new_text = "Hide Prompt"
@question_header.text(new_text) @question_header.text(new_text)
return false
scroll_to_top: () => scroll_to_top: () =>
$('html, body').animate({ $('html, body').animate({
......
...@@ -14,10 +14,10 @@ ...@@ -14,10 +14,10 @@
</div> </div>
<div class="prompt-wrapper"> <div class="prompt-wrapper">
<div class="visibility-control visibility-control-rubric"> <div class="visibility-control visibility-control-prompt">
<div class="inner"> <div class="inner">
</div> </div>
<span class="section-header section-header-rubric">${_('Hide Prompt')}</span> <a href="" class="section-header section-header-prompt question-header">${_('Hide Prompt')}</a>
</div> </div>
<div class="prompt-information-container"> <div class="prompt-information-container">
<section> <section>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment