Skip to content

Commit

Permalink
Warning
Browse files Browse the repository at this point in the history
  • Loading branch information
actiniumn404 committed Jul 7, 2024
1 parent 07e93c2 commit fec0a0c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion website/static/css/suggestions.css
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ main{
display: flex;
flex-direction: column;
row-gap: 10px;
word-break: break-all;
word-break: break-word;
}

.result h1{
Expand Down
6 changes: 5 additions & 1 deletion website/static/js/suggestions.js
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,13 @@ const render_suggestion = async (name) => {
document.querySelector("#detail__response").setAttribute("data-content", suggestion.response || "<No Response Given>")
document.querySelector("#detail__response").innerText = suggestion.response || "<No Response Given>"

document.querySelector("#focused_question").innerHTML = format_question(get_question_by_ID(suggestion.question_id), new Set(Stars), suggestion.response)
let quest = get_question_by_ID(suggestion.question_id)
document.querySelector("#focused_question").innerHTML = format_question(quest, new Set(Stars), suggestion.response)
await apply_question_callbacks()

document.querySelector(".warning").style.display =
(quest.category !== suggestion.subject || quest.tossup_question !== suggestion.question ? "block" : "none")

document.querySelector("#discussion_messages").innerHTML = ""

for (let message of suggestion.discussion){
Expand Down

0 comments on commit fec0a0c

Please sign in to comment.