Add ARIA attributes from Design System component

This commit copies the same ARIA attributes that are added to the
character count component[1] in the GOV.UK Design System.

This means that screen reader users will hear the count message when
they stop typing.

1. https://design-system.service.gov.uk/components/character-count/
This commit is contained in:
Chris Hill-Scott
2021-01-07 14:30:48 +00:00
parent 3fdaa29f35
commit c3b6c03411
5 changed files with 38 additions and 3 deletions

View File

@@ -484,6 +484,12 @@ def test_should_show_page_for_one_template(
template_type='sms',
)
assert (
page.select_one('[data-module=update-status]')['aria-live']
) == (
'polite'
)
mock_get_service_template.assert_called_with(SERVICE_ONE_ID, template_id, None)
@@ -518,6 +524,12 @@ def test_broadcast_template_doesnt_highlight_placeholders_but_does_count_charact
template_type='broadcast',
)
assert (
page.select_one('[data-module=update-status]')['aria-live']
) == (
'polite'
)
def test_caseworker_redirected_to_one_off(
client_request,