From fa5b02a767bde4e1836f828613e568cef01ced58 Mon Sep 17 00:00:00 2001
From: Florian Aucomte <33633200+faucomte97@users.noreply.github.com>
Date: Fri, 3 Nov 2023 15:51:46 +0000
Subject: [PATCH] fix: While loop final checks (#1513)
* fix: Rename level 109 and make popup buttons match styles
* Grey out coming soon episodes
* Merge branch 'master' into while_loop_final_checks
* Lighter grey and fix typo
* Merge remote-tracking branch 'origin/while_loop_final_checks' into while_loop_final_checks
* Remove chevron
* Merge branch 'master' into while_loop_final_checks
---
game/messages.py | 6 ++--
game/static/game/css/backgrounds.css | 4 +++
game/static/game/css/level_selection.css | 4 +--
game/static/game/js/drawing.js | 35 ++++++++++++++++++------
game/templates/game/level_selection.html | 13 ++++++---
5 files changed, 45 insertions(+), 17 deletions(-)
diff --git a/game/messages.py b/game/messages.py
index 2a074c645..4f83244f7 100644
--- a/game/messages.py
+++ b/game/messages.py
@@ -2339,12 +2339,12 @@ def hint_level108():
def title_level109():
- return "Final challenge!"
+ return "Spiral challenge!"
def description_level109():
message = (
- "For the last challenge, the road straight line sections of road start off increasing "
+ "For this challenge, the road straight line sections of road start off increasing "
"by 1 after each turn and then switch to dividing by 2 with a twist!"
)
return build_description(title_level109(), message)
@@ -2458,7 +2458,7 @@ def hint_level109():
lambda: "Wiggle while you work",
lambda: build_description(
title_level117(),
- "This time is's a little harder. We've added the directions back in."
+ "This time it's a little harder. We've added the directions back in."
"
"
"Can you put them in the right place?"
"
"
diff --git a/game/static/game/css/backgrounds.css b/game/static/game/css/backgrounds.css
index 05c3c315b..b661f5e86 100644
--- a/game/static/game/css/backgrounds.css
+++ b/game/static/game/css/backgrounds.css
@@ -31,3 +31,7 @@
.bg--loops {
background: #3F3F3F;
}
+
+.bg--loops-coming-soon {
+ background: #CBCBCB;
+}
diff --git a/game/static/game/css/level_selection.css b/game/static/game/css/level_selection.css
index 62e11de1f..a0aefee4a 100644
--- a/game/static/game/css/level_selection.css
+++ b/game/static/game/css/level_selection.css
@@ -73,13 +73,13 @@
margin-left: 15px;
}
-#episodes .collapsed.episode_range_text::after {
+#episodes .panel-header:not(.bg--loops-coming-soon) .collapsed.episode_range_text::after {
content: "\e250";
font-family: "Glyphicons Halflings";
margin-left: 10px;
}
-#episodes .episode_range_text::after {
+#episodes .panel-header:not(.bg--loops-coming-soon) .episode_range_text::after {
content: "\e252";
font-family: "Glyphicons Halflings";
margin-left: 10px;
diff --git a/game/static/game/js/drawing.js b/game/static/game/js/drawing.js
index 2a2938c84..e25e40f9e 100644
--- a/game/static/game/js/drawing.js
+++ b/game/static/game/js/drawing.js
@@ -1050,16 +1050,20 @@ ocargo.Drawing.startPopup = function (
if (youtubeVideo[0]) {
$("#modal-mascot").hide()
}
+
+ // create a wrapper for the buttons that will be appended
+ let buttonDiv = $("
{{episode.name}}
@@ -307,4 +312,4 @@ Owned by {{ teacher|make_into_username }}
{% endif %}