You are here

font.page.inc in Open Social 8

Contains font.page.inc.

Page callback for Font entities.

File

modules/custom/social_font/font.page.inc
View source
<?php

/**
 * @file
 * Contains font.page.inc.
 *
 * Page callback for Font entities.
 */
use Drupal\Core\Render\Element;

/**
 * Prepares variables for Font templates.
 *
 * Default template: font.html.twig.
 *
 * @param array $variables
 *   An associative array containing:
 *   - elements: An associative array containing the user information and any
 *   - attributes: HTML attributes for the containing element.
 */
function template_preprocess_font(array &$variables) {

  // Helpful $content variable for templates.
  foreach (Element::children($variables['elements']) as $key) {
    $variables['content'][$key] = $variables['elements'][$key];
  }
}

Functions

Namesort descending Description
template_preprocess_font Prepares variables for Font templates.