analog_digital_clock-9.1.x-dev/analog_digital_clock.module

analog_digital_clock.module
<?php

/**
 * @file
 * This file is used to write hooks that used in the module.
 */

use Drupal\Core\Routing\RouteMatchInterface;

/**
 * Hook_theme used to add theme to custom block.
 */
function analog_digital_clock_theme() {

  return [
    'analogDigitalLightDarkSkin' => [
      'variables' => ['analog_digital_clock_selected_skin' => NULL],
    ],
  ];
}

/**
 * Implements hook_help().
 */
function analog_digital_clock_help($route_name, RouteMatchInterface $route_match) {
  switch ($route_name) {
    case 'help.page.analog_digital_clock':
      $output = '';
      $output .= '<h3>' . t('About') . '</h3>';
      $output .= '<p>' . t('This module offering a simple Block that display time with different skin. This will use default system time.') . '</br>';
      $output .= '' . t('You can configure clock skin from configuration page.') . '</br>';
      $output .= '<h3>' . t('Skins are as follow.') . '</h3></br>';
      $output .= '1. ' . t('Simple digital clock with date') . '</br>';
      $output .= '2. ' . t('24 hr Digital clock with date') . '</br>';
      $output .= '3. ' . t('Analog clock') . '</br>';
      $output .= '4. ' . t('Animated digital clock') . '</p>';
      return $output;

    default:

  }
}

Главная | Обратная связь

drupal hosting | друпал хостинг | it patrol .inc