Fix bug: toggling expand diff did not current page
This commit is contained in:
parent
39c98c9ec7
commit
8282236c81
2 changed files with 19 additions and 10 deletions
|
@ -77,6 +77,7 @@ def index():
|
||||||
|
|
||||||
return render_template('./index.html',
|
return render_template('./index.html',
|
||||||
diffs=diffs,
|
diffs=diffs,
|
||||||
|
page=page,
|
||||||
pagination=pagination,
|
pagination=pagination,
|
||||||
diff_count = diff_count,
|
diff_count = diff_count,
|
||||||
search=search,
|
search=search,
|
||||||
|
|
|
@ -19,18 +19,26 @@
|
||||||
value="Hledat"
|
value="Hledat"
|
||||||
>
|
>
|
||||||
Hledat
|
Hledat
|
||||||
<svg class="inline-icon" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M18.031 16.6168L22.3137 20.8995L20.8995 22.3137L16.6168 18.031C15.0769 19.263 13.124 20 11 20C6.032 20 2 15.968 2 11C2 6.032 6.032 2 11 2C15.968 2 20 6.032 20 11C20 13.124 19.263 15.0769 18.031 16.6168ZM16.0247 15.8748C17.2475 14.6146 18 12.8956 18 11C18 7.1325 14.8675 4 11 4C7.1325 4 4 7.1325 4 11C4 14.8675 7.1325 18 11 18C12.8956 18 14.6146 17.2475 15.8748 16.0247L16.0247 15.8748Z"></path></svg>
|
<svg class="inline-icon" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
|
||||||
|
<path d="M18.031 16.6168L22.3137 20.8995L20.8995 22.3137L16.6168 18.031C15.0769 19.263 13.124 20 11 20C6.032 20 2 15.968 2 11C2 6.032 6.032 2 11 2C15.968 2 20 6.032 20 11C20 13.124 19.263 15.0769 18.031 16.6168ZM16.0247 15.8748C17.2475 14.6146 18 12.8956 18 11C18 7.1325 14.8675 4 11 4C7.1325 4 4 7.1325 4 11C4 14.8675 7.1325 18 11 18C12.8956 18 14.6146 17.2475 15.8748 16.0247L16.0247 15.8748Z"></path>
|
||||||
|
</svg>
|
||||||
</button>
|
</button>
|
||||||
</form>
|
</form>
|
||||||
<label class="checkbox">
|
<form
|
||||||
<input type="checkbox" name="expand_diffs" value="true"
|
|
||||||
hx-get="/"
|
hx-get="/"
|
||||||
|
hx-trigger="change"
|
||||||
hx-target="#diff-list"
|
hx-target="#diff-list"
|
||||||
hx-select="#diff-list"
|
hx-select="#diff-list"
|
||||||
hx-swap="outerHTML"
|
hx-swap="outerHTML"
|
||||||
/>
|
>
|
||||||
|
{% if page > 1 %}
|
||||||
|
<input type="hidden" name="page" value="{{ page }}" />
|
||||||
|
{% endif %}
|
||||||
|
<label class="checkbox">
|
||||||
|
<input type="checkbox" name="expand_diffs" value="true" />
|
||||||
<p>Expand diffs</p>
|
<p>Expand diffs</p>
|
||||||
</label>
|
</label>
|
||||||
|
</form>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue