Commit ef4f8837 authored by catch's avatar catch

Issue #2561115 by michaellenahan, alexpott, Lendude, cilefen, lomasr,...

Issue #2561115 by michaellenahan, alexpott, Lendude, cilefen, lomasr, amit.drupal, Gábor Hojtsy, ifrik, dawehner: Rollback: Use 'Filter' for exposed filter button text in new views and new installations (instead of 'Apply')
parent 22d18686
......@@ -36,7 +36,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -40,7 +40,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -37,7 +37,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -35,7 +35,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -35,7 +35,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -39,7 +39,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -37,7 +37,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -37,7 +37,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -42,7 +42,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -38,7 +38,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -38,7 +38,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -35,7 +35,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -39,7 +39,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -38,7 +38,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -37,7 +37,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -36,7 +36,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -39,7 +39,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -35,7 +35,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -40,7 +40,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -40,7 +40,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -37,7 +37,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -63,7 +63,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -38,7 +38,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -37,7 +37,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -37,7 +37,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -37,7 +37,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -37,7 +37,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -37,7 +37,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -35,7 +35,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -40,7 +40,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -37,7 +37,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -39,7 +39,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -39,7 +39,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -39,7 +39,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -40,7 +40,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -37,7 +37,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -35,7 +35,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -35,7 +35,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -35,7 +35,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -35,7 +35,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -35,7 +35,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -40,7 +40,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -38,7 +38,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -37,7 +37,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -38,7 +38,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -37,7 +37,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -37,7 +37,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -38,7 +38,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -38,7 +38,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -38,7 +38,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -37,7 +37,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -37,7 +37,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -38,7 +38,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -37,7 +37,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -36,7 +36,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -36,7 +36,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -35,7 +35,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -35,7 +35,7 @@ display:
exposed_form:
type: basic
options:
submit_button: Filter
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
......
......@@ -107,7 +107,7 @@ public function buildForm(array $form, FormStateInterface $form_state) {
// Prevent from showing up in \Drupal::request()->query.
'#name' => '',
'#type' => 'submit',
'#value' => $this->t('Filter'),
'#value' => $this->t('Apply'),
'#id' => Html::getUniqueId('edit-submit-' . $view->storage->id()),
);
......
......@@ -26,7 +26,7 @@ abstract class ExposedFormPluginBase extends PluginBase implements CacheableDepe
*/
protected function defineOptions() {
$options = parent::defineOptions();
$options['submit_button'] = array('default' => $this->t('Filter'));
$options['submit_button'] = array('default' => $this->t('Apply'));
$options['reset_button'] = array('default' => FALSE);
$options['reset_button_label'] = array('default' => $this->t('Reset'));
$options['exposed_sorts_label'] = array('default' => $this->t('Sort by'));
......
......@@ -50,10 +50,10 @@ protected function setUp() {
* Tests the submit button.
*/
public function testSubmitButton() {
// Test the submit button value defaults to 'Filter'.
// Test the submit button value defaults to 'Apply'.
$this->drupalGet('test_exposed_form_buttons');
$this->assertResponse(200);
$this->helperButtonHasLabel('edit-submit-test-exposed-form-buttons', t('Filter'));
$this->helperButtonHasLabel('edit-submit-test-exposed-form-buttons', t('Apply'));
// Rename the label of the submit button.
$view = Views::getView('test_exposed_form_buttons');
......@@ -68,7 +68,7 @@ public function testSubmitButton() {
$this->drupalGet('test_exposed_form_buttons');
$this->helperButtonHasLabel('edit-submit-test-exposed-form-buttons', $expected_label);
// Make sure an empty label uses the default 'Filter' button value too.
// Make sure an empty label uses the default 'Apply' button value too.
$view = Views::getView('test_exposed_form_buttons');
$view->setDisplay();
......@@ -77,9 +77,9 @@ public function testSubmitButton() {
$view->display_handler->setOption('exposed_form', $exposed_form);
$view->save();
// Make sure the submit button label shows 'Filter'.
// Make sure the submit button label shows 'Apply'.
$this->drupalGet('test_exposed_form_buttons');
$this->helperButtonHasLabel('edit-submit-test-exposed-form-buttons', t('Filter'));
$this->helperButtonHasLabel('edit-submit-test-exposed-form-buttons', t('Apply'));
}
/**
......@@ -296,7 +296,7 @@ public function testInputRequired() {
$this->drupalGet('test_exposed_form_buttons');
$this->assertResponse(200);
$this->helperButtonHasLabel('edit-submit-test-exposed-form-buttons', t('Filter'));
$this->helperButtonHasLabel('edit-submit-test-exposed-form-buttons', t('Apply'));
// Ensure that no results are displayed.
$rows = $this->xpath("//div[contains(@class, 'views-row')]");
......@@ -408,14 +408,14 @@ public function testFormErrorWithExposedForm() {
$this->assertResponse(200);
$form = $this->cssSelect('form.views-exposed-form');
$this->assertTrue($form, 'The exposed form element was found.');
$this->assertRaw(t('Filter'), 'Ensure the exposed form is rendered before submitting the normal form.');
$this->assertRaw(t('Apply'), 'Ensure the exposed form is rendered before submitting the normal form.');
$this->assertRaw('<div class="views-row">', 'Views result shown.');