mirror of
https://github.com/GSA/notifications-admin.git
synced 2025-12-16 01:53:56 -05:00
Simplify template picker to be just radio buttons
Includes making the selection buttons work properly
This commit is contained in:
@@ -1 +1,3 @@
|
|||||||
$(() => GOVUK.modules.start());
|
$(() => GOVUK.modules.start());
|
||||||
|
|
||||||
|
$(() => new GOVUK.SelectionButtons('.block-label input'));
|
||||||
|
|||||||
@@ -12,18 +12,15 @@
|
|||||||
|
|
||||||
<h1 class="heading-xlarge">Send text messages</h1>
|
<h1 class="heading-xlarge">Send text messages</h1>
|
||||||
|
|
||||||
<h2 class="heading-medium">1. Choose text message template</h2>
|
<fieldset class='form-group'>
|
||||||
|
<legend class="heading-medium">1. Choose text message template</legend>
|
||||||
{% for template in message_templates %}
|
{% for template in message_templates %}
|
||||||
<div class="template-picker-option">
|
|
||||||
<div class="template-picker-option-radio">
|
|
||||||
<label class="block-label" for="template-{{loop.index}}">
|
<label class="block-label" for="template-{{loop.index}}">
|
||||||
{{ template.name }}
|
{{ template.name }}
|
||||||
<input type="radio" name="template" id="template-{{loop.index}}" value="{{ template.name }}" />
|
<input type="radio" name="template" id="template-{{loop.index}}" value="{{ template.name }}" />
|
||||||
</label>
|
</label>
|
||||||
</div>
|
|
||||||
{{ sms_message(template.body) }}
|
|
||||||
</div>
|
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
|
</fieldset>
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
or <a href="{{ url_for(".add_template", service_id=service_id) }}">create a new template</a>
|
or <a href="{{ url_for(".add_template", service_id=service_id) }}">create a new template</a>
|
||||||
|
|||||||
@@ -32,6 +32,7 @@ gulp.task('copy:govuk_template:assets', () => gulp.src('bower_components/govuk_t
|
|||||||
gulp.task('javascripts', () => gulp
|
gulp.task('javascripts', () => gulp
|
||||||
.src([
|
.src([
|
||||||
paths.src + 'govuk_frontend_toolkit/javascripts/govuk/modules.js',
|
paths.src + 'govuk_frontend_toolkit/javascripts/govuk/modules.js',
|
||||||
|
paths.src + 'govuk_frontend_toolkit/javascripts/govuk/selection-buttons.js',
|
||||||
paths.src + 'javascripts/highlightTags.js',
|
paths.src + 'javascripts/highlightTags.js',
|
||||||
paths.src + 'javascripts/dropdown.js',
|
paths.src + 'javascripts/dropdown.js',
|
||||||
paths.src + 'javascripts/main.js'
|
paths.src + 'javascripts/main.js'
|
||||||
|
|||||||
Reference in New Issue
Block a user