diff --git a/core/modules/system/css/system.theme.css b/core/modules/system/css/system.theme.css index f397a5a..01ee3d1 100644 --- a/core/modules/system/css/system.theme.css +++ b/core/modules/system/css/system.theme.css @@ -124,6 +124,7 @@ abbr.form-required, abbr.tabledrag-changed, abbr.ajax-changed { * Markup generated by theme_more_link(). */ .more-link { + display: block; text-align: right; /* LTR */ } [dir="rtl"] .more-link { diff --git a/core/modules/views/lib/Drupal/views/Tests/Plugin/DisplayTest.php b/core/modules/views/lib/Drupal/views/Tests/Plugin/DisplayTest.php index 5a284d8..a99bfcd 100644 --- a/core/modules/views/lib/Drupal/views/Tests/Plugin/DisplayTest.php +++ b/core/modules/views/lib/Drupal/views/Tests/Plugin/DisplayTest.php @@ -182,7 +182,7 @@ public function testReadMore() { $output = drupal_render($output); $this->drupalSetContent($output); - $result = $this->xpath('//div[@class=:class]/a', array(':class' => 'more-link')); + $result = $this->xpath('//a[@class=:class]', array(':class' => 'more-link')); $this->assertEqual($result[0]->attributes()->href, url('test_display_more'), 'The right more link is shown.'); $this->assertEqual(trim($result[0][0]), $expected_more_text, 'The right link text is shown.'); @@ -191,7 +191,7 @@ public function testReadMore() { $more_link = $view->display_handler->renderMoreLink(); $more_link = drupal_render($more_link); $this->drupalSetContent($more_link); - $result = $this->xpath('//div[@class=:class]/a', array(':class' => 'more-link')); + $result = $this->xpath('//a[@class=:class]', array(':class' => 'more-link')); $this->assertEqual($result[0]->attributes()->href, url('test_display_more'), 'The right more link is shown.'); $this->assertEqual(trim($result[0][0]), $expected_more_text, 'The right link text is shown.'); @@ -207,7 +207,7 @@ public function testReadMore() { $output = $view->preview(); $output = drupal_render($output); $this->drupalSetContent($output); - $result = $this->xpath('//div[@class=:class]/a', array(':class' => 'more-link')); + $result = $this->xpath('//a[@class=:class]', array(':class' => 'more-link')); $this->assertTrue(empty($result), 'The more link is not shown.'); $view = Views::getView('test_display_more'); @@ -225,7 +225,7 @@ public function testReadMore() { $output = $view->preview(); $output = drupal_render($output); $this->drupalSetContent($output); - $result = $this->xpath('//div[@class=:class]/a', array(':class' => 'more-link')); + $result = $this->xpath('//a[@class=:class]', array(':class' => 'more-link')); $this->assertTrue(empty($result), 'The more link is not shown when view has more records.'); // Test the default value of use_more_always. diff --git a/core/modules/views/templates/views-more.html.twig b/core/modules/views/templates/views-more.html.twig index c92b849..b161a65 100644 --- a/core/modules/views/templates/views-more.html.twig +++ b/core/modules/views/templates/views-more.html.twig @@ -11,8 +11,4 @@ * @ingroup themeable */ #} - +{{ link_text }}