Commit 84cad37f authored by alexpott's avatar alexpott

Issue #2346101 by realityloop: Fixed Alternate text should be called Alternative text.

parent 1e727b38
......@@ -18,7 +18,7 @@ field_default_image:
label: 'Image'
alt:
type: label
label: 'Alternate text'
label: 'Alternative text'
title:
type: label
label: 'Title'
......
......@@ -123,7 +123,7 @@ field.image.value:
label: 'File ID'
alt:
type: string
label: 'Alternate text'
label: 'Alternative text'
title:
type: string
label: 'Title text'
......
......@@ -411,7 +411,7 @@ protected function defaultImageForm(array &$element, array $settings) {
);
$element['default_image']['alt'] = array(
'#type' => 'textfield',
'#title' => t('Alternate text'),
'#title' => t('Alternative text'),
'#description' => t('This text will be used by screen readers, search engines, and when the image cannot be loaded.'),
'#default_value' => $settings['default_image']['alt'],
'#maxlength' => 512,
......
......@@ -221,7 +221,7 @@ public static function process($element, FormStateInterface $form_state, $form)
// Add the additional alt and title fields.
$element['alt'] = array(
'#title' => t('Alternate text'),
'#title' => t('Alternative text'),
'#type' => 'textfield',
'#default_value' => isset($item['alt']) ? $item['alt'] : '',
'#description' => t('This text will be used by screen readers, search engines, or when the image cannot be loaded.'),
......
......@@ -231,7 +231,7 @@ function testImageFieldSettings() {
);
$this->drupalPostForm('node/' . $nid . '/edit', $edit, t('Save and keep published'));
$schema = $field->getFieldStorageDefinition()->getSchema();
$this->assertRaw(t('Alternate text cannot be longer than %max characters but is currently %length characters long.', array(
$this->assertRaw(t('Alternative text cannot be longer than %max characters but is currently %length characters long.', array(
'%max' => $schema['columns']['alt']['length'],
'%length' => $test_size,
)));
......
......@@ -65,7 +65,7 @@ function testRequiredAttributes() {
// Let's just use the first image.
$image = $images[0];
$this->uploadNodeImage($image, $field_name, 'article');
$this->assertText(t('The field Alternate text is required'), 'Node save failed when alt text required was set and alt text was left empty.');
$this->assertText(t('The field Alternative text is required'), 'Node save failed when alt text required was set and alt text was left empty.');
$this->assertText(t('The field Title is required'), 'Node save failed when title text required was set and title text was left empty.');
}
}
......@@ -10,7 +10,7 @@
* - width: The width of the image (if known).
* - height: The height of the image (if known).
* - title: The title of the image.
* - alt: The alternate text for the image.
* - alt: The alternative text for the image.
*
* @see template_preprocess_image_style()
*
......
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