faqfield-details-formatter.html.twig in FAQ Field 8
Same filename and directory in other branches
Default theme implementation of a FAQ Field details formatter.
Available variables:
- question: Prefiltered question value by check_plain.
- answer: Prefiltered answer value by field setting format.
- delta: Delta # of field element.
1 theme call to faqfield-details-formatter.html.twig
- FaqFieldDetailsFormatter::viewElements in src/
Plugin/ Field/ FieldFormatter/ FaqFieldDetailsFormatter.php - Builds a renderable array for a field value.
File
templates/faqfield-details-formatter.html.twigView source
- {#
- /**
- * @file
- * Default theme implementation of a FAQ Field details formatter.
- *
- * Available variables:
- * - question: Prefiltered question value by check_plain.
- * - answer: Prefiltered answer value by field setting format.
- * - delta: Delta # of field element.
- *
- * @see template_preprocess()
- * @see template_preprocess_faqfield_details_formatter()
- *
- * @ingroup themeable
- */
- #}
- {% spaceless %}
- <details class="faqfield-details">
- <summary class="faqfield-question">{{ question }}</summary>
- <div class="faqfield-answer">{{ answer }}</div>
- </details>
- {% endspaceless %}