You are here

function theme_rules_content_group in Rules 7.2

Themes a view of multiple configuration items.

3 theme calls to theme_rules_content_group()
RulesContainerPluginUI::buildContent in ui/ui.core.inc
Implements RulesPluginUIInterface.
RulesLoopUI::buildContent in ui/ui.plugins.inc
Implements RulesPluginUIInterface.
RulesPluginUI::buildContent in ui/ui.core.inc
Implements RulesPluginUIInterface.

File

ui/ui.theme.inc, line 120
Rules theme functions.

Code

function theme_rules_content_group($variables) {
  $element = $variables['element'];
  $output = array();
  foreach (element_children($element) as $key) {
    $output[] = drupal_render($element[$key]);
  }
  $output = array_filter($output);
  $heading = !empty($element['#caption']) ? "<span class='rules-content-heading'>" . $element['#caption'] . ': </span>' : '';
  if (!empty($output)) {
    $element['#attributes']['class'][] = 'rules-element-content-group';
    return '<div' . drupal_attributes($element['#attributes']) . '>' . $heading . implode(', ', $output) . '</div>';
  }
}