MDL-86701 customfield: Better naming of custom field action buttons
Include the category and field names for accessible names of the delete and action buttons to help assistive technology users better understand the buttons' purpose.
This commit is contained in:
@@ -86,7 +86,7 @@
|
||||
<span class="movecategory icon-size-3">{{> core/drag_handle}}</span>
|
||||
{{/canmovecategories}}
|
||||
{{{nameeditable}}}
|
||||
<button type="button" class="btn btn-link btn-icon icon-size-3" data-role="deletecategory" data-id="{{id}}" title="{{#str}} delete {{/str}}" aria-label="{{#str}} delete {{/str}}">
|
||||
<button type="button" class="btn btn-link btn-icon icon-size-3" data-role="deletecategory" data-id="{{id}}" title="{{#str}} deletecategory, customfield, {{name}} {{/str}}" aria-label="{{#str}} deletecategory, customfield, {{name}} {{/str}}">
|
||||
{{#pix}} t/delete, core {{/pix}}
|
||||
</button>
|
||||
</h3>
|
||||
@@ -118,10 +118,10 @@
|
||||
<td class="col-3">{{{shortname}}}</td>
|
||||
<td class="col-2">{{{type}}}</td>
|
||||
<td class="col-2 text-end">
|
||||
<button type="button" class="btn btn-link btn-icon icon-no-margin" data-role="editfield" data-name="{{name}}" data-id="{{id}}" title="{{#str}} edit {{/str}}" aria-label="{{#str}} edit {{/str}}">
|
||||
<button type="button" class="btn btn-link btn-icon" data-role="editfield" data-name="{{name}}" data-id="{{id}}" title="{{#str}} editfield, customfield, {{name}} {{/str}}" aria-label="{{#str}} editfield, customfield, {{name}} {{/str}}">
|
||||
{{#pix}} t/edit, core {{/pix}}
|
||||
</button>
|
||||
<button type="button" class="btn btn-link btn-icon icon-no-margin" data-id="{{id}}" data-role="deletefield" title=" {{#str}} delete {{/str}}" aria-label="{{#str}} delete {{/str}}">
|
||||
<button type="button" class="btn btn-link btn-icon" data-id="{{id}}" data-role="deletefield" title="{{#str}} deletefield, customfield, {{name}} {{/str}}" aria-label="{{#str}} deletefield, customfield, {{name}} {{/str}}">
|
||||
{{#pix}} t/delete, core {{/pix}}
|
||||
</button>
|
||||
</td>
|
||||
|
||||
@@ -35,7 +35,7 @@ Feature: Managers can manage categories for course custom fields
|
||||
| Field 1 | Category for test | text | f1 |
|
||||
And I log in as "admin"
|
||||
And I navigate to "Courses > Default settings > Course custom fields" in site administration
|
||||
And I click on "[data-role='deletecategory']" "css_element"
|
||||
And I press "Delete custom field category: Category for test"
|
||||
And I click on "Yes" "button" in the "Confirm" "dialogue"
|
||||
And I wait until the page is ready
|
||||
And I wait until "Test category" "text" does not exist
|
||||
|
||||
@@ -77,7 +77,7 @@ Feature: Teachers can edit course custom fields
|
||||
Scenario: Use images in the custom field description
|
||||
When I log in as "admin"
|
||||
And I navigate to "Courses > Default settings > Course custom fields" in site administration
|
||||
And I click on "Edit" "link" in the "Field 1" "table_row"
|
||||
And I press "Edit custom field: Field 1"
|
||||
And I click on "Image" "button" in the "Description" "form_row"
|
||||
And I click on "Browse repositories" "button"
|
||||
And I click on "Private files" "link" in the ".fp-repo-area" "css_element"
|
||||
|
||||
@@ -37,10 +37,13 @@ $string['customfield'] = 'Custom field';
|
||||
$string['customfielddata'] = 'Custom fields data';
|
||||
$string['customfields'] = 'Custom fields';
|
||||
$string['defaultvalue'] = 'Default value';
|
||||
$string['deletecategory'] = 'Delete custom field category: {$a}';
|
||||
$string['deletefield'] = 'Delete custom field: {$a}';
|
||||
$string['description'] = 'Description';
|
||||
$string['description_help'] = 'The description is displayed in the form below the field.';
|
||||
$string['edit'] = 'Edit';
|
||||
$string['editcategoryname'] = 'Edit category name';
|
||||
$string['editfield'] = 'Edit custom field: {$a}';
|
||||
$string['editingfield'] = 'Updating {$a}';
|
||||
$string['errorfieldtypenotfound'] = 'Field type {$a} not found';
|
||||
$string['erroruniquevalues'] = 'This value is already used.';
|
||||
|
||||
Reference in New Issue
Block a user