📜  drupal 8 表单元素主题建议 - 任何代码示例

📅  最后修改于: 2022-03-11 15:00:24.253000             🧑  作者: Mango

代码示例1
function MYMODULE_theme_suggestions_form_element_alter(array &$suggestions, array $variables, $hook) {
  if ( $variables['element']['#id'] === 'FORMID') {
    $suggestions[] = $hook . '__custom';
  }
}