- Issue created by @larowlan
- Status changed to Active
8 months ago 12:05am 15 February 2024 - Status changed to Postponed
8 months ago 12:10am 15 February 2024 - Status changed to Active
7 months ago 11:39am 13 March 2024 - ๐ฎ๐ณIndia Ruturaj Chaubey Pune, India
Ruturaj Chaubey โ made their first commit to this issueโs fork.
- Merge request !7035Issue/3421004: Convert ViewsPager plugin discovery to attributes. โ (Open) created by Ruturaj Chaubey
- Status changed to Needs review
7 months ago 6:22am 14 March 2024 - Status changed to Needs work
7 months ago 2:02pm 14 March 2024 - ๐บ๐ธUnited States smustgrave
Appears to have test failures
Why was it tagged for tests?
- First commit to issue fork.
- First commit to issue fork.
- Status changed to Needs review
7 months ago 9:09am 26 March 2024 - ๐ณ๐ฟNew Zealand quietone
In trying to figure out why the test was failing I notices that two of the plugins do not declare a theme. That means that 'register_theme' will be TRUE which makes no sense because there is no theme declared in the plugin. Therefore, this adds
register_theme: FALSE,
for those two plugins. - Status changed to RTBC
7 months ago 1:39pm 26 March 2024 - ๐บ๐ธUnited States smustgrave
Great investigative work @quietone!
I'm seeing that fixed all the tests and searched the repo and all 4 instances of @ViewsPager have been replaced.
I made 1 small nitpicky change adding "class-" to the driver.
- Status changed to Needs work
7 months ago 1:58pm 26 March 2024 - ๐ฌ๐งUnited Kingdom alexpott ๐ช๐บ๐
$theme has the wrong default value - causing the problems with register theme.
- ๐ฌ๐งUnited Kingdom alexpott ๐ช๐บ๐
Here are the current definitions for none and some... let's not change register_theme. It'll be work once the attribute as a theme value set to NULL rather than an empty string. Which makes more sense anyways.
"none" => [ "parent" => "parent", "plugin_type" => "pager", "register_theme" => true, "title" => Drupal\Core\StringTranslation\TranslatableMarkup {#7635}, "short_title" => "", "help" => Drupal\Core\StringTranslation\TranslatableMarkup {#7645}, "id" => "none", "display_types" => [ "basic", ], "class" => "Drupal\views\Plugin\views\pager\None", "provider" => "views", ], "some" => [ "parent" => "parent", "plugin_type" => "pager", "register_theme" => true, "title" => Drupal\Core\StringTranslation\TranslatableMarkup {#7647}, "short_title" => "", "help" => Drupal\Core\StringTranslation\TranslatableMarkup {#7648}, "id" => "some", "display_types" => [ "basic", ], "class" => "Drupal\views\Plugin\views\pager\Some", "provider" => "views", ],
- Status changed to Needs review
7 months ago 12:32am 27 March 2024 - ๐ณ๐ฟNew Zealand quietone
@alexpott, thanks for the changes. I thought I had changed $theme to NULL and tested before I went on holiday. I guess I was wrong about that. Maybe I should have tried again.
Changes made, tests are passing. So back to needs review.
- Status changed to RTBC
7 months ago 1:54pm 28 March 2024 - ๐บ๐ธUnited States smustgrave
So " vs ' I don't think there is a standard for that right?
I see for example #[ViewsRow are using " but #[ViewsArgument used '
Most appear to be using " but if a follow up is needed to fix #[ViewsArgument then we should maybe make it inline too right?
#[ViewsArgument("node_type")]
vs
#[ViewsArgument( id: 'node_type', )]
But changes here look good.
- ๐ฌ๐งUnited Kingdom alexpott ๐ช๐บ๐
Committed and pushed 0eca710d8b to 11.x and 95bfc525bd to 10.3.x. Thanks!
diff --git a/core/modules/views/src/Attribute/ViewsPager.php b/core/modules/views/src/Attribute/ViewsPager.php index 0c222c4e03..2a19944ced 100644 --- a/core/modules/views/src/Attribute/ViewsPager.php +++ b/core/modules/views/src/Attribute/ViewsPager.php @@ -20,14 +20,14 @@ class ViewsPager extends Plugin { * * @param string $id * The plugin ID. - * @param \Drupal\Core\StringTranslation\TranslatableMarkup|null $title + * @param \Drupal\Core\StringTranslation\TranslatableMarkup $title * The plugin title used in the views UI. * @param \Drupal\Core\StringTranslation\TranslatableMarkup|null $short_title * (optional) The short title used in the views UI. * @param \Drupal\Core\StringTranslation\TranslatableMarkup|null $help * (optional) A short help string; this is displayed in the views UI. * @param string|null $theme - * The theme function used to render the pager's output. + * (optional) The theme function used to render the pager's output. * @param string[]|null $display_types * (optional) The types of the display this plugin can be used with. * For example the Feed display defines the type 'feed', so only rss style
Fixed on commit.
-
alexpott โ
committed 95bfc525 on 10.3.x
Issue #3421004 by Ruturaj Chaubey, sorlov, quietone, smustgrave,...
-
alexpott โ
committed 95bfc525 on 10.3.x
- Status changed to Fixed
7 months ago 10:01am 29 March 2024 -
alexpott โ
committed 0eca710d on 11.x
Issue #3421004 by Ruturaj Chaubey, sorlov, quietone, smustgrave,...
-
alexpott โ
committed 0eca710d on 11.x
Automatically closed - issue fixed for 2 weeks with no activity.