Use aria-labelledby for conversations
This commit is contained in:
parent
4819544030
commit
5fd89961c4
3 changed files with 25 additions and 8 deletions
|
|
@ -7,8 +7,16 @@
|
|||
= owner_image_tag(:thumb_small)
|
||||
.media-body
|
||||
= form_for [conversation, Message.new], html: {class: "control-group"} do |message|
|
||||
= message.text_area :text, rows: 5, tabindex: 1, class: "form-control form-group"
|
||||
= message.submit t("conversations.show.reply").capitalize,
|
||||
.form-group
|
||||
%label#messageLabel.sr-only{for: "message_text"}
|
||||
= t("conversations.new.message")
|
||||
= message.text_area :text,
|
||||
rows: 5,
|
||||
tabindex: 1,
|
||||
class: "form-control form-group",
|
||||
aria: {labelledby: "messageLabel"}
|
||||
|
||||
= message.submit t("conversations.show.reply"),
|
||||
"data-disable-with" => t("conversations.show.replying"),
|
||||
class: "btn btn-primary pull-right", tabindex: 2
|
||||
.clearfix
|
||||
|
|
|
|||
|
|
@ -1,14 +1,22 @@
|
|||
.container-fluid
|
||||
= form_for Conversation.new, html: {class: "form-horizontal form_do_not_clear"}, remote: true do |conversation|
|
||||
.form-group
|
||||
%label{ for: 'contact_ids' }
|
||||
= t('.to')
|
||||
%label#toLabel{for: "contact_ids"}
|
||||
= t(".to")
|
||||
= text_field_tag "contact_autocomplete", nil, class: "form-control"
|
||||
.form-group
|
||||
%label{ for: 'conversation_subject' }
|
||||
= t('.subject')
|
||||
= conversation.text_field :subject, class: 'input-block-level form-control'
|
||||
%label#subjectLabel{for: "conversation_subject"}
|
||||
= t(".subject")
|
||||
= conversation.text_field :subject,
|
||||
class: "input-block-level form-control",
|
||||
aria: {labelledby: "subjectLabel"}
|
||||
.form-group
|
||||
= text_area_tag "conversation[text]", '', rows: 5, class: 'input-block-level form-control'
|
||||
%label#messageLabel.sr-only{for: "conversation_text"}
|
||||
= t(".message")
|
||||
= text_area_tag "conversation[text]",
|
||||
"",
|
||||
rows: 5,
|
||||
class: "input-block-level form-control",
|
||||
aria: {labelledby: "messageLabel"}
|
||||
.form-group
|
||||
= conversation.submit t('.send'), 'data-disable-with' => t('.sending'), class: 'btn btn-primary pull-right'
|
||||
|
|
|
|||
|
|
@ -352,6 +352,7 @@ en:
|
|||
to: "To"
|
||||
subject: "Subject"
|
||||
subject_default: "No subject"
|
||||
message: "Message"
|
||||
send: "Send"
|
||||
sending: "Sending..."
|
||||
abandon_changes: "Abandon changes?"
|
||||
|
|
|
|||
Loading…
Reference in a new issue