From 458af8d30a1bca153f770358b8f914554b0da6c3 Mon Sep 17 00:00:00 2001 From: Thomas Bruederli Date: Tue, 3 Jun 2014 14:11:13 +0200 Subject: Apply accessibility improvements to the address book task --- program/steps/addressbook/func.inc | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'program/steps/addressbook') diff --git a/program/steps/addressbook/func.inc b/program/steps/addressbook/func.inc index be0dd2a33..e68a694ef 100644 --- a/program/steps/addressbook/func.inc +++ b/program/steps/addressbook/func.inc @@ -395,7 +395,7 @@ function rcmail_js_contacts_list($result, $prefix='') ), '»'); } else - $val = ' '; + $val = ''; break; default: @@ -422,7 +422,7 @@ function rcmail_contacts_list_title($attrib) unset($attrib['name']); $OUTPUT->add_gui_object('addresslist_title', $attrib['id']); - $OUTPUT->add_label('contacts'); + $OUTPUT->add_label('contacts','uponelevel'); return html::tag($attrib['tag'], $attrib, $RCMAIL->gettext($attrib['label']), html::$common_attrib); } @@ -518,7 +518,7 @@ function rcmail_contact_form($form, $record, $attrib = null) foreach ($coltypes as $col => $prop) { if ($prop['subtypes']) { $subtype_names = array_map('rcmail_get_type_label', $prop['subtypes']); - $select_subtype = new html_select(array('name' => '_subtype_'.$col.'[]', 'class' => 'contactselectsubtype')); + $select_subtype = new html_select(array('name' => '_subtype_'.$col.'[]', 'class' => 'contactselectsubtype', 'title' => $prop['label'] . ' ' . $RCMAIL->gettext('type'))); $select_subtype->add($subtype_names, $prop['subtypes']); $coltypes[$col]['subtypes_select'] = $select_subtype->show(); } @@ -607,7 +607,7 @@ function rcmail_contact_form($form, $record, $attrib = null) // prepare subtype selector in edit mode if ($edit_mode && is_array($colprop['subtypes'])) { $subtype_names = array_map('rcmail_get_type_label', $colprop['subtypes']); - $select_subtype = new html_select(array('name' => '_subtype_'.$col.'[]', 'class' => 'contactselectsubtype')); + $select_subtype = new html_select(array('name' => '_subtype_'.$col.'[]', 'class' => 'contactselectsubtype', 'title' => $colprop['label'] . ' ' . $RCMAIL->gettext('type'))); $select_subtype->add($subtype_names, $colprop['subtypes']); } else -- cgit v1.2.3 From 24e89eceed9694882ff943c4106519fab449705f Mon Sep 17 00:00:00 2001 From: Thomas Bruederli Date: Wed, 4 Jun 2014 12:10:49 +0200 Subject: Add fieldset legends and input element labels to contact edit form --- program/js/app.js | 17 ++++++----------- program/localization/en_US/labels.inc | 2 ++ program/steps/addressbook/edit.inc | 3 +++ program/steps/addressbook/func.inc | 6 ++++-- program/steps/addressbook/show.inc | 1 + skins/classic/addressbook.css | 5 +++++ skins/larry/addressbook.css | 10 ++++++++++ skins/larry/settings.css | 2 +- skins/larry/templates/contactedit.html | 5 +++-- 9 files changed, 35 insertions(+), 16 deletions(-) (limited to 'program/steps/addressbook') diff --git a/program/js/app.js b/program/js/app.js index ea7265d59..1f6582bf6 100644 --- a/program/js/app.js +++ b/program/js/app.js @@ -5562,6 +5562,7 @@ function rcube_webmail() if (appendcontainer.length && appendcontainer.get(0).nodeName == 'FIELDSET') { var input, colprop = this.env.coltypes[col], + input_id = 'ff_' + col + (colprop.count || 0), row = $('
').addClass('row'), cell = $('
').addClass('contactfieldcontent data'), label = $('
').addClass('contactfieldlabel label'); @@ -5569,13 +5570,13 @@ function rcube_webmail() if (colprop.subtypes_select) label.html(colprop.subtypes_select); else - label.html(colprop.label); + label.html(''); var name_suffix = colprop.limit != 1 ? '[]' : ''; if (colprop.type == 'text' || colprop.type == 'date') { input = $('') .addClass('ff_'+col) - .attr({type: 'text', name: '_'+col+name_suffix, size: colprop.size}) + .attr({type: 'text', name: '_'+col+name_suffix, size: colprop.size, id: input_id}) .appendTo(cell); this.init_edit_field(col, input); @@ -5586,7 +5587,7 @@ function rcube_webmail() else if (colprop.type == 'textarea') { input = $('