diff --git a/app/src/apps/Examinations/Lab.svelte b/app/src/apps/Examinations/Lab.svelte
index f6d8d5d3..8907c939 100644
--- a/app/src/apps/Examinations/Lab.svelte
+++ b/app/src/apps/Examinations/Lab.svelte
@@ -3,6 +3,7 @@
import { mathjaxLoad, mathjaxTypeset } from "../../utilities";
import { Question } from "./components";
import { Button } from "../../components";
+ import { LoadingAnimation } from "../../components/LoadingAnimation";
import Lab from "./lib/examinations/Lab";
export let data;
@@ -45,8 +46,7 @@
on:update={updateLab}
/>
{:else}
-
-
Loading...
+
{/if}
diff --git a/app/src/apps/Examinations/components/Question/Question.svelte b/app/src/apps/Examinations/components/Question/Question.svelte
index b25b578e..fb3dd2fc 100644
--- a/app/src/apps/Examinations/components/Question/Question.svelte
+++ b/app/src/apps/Examinations/components/Question/Question.svelte
@@ -46,3 +46,9 @@
on:update={updateExamination}
/>
{/if}
+
+{#if typeof question.labId !== "undefined"}
+ Go to the associated Lab!
+{/if}
diff --git a/app/src/apps/Examinations/components/WrittenQuestion/styles.scss b/app/src/apps/Examinations/components/WrittenQuestion/styles.scss
index e69de29b..5a3d8016 100644
--- a/app/src/apps/Examinations/components/WrittenQuestion/styles.scss
+++ b/app/src/apps/Examinations/components/WrittenQuestion/styles.scss
@@ -0,0 +1,10 @@
+input {
+ height: 2rem;
+ width: 66rem;
+ text-indent: 10px;
+ border-style: solid;
+ border-radius: 0.6rem;
+ border-width: 0.1rem;
+ border-color: #c0c0c0;
+ margin: 1rem 0rem;
+}
diff --git a/app/src/apps/Examinations/lib/Examination.js b/app/src/apps/Examinations/lib/Examination.js
index 38706191..cf8ddfb3 100644
--- a/app/src/apps/Examinations/lib/Examination.js
+++ b/app/src/apps/Examinations/lib/Examination.js
@@ -17,7 +17,11 @@ class Examination {
constructQuestion(question) {
switch (question.type) {
case "MultipleChoice":
- return new MultipleChoiceQuestion(question.body, question.options);
+ return new MultipleChoiceQuestion(
+ question.body,
+ question.lab,
+ question.options
+ );
default:
throw "ERROR: Unsupported question type.";
}
diff --git a/app/src/apps/Examinations/lib/Question.js b/app/src/apps/Examinations/lib/Question.js
index b7d82f0e..d93eb04d 100644
--- a/app/src/apps/Examinations/lib/Question.js
+++ b/app/src/apps/Examinations/lib/Question.js
@@ -1,8 +1,10 @@
class Question {
body;
+ labId;
- constructor(body) {
+ constructor(body, labId) {
this.body = body;
+ this.labId = labId;
}
updateOption(event) {
diff --git a/app/src/apps/Examinations/lib/questions/MultipleChoiceQuestion.js b/app/src/apps/Examinations/lib/questions/MultipleChoiceQuestion.js
index 133c88b4..334343f5 100644
--- a/app/src/apps/Examinations/lib/questions/MultipleChoiceQuestion.js
+++ b/app/src/apps/Examinations/lib/questions/MultipleChoiceQuestion.js
@@ -4,8 +4,8 @@ class MultipleChoiceQuestion extends Question {
selectedOptionIndex = -1;
options = [];
- constructor(body, options) {
- super(body);
+ constructor(body, labId, options) {
+ super(body, labId);
this.options = this.constructOptions(options);
}
diff --git a/app/src/components/LoadingAnimation/LoadingAnimation.svelte b/app/src/components/LoadingAnimation/LoadingAnimation.svelte
new file mode 100644
index 00000000..c54cd7a4
--- /dev/null
+++ b/app/src/components/LoadingAnimation/LoadingAnimation.svelte
@@ -0,0 +1,15 @@
+
+
+
diff --git a/app/src/components/LoadingAnimation/index.js b/app/src/components/LoadingAnimation/index.js
new file mode 100644
index 00000000..000598b0
--- /dev/null
+++ b/app/src/components/LoadingAnimation/index.js
@@ -0,0 +1 @@
+export { default as LoadingAnimation } from "./LoadingAnimation.svelte";
diff --git a/app/src/components/LoadingAnimation/styles.scss b/app/src/components/LoadingAnimation/styles.scss
new file mode 100644
index 00000000..0e099b03
--- /dev/null
+++ b/app/src/components/LoadingAnimation/styles.scss
@@ -0,0 +1,94 @@
+.ball-grid-beat > div {
+ -webkit-animation-fill-mode: both;
+ -webkit-animation-iteration-count: infinite;
+ height: 15px;
+ border-radius: 100%;
+ display: inline-block;
+ background-color: rgb(255, 171, 64);
+ margin: 2px;
+}
+@-webkit-keyframes ball-grid-beat {
+ 50% {
+ opacity: 0.7;
+ }
+ 100% {
+ opacity: 1;
+ }
+}
+@keyframes ball-grid-beat {
+ 50% {
+ opacity: 0.7;
+ }
+ 100% {
+ opacity: 1;
+ }
+}
+.ball-grid-beat {
+ width: 57px;
+ margin-top: 250px;
+ margin-left: 500px;
+}
+.ball-grid-beat > div:nth-child(1) {
+ -webkit-animation-delay: 0.15s;
+ animation-delay: 0.15s;
+ -webkit-animation-duration: 1.45s;
+ animation-duration: 1.45s;
+}
+.ball-grid-beat > div:nth-child(2) {
+ -webkit-animation-delay: -20ms;
+ animation-delay: -20ms;
+ -webkit-animation-duration: 0.97s;
+ animation-duration: 0.97s;
+}
+.ball-grid-beat > div:nth-child(3) {
+ -webkit-animation-delay: 0.66s;
+ animation-delay: 0.66s;
+ -webkit-animation-duration: 1.23s;
+ animation-duration: 1.23s;
+}
+.ball-grid-beat > div:nth-child(4) {
+ -webkit-animation-delay: 0.64s;
+ animation-delay: 0.64s;
+ -webkit-animation-duration: 1.24s;
+ animation-duration: 1.24s;
+}
+.ball-grid-beat > div:nth-child(5) {
+ -webkit-animation-delay: -0.19s;
+ animation-delay: -0.19s;
+ -webkit-animation-duration: 1.13s;
+ animation-duration: 1.13s;
+}
+.ball-grid-beat > div:nth-child(6) {
+ -webkit-animation-delay: 0.69s;
+ animation-delay: 0.69s;
+ -webkit-animation-duration: 1.42s;
+ animation-duration: 1.42s;
+}
+.ball-grid-beat > div:nth-child(7) {
+ -webkit-animation-delay: 0.58s;
+ animation-delay: 0.58s;
+ -webkit-animation-duration: 1.14s;
+ animation-duration: 1.14s;
+}
+.ball-grid-beat > div:nth-child(8) {
+ -webkit-animation-delay: 0.21s;
+ animation-delay: 0.21s;
+ -webkit-animation-duration: 1.17s;
+ animation-duration: 1.17s;
+}
+.ball-grid-beat > div:nth-child(9) {
+ -webkit-animation-delay: -0.18s;
+ animation-delay: -0.18s;
+ -webkit-animation-duration: 0.65s;
+ animation-duration: 0.65s;
+}
+.ball-grid-beat > div {
+ width: 15px;
+ animation-fill-mode: both;
+ float: right;
+ -webkit-animation-name: ball-grid-beat;
+ animation-name: ball-grid-beat;
+ animation-iteration-count: infinite;
+ -webkit-animation-delay: 0;
+ animation-delay: 0;
+}
diff --git a/app/src/components/index.js b/app/src/components/index.js
index cee4d49d..610530f5 100644
--- a/app/src/components/index.js
+++ b/app/src/components/index.js
@@ -1,2 +1,3 @@
export { Button } from "./Button";
export { CourseNavbar } from "./CourseNavbar";
+export { LoadingAnimation } from "./LoadingAnimation";