mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-09-08 04:48:24 -04:00
Put message previews on ‘Send SMS’ page
A previous commit removed these to differentiate between this page and the manage templates page. It turns out that we do want previews on this page because: - the users for the two pages might be different—they might only be allowed to do one or the other depending what permissions they have - it’s useful to see what the placeholders in the message are before uploading a CSV, to make sure the CSV has the correct column headings This commit re-adds the message preview with a simpler UI. Discussed with @antimega and we both agreed that the speech bubble tails on the messages should go.
This commit is contained in:
@@ -1,4 +1,9 @@
|
||||
{% macro sms_message(body, recipient=None, name=None, edit_link=None) %}
|
||||
{% macro sms_message(
|
||||
body, recipient=None, name=None, edit_link=None, input_name=None, input_index=None
|
||||
) %}
|
||||
{% if input_name %}
|
||||
<label class="sms-message-option" for="{{ input_name }}-{{ input_index }}">
|
||||
{% endif %}
|
||||
{% if name %}
|
||||
<h3 class="sms-message-name">
|
||||
{% if edit_link %}
|
||||
@@ -8,14 +13,18 @@
|
||||
{% endif %}
|
||||
</h3>
|
||||
{% endif %}
|
||||
<div class="sms-message">
|
||||
<div class="sms-message-wrapper">
|
||||
{{ body|placeholders }}
|
||||
</div>
|
||||
{% if input_name %}
|
||||
<input class="sms-message-picker" type="radio" id="{{ input_name }}-{{ input_index }}" name="{{ input_name }}" />
|
||||
{% endif %}
|
||||
<div class="sms-message-wrapper{% if input_name %}-with-radio{% endif %}">
|
||||
{{ body|placeholders }}
|
||||
</div>
|
||||
{% if recipient %}
|
||||
<p class="sms-message-recipient">
|
||||
{{ recipient }}
|
||||
</p>
|
||||
{% endif %}
|
||||
{% if input_name %}
|
||||
</label>
|
||||
{% endif %}
|
||||
{% endmacro %}
|
||||
|
||||
Reference in New Issue
Block a user