feat: make hints a group in one stage

This commit is contained in:
Lin, Hung-Shin committed 2023-11-21 11:55:32 +08:00
1 parent 42ac27126c
commit 36f53da08a
4 files changed
+12 -6

No files matched your search

+9 -3
View File
@@ -60,9 +60,15 @@ const right = () => {
</div>
</div>
<div id="hint" class="bg-bg flex flex-wrap p-8">
<p class="text-text font-xl whitespace-pre-wrap">
{{ sessionStore.session.hints[current] }}
</p>
<ul>
<li
v-for="hint in sessionStore.session.hints[current]"
:key="hint"
class="text-text font-xl whitespace-pre-wrap"
>
➤ {{ hint }}
</li>
</ul>
<br />
</div>
</template>
+1 -1
View File
@@ -86,7 +86,7 @@ function updateGraph(event) {
}
function updateHints(hints) {
store.session.hints.push(...hints)
store.session.hints.push(hints)
}
function updateStatus(status) {
+1 -1
View File
@@ -54,7 +54,7 @@ const Session = model(
required: true,
},
tasks: [taskSchema],
hints: [String],
hints: [[String]],
graph: {
type: nodeSchema,
default: {
+1 -1
View File
@@ -47,7 +47,7 @@ export default class SessionHandler {
t.completed = true
})
this.session.hints.push(...stage.hints)
this.session.hints.push(stage.hints)
this.addNewTasks()