Added: Reviewer entrypoint

This commit is contained in:
Luc Mcgrady 2025-09-03 18:40:37 +01:00
parent fac5d64558
commit 4bf38ec2af
No known key found for this signature in database
GPG key ID: 4F3D7A0B17CC3D9C
10 changed files with 12 additions and 16 deletions

View file

@ -334,7 +334,7 @@ def is_sveltekit_page(path: str) -> bool:
"import-csv", "import-csv",
"import-page", "import-page",
"image-occlusion", "image-occlusion",
"reviewer-bottom", "reviewer",
] ]

View file

@ -341,21 +341,12 @@ class Reviewer:
def _initWeb(self) -> None: def _initWeb(self) -> None:
self._reps = 0 self._reps = 0
# main window # main window
self.web.stdHtml( self.web.load_sveltekit_page("reviewer")
self.revHtml(),
css=["css/reviewer.css"],
js=[
"js/mathjax.js",
"js/vendor/mathjax/tex-chtml-full.js",
"js/reviewer.js",
],
context=self,
)
# block default drag & drop behavior while allowing drop events to be received by JS handlers # block default drag & drop behavior while allowing drop events to be received by JS handlers
self.web.allow_drops = True self.web.allow_drops = True
self.web.eval("_blockDefaultDragDropBehavior();") self.web.eval("_blockDefaultDragDropBehavior();")
# show answer / ease buttons # show answer / ease buttons
self.bottom.web.load_sveltekit_page("reviewer-bottom") self.bottom.web = self.web
# Showing the question # Showing the question
########################################################################## ##########################################################################

View file

@ -0,0 +1,5 @@
<script>
import ReviewerBottomOuter from "./reviewer-bottom/ReviewerBottomOuter.svelte";
</script>
<ReviewerBottomOuter></ReviewerBottomOuter>

View file

View file

@ -1,10 +1,10 @@
/* Copyright: Ankitects Pty Ltd and contributors /* Copyright: Ankitects Pty Ltd and contributors
* License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html */ * License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html */
@use "../../lib/sass/root-vars"; @use "../../../lib/sass/root-vars";
@use "../../lib/sass/vars" as *; @use "../../../lib/sass/vars" as *;
@use "../../lib/sass/card-counts"; @use "../../../lib/sass/card-counts";
@use "../../lib/sass/buttons"; @use "../../../lib/sass/buttons";
:root { :root {
--focus-color: #{palette-of(border-focus)}; --focus-color: #{palette-of(border-focus)};