X-Git-Url: http://www.aleph1.co.uk/gitweb/?p=yaffs-website;a=blobdiff_plain;f=vendor%2Fchi-teck%2Fdrupal-code-generator%2Ftemplates%2Fd8%2Fhook%2Fsystem_themes_page_alter.twig;fp=vendor%2Fchi-teck%2Fdrupal-code-generator%2Ftemplates%2Fd8%2Fhook%2Fsystem_themes_page_alter.twig;h=dbc839207077f23c9a577e23d5d702ec953b8a64;hp=0000000000000000000000000000000000000000;hb=af6d1fb995500ae68849458ee10d66abbdcfb252;hpb=680c79a86e3ed402f263faeac92e89fb6d9edcc0 diff --git a/vendor/chi-teck/drupal-code-generator/templates/d8/hook/system_themes_page_alter.twig b/vendor/chi-teck/drupal-code-generator/templates/d8/hook/system_themes_page_alter.twig new file mode 100644 index 000000000..dbc839207 --- /dev/null +++ b/vendor/chi-teck/drupal-code-generator/templates/d8/hook/system_themes_page_alter.twig @@ -0,0 +1,15 @@ +/** + * Implements hook_system_themes_page_alter(). + */ +function {{ machine_name }}_system_themes_page_alter(&$theme_groups) { + foreach ($theme_groups as $state => &$group) { + foreach ($theme_groups[$state] as &$theme) { + // Add a foo link to each list of theme operations. + $theme->operations[] = [ + 'title' => t('Foo'), + 'url' => Url::fromRoute('system.themes_page'), + 'query' => ['theme' => $theme->getName()] + ]; + } + } +}