You are here

function bootstrap4_modal_help in Bootstrap 4 Modal 8

Same name and namespace in other branches
  1. 2.x bootstrap4_modal.module \bootstrap4_modal_help()

Implements hook_help().

File

./bootstrap4_modal.module, line 14
Contains bootstrap4_modal.module.

Code

function bootstrap4_modal_help($route_name, RouteMatchInterface $route_match) {
  switch ($route_name) {
    case 'help.page.bootstrap4_modal':
      $output = '';
      $output .= '<h3>' . t('About') . '</h3>';
      $output .= '<p>' . t('Bootstrap 4 Modal provides bootstrap 4 modal to be loaded like the core ajax dialog') . '</p>';
      $output .= '<h3>' . t('Uses') . '</h3>';
      $output .= '<dl>';
      $output .= '<dt>' . t('Loading ajax pages to a dialog') . '</dt>';
      $output .= '<dd>' . t('This module, and the core ajax dialog provides a dialog using Bootstrap 4 modal. It is recommended to use this theme if you are using a Bootstrap 4 based theme.') . '</dd>';
      $output .= '<dt>' . t('Sample usage') . '</dt>';
      $output .= '<dd><code>' . Html::escape('<a href="[some-links]" class="use-ajax" data-dialog-type="bootstrap4_modal" data-dialog-options="{&quot;dialogClasses&quot;:&quot;modal-dialog-centered&quot;,&quot;dialogShowHeader&quot;:false}">Open in Bootstrap 4 Modal</a>') . '</code></dd>';
      $output .= '</dl>';
      return $output;
  }
}