diff --git a/web/modules/custom/github_feed/github_feed.module b/web/modules/custom/github_feed/github_feed.module index 86b95d8cdb6991188a4d37e747246297e38e83aa..b302dbaa4925557fca2b43550e9fecd53da537dc 100644 --- a/web/modules/custom/github_feed/github_feed.module +++ b/web/modules/custom/github_feed/github_feed.module @@ -15,7 +15,7 @@ function github_feed_theme(array $existing, string $type, string $theme, string 'github_feed' => [ 'variables' => [ 'url' => NULL, - 'type' => NULL, + 'feed_type' => NULL, 'items' => NULL, ], ], @@ -52,7 +52,7 @@ function github_feed_theme(array $existing, string $type, string $theme, string * Implements template_preprocess_HOOK(). */ function template_preprocess_github_feed(array &$variables): void { - switch ($variables['type']) { + switch ($variables['feed_type']) { case 'issue': $variables['type_parsed'] = t('Issues'); $variables['icon_id'] = 'info-circle'; diff --git a/web/modules/custom/github_feed/src/Plugin/Field/FieldFormatter/GitHubFeedDefaultFormatter.php b/web/modules/custom/github_feed/src/Plugin/Field/FieldFormatter/GitHubFeedDefaultFormatter.php index 9aeb6b962f6df6c1a10f3e3818a4a0b29d086d78..1138a5ef043548aa4d2ef5036c46ec5592210e05 100644 --- a/web/modules/custom/github_feed/src/Plugin/Field/FieldFormatter/GitHubFeedDefaultFormatter.php +++ b/web/modules/custom/github_feed/src/Plugin/Field/FieldFormatter/GitHubFeedDefaultFormatter.php @@ -90,7 +90,7 @@ public function viewElements(FieldItemListInterface $items, $langcode): array { $element[$delta] = [ '#theme' => 'github_feed', '#url' => $item->repository, - '#type' => $item->type, + '#feed_type' => $item->type, '#cache' => [ 'max-age' => $this->getFieldSetting('cache_max_age'), ], diff --git a/web/modules/custom/github_feed/templates/github-feed.html.twig b/web/modules/custom/github_feed/templates/github-feed.html.twig index a61e624509f9db860f6a2a639178e04976c9e56a..b762dfe8ede0288fc01103607104ce1bfd5200e2 100644 --- a/web/modules/custom/github_feed/templates/github-feed.html.twig +++ b/web/modules/custom/github_feed/templates/github-feed.html.twig @@ -3,7 +3,7 @@ * Variables: * - items: The feed object. * - url: The url of the feed. - * - type: The type of the feed. + * - feed_type: The type of the feed. #} <div class="github-feed"> <h3>{{ "Items of type"|t }} "{{ type_parsed }}" {{ "from"|t }} {{ url }}:</h3> diff --git a/web/themes/ventuno/templates/github_feed/github-feed.html.twig b/web/themes/ventuno/templates/github_feed/github-feed.html.twig index e7d3bf41c62df532b9d5db24c0856173f1f4c43b..1b4fa06e341d1330fd0beb594dcbfdc508260086 100644 --- a/web/themes/ventuno/templates/github_feed/github-feed.html.twig +++ b/web/themes/ventuno/templates/github_feed/github-feed.html.twig @@ -3,7 +3,7 @@ * Variables: * - items: The feed object. * - url: The url of the feed. - * - type: The type of the feed. + * - feed_type: The type of the feed. #} <div class="github-feed mb-4"> <h4 class="mb-3">