En Joomla le template bootstrap4/5 que j'ai personnalisé permet d'afficher un bouton lire la suite et commentaire.
J'ai trouvé comment avoir l'équivalent en Drupal :
Making everything buttons in Drupal 8 with Bootstrap 4 | by Sarah Carney | Medium
Il faut mettre à jour le fichier theme du style : pour moi le fichier bootstrap5custom
/**
* Implements hook_preprocess_links().
*/
function bootstrap5custom_preprocess_links(&$variables) {
$variables['links']['node-readmore']['link']['#options']['attributes']['class'][] = 'btn btn-sm btn-secondary';
$variables['links']['comment-comments']['link']['#options']['attributes']['class'][] = 'btn btn-sm btn-secondary';
$variables['links']['comment-add']['link']['#options']['attributes']['class'][] = 'btn btn-sm btn-primary';
$variables['links']['comment-delete']['link']['#options']['attributes']['class'][] = 'btn btn-sm btn-secondary';
$variables['links']['comment-edit']['link']['#options']['attributes']['class'][] = 'btn btn-sm btn-secondary';
$variables['links']['comment-reply']['link']['#options']['attributes']['class'][] = 'btn btn-sm btn-secondary';
/* Book */
$variables['links']['book_printer']['link']['#options']['attributes']['class'][] = 'btn btn-sm btn-secondary';
$variables['links']['book_add_child']['link']['#options']['attributes']['class'][] = 'btn btn-sm btn-secondary';
}
Ajouter un commentaire