Skip to content

Commit

Permalink
Add component for quizes
Browse files Browse the repository at this point in the history
  • Loading branch information
Zaprogramiacz committed Feb 10, 2025
1 parent ee657f6 commit e7c31f5
Show file tree
Hide file tree
Showing 6 changed files with 37 additions and 0 deletions.
1 change: 1 addition & 0 deletions layouts/_default/single.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
{{- define "main" }}
{{- partial "custom-header.html" . }}

<article class="post-single">
<header class="post-header">
Expand Down
6 changes: 6 additions & 0 deletions layouts/partials/custom-header.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
<script src="/js/quizdown.js"></script>
<script src="/js/quizdownKatex.js"></script>
<script src="/js/quizdownHighlight.js"></script>
<script>
quizdown.register(quizdownHighlight).register(quizdownKatex).init();
</script>
4 changes: 4 additions & 0 deletions layouts/shortcodes/quizdown.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{{ $_hugo_config := `{ "version": 1 }` }}
<div class='quizdown'>
{{ .Inner }}
</div>
24 changes: 24 additions & 0 deletions static/js/quizdown.js

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions static/js/quizdownHighlight.js

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions static/js/quizdownKatex.js

Large diffs are not rendered by default.

0 comments on commit e7c31f5

Please sign in to comment.