.
This commit is contained in:
@@ -6,7 +6,7 @@ There are {{ questions|length }} question sets.
|
||||
<ul>
|
||||
{% for question in questions %}
|
||||
<li class="question">
|
||||
<pre>{{ question }}</pre>
|
||||
<pre class="pre-question">{{ question }}</pre>
|
||||
<form>
|
||||
<input type="hidden" name="question" value="{{ question }}">
|
||||
<button
|
||||
@@ -29,11 +29,32 @@ There are {{ questions|length }} question sets.
|
||||
|
||||
<div>Diff:</div>
|
||||
<form>
|
||||
<textarea id="question1" name="question1"></textarea>
|
||||
<textarea id="question2" name="question2"></textarea>
|
||||
<textarea id="question1" name="question1" cols=40 rows=10></textarea>
|
||||
<textarea id="question2" name="question2" cols=40 rows=10></textarea>
|
||||
<button
|
||||
hx-post='{% url "oef:questions_diff" %}'
|
||||
hx-target="#diff-results">Diff</button>
|
||||
<br/>
|
||||
<button type="button" style="font:inherit;font-size:.8em;background:#3465a4;color:white;border:none;padding: 0 .4em; border-radius: .4em" _="on click
|
||||
writeText(#question1.value) on navigator.clipboard
|
||||
put 'copied!' into me
|
||||
wait 1s
|
||||
put 'copy1' into me">copy1</button>
|
||||
<button type="button" style="font:inherit;font-size:.8em;background:#3465a4;color:white;border:none;padding: 0 .4em; border-radius: .4em" _="on click
|
||||
writeText(#question2.value) on navigator.clipboard
|
||||
put 'copied!' into me
|
||||
wait 1s
|
||||
put 'copy2' into me">copy2</button>
|
||||
<button type="button" style="font:inherit;font-size:.8em;background:#3465a4;color:white;border:none;padding: 0 .4em; border-radius: .4em" _="on click
|
||||
repeat for pre in .pre-question
|
||||
if #question1.value is pre.innerHTML
|
||||
then go to pre then break
|
||||
">go1</button>
|
||||
<button type="button" style="font:inherit;font-size:.8em;background:#3465a4;color:white;border:none;padding: 0 .4em; border-radius: .4em" _="on click
|
||||
repeat for pre in .pre-question
|
||||
if #question2.value is pre.innerHTML
|
||||
then go to pre then break
|
||||
">go2</button>
|
||||
<br/>results
|
||||
<span id="diff-results"></span>
|
||||
</form>
|
||||
|
||||
Reference in New Issue
Block a user