Issue #1898456 by joelpittet: Common_test().module - Convert theme_ functions to Twig.

8.0.x
Alex Pott 2013-06-17 01:19:04 +02:00
parent e89fbf339d
commit c5cecfde1d
2 changed files with 16 additions and 7 deletions

View File

@ -249,17 +249,11 @@ function common_test_theme() {
return array(
'common_test_foo' => array(
'variables' => array('foo' => 'foo', 'bar' => 'bar'),
'template' => 'common-test-foo',
),
);
}
/**
* Provides a theme function for drupal_render().
*/
function theme_common_test_foo($variables) {
return $variables['foo'] . $variables['bar'];
}
/**
* Implements hook_library_info_alter().
*/

View File

@ -0,0 +1,15 @@
{#
/**
* @file
* Default theme implementation for the common test foo.
*
* Available variables:
* - foo: foo.
* - bar: bar.
*
* @see template_preprocess()
*
* @ingroup themeable
*/
#}
{{ foo }}{{ bar -}}