Unverified Commit 3cb53fef authored by larowlan's avatar larowlan

Issue #2898913 by Sam152, andrewmacpherson, Wim Leers: Review a11y concerns in...

Issue #2898913 by Sam152, andrewmacpherson, Wim Leers: Review a11y concerns in ContentModerationConfigureForm
parent 8742371f
...@@ -110,7 +110,6 @@ public function buildConfigurationForm(array $form, FormStateInterface $form_sta ...@@ -110,7 +110,6 @@ public function buildConfigurationForm(array $form, FormStateInterface $form_sta
'title' => $this->t('Select'), 'title' => $this->t('Select'),
'url' => Url::fromRoute('content_moderation.workflow_type_edit_form', ['workflow' => $workflow->id(), 'entity_type_id' => $entity_type->id()]), 'url' => Url::fromRoute('content_moderation.workflow_type_edit_form', ['workflow' => $workflow->id(), 'entity_type_id' => $entity_type->id()]),
'attributes' => [ 'attributes' => [
'aria-label' => $this->t('Select'),
'class' => ['use-ajax'], 'class' => ['use-ajax'],
'data-dialog-type' => 'modal', 'data-dialog-type' => 'modal',
'data-dialog-options' => Json::encode([ 'data-dialog-options' => Json::encode([
......
...@@ -115,7 +115,6 @@ public function form(array $form, FormStateInterface $form_state) { ...@@ -115,7 +115,6 @@ public function form(array $form, FormStateInterface $form_state) {
'edit' => [ 'edit' => [
'title' => $this->t('Edit'), 'title' => $this->t('Edit'),
'url' => Url::fromRoute('entity.workflow.edit_state_form', ['workflow' => $workflow->id(), 'workflow_state' => $state->id()]), 'url' => Url::fromRoute('entity.workflow.edit_state_form', ['workflow' => $workflow->id(), 'workflow_state' => $state->id()]),
'attributes' => ['aria-label' => $this->t('Edit @state state', ['@state' => $state->label()])],
] ]
]; ];
if ($this->entity->access('delete-state:' . $state->id())) { if ($this->entity->access('delete-state:' . $state->id())) {
...@@ -125,7 +124,6 @@ public function form(array $form, FormStateInterface $form_state) { ...@@ -125,7 +124,6 @@ public function form(array $form, FormStateInterface $form_state) {
'workflow' => $workflow->id(), 'workflow' => $workflow->id(),
'workflow_state' => $state->id() 'workflow_state' => $state->id()
]), ]),
'attributes' => ['aria-label' => $this->t('Delete @state state', ['@state' => $state->label()])],
]; ];
} }
$form['states_container']['states'][$state->id()] = [ $form['states_container']['states'][$state->id()] = [
...@@ -178,12 +176,10 @@ public function form(array $form, FormStateInterface $form_state) { ...@@ -178,12 +176,10 @@ public function form(array $form, FormStateInterface $form_state) {
$links['edit'] = [ $links['edit'] = [
'title' => $this->t('Edit'), 'title' => $this->t('Edit'),
'url' => Url::fromRoute('entity.workflow.edit_transition_form', ['workflow' => $workflow->id(), 'workflow_transition' => $transition->id()]), 'url' => Url::fromRoute('entity.workflow.edit_transition_form', ['workflow' => $workflow->id(), 'workflow_transition' => $transition->id()]),
'attributes' => ['aria-label' => $this->t('Edit \'@transition\' transition', ['@transition' => $transition->label()])],
]; ];
$links['delete'] = [ $links['delete'] = [
'title' => t('Delete'), 'title' => t('Delete'),
'url' => Url::fromRoute('entity.workflow.delete_transition_form', ['workflow' => $workflow->id(), 'workflow_transition' => $transition->id()]), 'url' => Url::fromRoute('entity.workflow.delete_transition_form', ['workflow' => $workflow->id(), 'workflow_transition' => $transition->id()]),
'attributes' => ['aria-label' => $this->t('Delete \'@transition\' transition', ['@transition' => $transition->label()])],
]; ];
$form['transitions_container']['transitions'][$transition->id()] = [ $form['transitions_container']['transitions'][$transition->id()] = [
'#attributes' => ['class' => ['draggable']], '#attributes' => ['class' => ['draggable']],
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment