forked from mirrors/bookwyrm
Merge pull request #547 from mouse-reeve/form-clash
Fixes clashing form ids in rate/review
This commit is contained in:
commit
b82aa54c6e
1 changed files with 4 additions and 4 deletions
|
@ -10,11 +10,11 @@
|
|||
<input type="hidden" name="rating" value="{{ forloop.counter }}">
|
||||
|
||||
<div class="field is-grouped stars form-rate-stars mb-1">
|
||||
<label class="is-sr-only" for="no-rating-{{ book.id }}">No rating</label>
|
||||
<input class="is-sr-only" type="radio" name="rating" value="" id="no-rating-{{ book.id }}" checked>
|
||||
<label class="is-sr-only" for="rating-no-rating-{{ book.id }}">No rating</label>
|
||||
<input class="is-sr-only" type="radio" name="rating" value="" id="rating-no-rating-{{ book.id }}" checked>
|
||||
{% for i in '12345'|make_list %}
|
||||
<input class="is-sr-only" id="book{{book.id}}-star-{{ forloop.counter }}" type="radio" name="rating" value="{{ forloop.counter }}" {% if book|rating:user == forloop.counter %}checked{% endif %}>
|
||||
<label class="icon icon-star-empty" for="book{{book.id}}-star-{{ forloop.counter }}">
|
||||
<input class="is-sr-only" id="rating-book{{book.id}}-star-{{ forloop.counter }}" type="radio" name="rating" value="{{ forloop.counter }}" {% if book|rating:user == forloop.counter %}checked{% endif %}>
|
||||
<label class="icon icon-star-empty" for="rating-book{{book.id}}-star-{{ forloop.counter }}">
|
||||
<span class="is-sr-only">{{ forloop.counter }} star{{ forloop.counter | pluralize }}</span>
|
||||
</label>
|
||||
{% endfor %}
|
||||
|
|
Loading…
Reference in a new issue