diff --git a/project_browser.module b/project_browser.module index df690ca547774bad1a07dc6e3419a8f53f2ac6ef..329bffad7f777351e4fce43a9772d5711300f7ab 100644 --- a/project_browser.module +++ b/project_browser.module @@ -51,7 +51,7 @@ function project_browser_project_browser_source_info_alter(array &$definitions): $definitions['recipes'] = [ 'id' => 'recipes', 'label' => t('Recipes'), - 'description' => t('Shows recipes available in the local code base.'), + 'description' => t('Recipes available in the local code base'), 'class' => Recipes::class, ]; } diff --git a/src/Plugin/ProjectBrowserSource/DrupalCore.php b/src/Plugin/ProjectBrowserSource/DrupalCore.php index 174def6dedbc9174655dee046de07a9960932a16..8c75a93e44f52ab321cd51e7bab12798fd26dbed 100644 --- a/src/Plugin/ProjectBrowserSource/DrupalCore.php +++ b/src/Plugin/ProjectBrowserSource/DrupalCore.php @@ -18,8 +18,8 @@ use Symfony\Component\HttpFoundation\RequestStack; * * @ProjectBrowserSource( * id = "drupal_core", - * label = @Translation("Core Modules"), - * description = @Translation("Gets core projects and filters information"), + * label = @Translation("Core modules"), + * description = @Translation("Modules included in Drupal core"), * ) */ class DrupalCore extends ProjectBrowserSourceBase { diff --git a/src/Plugin/ProjectBrowserSource/DrupalDotOrgJsonApi.php b/src/Plugin/ProjectBrowserSource/DrupalDotOrgJsonApi.php index 8b4ce57b1c937f0b2adbe641bc2bea6f462d7fb1..962eb26e38602be3cc29d57d0e4a65cfedfc28a4 100644 --- a/src/Plugin/ProjectBrowserSource/DrupalDotOrgJsonApi.php +++ b/src/Plugin/ProjectBrowserSource/DrupalDotOrgJsonApi.php @@ -28,7 +28,7 @@ use Symfony\Component\HttpFoundation\Response; * * @ProjectBrowserSource( * id = "drupalorg_jsonapi", - * label = @Translation("Contrib Modules"), + * label = @Translation("Contrib modules"), * description = @Translation("Modules on Drupal.org queried via the JSON:API endpoint"), * ) */ @@ -703,11 +703,11 @@ class DrupalDotOrgJsonApi extends ProjectBrowserSourceBase { return [ 'best_match' => [ 'id' => 'best_match', - 'text' => $this->t('Most Relevant'), + 'text' => $this->t('Most relevant'), ], 'created' => [ 'id' => 'created', - 'text' => $this->t('Newest First'), + 'text' => $this->t('Newest first'), ], ]; } diff --git a/src/Plugin/ProjectBrowserSourceBase.php b/src/Plugin/ProjectBrowserSourceBase.php index c63cbf98444fd0434f18b9dd18e8a75900e7d15e..17accd58ed36c2d083d71c366d8e0738253af5a5 100644 --- a/src/Plugin/ProjectBrowserSourceBase.php +++ b/src/Plugin/ProjectBrowserSourceBase.php @@ -58,7 +58,7 @@ abstract class ProjectBrowserSourceBase extends PluginBase implements ProjectBro return [ 'usage_total' => [ 'id' => 'usage_total', - 'text' => $this->t('Most Popular'), + 'text' => $this->t('Most popular'), ], 'a_z' => [ 'id' => 'a_z', @@ -70,11 +70,11 @@ abstract class ProjectBrowserSourceBase extends PluginBase implements ProjectBro ], 'created' => [ 'id' => 'created', - 'text' => $this->t('Newest First'), + 'text' => $this->t('Newest first'), ], 'best_match' => [ 'id' => 'best_match', - 'text' => $this->t('Most Relevant'), + 'text' => $this->t('Most relevant'), ], ]; } diff --git a/tests/src/FunctionalJavascript/ProjectBrowserUiTest.php b/tests/src/FunctionalJavascript/ProjectBrowserUiTest.php index cc06f8bf963d8cd67951e2cdaceb935a008b2d2d..3dfcfd068d486c0d6a204a9d899c87364e51118d 100644 --- a/tests/src/FunctionalJavascript/ProjectBrowserUiTest.php +++ b/tests/src/FunctionalJavascript/ProjectBrowserUiTest.php @@ -452,10 +452,10 @@ class ProjectBrowserUiTest extends WebDriverTestBase { $this->svelteInitHelper('text', 'Clear Filters'); $this->pressWithWait('Clear filters'); $assert_session->elementsCount('css', '#pb-sort option', 4); - $this->assertEquals('Most Popular', $this->getElementText('#pb-sort option:nth-child(1)')); + $this->assertEquals('Most popular', $this->getElementText('#pb-sort option:nth-child(1)')); $this->assertEquals('A-Z', $this->getElementText('#pb-sort option:nth-child(2)')); $this->assertEquals('Z-A', $this->getElementText('#pb-sort option:nth-child(3)')); - $this->assertEquals('Newest First', $this->getElementText('#pb-sort option:nth-child(4)')); + $this->assertEquals('Newest first', $this->getElementText('#pb-sort option:nth-child(4)')); // Select 'A-Z' sorting order. $this->sortBy('a_z');