feature_toggle-2.0.x-dev/templates/feature-toggle-form.html.twig
templates/feature-toggle-form.html.twig
{# /** * @file * Default theme implementation for the features uninstall page. * * Available variables: * - form: The features uninstall form. * - features: Contains multiple feature instances. Each feature contains: * - attributes: Attributes on the row. * - feature_name: The name of the feature. * - checkbox: A checkbox for uninstalling the feature. * - checkbox_id: A unique identifier for interacting with the checkbox * element. * - label: The human-readable name of the feature. * * @see template_preprocess_feature_toggle_form() * * @ingroup themeable */ #} {{ form.filters }} <table class="responsive-enabled" data-striping="1"> <thead> <tr> <th>{{ 'Status'|t }}</th> <th>{{ 'Feature name'|t }}</th> <th>{{ 'Machine name'|t }}</th> <th>{{ 'Delete'|t }}</th> </tr> </thead> <tbody> {% for feature in features|sort((a, b) => a.label <=> b.label) %} {% set zebra = cycle(['odd', 'even'], loop.index0) -%} <tr{{ feature.attributes.addClass(zebra) }}> <td align="center"> {{- feature.checkbox -}} </td> <td> <label for="{{ feature.checkbox_id }}" class="feature-name table-filter-text-source">{{ feature.label }}</label> </td> <td> <span class="text feature-delete">{{ feature.feature_name }}</span> </td> <td class="delete"> <span class="text feature-delete">{{ feature.delete }}</span> </td> </tr> {% else %} <tr class="odd"> <td colspan="3" class="empty message">{{ 'No features are available to toggle.'|t }}</td> </tr> {% endfor %} </tbody> </table> {{ form|without('filters', 'features', 'status') }}