Skip to content

Commit

Permalink
fix(forum): ab test forum rating (#688)
Browse files Browse the repository at this point in the history
## Description

fix #686  #687 

🎸 ajout `{{ block.super }}` dans `{% block extra_js %}` pour preserver
HTMX

## Type de changement

🪲 Correction de bug (changement non cassant qui corrige un problème).
🚧 technique
  • Loading branch information
vincentporte authored Jun 18, 2024
1 parent f0e9c2b commit d3027e4
Show file tree
Hide file tree
Showing 4 changed files with 1 addition and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@
</div>

</div>


</div>

Expand Down Expand Up @@ -84,7 +83,6 @@
</div>

</div>


</div>

Expand Down
1 change: 0 additions & 1 deletion lacommunaute/forum/tests/__snapshots__/tests_views.ambr
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,6 @@
</div>

</div>


</div>
'''
Expand Down
1 change: 1 addition & 0 deletions lacommunaute/templates/forum/forum_detail.html
Original file line number Diff line number Diff line change
Expand Up @@ -179,6 +179,7 @@ <h1>{{ forum.name }}</h1>
{% endif %}
{% endblock content %}
{% block extra_js %}
{{ block.super }}
<!-- Matomo A/B Test -->
<script nonce="{{ request.csp_nonce }}">
var _paq = _paq || [];
Expand Down
2 changes: 0 additions & 2 deletions lacommunaute/templates/forum/partials/rating.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ <h3 class="h4">Merci d'avoir noté cette fiche !</h3>
{% endfor %}
</div>
</div>
{% for star in "12345" %}{% endfor %}
{% else %}
<h3 class="h4">Cette fiche vous a-t-elle été utile ?</h3>
<form class="d-inline-block d-lg-block bg-button-lightest rounded-1 text-center"
Expand Down Expand Up @@ -50,7 +49,6 @@ <h3 class="h3">Merci d'avoir noté cette fiche !</h3>
</div>
{% endfor %}
</div>
{% for star in "12345" %}{% endfor %}
{% else %}
<h3 class="h3">Cette fiche vous a-t-elle été utile ?</h3>
<form hx-post="{% url 'forum_extension:rate' forum.slug forum.pk %}" id="rating-button" hx-target="#rating-area{{ rating_area_id }}" hx-swap="outerHTML">
Expand Down

0 comments on commit d3027e4

Please sign in to comment.